update devspec.en_US/1.0.general.md.
[devspec.git] / devspec.en_US / project / recutils / lib / stdint.h
blobbc902c781ce31842e9b1306f55358b4481b217f2
1 /* DO NOT EDIT! GENERATED AUTOMATICALLY! */
2 /* Copyright (C) 2001-2002, 2004-2019 Free Software Foundation, Inc.
3 Written by Paul Eggert, Bruno Haible, Sam Steingold, Peter Burwood.
4 This file is part of gnulib.
6 This program is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 3, or (at your option)
9 any later version.
11 This program is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, see <https://www.gnu.org/licenses/>. */
20 * ISO C 99 <stdint.h> for platforms that lack it.
21 * <http://www.opengroup.org/susv3xbd/stdint.h.html>
24 #ifndef _GL_STDINT_H
26 #if __GNUC__ >= 3
27 #pragma GCC system_header
28 #endif
31 /* When including a system file that in turn includes <inttypes.h>,
32 use the system <inttypes.h>, not our substitute. This avoids
33 problems with (for example) VMS, whose <sys/bitypes.h> includes
34 <inttypes.h>. */
35 #define _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H
37 /* On Android (Bionic libc), <sys/types.h> includes this file before
38 having defined 'time_t'. Therefore in this case avoid including
39 other system header files; just include the system's <stdint.h>.
40 Ideally we should test __BIONIC__ here, but it is only defined after
41 <sys/cdefs.h> has been included; hence test __ANDROID__ instead. */
42 #if defined __ANDROID__ && defined _GL_INCLUDING_SYS_TYPES_H
43 # include_next <stdint.h>
44 #else
46 /* Get those types that are already defined in other system include
47 files, so that we can "#define int8_t signed char" below without
48 worrying about a later system include file containing a "typedef
49 signed char int8_t;" that will get messed up by our macro. Our
50 macros should all be consistent with the system versions, except
51 for the "fast" types and macros, which we recommend against using
52 in public interfaces due to compiler differences. */
54 #if 1
55 # if defined __sgi && ! defined __c99
56 /* Bypass IRIX's <stdint.h> if in C89 mode, since it merely annoys users
57 with "This header file is to be used only for c99 mode compilations"
58 diagnostics. */
59 # define __STDINT_H__
60 # endif
62 /* Some pre-C++11 <stdint.h> implementations need this. */
63 # ifdef __cplusplus
64 # ifndef __STDC_CONSTANT_MACROS
65 # define __STDC_CONSTANT_MACROS 1
66 # endif
67 # ifndef __STDC_LIMIT_MACROS
68 # define __STDC_LIMIT_MACROS 1
69 # endif
70 # endif
72 /* Other systems may have an incomplete or buggy <stdint.h>.
73 Include it before <inttypes.h>, since any "#include <stdint.h>"
74 in <inttypes.h> would reinclude us, skipping our contents because
75 _GL_STDINT_H is defined.
76 The include_next requires a split double-inclusion guard. */
77 # include_next <stdint.h>
78 #endif
80 #if ! defined _GL_STDINT_H && ! defined _GL_JUST_INCLUDE_SYSTEM_STDINT_H
81 #define _GL_STDINT_H
83 /* Get SCHAR_MIN, SCHAR_MAX, UCHAR_MAX, INT_MIN, INT_MAX,
84 LONG_MIN, LONG_MAX, ULONG_MAX, _GL_INTEGER_WIDTH. */
85 #include <limits.h>
87 /* Override WINT_MIN and WINT_MAX if gnulib's <wchar.h> or <wctype.h> overrides
88 wint_t. */
89 #if 0
90 # undef WINT_MIN
91 # undef WINT_MAX
92 # define WINT_MIN 0x0U
93 # define WINT_MAX 0xffffffffU
94 #endif
96 #if ! 1
98 /* <sys/types.h> defines some of the stdint.h types as well, on glibc,
99 IRIX 6.5, and OpenBSD 3.8 (via <machine/types.h>).
100 AIX 5.2 <sys/types.h> isn't needed and causes troubles.
101 Mac OS X 10.4.6 <sys/types.h> includes <stdint.h> (which is us), but
102 relies on the system <stdint.h> definitions, so include
103 <sys/types.h> after <stdint.h>. */
104 # if 1 && ! defined _AIX
105 # include <sys/types.h>
106 # endif
108 # if 1
109 /* In OpenBSD 3.8, <inttypes.h> includes <machine/types.h>, which defines
110 int{8,16,32,64}_t, uint{8,16,32,64}_t and __BIT_TYPES_DEFINED__.
111 <inttypes.h> also defines intptr_t and uintptr_t. */
112 # include <inttypes.h>
113 # elif 0
114 /* Solaris 7 <sys/inttypes.h> has the types except the *_fast*_t types, and
115 the macros except for *_FAST*_*, INTPTR_MIN, PTRDIFF_MIN, PTRDIFF_MAX. */
116 # include <sys/inttypes.h>
117 # endif
119 # if 0 && ! defined __BIT_TYPES_DEFINED__
120 /* Linux libc4 >= 4.6.7 and libc5 have a <sys/bitypes.h> that defines
121 int{8,16,32,64}_t and __BIT_TYPES_DEFINED__. In libc5 >= 5.2.2 it is
122 included by <sys/types.h>. */
123 # include <sys/bitypes.h>
124 # endif
126 # undef _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H
128 /* Minimum and maximum values for an integer type under the usual assumption.
129 Return an unspecified value if BITS == 0, adding a check to pacify
130 picky compilers. */
132 /* These are separate macros, because if you try to merge these macros into
133 a single one, HP-UX cc rejects the resulting expression in constant
134 expressions. */
135 # define _STDINT_UNSIGNED_MIN(bits, zero) \
136 (zero)
137 # define _STDINT_SIGNED_MIN(bits, zero) \
138 (~ _STDINT_MAX (1, bits, zero))
140 # define _STDINT_MAX(signed, bits, zero) \
141 (((((zero) + 1) << ((bits) ? (bits) - 1 - (signed) : 0)) - 1) * 2 + 1)
143 #if !GNULIB_defined_stdint_types
145 /* 7.18.1.1. Exact-width integer types */
147 /* Here we assume a standard architecture where the hardware integer
148 types have 8, 16, 32, optionally 64 bits. */
150 # undef int8_t
151 # undef uint8_t
152 typedef signed char gl_int8_t;
153 typedef unsigned char gl_uint8_t;
154 # define int8_t gl_int8_t
155 # define uint8_t gl_uint8_t
157 # undef int16_t
158 # undef uint16_t
159 typedef short int gl_int16_t;
160 typedef unsigned short int gl_uint16_t;
161 # define int16_t gl_int16_t
162 # define uint16_t gl_uint16_t
164 # undef int32_t
165 # undef uint32_t
166 typedef int gl_int32_t;
167 typedef unsigned int gl_uint32_t;
168 # define int32_t gl_int32_t
169 # define uint32_t gl_uint32_t
171 /* If the system defines INT64_MAX, assume int64_t works. That way,
172 if the underlying platform defines int64_t to be a 64-bit long long
173 int, the code below won't mistakenly define it to be a 64-bit long
174 int, which would mess up C++ name mangling. We must use #ifdef
175 rather than #if, to avoid an error with HP-UX 10.20 cc. */
177 # ifdef INT64_MAX
178 # define GL_INT64_T
179 # else
180 /* Do not undefine int64_t if gnulib is not being used with 64-bit
181 types, since otherwise it breaks platforms like Tandem/NSK. */
182 # if LONG_MAX >> 31 >> 31 == 1
183 # undef int64_t
184 typedef long int gl_int64_t;
185 # define int64_t gl_int64_t
186 # define GL_INT64_T
187 # elif defined _MSC_VER
188 # undef int64_t
189 typedef __int64 gl_int64_t;
190 # define int64_t gl_int64_t
191 # define GL_INT64_T
192 # elif 1
193 # undef int64_t
194 typedef long long int gl_int64_t;
195 # define int64_t gl_int64_t
196 # define GL_INT64_T
197 # endif
198 # endif
200 # ifdef UINT64_MAX
201 # define GL_UINT64_T
202 # else
203 # if ULONG_MAX >> 31 >> 31 >> 1 == 1
204 # undef uint64_t
205 typedef unsigned long int gl_uint64_t;
206 # define uint64_t gl_uint64_t
207 # define GL_UINT64_T
208 # elif defined _MSC_VER
209 # undef uint64_t
210 typedef unsigned __int64 gl_uint64_t;
211 # define uint64_t gl_uint64_t
212 # define GL_UINT64_T
213 # elif 1
214 # undef uint64_t
215 typedef unsigned long long int gl_uint64_t;
216 # define uint64_t gl_uint64_t
217 # define GL_UINT64_T
218 # endif
219 # endif
221 /* Avoid collision with Solaris 2.5.1 <pthread.h> etc. */
222 # define _UINT8_T
223 # define _UINT32_T
224 # define _UINT64_T
227 /* 7.18.1.2. Minimum-width integer types */
229 /* Here we assume a standard architecture where the hardware integer
230 types have 8, 16, 32, optionally 64 bits. Therefore the leastN_t types
231 are the same as the corresponding N_t types. */
233 # undef int_least8_t
234 # undef uint_least8_t
235 # undef int_least16_t
236 # undef uint_least16_t
237 # undef int_least32_t
238 # undef uint_least32_t
239 # undef int_least64_t
240 # undef uint_least64_t
241 # define int_least8_t int8_t
242 # define uint_least8_t uint8_t
243 # define int_least16_t int16_t
244 # define uint_least16_t uint16_t
245 # define int_least32_t int32_t
246 # define uint_least32_t uint32_t
247 # ifdef GL_INT64_T
248 # define int_least64_t int64_t
249 # endif
250 # ifdef GL_UINT64_T
251 # define uint_least64_t uint64_t
252 # endif
254 /* 7.18.1.3. Fastest minimum-width integer types */
256 /* Note: Other <stdint.h> substitutes may define these types differently.
257 It is not recommended to use these types in public header files. */
259 /* Here we assume a standard architecture where the hardware integer
260 types have 8, 16, 32, optionally 64 bits. Therefore the fastN_t types
261 are taken from the same list of types. The following code normally
262 uses types consistent with glibc, as that lessens the chance of
263 incompatibility with older GNU hosts. */
265 # undef int_fast8_t
266 # undef uint_fast8_t
267 # undef int_fast16_t
268 # undef uint_fast16_t
269 # undef int_fast32_t
270 # undef uint_fast32_t
271 # undef int_fast64_t
272 # undef uint_fast64_t
273 typedef signed char gl_int_fast8_t;
274 typedef unsigned char gl_uint_fast8_t;
276 # ifdef __sun
277 /* Define types compatible with SunOS 5.10, so that code compiled under
278 earlier SunOS versions works with code compiled under SunOS 5.10. */
279 typedef int gl_int_fast32_t;
280 typedef unsigned int gl_uint_fast32_t;
281 # else
282 typedef long int gl_int_fast32_t;
283 typedef unsigned long int gl_uint_fast32_t;
284 # endif
285 typedef gl_int_fast32_t gl_int_fast16_t;
286 typedef gl_uint_fast32_t gl_uint_fast16_t;
288 # define int_fast8_t gl_int_fast8_t
289 # define uint_fast8_t gl_uint_fast8_t
290 # define int_fast16_t gl_int_fast16_t
291 # define uint_fast16_t gl_uint_fast16_t
292 # define int_fast32_t gl_int_fast32_t
293 # define uint_fast32_t gl_uint_fast32_t
294 # ifdef GL_INT64_T
295 # define int_fast64_t int64_t
296 # endif
297 # ifdef GL_UINT64_T
298 # define uint_fast64_t uint64_t
299 # endif
301 /* 7.18.1.4. Integer types capable of holding object pointers */
303 /* kLIBC's stdint.h defines _INTPTR_T_DECLARED and needs its own
304 definitions of intptr_t and uintptr_t (which use int and unsigned)
305 to avoid clashes with declarations of system functions like sbrk. */
306 # ifndef _INTPTR_T_DECLARED
307 # undef intptr_t
308 # undef uintptr_t
309 typedef long int gl_intptr_t;
310 typedef unsigned long int gl_uintptr_t;
311 # define intptr_t gl_intptr_t
312 # define uintptr_t gl_uintptr_t
313 # endif
315 /* 7.18.1.5. Greatest-width integer types */
317 /* Note: These types are compiler dependent. It may be unwise to use them in
318 public header files. */
320 /* If the system defines INTMAX_MAX, assume that intmax_t works, and
321 similarly for UINTMAX_MAX and uintmax_t. This avoids problems with
322 assuming one type where another is used by the system. */
324 # ifndef INTMAX_MAX
325 # undef INTMAX_C
326 # undef intmax_t
327 # if 1 && LONG_MAX >> 30 == 1
328 typedef long long int gl_intmax_t;
329 # define intmax_t gl_intmax_t
330 # elif defined GL_INT64_T
331 # define intmax_t int64_t
332 # else
333 typedef long int gl_intmax_t;
334 # define intmax_t gl_intmax_t
335 # endif
336 # endif
338 # ifndef UINTMAX_MAX
339 # undef UINTMAX_C
340 # undef uintmax_t
341 # if 1 && ULONG_MAX >> 31 == 1
342 typedef unsigned long long int gl_uintmax_t;
343 # define uintmax_t gl_uintmax_t
344 # elif defined GL_UINT64_T
345 # define uintmax_t uint64_t
346 # else
347 typedef unsigned long int gl_uintmax_t;
348 # define uintmax_t gl_uintmax_t
349 # endif
350 # endif
352 /* Verify that intmax_t and uintmax_t have the same size. Too much code
353 breaks if this is not the case. If this check fails, the reason is likely
354 to be found in the autoconf macros. */
355 typedef int _verify_intmax_size[sizeof (intmax_t) == sizeof (uintmax_t)
356 ? 1 : -1];
358 # define GNULIB_defined_stdint_types 1
359 # endif /* !GNULIB_defined_stdint_types */
361 /* 7.18.2. Limits of specified-width integer types */
363 /* 7.18.2.1. Limits of exact-width integer types */
365 /* Here we assume a standard architecture where the hardware integer
366 types have 8, 16, 32, optionally 64 bits. */
368 # undef INT8_MIN
369 # undef INT8_MAX
370 # undef UINT8_MAX
371 # define INT8_MIN (~ INT8_MAX)
372 # define INT8_MAX 127
373 # define UINT8_MAX 255
375 # undef INT16_MIN
376 # undef INT16_MAX
377 # undef UINT16_MAX
378 # define INT16_MIN (~ INT16_MAX)
379 # define INT16_MAX 32767
380 # define UINT16_MAX 65535
382 # undef INT32_MIN
383 # undef INT32_MAX
384 # undef UINT32_MAX
385 # define INT32_MIN (~ INT32_MAX)
386 # define INT32_MAX 2147483647
387 # define UINT32_MAX 4294967295U
389 # if defined GL_INT64_T && ! defined INT64_MAX
390 /* Prefer (- INTMAX_C (1) << 63) over (~ INT64_MAX) because SunPRO C 5.0
391 evaluates the latter incorrectly in preprocessor expressions. */
392 # define INT64_MIN (- INTMAX_C (1) << 63)
393 # define INT64_MAX INTMAX_C (9223372036854775807)
394 # endif
396 # if defined GL_UINT64_T && ! defined UINT64_MAX
397 # define UINT64_MAX UINTMAX_C (18446744073709551615)
398 # endif
400 /* 7.18.2.2. Limits of minimum-width integer types */
402 /* Here we assume a standard architecture where the hardware integer
403 types have 8, 16, 32, optionally 64 bits. Therefore the leastN_t types
404 are the same as the corresponding N_t types. */
406 # undef INT_LEAST8_MIN
407 # undef INT_LEAST8_MAX
408 # undef UINT_LEAST8_MAX
409 # define INT_LEAST8_MIN INT8_MIN
410 # define INT_LEAST8_MAX INT8_MAX
411 # define UINT_LEAST8_MAX UINT8_MAX
413 # undef INT_LEAST16_MIN
414 # undef INT_LEAST16_MAX
415 # undef UINT_LEAST16_MAX
416 # define INT_LEAST16_MIN INT16_MIN
417 # define INT_LEAST16_MAX INT16_MAX
418 # define UINT_LEAST16_MAX UINT16_MAX
420 # undef INT_LEAST32_MIN
421 # undef INT_LEAST32_MAX
422 # undef UINT_LEAST32_MAX
423 # define INT_LEAST32_MIN INT32_MIN
424 # define INT_LEAST32_MAX INT32_MAX
425 # define UINT_LEAST32_MAX UINT32_MAX
427 # undef INT_LEAST64_MIN
428 # undef INT_LEAST64_MAX
429 # ifdef GL_INT64_T
430 # define INT_LEAST64_MIN INT64_MIN
431 # define INT_LEAST64_MAX INT64_MAX
432 # endif
434 # undef UINT_LEAST64_MAX
435 # ifdef GL_UINT64_T
436 # define UINT_LEAST64_MAX UINT64_MAX
437 # endif
439 /* 7.18.2.3. Limits of fastest minimum-width integer types */
441 /* Here we assume a standard architecture where the hardware integer
442 types have 8, 16, 32, optionally 64 bits. Therefore the fastN_t types
443 are taken from the same list of types. */
445 # undef INT_FAST8_MIN
446 # undef INT_FAST8_MAX
447 # undef UINT_FAST8_MAX
448 # define INT_FAST8_MIN SCHAR_MIN
449 # define INT_FAST8_MAX SCHAR_MAX
450 # define UINT_FAST8_MAX UCHAR_MAX
452 # undef INT_FAST16_MIN
453 # undef INT_FAST16_MAX
454 # undef UINT_FAST16_MAX
455 # define INT_FAST16_MIN INT_FAST32_MIN
456 # define INT_FAST16_MAX INT_FAST32_MAX
457 # define UINT_FAST16_MAX UINT_FAST32_MAX
459 # undef INT_FAST32_MIN
460 # undef INT_FAST32_MAX
461 # undef UINT_FAST32_MAX
462 # ifdef __sun
463 # define INT_FAST32_MIN INT_MIN
464 # define INT_FAST32_MAX INT_MAX
465 # define UINT_FAST32_MAX UINT_MAX
466 # else
467 # define INT_FAST32_MIN LONG_MIN
468 # define INT_FAST32_MAX LONG_MAX
469 # define UINT_FAST32_MAX ULONG_MAX
470 # endif
472 # undef INT_FAST64_MIN
473 # undef INT_FAST64_MAX
474 # ifdef GL_INT64_T
475 # define INT_FAST64_MIN INT64_MIN
476 # define INT_FAST64_MAX INT64_MAX
477 # endif
479 # undef UINT_FAST64_MAX
480 # ifdef GL_UINT64_T
481 # define UINT_FAST64_MAX UINT64_MAX
482 # endif
484 /* 7.18.2.4. Limits of integer types capable of holding object pointers */
486 # undef INTPTR_MIN
487 # undef INTPTR_MAX
488 # undef UINTPTR_MAX
489 # define INTPTR_MIN LONG_MIN
490 # define INTPTR_MAX LONG_MAX
491 # define UINTPTR_MAX ULONG_MAX
493 /* 7.18.2.5. Limits of greatest-width integer types */
495 # ifndef INTMAX_MAX
496 # undef INTMAX_MIN
497 # ifdef INT64_MAX
498 # define INTMAX_MIN INT64_MIN
499 # define INTMAX_MAX INT64_MAX
500 # else
501 # define INTMAX_MIN INT32_MIN
502 # define INTMAX_MAX INT32_MAX
503 # endif
504 # endif
506 # ifndef UINTMAX_MAX
507 # ifdef UINT64_MAX
508 # define UINTMAX_MAX UINT64_MAX
509 # else
510 # define UINTMAX_MAX UINT32_MAX
511 # endif
512 # endif
514 /* 7.18.3. Limits of other integer types */
516 /* ptrdiff_t limits */
517 # undef PTRDIFF_MIN
518 # undef PTRDIFF_MAX
519 # if 0
520 # ifdef _LP64
521 # define PTRDIFF_MIN _STDINT_SIGNED_MIN (64, 0l)
522 # define PTRDIFF_MAX _STDINT_MAX (1, 64, 0l)
523 # else
524 # define PTRDIFF_MIN _STDINT_SIGNED_MIN (32, 0)
525 # define PTRDIFF_MAX _STDINT_MAX (1, 32, 0)
526 # endif
527 # else
528 # define PTRDIFF_MIN \
529 _STDINT_SIGNED_MIN (, 0)
530 # define PTRDIFF_MAX \
531 _STDINT_MAX (1, , 0)
532 # endif
534 /* sig_atomic_t limits */
535 # undef SIG_ATOMIC_MIN
536 # undef SIG_ATOMIC_MAX
537 # if
538 # define SIG_ATOMIC_MIN \
539 _STDINT_SIGNED_MIN (, 0)
540 # else
541 # define SIG_ATOMIC_MIN \
542 _STDINT_UNSIGNED_MIN (, 0)
543 # endif
544 # define SIG_ATOMIC_MAX \
545 _STDINT_MAX (, , \
549 /* size_t limit */
550 # undef SIZE_MAX
551 # if 0
552 # ifdef _LP64
553 # define SIZE_MAX _STDINT_MAX (0, 64, 0ul)
554 # else
555 # define SIZE_MAX _STDINT_MAX (0, 32, 0ul)
556 # endif
557 # else
558 # define SIZE_MAX _STDINT_MAX (0, , 0)
559 # endif
561 /* wchar_t limits */
562 /* Get WCHAR_MIN, WCHAR_MAX.
563 This include is not on the top, above, because on OSF/1 4.0 we have a
564 sequence of nested includes
565 <wchar.h> -> <stdio.h> -> <getopt.h> -> <stdlib.h>, and the latter includes
566 <stdint.h> and assumes its types are already defined. */
567 # if 1 && ! (defined WCHAR_MIN && defined WCHAR_MAX)
568 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
569 included before <wchar.h>. */
570 # include <stddef.h>
571 # include <stdio.h>
572 # include <time.h>
573 # define _GL_JUST_INCLUDE_SYSTEM_WCHAR_H
574 # include <wchar.h>
575 # undef _GL_JUST_INCLUDE_SYSTEM_WCHAR_H
576 # endif
577 # undef WCHAR_MIN
578 # undef WCHAR_MAX
579 # if
580 # define WCHAR_MIN \
581 _STDINT_SIGNED_MIN (, 0)
582 # else
583 # define WCHAR_MIN \
584 _STDINT_UNSIGNED_MIN (, 0)
585 # endif
586 # define WCHAR_MAX \
587 _STDINT_MAX (, , 0)
589 /* wint_t limits */
590 # undef WINT_MIN
591 # undef WINT_MAX
592 # if
593 # define WINT_MIN \
594 _STDINT_SIGNED_MIN (, 0)
595 # else
596 # define WINT_MIN \
597 _STDINT_UNSIGNED_MIN (, 0)
598 # endif
599 # define WINT_MAX \
600 _STDINT_MAX (, , 0)
602 /* 7.18.4. Macros for integer constants */
604 /* 7.18.4.1. Macros for minimum-width integer constants */
605 /* According to ISO C 99 Technical Corrigendum 1 */
607 /* Here we assume a standard architecture where the hardware integer
608 types have 8, 16, 32, optionally 64 bits, and int is 32 bits. */
610 # undef INT8_C
611 # undef UINT8_C
612 # define INT8_C(x) x
613 # define UINT8_C(x) x
615 # undef INT16_C
616 # undef UINT16_C
617 # define INT16_C(x) x
618 # define UINT16_C(x) x
620 # undef INT32_C
621 # undef UINT32_C
622 # define INT32_C(x) x
623 # define UINT32_C(x) x ## U
625 # undef INT64_C
626 # undef UINT64_C
627 # if LONG_MAX >> 31 >> 31 == 1
628 # define INT64_C(x) x##L
629 # elif defined _MSC_VER
630 # define INT64_C(x) x##i64
631 # elif 1
632 # define INT64_C(x) x##LL
633 # endif
634 # if ULONG_MAX >> 31 >> 31 >> 1 == 1
635 # define UINT64_C(x) x##UL
636 # elif defined _MSC_VER
637 # define UINT64_C(x) x##ui64
638 # elif 1
639 # define UINT64_C(x) x##ULL
640 # endif
642 /* 7.18.4.2. Macros for greatest-width integer constants */
644 # ifndef INTMAX_C
645 # if 1 && LONG_MAX >> 30 == 1
646 # define INTMAX_C(x) x##LL
647 # elif defined GL_INT64_T
648 # define INTMAX_C(x) INT64_C(x)
649 # else
650 # define INTMAX_C(x) x##L
651 # endif
652 # endif
654 # ifndef UINTMAX_C
655 # if 1 && ULONG_MAX >> 31 == 1
656 # define UINTMAX_C(x) x##ULL
657 # elif defined GL_UINT64_T
658 # define UINTMAX_C(x) UINT64_C(x)
659 # else
660 # define UINTMAX_C(x) x##UL
661 # endif
662 # endif
664 #endif /* !1 */
666 /* Macros specified by ISO/IEC TS 18661-1:2014. */
668 #if (!defined UINTMAX_WIDTH \
669 && (defined _GNU_SOURCE || defined __STDC_WANT_IEC_60559_BFP_EXT__))
670 # ifdef INT8_MAX
671 # define INT8_WIDTH _GL_INTEGER_WIDTH (INT8_MIN, INT8_MAX)
672 # endif
673 # ifdef UINT8_MAX
674 # define UINT8_WIDTH _GL_INTEGER_WIDTH (0, UINT8_MAX)
675 # endif
676 # ifdef INT16_MAX
677 # define INT16_WIDTH _GL_INTEGER_WIDTH (INT16_MIN, INT16_MAX)
678 # endif
679 # ifdef UINT16_MAX
680 # define UINT16_WIDTH _GL_INTEGER_WIDTH (0, UINT16_MAX)
681 # endif
682 # ifdef INT32_MAX
683 # define INT32_WIDTH _GL_INTEGER_WIDTH (INT32_MIN, INT32_MAX)
684 # endif
685 # ifdef UINT32_MAX
686 # define UINT32_WIDTH _GL_INTEGER_WIDTH (0, UINT32_MAX)
687 # endif
688 # ifdef INT64_MAX
689 # define INT64_WIDTH _GL_INTEGER_WIDTH (INT64_MIN, INT64_MAX)
690 # endif
691 # ifdef UINT64_MAX
692 # define UINT64_WIDTH _GL_INTEGER_WIDTH (0, UINT64_MAX)
693 # endif
694 # define INT_LEAST8_WIDTH _GL_INTEGER_WIDTH (INT_LEAST8_MIN, INT_LEAST8_MAX)
695 # define UINT_LEAST8_WIDTH _GL_INTEGER_WIDTH (0, UINT_LEAST8_MAX)
696 # define INT_LEAST16_WIDTH _GL_INTEGER_WIDTH (INT_LEAST16_MIN, INT_LEAST16_MAX)
697 # define UINT_LEAST16_WIDTH _GL_INTEGER_WIDTH (0, UINT_LEAST16_MAX)
698 # define INT_LEAST32_WIDTH _GL_INTEGER_WIDTH (INT_LEAST32_MIN, INT_LEAST32_MAX)
699 # define UINT_LEAST32_WIDTH _GL_INTEGER_WIDTH (0, UINT_LEAST32_MAX)
700 # define INT_LEAST64_WIDTH _GL_INTEGER_WIDTH (INT_LEAST64_MIN, INT_LEAST64_MAX)
701 # define UINT_LEAST64_WIDTH _GL_INTEGER_WIDTH (0, UINT_LEAST64_MAX)
702 # define INT_FAST8_WIDTH _GL_INTEGER_WIDTH (INT_FAST8_MIN, INT_FAST8_MAX)
703 # define UINT_FAST8_WIDTH _GL_INTEGER_WIDTH (0, UINT_FAST8_MAX)
704 # define INT_FAST16_WIDTH _GL_INTEGER_WIDTH (INT_FAST16_MIN, INT_FAST16_MAX)
705 # define UINT_FAST16_WIDTH _GL_INTEGER_WIDTH (0, UINT_FAST16_MAX)
706 # define INT_FAST32_WIDTH _GL_INTEGER_WIDTH (INT_FAST32_MIN, INT_FAST32_MAX)
707 # define UINT_FAST32_WIDTH _GL_INTEGER_WIDTH (0, UINT_FAST32_MAX)
708 # define INT_FAST64_WIDTH _GL_INTEGER_WIDTH (INT_FAST64_MIN, INT_FAST64_MAX)
709 # define UINT_FAST64_WIDTH _GL_INTEGER_WIDTH (0, UINT_FAST64_MAX)
710 # define INTPTR_WIDTH _GL_INTEGER_WIDTH (INTPTR_MIN, INTPTR_MAX)
711 # define UINTPTR_WIDTH _GL_INTEGER_WIDTH (0, UINTPTR_MAX)
712 # define INTMAX_WIDTH _GL_INTEGER_WIDTH (INTMAX_MIN, INTMAX_MAX)
713 # define UINTMAX_WIDTH _GL_INTEGER_WIDTH (0, UINTMAX_MAX)
714 # define PTRDIFF_WIDTH _GL_INTEGER_WIDTH (PTRDIFF_MIN, PTRDIFF_MAX)
715 # define SIZE_WIDTH _GL_INTEGER_WIDTH (0, SIZE_MAX)
716 # define WCHAR_WIDTH _GL_INTEGER_WIDTH (WCHAR_MIN, WCHAR_MAX)
717 # ifdef WINT_MAX
718 # define WINT_WIDTH _GL_INTEGER_WIDTH (WINT_MIN, WINT_MAX)
719 # endif
720 # ifdef SIG_ATOMIC_MAX
721 # define SIG_ATOMIC_WIDTH _GL_INTEGER_WIDTH (SIG_ATOMIC_MIN, SIG_ATOMIC_MAX)
722 # endif
723 #endif /* !WINT_WIDTH && (_GNU_SOURCE || __STDC_WANT_IEC_60559_BFP_EXT__) */
725 #endif /* _GL_STDINT_H */
726 #endif /* !(defined __ANDROID__ && ...) */
727 #endif /* !defined _GL_STDINT_H && !defined _GL_JUST_INCLUDE_SYSTEM_STDINT_H */