[Bug libstdc++/97044] Undefined format macros because of include order on AIX

redi at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Sun Sep 20 20:10:43 GMT 2020


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97044

--- Comment #1 from Jonathan Wakely <redi at gcc dot gnu.org> ---
The C99 standard says that __STDC_FORMATE_MACROS must be defined before
including the header. The C++11 standard is clear that __STDC_FORMAT_MACROS has
no effect in C++ programs, and the header must defined the format macros
unconditionally. AIX apparently follows the C99 rule, even though obviously the
C++ standard defines how C++ works, not C.

This is a bug in the AIX headers.


More information about the Gcc-bugs mailing list