From: Bruno Haible Date: Wed, 12 Aug 2026 10:14:51 +0000 (+0200) Subject: hamt: Fix compilation error on MSVC (regression 2026-08-10). X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b2bb0c2fc03c0d9408dcbcb88d4e280d3eea4391;p=thirdparty%2Fgnulib.git hamt: Fix compilation error on MSVC (regression 2026-08-10). * lib/hamt.h (HAVE_C11__ATOMIC): Add parentheses to #if expression. --- diff --git a/ChangeLog b/ChangeLog index 2f90aa99c3..b4916c518e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2026-08-12 Bruno Haible + + hamt: Fix compilation error on MSVC (regression 2026-08-10). + * lib/hamt.h (HAVE_C11__ATOMIC): Add parentheses to #if expression. + 2026-08-12 Bruno Haible hamt: Fix compilation error (regression 2026-08-10). diff --git a/lib/hamt.h b/lib/hamt.h index 8430313811..0e4ccc603e 100644 --- a/lib/hamt.h +++ b/lib/hamt.h @@ -68,13 +68,14 @@ _GL_INLINE_HEADER_BEGIN #ifndef HAVE_C11__ATOMIC # if (!defined __STDC_NO_ATOMICS__ && !defined __cplusplus \ && (defined __apple_build_version__ ? 8000000 <= __apple_build_version__ \ - : defined __clang__ ? 4 <= __clang_major__ \ - : defined _MSC_VER ? 1935 <= _MSC_VER \ - : defined __NVCOMPILER \ - ? 21 < __NVCOMPILER_MAJOR__ + (3 <= __NVCOMPILER_MINOR__) \ - : defined __GNUC__ ? 4 < __GNUC__ + (9 <= __GNUC_MINOR__) \ - : (!defined __xlC__ && !defined __PGI \ - && defined __STDC_VERSION__ && 201112 <= __STDC_VERSION__))) + : (defined __clang__ ? 4 <= __clang_major__ \ + : (defined _MSC_VER ? 1935 <= _MSC_VER \ + : (defined __NVCOMPILER \ + ? 21 < __NVCOMPILER_MAJOR__ + (3 <= __NVCOMPILER_MINOR__) \ + : (defined __GNUC__ ? 4 < __GNUC__ + (9 <= __GNUC_MINOR__) \ + : (!defined __xlC__ && !defined __PGI \ + && defined __STDC_VERSION__ \ + && 201112 <= __STDC_VERSION__))))))) # define HAVE_C11__ATOMIC 1 # else # define HAVE_C11__ATOMIC 0