1 /* DO NOT EDIT! GENERATED AUTOMATICALLY! */
2 /* Copyright (C) 2006-2015 Free Software Foundation, Inc.
3    Written by Paul Eggert, Bruno Haible, Derek Price.
4    This file is part of gnulib.
5 
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 of the License, or
9    (at your option) any later version.
10 
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.
15 
16    You should have received a copy of the GNU General Public License
17    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
18 
19 /*
20  * ISO C 99 <inttypes.h> for platforms that lack it.
21  * <http://www.opengroup.org/susv3xbd/inttypes.h.html>
22  */
23 
24 #if __GNUC__ >= 3
25 #pragma GCC system_header
26 #endif
27 
28 
29 /* Include the original <inttypes.h> if it exists, and if this file
30    has not been included yet or if this file includes gnulib stdint.h
31    which in turn includes this file.
32    The include_next requires a split double-inclusion guard.  */
33 #if ! defined INTTYPES_H || defined _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H
34 # if 1
35 
36    /* Some pre-C++11 <stdint.h> implementations need this.  */
37 #  if defined __cplusplus && ! defined __STDC_FORMAT_MACROS
38 #   define __STDC_FORMAT_MACROS 1
39 #  endif
40 
41 #  include_next <inttypes.h>
42 # endif
43 #endif
44 
45 #if ! defined INTTYPES_H && ! defined _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H
46 #define INTTYPES_H
47 
48 /* Include <stdint.h> or the gnulib replacement.
49    But avoid namespace pollution on glibc systems.  */
50 #ifndef __GLIBC__
51 # include <stdint.h>
52 #endif
53 /* Get CHAR_BIT.  */
54 #include <limits.h>
55 /* On mingw, __USE_MINGW_ANSI_STDIO only works if <stdio.h> is also included */
56 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
57 # include <stdio.h>
58 #endif
59 
60 #if !(INT_MIN == INT32_MIN && INT_MAX == INT32_MAX)
61 # error "This file assumes that 'int' has exactly 32 bits. Please report your platform and compiler to <bug-gnulib@gnu.org>."
62 #endif
63 
64 /* The definitions of _GL_FUNCDECL_RPL etc. are copied here.  */
65 #ifndef _GL_CXXDEFS_H
66 #define _GL_CXXDEFS_H
67 
68 /* The three most frequent use cases of these macros are:
69 
70    * For providing a substitute for a function that is missing on some
71      platforms, but is declared and works fine on the platforms on which
72      it exists:
73 
74        #if @GNULIB_FOO@
75        # if !@HAVE_FOO@
76        _GL_FUNCDECL_SYS (foo, ...);
77        # endif
78        _GL_CXXALIAS_SYS (foo, ...);
79        _GL_CXXALIASWARN (foo);
80        #elif defined GNULIB_POSIXCHECK
81        ...
82        #endif
83 
84    * For providing a replacement for a function that exists on all platforms,
85      but is broken/insufficient and needs to be replaced on some platforms:
86 
87        #if @GNULIB_FOO@
88        # if @REPLACE_FOO@
89        #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
90        #   undef foo
91        #   define foo rpl_foo
92        #  endif
93        _GL_FUNCDECL_RPL (foo, ...);
94        _GL_CXXALIAS_RPL (foo, ...);
95        # else
96        _GL_CXXALIAS_SYS (foo, ...);
97        # endif
98        _GL_CXXALIASWARN (foo);
99        #elif defined GNULIB_POSIXCHECK
100        ...
101        #endif
102 
103    * For providing a replacement for a function that exists on some platforms
104      but is broken/insufficient and needs to be replaced on some of them and
105      is additionally either missing or undeclared on some other platforms:
106 
107        #if @GNULIB_FOO@
108        # if @REPLACE_FOO@
109        #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
110        #   undef foo
111        #   define foo rpl_foo
112        #  endif
113        _GL_FUNCDECL_RPL (foo, ...);
114        _GL_CXXALIAS_RPL (foo, ...);
115        # else
116        #  if !@HAVE_FOO@   or   if !@HAVE_DECL_FOO@
117        _GL_FUNCDECL_SYS (foo, ...);
118        #  endif
119        _GL_CXXALIAS_SYS (foo, ...);
120        # endif
121        _GL_CXXALIASWARN (foo);
122        #elif defined GNULIB_POSIXCHECK
123        ...
124        #endif
125 */
126 
127 /* _GL_EXTERN_C declaration;
128    performs the declaration with C linkage.  */
129 #if defined __cplusplus
130 # define _GL_EXTERN_C extern "C"
131 #else
132 # define _GL_EXTERN_C extern
133 #endif
134 
135 /* _GL_FUNCDECL_RPL (func, rettype, parameters_and_attributes);
136    declares a replacement function, named rpl_func, with the given prototype,
137    consisting of return type, parameters, and attributes.
138    Example:
139      _GL_FUNCDECL_RPL (open, int, (const char *filename, int flags, ...)
140                                   _GL_ARG_NONNULL ((1)));
141  */
142 #define _GL_FUNCDECL_RPL(func,rettype,parameters_and_attributes) \
143   _GL_FUNCDECL_RPL_1 (rpl_##func, rettype, parameters_and_attributes)
144 #define _GL_FUNCDECL_RPL_1(rpl_func,rettype,parameters_and_attributes) \
145   _GL_EXTERN_C rettype rpl_func parameters_and_attributes
146 
147 /* _GL_FUNCDECL_SYS (func, rettype, parameters_and_attributes);
148    declares the system function, named func, with the given prototype,
149    consisting of return type, parameters, and attributes.
150    Example:
151      _GL_FUNCDECL_SYS (open, int, (const char *filename, int flags, ...)
152                                   _GL_ARG_NONNULL ((1)));
153  */
154 #define _GL_FUNCDECL_SYS(func,rettype,parameters_and_attributes) \
155   _GL_EXTERN_C rettype func parameters_and_attributes
156 
157 /* _GL_CXXALIAS_RPL (func, rettype, parameters);
158    declares a C++ alias called GNULIB_NAMESPACE::func
159    that redirects to rpl_func, if GNULIB_NAMESPACE is defined.
160    Example:
161      _GL_CXXALIAS_RPL (open, int, (const char *filename, int flags, ...));
162  */
163 #define _GL_CXXALIAS_RPL(func,rettype,parameters) \
164   _GL_CXXALIAS_RPL_1 (func, rpl_##func, rettype, parameters)
165 #if defined __cplusplus && defined GNULIB_NAMESPACE
166 # define _GL_CXXALIAS_RPL_1(func,rpl_func,rettype,parameters) \
167     namespace GNULIB_NAMESPACE                                \
168     {                                                         \
169       rettype (*const func) parameters = ::rpl_func;          \
170     }                                                         \
171     _GL_EXTERN_C int _gl_cxxalias_dummy
172 #else
173 # define _GL_CXXALIAS_RPL_1(func,rpl_func,rettype,parameters) \
174     _GL_EXTERN_C int _gl_cxxalias_dummy
175 #endif
176 
177 /* _GL_CXXALIAS_RPL_CAST_1 (func, rpl_func, rettype, parameters);
178    is like  _GL_CXXALIAS_RPL_1 (func, rpl_func, rettype, parameters);
179    except that the C function rpl_func may have a slightly different
180    declaration.  A cast is used to silence the "invalid conversion" error
181    that would otherwise occur.  */
182 #if defined __cplusplus && defined GNULIB_NAMESPACE
183 # define _GL_CXXALIAS_RPL_CAST_1(func,rpl_func,rettype,parameters) \
184     namespace GNULIB_NAMESPACE                                     \
185     {                                                              \
186       rettype (*const func) parameters =                           \
187         reinterpret_cast<rettype(*)parameters>(::rpl_func);        \
188     }                                                              \
189     _GL_EXTERN_C int _gl_cxxalias_dummy
190 #else
191 # define _GL_CXXALIAS_RPL_CAST_1(func,rpl_func,rettype,parameters) \
192     _GL_EXTERN_C int _gl_cxxalias_dummy
193 #endif
194 
195 /* _GL_CXXALIAS_SYS (func, rettype, parameters);
196    declares a C++ alias called GNULIB_NAMESPACE::func
197    that redirects to the system provided function func, if GNULIB_NAMESPACE
198    is defined.
199    Example:
200      _GL_CXXALIAS_SYS (open, int, (const char *filename, int flags, ...));
201  */
202 #if defined __cplusplus && defined GNULIB_NAMESPACE
203   /* If we were to write
204        rettype (*const func) parameters = ::func;
205      like above in _GL_CXXALIAS_RPL_1, the compiler could optimize calls
206      better (remove an indirection through a 'static' pointer variable),
207      but then the _GL_CXXALIASWARN macro below would cause a warning not only
208      for uses of ::func but also for uses of GNULIB_NAMESPACE::func.  */
209 # define _GL_CXXALIAS_SYS(func,rettype,parameters) \
210     namespace GNULIB_NAMESPACE                     \
211     {                                              \
212       static rettype (*func) parameters = ::func;  \
213     }                                              \
214     _GL_EXTERN_C int _gl_cxxalias_dummy
215 #else
216 # define _GL_CXXALIAS_SYS(func,rettype,parameters) \
217     _GL_EXTERN_C int _gl_cxxalias_dummy
218 #endif
219 
220 /* _GL_CXXALIAS_SYS_CAST (func, rettype, parameters);
221    is like  _GL_CXXALIAS_SYS (func, rettype, parameters);
222    except that the C function func may have a slightly different declaration.
223    A cast is used to silence the "invalid conversion" error that would
224    otherwise occur.  */
225 #if defined __cplusplus && defined GNULIB_NAMESPACE
226 # define _GL_CXXALIAS_SYS_CAST(func,rettype,parameters) \
227     namespace GNULIB_NAMESPACE                          \
228     {                                                   \
229       static rettype (*func) parameters =               \
230         reinterpret_cast<rettype(*)parameters>(::func); \
231     }                                                   \
232     _GL_EXTERN_C int _gl_cxxalias_dummy
233 #else
234 # define _GL_CXXALIAS_SYS_CAST(func,rettype,parameters) \
235     _GL_EXTERN_C int _gl_cxxalias_dummy
236 #endif
237 
238 /* _GL_CXXALIAS_SYS_CAST2 (func, rettype, parameters, rettype2, parameters2);
239    is like  _GL_CXXALIAS_SYS (func, rettype, parameters);
240    except that the C function is picked among a set of overloaded functions,
241    namely the one with rettype2 and parameters2.  Two consecutive casts
242    are used to silence the "cannot find a match" and "invalid conversion"
243    errors that would otherwise occur.  */
244 #if defined __cplusplus && defined GNULIB_NAMESPACE
245   /* The outer cast must be a reinterpret_cast.
246      The inner cast: When the function is defined as a set of overloaded
247      functions, it works as a static_cast<>, choosing the designated variant.
248      When the function is defined as a single variant, it works as a
249      reinterpret_cast<>. The parenthesized cast syntax works both ways.  */
250 # define _GL_CXXALIAS_SYS_CAST2(func,rettype,parameters,rettype2,parameters2) \
251     namespace GNULIB_NAMESPACE                                                \
252     {                                                                         \
253       static rettype (*func) parameters =                                     \
254         reinterpret_cast<rettype(*)parameters>(                               \
255           (rettype2(*)parameters2)(::func));                                  \
256     }                                                                         \
257     _GL_EXTERN_C int _gl_cxxalias_dummy
258 #else
259 # define _GL_CXXALIAS_SYS_CAST2(func,rettype,parameters,rettype2,parameters2) \
260     _GL_EXTERN_C int _gl_cxxalias_dummy
261 #endif
262 
263 /* _GL_CXXALIASWARN (func);
264    causes a warning to be emitted when ::func is used but not when
265    GNULIB_NAMESPACE::func is used.  func must be defined without overloaded
266    variants.  */
267 #if defined __cplusplus && defined GNULIB_NAMESPACE
268 # define _GL_CXXALIASWARN(func) \
269    _GL_CXXALIASWARN_1 (func, GNULIB_NAMESPACE)
270 # define _GL_CXXALIASWARN_1(func,namespace) \
271    _GL_CXXALIASWARN_2 (func, namespace)
272 /* To work around GCC bug <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43881>,
273    we enable the warning only when not optimizing.  */
274 # if !__OPTIMIZE__
275 #  define _GL_CXXALIASWARN_2(func,namespace) \
276     _GL_WARN_ON_USE (func, \
277                      "The symbol ::" #func " refers to the system function. " \
278                      "Use " #namespace "::" #func " instead.")
279 # elif __GNUC__ >= 3 && GNULIB_STRICT_CHECKING
280 #  define _GL_CXXALIASWARN_2(func,namespace) \
281      extern __typeof__ (func) func
282 # else
283 #  define _GL_CXXALIASWARN_2(func,namespace) \
284      _GL_EXTERN_C int _gl_cxxalias_dummy
285 # endif
286 #else
287 # define _GL_CXXALIASWARN(func) \
288     _GL_EXTERN_C int _gl_cxxalias_dummy
289 #endif
290 
291 /* _GL_CXXALIASWARN1 (func, rettype, parameters_and_attributes);
292    causes a warning to be emitted when the given overloaded variant of ::func
293    is used but not when GNULIB_NAMESPACE::func is used.  */
294 #if defined __cplusplus && defined GNULIB_NAMESPACE
295 # define _GL_CXXALIASWARN1(func,rettype,parameters_and_attributes) \
296    _GL_CXXALIASWARN1_1 (func, rettype, parameters_and_attributes, \
297                         GNULIB_NAMESPACE)
298 # define _GL_CXXALIASWARN1_1(func,rettype,parameters_and_attributes,namespace) \
299    _GL_CXXALIASWARN1_2 (func, rettype, parameters_and_attributes, namespace)
300 /* To work around GCC bug <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43881>,
301    we enable the warning only when not optimizing.  */
302 # if !__OPTIMIZE__
303 #  define _GL_CXXALIASWARN1_2(func,rettype,parameters_and_attributes,namespace) \
304     _GL_WARN_ON_USE_CXX (func, rettype, parameters_and_attributes, \
305                          "The symbol ::" #func " refers to the system function. " \
306                          "Use " #namespace "::" #func " instead.")
307 # elif __GNUC__ >= 3 && GNULIB_STRICT_CHECKING
308 #  define _GL_CXXALIASWARN1_2(func,rettype,parameters_and_attributes,namespace) \
309      extern __typeof__ (func) func
310 # else
311 #  define _GL_CXXALIASWARN1_2(func,rettype,parameters_and_attributes,namespace) \
312      _GL_EXTERN_C int _gl_cxxalias_dummy
313 # endif
314 #else
315 # define _GL_CXXALIASWARN1(func,rettype,parameters_and_attributes) \
316     _GL_EXTERN_C int _gl_cxxalias_dummy
317 #endif
318 
319 #endif /* _GL_CXXDEFS_H */
320 
321 /* The definition of _GL_ARG_NONNULL is copied here.  */
322 /* _GL_ARG_NONNULL((n,...,m)) tells the compiler and static analyzer tools
323    that the values passed as arguments n, ..., m must be non-NULL pointers.
324    n = 1 stands for the first argument, n = 2 for the second argument etc.  */
325 #ifndef _GL_ARG_NONNULL
326 # if (__GNUC__ == 3 && __GNUC_MINOR__ >= 3) || __GNUC__ > 3
327 #  define _GL_ARG_NONNULL(params) __attribute__ ((__nonnull__ params))
328 # else
329 #  define _GL_ARG_NONNULL(params)
330 # endif
331 #endif
332 
333 /* The definition of _GL_WARN_ON_USE is copied here.  */
334 #ifndef _GL_WARN_ON_USE
335 
336 # if 4 < __GNUC__ || (__GNUC__ == 4 && 3 <= __GNUC_MINOR__)
337 /* A compiler attribute is available in gcc versions 4.3.0 and later.  */
338 #  define _GL_WARN_ON_USE(function, message) \
339 extern __typeof__ (function) function __attribute__ ((__warning__ (message)))
340 # elif __GNUC__ >= 3 && GNULIB_STRICT_CHECKING
341 /* Verify the existence of the function.  */
342 #  define _GL_WARN_ON_USE(function, message) \
343 extern __typeof__ (function) function
344 # else /* Unsupported.  */
345 #  define _GL_WARN_ON_USE(function, message) \
346 _GL_WARN_EXTERN_C int _gl_warn_on_use
347 # endif
348 #endif
349 
350 /* _GL_WARN_ON_USE_CXX (function, rettype, parameters_and_attributes, "string")
351    is like _GL_WARN_ON_USE (function, "string"), except that the function is
352    declared with the given prototype, consisting of return type, parameters,
353    and attributes.
354    This variant is useful for overloaded functions in C++. _GL_WARN_ON_USE does
355    not work in this case.  */
356 #ifndef _GL_WARN_ON_USE_CXX
357 # if 4 < __GNUC__ || (__GNUC__ == 4 && 3 <= __GNUC_MINOR__)
358 #  define _GL_WARN_ON_USE_CXX(function,rettype,parameters_and_attributes,msg) \
359 extern rettype function parameters_and_attributes \
360      __attribute__ ((__warning__ (msg)))
361 # elif __GNUC__ >= 3 && GNULIB_STRICT_CHECKING
362 /* Verify the existence of the function.  */
363 #  define _GL_WARN_ON_USE_CXX(function,rettype,parameters_and_attributes,msg) \
364 extern rettype function parameters_and_attributes
365 # else /* Unsupported.  */
366 #  define _GL_WARN_ON_USE_CXX(function,rettype,parameters_and_attributes,msg) \
367 _GL_WARN_EXTERN_C int _gl_warn_on_use
368 # endif
369 #endif
370 
371 /* _GL_WARN_EXTERN_C declaration;
372    performs the declaration with C linkage.  */
373 #ifndef _GL_WARN_EXTERN_C
374 # if defined __cplusplus
375 #  define _GL_WARN_EXTERN_C extern "C"
376 # else
377 #  define _GL_WARN_EXTERN_C extern
378 # endif
379 #endif
380 
381 /* 7.8.1 Macros for format specifiers */
382 
383 #if defined _TNS_R_TARGET
384    /* Tandem NonStop R series and compatible platforms released before
385       July 2005 support %Ld but not %lld.  */
386 # define _LONG_LONG_FORMAT_PREFIX "L"
387 #else
388 # define _LONG_LONG_FORMAT_PREFIX "ll"
389 #endif
390 
391 #if !defined PRId8 || 0
392 # undef PRId8
393 # ifdef INT8_MAX
394 #  define PRId8 "d"
395 # endif
396 #endif
397 #if !defined PRIi8 || 0
398 # undef PRIi8
399 # ifdef INT8_MAX
400 #  define PRIi8 "i"
401 # endif
402 #endif
403 #if !defined PRIo8 || 0
404 # undef PRIo8
405 # ifdef UINT8_MAX
406 #  define PRIo8 "o"
407 # endif
408 #endif
409 #if !defined PRIu8 || 0
410 # undef PRIu8
411 # ifdef UINT8_MAX
412 #  define PRIu8 "u"
413 # endif
414 #endif
415 #if !defined PRIx8 || 0
416 # undef PRIx8
417 # ifdef UINT8_MAX
418 #  define PRIx8 "x"
419 # endif
420 #endif
421 #if !defined PRIX8 || 0
422 # undef PRIX8
423 # ifdef UINT8_MAX
424 #  define PRIX8 "X"
425 # endif
426 #endif
427 #if !defined PRId16 || 0
428 # undef PRId16
429 # ifdef INT16_MAX
430 #  define PRId16 "d"
431 # endif
432 #endif
433 #if !defined PRIi16 || 0
434 # undef PRIi16
435 # ifdef INT16_MAX
436 #  define PRIi16 "i"
437 # endif
438 #endif
439 #if !defined PRIo16 || 0
440 # undef PRIo16
441 # ifdef UINT16_MAX
442 #  define PRIo16 "o"
443 # endif
444 #endif
445 #if !defined PRIu16 || 0
446 # undef PRIu16
447 # ifdef UINT16_MAX
448 #  define PRIu16 "u"
449 # endif
450 #endif
451 #if !defined PRIx16 || 0
452 # undef PRIx16
453 # ifdef UINT16_MAX
454 #  define PRIx16 "x"
455 # endif
456 #endif
457 #if !defined PRIX16 || 0
458 # undef PRIX16
459 # ifdef UINT16_MAX
460 #  define PRIX16 "X"
461 # endif
462 #endif
463 #if !defined PRId32 || 0
464 # undef PRId32
465 # ifdef INT32_MAX
466 #  define PRId32 "d"
467 # endif
468 #endif
469 #if !defined PRIi32 || 0
470 # undef PRIi32
471 # ifdef INT32_MAX
472 #  define PRIi32 "i"
473 # endif
474 #endif
475 #if !defined PRIo32 || 0
476 # undef PRIo32
477 # ifdef UINT32_MAX
478 #  define PRIo32 "o"
479 # endif
480 #endif
481 #if !defined PRIu32 || 0
482 # undef PRIu32
483 # ifdef UINT32_MAX
484 #  define PRIu32 "u"
485 # endif
486 #endif
487 #if !defined PRIx32 || 0
488 # undef PRIx32
489 # ifdef UINT32_MAX
490 #  define PRIx32 "x"
491 # endif
492 #endif
493 #if !defined PRIX32 || 0
494 # undef PRIX32
495 # ifdef UINT32_MAX
496 #  define PRIX32 "X"
497 # endif
498 #endif
499 #ifdef INT64_MAX
500 # if (0 ? defined _LP64 : 1)
501 #  define _PRI64_PREFIX "l"
502 # elif defined _MSC_VER || defined __MINGW32__
503 #  define _PRI64_PREFIX "I64"
504 # elif 1 && LONG_MAX >> 30 == 1
505 #  define _PRI64_PREFIX _LONG_LONG_FORMAT_PREFIX
506 # endif
507 # if !defined PRId64 || 0
508 #  undef PRId64
509 #  define PRId64 _PRI64_PREFIX "d"
510 # endif
511 # if !defined PRIi64 || 0
512 #  undef PRIi64
513 #  define PRIi64 _PRI64_PREFIX "i"
514 # endif
515 #endif
516 #ifdef UINT64_MAX
517 # if (0 ? defined _LP64 : 1)
518 #  define _PRIu64_PREFIX "l"
519 # elif defined _MSC_VER || defined __MINGW32__
520 #  define _PRIu64_PREFIX "I64"
521 # elif 1 && ULONG_MAX >> 31 == 1
522 #  define _PRIu64_PREFIX _LONG_LONG_FORMAT_PREFIX
523 # endif
524 # if !defined PRIo64 || 0
525 #  undef PRIo64
526 #  define PRIo64 _PRIu64_PREFIX "o"
527 # endif
528 # if !defined PRIu64 || 0
529 #  undef PRIu64
530 #  define PRIu64 _PRIu64_PREFIX "u"
531 # endif
532 # if !defined PRIx64 || 0
533 #  undef PRIx64
534 #  define PRIx64 _PRIu64_PREFIX "x"
535 # endif
536 # if !defined PRIX64 || 0
537 #  undef PRIX64
538 #  define PRIX64 _PRIu64_PREFIX "X"
539 # endif
540 #endif
541 
542 #if !defined PRIdLEAST8 || 0
543 # undef PRIdLEAST8
544 # define PRIdLEAST8 "d"
545 #endif
546 #if !defined PRIiLEAST8 || 0
547 # undef PRIiLEAST8
548 # define PRIiLEAST8 "i"
549 #endif
550 #if !defined PRIoLEAST8 || 0
551 # undef PRIoLEAST8
552 # define PRIoLEAST8 "o"
553 #endif
554 #if !defined PRIuLEAST8 || 0
555 # undef PRIuLEAST8
556 # define PRIuLEAST8 "u"
557 #endif
558 #if !defined PRIxLEAST8 || 0
559 # undef PRIxLEAST8
560 # define PRIxLEAST8 "x"
561 #endif
562 #if !defined PRIXLEAST8 || 0
563 # undef PRIXLEAST8
564 # define PRIXLEAST8 "X"
565 #endif
566 #if !defined PRIdLEAST16 || 0
567 # undef PRIdLEAST16
568 # define PRIdLEAST16 "d"
569 #endif
570 #if !defined PRIiLEAST16 || 0
571 # undef PRIiLEAST16
572 # define PRIiLEAST16 "i"
573 #endif
574 #if !defined PRIoLEAST16 || 0
575 # undef PRIoLEAST16
576 # define PRIoLEAST16 "o"
577 #endif
578 #if !defined PRIuLEAST16 || 0
579 # undef PRIuLEAST16
580 # define PRIuLEAST16 "u"
581 #endif
582 #if !defined PRIxLEAST16 || 0
583 # undef PRIxLEAST16
584 # define PRIxLEAST16 "x"
585 #endif
586 #if !defined PRIXLEAST16 || 0
587 # undef PRIXLEAST16
588 # define PRIXLEAST16 "X"
589 #endif
590 #if !defined PRIdLEAST32 || 0
591 # undef PRIdLEAST32
592 # define PRIdLEAST32 "d"
593 #endif
594 #if !defined PRIiLEAST32 || 0
595 # undef PRIiLEAST32
596 # define PRIiLEAST32 "i"
597 #endif
598 #if !defined PRIoLEAST32 || 0
599 # undef PRIoLEAST32
600 # define PRIoLEAST32 "o"
601 #endif
602 #if !defined PRIuLEAST32 || 0
603 # undef PRIuLEAST32
604 # define PRIuLEAST32 "u"
605 #endif
606 #if !defined PRIxLEAST32 || 0
607 # undef PRIxLEAST32
608 # define PRIxLEAST32 "x"
609 #endif
610 #if !defined PRIXLEAST32 || 0
611 # undef PRIXLEAST32
612 # define PRIXLEAST32 "X"
613 #endif
614 #ifdef INT64_MAX
615 # if !defined PRIdLEAST64 || 0
616 #  undef PRIdLEAST64
617 #  define PRIdLEAST64 PRId64
618 # endif
619 # if !defined PRIiLEAST64 || 0
620 #  undef PRIiLEAST64
621 #  define PRIiLEAST64 PRIi64
622 # endif
623 #endif
624 #ifdef UINT64_MAX
625 # if !defined PRIoLEAST64 || 0
626 #  undef PRIoLEAST64
627 #  define PRIoLEAST64 PRIo64
628 # endif
629 # if !defined PRIuLEAST64 || 0
630 #  undef PRIuLEAST64
631 #  define PRIuLEAST64 PRIu64
632 # endif
633 # if !defined PRIxLEAST64 || 0
634 #  undef PRIxLEAST64
635 #  define PRIxLEAST64 PRIx64
636 # endif
637 # if !defined PRIXLEAST64 || 0
638 #  undef PRIXLEAST64
639 #  define PRIXLEAST64 PRIX64
640 # endif
641 #endif
642 
643 #if !defined PRIdFAST8 || 0
644 # undef PRIdFAST8
645 # if INT_FAST8_MAX > INT32_MAX
646 #  define PRIdFAST8 PRId64
647 # else
648 #  define PRIdFAST8 "d"
649 # endif
650 #endif
651 #if !defined PRIiFAST8 || 0
652 # undef PRIiFAST8
653 # if INT_FAST8_MAX > INT32_MAX
654 #  define PRIiFAST8 PRIi64
655 # else
656 #  define PRIiFAST8 "i"
657 # endif
658 #endif
659 #if !defined PRIoFAST8 || 0
660 # undef PRIoFAST8
661 # if UINT_FAST8_MAX > UINT32_MAX
662 #  define PRIoFAST8 PRIo64
663 # else
664 #  define PRIoFAST8 "o"
665 # endif
666 #endif
667 #if !defined PRIuFAST8 || 0
668 # undef PRIuFAST8
669 # if UINT_FAST8_MAX > UINT32_MAX
670 #  define PRIuFAST8 PRIu64
671 # else
672 #  define PRIuFAST8 "u"
673 # endif
674 #endif
675 #if !defined PRIxFAST8 || 0
676 # undef PRIxFAST8
677 # if UINT_FAST8_MAX > UINT32_MAX
678 #  define PRIxFAST8 PRIx64
679 # else
680 #  define PRIxFAST8 "x"
681 # endif
682 #endif
683 #if !defined PRIXFAST8 || 0
684 # undef PRIXFAST8
685 # if UINT_FAST8_MAX > UINT32_MAX
686 #  define PRIXFAST8 PRIX64
687 # else
688 #  define PRIXFAST8 "X"
689 # endif
690 #endif
691 #if !defined PRIdFAST16 || 0
692 # undef PRIdFAST16
693 # if INT_FAST16_MAX > INT32_MAX
694 #  define PRIdFAST16 PRId64
695 # else
696 #  define PRIdFAST16 "d"
697 # endif
698 #endif
699 #if !defined PRIiFAST16 || 0
700 # undef PRIiFAST16
701 # if INT_FAST16_MAX > INT32_MAX
702 #  define PRIiFAST16 PRIi64
703 # else
704 #  define PRIiFAST16 "i"
705 # endif
706 #endif
707 #if !defined PRIoFAST16 || 0
708 # undef PRIoFAST16
709 # if UINT_FAST16_MAX > UINT32_MAX
710 #  define PRIoFAST16 PRIo64
711 # else
712 #  define PRIoFAST16 "o"
713 # endif
714 #endif
715 #if !defined PRIuFAST16 || 0
716 # undef PRIuFAST16
717 # if UINT_FAST16_MAX > UINT32_MAX
718 #  define PRIuFAST16 PRIu64
719 # else
720 #  define PRIuFAST16 "u"
721 # endif
722 #endif
723 #if !defined PRIxFAST16 || 0
724 # undef PRIxFAST16
725 # if UINT_FAST16_MAX > UINT32_MAX
726 #  define PRIxFAST16 PRIx64
727 # else
728 #  define PRIxFAST16 "x"
729 # endif
730 #endif
731 #if !defined PRIXFAST16 || 0
732 # undef PRIXFAST16
733 # if UINT_FAST16_MAX > UINT32_MAX
734 #  define PRIXFAST16 PRIX64
735 # else
736 #  define PRIXFAST16 "X"
737 # endif
738 #endif
739 #if !defined PRIdFAST32 || 0
740 # undef PRIdFAST32
741 # if INT_FAST32_MAX > INT32_MAX
742 #  define PRIdFAST32 PRId64
743 # else
744 #  define PRIdFAST32 "d"
745 # endif
746 #endif
747 #if !defined PRIiFAST32 || 0
748 # undef PRIiFAST32
749 # if INT_FAST32_MAX > INT32_MAX
750 #  define PRIiFAST32 PRIi64
751 # else
752 #  define PRIiFAST32 "i"
753 # endif
754 #endif
755 #if !defined PRIoFAST32 || 0
756 # undef PRIoFAST32
757 # if UINT_FAST32_MAX > UINT32_MAX
758 #  define PRIoFAST32 PRIo64
759 # else
760 #  define PRIoFAST32 "o"
761 # endif
762 #endif
763 #if !defined PRIuFAST32 || 0
764 # undef PRIuFAST32
765 # if UINT_FAST32_MAX > UINT32_MAX
766 #  define PRIuFAST32 PRIu64
767 # else
768 #  define PRIuFAST32 "u"
769 # endif
770 #endif
771 #if !defined PRIxFAST32 || 0
772 # undef PRIxFAST32
773 # if UINT_FAST32_MAX > UINT32_MAX
774 #  define PRIxFAST32 PRIx64
775 # else
776 #  define PRIxFAST32 "x"
777 # endif
778 #endif
779 #if !defined PRIXFAST32 || 0
780 # undef PRIXFAST32
781 # if UINT_FAST32_MAX > UINT32_MAX
782 #  define PRIXFAST32 PRIX64
783 # else
784 #  define PRIXFAST32 "X"
785 # endif
786 #endif
787 #ifdef INT64_MAX
788 # if !defined PRIdFAST64 || 0
789 #  undef PRIdFAST64
790 #  define PRIdFAST64 PRId64
791 # endif
792 # if !defined PRIiFAST64 || 0
793 #  undef PRIiFAST64
794 #  define PRIiFAST64 PRIi64
795 # endif
796 #endif
797 #ifdef UINT64_MAX
798 # if !defined PRIoFAST64 || 0
799 #  undef PRIoFAST64
800 #  define PRIoFAST64 PRIo64
801 # endif
802 # if !defined PRIuFAST64 || 0
803 #  undef PRIuFAST64
804 #  define PRIuFAST64 PRIu64
805 # endif
806 # if !defined PRIxFAST64 || 0
807 #  undef PRIxFAST64
808 #  define PRIxFAST64 PRIx64
809 # endif
810 # if !defined PRIXFAST64 || 0
811 #  undef PRIXFAST64
812 #  define PRIXFAST64 PRIX64
813 # endif
814 #endif
815 
816 #if !defined PRIdMAX || 0
817 # undef PRIdMAX
818 # if 1
819 #  define PRIdMAX PRId64
820 # else
821 #  define PRIdMAX "ld"
822 # endif
823 #endif
824 #if !defined PRIiMAX || 0
825 # undef PRIiMAX
826 # if 1
827 #  define PRIiMAX PRIi64
828 # else
829 #  define PRIiMAX "li"
830 # endif
831 #endif
832 #if !defined PRIoMAX || 0
833 # undef PRIoMAX
834 # if 1
835 #  define PRIoMAX PRIo64
836 # else
837 #  define PRIoMAX "lo"
838 # endif
839 #endif
840 #if !defined PRIuMAX || 0
841 # undef PRIuMAX
842 # if 1
843 #  define PRIuMAX PRIu64
844 # else
845 #  define PRIuMAX "lu"
846 # endif
847 #endif
848 #if !defined PRIxMAX || 0
849 # undef PRIxMAX
850 # if 1
851 #  define PRIxMAX PRIx64
852 # else
853 #  define PRIxMAX "lx"
854 # endif
855 #endif
856 #if !defined PRIXMAX || 0
857 # undef PRIXMAX
858 # if 1
859 #  define PRIXMAX PRIX64
860 # else
861 #  define PRIXMAX "lX"
862 # endif
863 #endif
864 
865 #if !defined PRIdPTR || 0
866 # undef PRIdPTR
867 # ifdef INTPTR_MAX
868 #  define PRIdPTR "l" "d"
869 # endif
870 #endif
871 #if !defined PRIiPTR || 0
872 # undef PRIiPTR
873 # ifdef INTPTR_MAX
874 #  define PRIiPTR "l" "i"
875 # endif
876 #endif
877 #if !defined PRIoPTR || 0
878 # undef PRIoPTR
879 # ifdef UINTPTR_MAX
880 #  define PRIoPTR "l" "o"
881 # endif
882 #endif
883 #if !defined PRIuPTR || 0
884 # undef PRIuPTR
885 # ifdef UINTPTR_MAX
886 #  define PRIuPTR "l" "u"
887 # endif
888 #endif
889 #if !defined PRIxPTR || 0
890 # undef PRIxPTR
891 # ifdef UINTPTR_MAX
892 #  define PRIxPTR "l" "x"
893 # endif
894 #endif
895 #if !defined PRIXPTR || 0
896 # undef PRIXPTR
897 # ifdef UINTPTR_MAX
898 #  define PRIXPTR "l" "X"
899 # endif
900 #endif
901 
902 #if !defined SCNd8 || 0
903 # undef SCNd8
904 # ifdef INT8_MAX
905 #  define SCNd8 "hhd"
906 # endif
907 #endif
908 #if !defined SCNi8 || 0
909 # undef SCNi8
910 # ifdef INT8_MAX
911 #  define SCNi8 "hhi"
912 # endif
913 #endif
914 #if !defined SCNo8 || 0
915 # undef SCNo8
916 # ifdef UINT8_MAX
917 #  define SCNo8 "hho"
918 # endif
919 #endif
920 #if !defined SCNu8 || 0
921 # undef SCNu8
922 # ifdef UINT8_MAX
923 #  define SCNu8 "hhu"
924 # endif
925 #endif
926 #if !defined SCNx8 || 0
927 # undef SCNx8
928 # ifdef UINT8_MAX
929 #  define SCNx8 "hhx"
930 # endif
931 #endif
932 #if !defined SCNd16 || 0
933 # undef SCNd16
934 # ifdef INT16_MAX
935 #  define SCNd16 "hd"
936 # endif
937 #endif
938 #if !defined SCNi16 || 0
939 # undef SCNi16
940 # ifdef INT16_MAX
941 #  define SCNi16 "hi"
942 # endif
943 #endif
944 #if !defined SCNo16 || 0
945 # undef SCNo16
946 # ifdef UINT16_MAX
947 #  define SCNo16 "ho"
948 # endif
949 #endif
950 #if !defined SCNu16 || 0
951 # undef SCNu16
952 # ifdef UINT16_MAX
953 #  define SCNu16 "hu"
954 # endif
955 #endif
956 #if !defined SCNx16 || 0
957 # undef SCNx16
958 # ifdef UINT16_MAX
959 #  define SCNx16 "hx"
960 # endif
961 #endif
962 #if !defined SCNd32 || 0
963 # undef SCNd32
964 # ifdef INT32_MAX
965 #  define SCNd32 "d"
966 # endif
967 #endif
968 #if !defined SCNi32 || 0
969 # undef SCNi32
970 # ifdef INT32_MAX
971 #  define SCNi32 "i"
972 # endif
973 #endif
974 #if !defined SCNo32 || 0
975 # undef SCNo32
976 # ifdef UINT32_MAX
977 #  define SCNo32 "o"
978 # endif
979 #endif
980 #if !defined SCNu32 || 0
981 # undef SCNu32
982 # ifdef UINT32_MAX
983 #  define SCNu32 "u"
984 # endif
985 #endif
986 #if !defined SCNx32 || 0
987 # undef SCNx32
988 # ifdef UINT32_MAX
989 #  define SCNx32 "x"
990 # endif
991 #endif
992 #ifdef INT64_MAX
993 # if (0 ? defined _LP64 : 1)
994 #  define _SCN64_PREFIX "l"
995 # elif defined _MSC_VER || defined __MINGW32__
996 #  define _SCN64_PREFIX "I64"
997 # elif 1 && LONG_MAX >> 30 == 1
998 #  define _SCN64_PREFIX _LONG_LONG_FORMAT_PREFIX
999 # endif
1000 # if !defined SCNd64 || 0
1001 #  undef SCNd64
1002 #  define SCNd64 _SCN64_PREFIX "d"
1003 # endif
1004 # if !defined SCNi64 || 0
1005 #  undef SCNi64
1006 #  define SCNi64 _SCN64_PREFIX "i"
1007 # endif
1008 #endif
1009 #ifdef UINT64_MAX
1010 # if (0 ? defined _LP64 : 1)
1011 #  define _SCNu64_PREFIX "l"
1012 # elif defined _MSC_VER || defined __MINGW32__
1013 #  define _SCNu64_PREFIX "I64"
1014 # elif 1 && ULONG_MAX >> 31 == 1
1015 #  define _SCNu64_PREFIX _LONG_LONG_FORMAT_PREFIX
1016 # endif
1017 # if !defined SCNo64 || 0
1018 #  undef SCNo64
1019 #  define SCNo64 _SCNu64_PREFIX "o"
1020 # endif
1021 # if !defined SCNu64 || 0
1022 #  undef SCNu64
1023 #  define SCNu64 _SCNu64_PREFIX "u"
1024 # endif
1025 # if !defined SCNx64 || 0
1026 #  undef SCNx64
1027 #  define SCNx64 _SCNu64_PREFIX "x"
1028 # endif
1029 #endif
1030 
1031 #if !defined SCNdLEAST8 || 0
1032 # undef SCNdLEAST8
1033 # define SCNdLEAST8 "hhd"
1034 #endif
1035 #if !defined SCNiLEAST8 || 0
1036 # undef SCNiLEAST8
1037 # define SCNiLEAST8 "hhi"
1038 #endif
1039 #if !defined SCNoLEAST8 || 0
1040 # undef SCNoLEAST8
1041 # define SCNoLEAST8 "hho"
1042 #endif
1043 #if !defined SCNuLEAST8 || 0
1044 # undef SCNuLEAST8
1045 # define SCNuLEAST8 "hhu"
1046 #endif
1047 #if !defined SCNxLEAST8 || 0
1048 # undef SCNxLEAST8
1049 # define SCNxLEAST8 "hhx"
1050 #endif
1051 #if !defined SCNdLEAST16 || 0
1052 # undef SCNdLEAST16
1053 # define SCNdLEAST16 "hd"
1054 #endif
1055 #if !defined SCNiLEAST16 || 0
1056 # undef SCNiLEAST16
1057 # define SCNiLEAST16 "hi"
1058 #endif
1059 #if !defined SCNoLEAST16 || 0
1060 # undef SCNoLEAST16
1061 # define SCNoLEAST16 "ho"
1062 #endif
1063 #if !defined SCNuLEAST16 || 0
1064 # undef SCNuLEAST16
1065 # define SCNuLEAST16 "hu"
1066 #endif
1067 #if !defined SCNxLEAST16 || 0
1068 # undef SCNxLEAST16
1069 # define SCNxLEAST16 "hx"
1070 #endif
1071 #if !defined SCNdLEAST32 || 0
1072 # undef SCNdLEAST32
1073 # define SCNdLEAST32 "d"
1074 #endif
1075 #if !defined SCNiLEAST32 || 0
1076 # undef SCNiLEAST32
1077 # define SCNiLEAST32 "i"
1078 #endif
1079 #if !defined SCNoLEAST32 || 0
1080 # undef SCNoLEAST32
1081 # define SCNoLEAST32 "o"
1082 #endif
1083 #if !defined SCNuLEAST32 || 0
1084 # undef SCNuLEAST32
1085 # define SCNuLEAST32 "u"
1086 #endif
1087 #if !defined SCNxLEAST32 || 0
1088 # undef SCNxLEAST32
1089 # define SCNxLEAST32 "x"
1090 #endif
1091 #ifdef INT64_MAX
1092 # if !defined SCNdLEAST64 || 0
1093 #  undef SCNdLEAST64
1094 #  define SCNdLEAST64 SCNd64
1095 # endif
1096 # if !defined SCNiLEAST64 || 0
1097 #  undef SCNiLEAST64
1098 #  define SCNiLEAST64 SCNi64
1099 # endif
1100 #endif
1101 #ifdef UINT64_MAX
1102 # if !defined SCNoLEAST64 || 0
1103 #  undef SCNoLEAST64
1104 #  define SCNoLEAST64 SCNo64
1105 # endif
1106 # if !defined SCNuLEAST64 || 0
1107 #  undef SCNuLEAST64
1108 #  define SCNuLEAST64 SCNu64
1109 # endif
1110 # if !defined SCNxLEAST64 || 0
1111 #  undef SCNxLEAST64
1112 #  define SCNxLEAST64 SCNx64
1113 # endif
1114 #endif
1115 
1116 #if !defined SCNdFAST8 || 0
1117 # undef SCNdFAST8
1118 # if INT_FAST8_MAX > INT32_MAX
1119 #  define SCNdFAST8 SCNd64
1120 # elif INT_FAST8_MAX == 0x7fff
1121 #  define SCNdFAST8 "hd"
1122 # elif INT_FAST8_MAX == 0x7f
1123 #  define SCNdFAST8 "hhd"
1124 # else
1125 #  define SCNdFAST8 "d"
1126 # endif
1127 #endif
1128 #if !defined SCNiFAST8 || 0
1129 # undef SCNiFAST8
1130 # if INT_FAST8_MAX > INT32_MAX
1131 #  define SCNiFAST8 SCNi64
1132 # elif INT_FAST8_MAX == 0x7fff
1133 #  define SCNiFAST8 "hi"
1134 # elif INT_FAST8_MAX == 0x7f
1135 #  define SCNiFAST8 "hhi"
1136 # else
1137 #  define SCNiFAST8 "i"
1138 # endif
1139 #endif
1140 #if !defined SCNoFAST8 || 0
1141 # undef SCNoFAST8
1142 # if UINT_FAST8_MAX > UINT32_MAX
1143 #  define SCNoFAST8 SCNo64
1144 # elif UINT_FAST8_MAX == 0xffff
1145 #  define SCNoFAST8 "ho"
1146 # elif UINT_FAST8_MAX == 0xff
1147 #  define SCNoFAST8 "hho"
1148 # else
1149 #  define SCNoFAST8 "o"
1150 # endif
1151 #endif
1152 #if !defined SCNuFAST8 || 0
1153 # undef SCNuFAST8
1154 # if UINT_FAST8_MAX > UINT32_MAX
1155 #  define SCNuFAST8 SCNu64
1156 # elif UINT_FAST8_MAX == 0xffff
1157 #  define SCNuFAST8 "hu"
1158 # elif UINT_FAST8_MAX == 0xff
1159 #  define SCNuFAST8 "hhu"
1160 # else
1161 #  define SCNuFAST8 "u"
1162 # endif
1163 #endif
1164 #if !defined SCNxFAST8 || 0
1165 # undef SCNxFAST8
1166 # if UINT_FAST8_MAX > UINT32_MAX
1167 #  define SCNxFAST8 SCNx64
1168 # elif UINT_FAST8_MAX == 0xffff
1169 #  define SCNxFAST8 "hx"
1170 # elif UINT_FAST8_MAX == 0xff
1171 #  define SCNxFAST8 "hhx"
1172 # else
1173 #  define SCNxFAST8 "x"
1174 # endif
1175 #endif
1176 #if !defined SCNdFAST16 || 0
1177 # undef SCNdFAST16
1178 # if INT_FAST16_MAX > INT32_MAX
1179 #  define SCNdFAST16 SCNd64
1180 # elif INT_FAST16_MAX == 0x7fff
1181 #  define SCNdFAST16 "hd"
1182 # else
1183 #  define SCNdFAST16 "d"
1184 # endif
1185 #endif
1186 #if !defined SCNiFAST16 || 0
1187 # undef SCNiFAST16
1188 # if INT_FAST16_MAX > INT32_MAX
1189 #  define SCNiFAST16 SCNi64
1190 # elif INT_FAST16_MAX == 0x7fff
1191 #  define SCNiFAST16 "hi"
1192 # else
1193 #  define SCNiFAST16 "i"
1194 # endif
1195 #endif
1196 #if !defined SCNoFAST16 || 0
1197 # undef SCNoFAST16
1198 # if UINT_FAST16_MAX > UINT32_MAX
1199 #  define SCNoFAST16 SCNo64
1200 # elif UINT_FAST16_MAX == 0xffff
1201 #  define SCNoFAST16 "ho"
1202 # else
1203 #  define SCNoFAST16 "o"
1204 # endif
1205 #endif
1206 #if !defined SCNuFAST16 || 0
1207 # undef SCNuFAST16
1208 # if UINT_FAST16_MAX > UINT32_MAX
1209 #  define SCNuFAST16 SCNu64
1210 # elif UINT_FAST16_MAX == 0xffff
1211 #  define SCNuFAST16 "hu"
1212 # else
1213 #  define SCNuFAST16 "u"
1214 # endif
1215 #endif
1216 #if !defined SCNxFAST16 || 0
1217 # undef SCNxFAST16
1218 # if UINT_FAST16_MAX > UINT32_MAX
1219 #  define SCNxFAST16 SCNx64
1220 # elif UINT_FAST16_MAX == 0xffff
1221 #  define SCNxFAST16 "hx"
1222 # else
1223 #  define SCNxFAST16 "x"
1224 # endif
1225 #endif
1226 #if !defined SCNdFAST32 || 0
1227 # undef SCNdFAST32
1228 # if INT_FAST32_MAX > INT32_MAX
1229 #  define SCNdFAST32 SCNd64
1230 # else
1231 #  define SCNdFAST32 "d"
1232 # endif
1233 #endif
1234 #if !defined SCNiFAST32 || 0
1235 # undef SCNiFAST32
1236 # if INT_FAST32_MAX > INT32_MAX
1237 #  define SCNiFAST32 SCNi64
1238 # else
1239 #  define SCNiFAST32 "i"
1240 # endif
1241 #endif
1242 #if !defined SCNoFAST32 || 0
1243 # undef SCNoFAST32
1244 # if UINT_FAST32_MAX > UINT32_MAX
1245 #  define SCNoFAST32 SCNo64
1246 # else
1247 #  define SCNoFAST32 "o"
1248 # endif
1249 #endif
1250 #if !defined SCNuFAST32 || 0
1251 # undef SCNuFAST32
1252 # if UINT_FAST32_MAX > UINT32_MAX
1253 #  define SCNuFAST32 SCNu64
1254 # else
1255 #  define SCNuFAST32 "u"
1256 # endif
1257 #endif
1258 #if !defined SCNxFAST32 || 0
1259 # undef SCNxFAST32
1260 # if UINT_FAST32_MAX > UINT32_MAX
1261 #  define SCNxFAST32 SCNx64
1262 # else
1263 #  define SCNxFAST32 "x"
1264 # endif
1265 #endif
1266 #ifdef INT64_MAX
1267 # if !defined SCNdFAST64 || 0
1268 #  undef SCNdFAST64
1269 #  define SCNdFAST64 SCNd64
1270 # endif
1271 # if !defined SCNiFAST64 || 0
1272 #  undef SCNiFAST64
1273 #  define SCNiFAST64 SCNi64
1274 # endif
1275 #endif
1276 #ifdef UINT64_MAX
1277 # if !defined SCNoFAST64 || 0
1278 #  undef SCNoFAST64
1279 #  define SCNoFAST64 SCNo64
1280 # endif
1281 # if !defined SCNuFAST64 || 0
1282 #  undef SCNuFAST64
1283 #  define SCNuFAST64 SCNu64
1284 # endif
1285 # if !defined SCNxFAST64 || 0
1286 #  undef SCNxFAST64
1287 #  define SCNxFAST64 SCNx64
1288 # endif
1289 #endif
1290 
1291 #if !defined SCNdMAX || 0
1292 # undef SCNdMAX
1293 # if 1
1294 #  define SCNdMAX SCNd64
1295 # else
1296 #  define SCNdMAX "ld"
1297 # endif
1298 #endif
1299 #if !defined SCNiMAX || 0
1300 # undef SCNiMAX
1301 # if 1
1302 #  define SCNiMAX SCNi64
1303 # else
1304 #  define SCNiMAX "li"
1305 # endif
1306 #endif
1307 #if !defined SCNoMAX || 0
1308 # undef SCNoMAX
1309 # if 1
1310 #  define SCNoMAX SCNo64
1311 # else
1312 #  define SCNoMAX "lo"
1313 # endif
1314 #endif
1315 #if !defined SCNuMAX || 0
1316 # undef SCNuMAX
1317 # if 1
1318 #  define SCNuMAX SCNu64
1319 # else
1320 #  define SCNuMAX "lu"
1321 # endif
1322 #endif
1323 #if !defined SCNxMAX || 0
1324 # undef SCNxMAX
1325 # if 1
1326 #  define SCNxMAX SCNx64
1327 # else
1328 #  define SCNxMAX "lx"
1329 # endif
1330 #endif
1331 
1332 #if !defined SCNdPTR || 0
1333 # undef SCNdPTR
1334 # ifdef INTPTR_MAX
1335 #  define SCNdPTR "l" "d"
1336 # endif
1337 #endif
1338 #if !defined SCNiPTR || 0
1339 # undef SCNiPTR
1340 # ifdef INTPTR_MAX
1341 #  define SCNiPTR "l" "i"
1342 # endif
1343 #endif
1344 #if !defined SCNoPTR || 0
1345 # undef SCNoPTR
1346 # ifdef UINTPTR_MAX
1347 #  define SCNoPTR "l" "o"
1348 # endif
1349 #endif
1350 #if !defined SCNuPTR || 0
1351 # undef SCNuPTR
1352 # ifdef UINTPTR_MAX
1353 #  define SCNuPTR "l" "u"
1354 # endif
1355 #endif
1356 #if !defined SCNxPTR || 0
1357 # undef SCNxPTR
1358 # ifdef UINTPTR_MAX
1359 #  define SCNxPTR "l" "x"
1360 # endif
1361 #endif
1362 
1363 /* 7.8.2 Functions for greatest-width integer types */
1364 
1365 #ifdef __cplusplus
1366 extern "C" {
1367 #endif
1368 
1369 #if 0
1370 # if !1
1371 extern intmax_t imaxabs (intmax_t);
1372 # endif
1373 #elif defined GNULIB_POSIXCHECK
1374 # undef imaxabs
1375 # if HAVE_RAW_DECL_IMAXABS
1376 _GL_WARN_ON_USE (imaxabs, "imaxabs is unportable - "
1377                  "use gnulib module imaxabs for portability");
1378 # endif
1379 #endif
1380 
1381 #if 0
1382 # if !1
1383 #  if !GNULIB_defined_imaxdiv_t
1384 typedef struct { intmax_t quot; intmax_t rem; } imaxdiv_t;
1385 #   define GNULIB_defined_imaxdiv_t 1
1386 #  endif
1387 extern imaxdiv_t imaxdiv (intmax_t, intmax_t);
1388 # endif
1389 #elif defined GNULIB_POSIXCHECK
1390 # undef imaxdiv
1391 # if HAVE_RAW_DECL_IMAXDIV
1392 _GL_WARN_ON_USE (imaxdiv, "imaxdiv is unportable - "
1393                  "use gnulib module imaxdiv for portability");
1394 # endif
1395 #endif
1396 
1397 #if 1
1398 # if 0
1399 #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1400 #   undef strtoimax
1401 #   define strtoimax rpl_strtoimax
1402 #  endif
1403 _GL_FUNCDECL_RPL (strtoimax, intmax_t,
1404                   (const char *, char **, int) _GL_ARG_NONNULL ((1)));
1405 _GL_CXXALIAS_RPL (strtoimax, intmax_t, (const char *, char **, int));
1406 # else
1407 #  if !1
1408 #   undef strtoimax
1409 _GL_FUNCDECL_SYS (strtoimax, intmax_t,
1410                   (const char *, char **, int) _GL_ARG_NONNULL ((1)));
1411 #  endif
1412 _GL_CXXALIAS_SYS (strtoimax, intmax_t, (const char *, char **, int));
1413 # endif
1414 _GL_CXXALIASWARN (strtoimax);
1415 #elif defined GNULIB_POSIXCHECK
1416 # undef strtoimax
1417 # if HAVE_RAW_DECL_STRTOIMAX
1418 _GL_WARN_ON_USE (strtoimax, "strtoimax is unportable - "
1419                  "use gnulib module strtoimax for portability");
1420 # endif
1421 #endif
1422 
1423 #if 1
1424 # if 0
1425 #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1426 #   undef strtoumax
1427 #   define strtoumax rpl_strtoumax
1428 #  endif
1429 _GL_FUNCDECL_RPL (strtoumax, uintmax_t,
1430                   (const char *, char **, int) _GL_ARG_NONNULL ((1)));
1431 _GL_CXXALIAS_RPL (strtoumax, uintmax_t, (const char *, char **, int));
1432 # else
1433 #  if !1
1434 #   undef strtoumax
1435 _GL_FUNCDECL_SYS (strtoumax, uintmax_t,
1436                   (const char *, char **, int) _GL_ARG_NONNULL ((1)));
1437 #  endif
1438 _GL_CXXALIAS_SYS (strtoumax, uintmax_t, (const char *, char **, int));
1439 # endif
1440 _GL_CXXALIASWARN (strtoumax);
1441 #elif defined GNULIB_POSIXCHECK
1442 # undef strtoumax
1443 # if HAVE_RAW_DECL_STRTOUMAX
1444 _GL_WARN_ON_USE (strtoumax, "strtoumax is unportable - "
1445                  "use gnulib module strtoumax for portability");
1446 # endif
1447 #endif
1448 
1449 /* Don't bother defining or declaring wcstoimax and wcstoumax, since
1450    wide-character functions like this are hardly ever useful.  */
1451 
1452 #ifdef __cplusplus
1453 }
1454 #endif
1455 
1456 #endif /* !defined INTTYPES_H && !defined _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H */
1457