summaryrefslogtreecommitdiffstats
path: root/gl/m4/stdint.m4
diff options
context:
space:
mode:
Diffstat (limited to 'gl/m4/stdint.m4')
-rw-r--r--gl/m4/stdint.m418
1 files changed, 11 insertions, 7 deletions
diff --git a/gl/m4/stdint.m4 b/gl/m4/stdint.m4
index d6961b0..2dea846 100644
--- a/gl/m4/stdint.m4
+++ b/gl/m4/stdint.m4
@@ -1,5 +1,6 @@
1# stdint.m4 serial 61 1# stdint.m4
2dnl Copyright (C) 2001-2023 Free Software Foundation, Inc. 2# serial 63
3dnl Copyright (C) 2001-2024 Free Software Foundation, Inc.
3dnl This file is free software; the Free Software Foundation 4dnl This file is free software; the Free Software Foundation
4dnl gives unlimited permission to copy and/or distribute it, 5dnl gives unlimited permission to copy and/or distribute it,
5dnl with or without modifications, as long as this notice is preserved. 6dnl with or without modifications, as long as this notice is preserved.
@@ -150,7 +151,10 @@ intmax_t i = INTMAX_MAX;
150uintmax_t j = UINTMAX_MAX; 151uintmax_t j = UINTMAX_MAX;
151 152
152/* Check that SIZE_MAX has the correct type, if possible. */ 153/* Check that SIZE_MAX has the correct type, if possible. */
153#if 201112 <= __STDC_VERSION__ 154/* ISO C 11 mandates _Generic, but GCC versions < 4.9 lack it. */
155#if 201112 <= __STDC_VERSION__ \
156 && (!defined __GNUC__ || 4 < __GNUC__ + (9 <= __GNUC_MINOR__) \
157 || defined __clang__)
154int k = _Generic (SIZE_MAX, size_t: 0); 158int k = _Generic (SIZE_MAX, size_t: 0);
155#elif (2 <= __GNUC__ || 4 <= __clang_major__ || defined __IBM__TYPEOF__ \ 159#elif (2 <= __GNUC__ || 4 <= __clang_major__ || defined __IBM__TYPEOF__ \
156 || (0x5110 <= __SUNPRO_C && !__STDC__)) 160 || (0x5110 <= __SUNPRO_C && !__STDC__))
@@ -283,10 +287,10 @@ static const char *macro_values[] =
283 [gl_cv_header_working_stdint_h=yes], 287 [gl_cv_header_working_stdint_h=yes],
284 [], 288 [],
285 [case "$host_os" in 289 [case "$host_os" in
286 # Guess yes on native Windows. 290 # Guess yes on native Windows.
287 mingw*) gl_cv_header_working_stdint_h="guessing yes" ;; 291 mingw* | windows*) gl_cv_header_working_stdint_h="guessing yes" ;;
288 # In general, assume it works. 292 # In general, assume it works.
289 *) gl_cv_header_working_stdint_h="guessing yes" ;; 293 *) gl_cv_header_working_stdint_h="guessing yes" ;;
290 esac 294 esac
291 ]) 295 ])
292 ]) 296 ])