[Bug c/448] <stdint.h>-related issues (C99 issues)
paolo dot carlini at oracle dot com
gcc-bugzilla@gcc.gnu.org
Fri Jul 31 13:57:00 GMT 2009
------- Comment #25 from paolo dot carlini at oracle dot com 2009-07-31 13:57 -------
Something like this should be enough, barring objections, I'll polish it, add a
testcase and submit it.
Index: c-cppbuiltin.c
===================================================================
--- c-cppbuiltin.c (revision 150315)
+++ c-cppbuiltin.c (working copy)
@@ -561,7 +561,15 @@
if (flag_rtti)
cpp_define (pfile, "__GXX_RTTI");
if (cxx_dialect == cxx0x)
- cpp_define (pfile, "__GXX_EXPERIMENTAL_CXX0X__");
+ {
+ cpp_define (pfile, "__GXX_EXPERIMENTAL_CXX0X__");
+ /* Note that this is a temporary solution: eventually the
+ <stdint.h> and <inttypes.h> headers will have to know about
+ C++0x mode and provide the macros unconditionally. */
+ cpp_define (pfile, "__STDC_LIMIT_MACROS");
+ cpp_define (pfile, "__STDC_CONSTANT_MACROS");
+ cpp_define (pfile, "__STDC_FORMAT_MACROS");
+ }
}
/* Note that we define this for C as well, so that we know if
__attribute__((cleanup)) will interface with EH. */
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=448
More information about the Gcc-bugs
mailing list