This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c/448] <stdint.h>-related issues (C99 issues)



------- Comment #20 from paolo dot carlini at oracle dot com  2009-07-31 12:40 -------
I'm wondering if there is something we can/should do here about C++1x: in the
new Standard (see 18.4.1/2 in n2914, for example), for <cstdint> we have:

The header defines all functions, types, and macros the same as C99 7.18. [
Note: The macros defined by <cstdint> are provided unconditionally. In
particular, the symbols __STDC_LIMIT_MACROS and __STDC_CONSTANT_MACROS
(mentioned in C99 footnotes 219, 220, and 222) play no role in C++. ?end note ]

and since the implementation of <cstdint> can, conformingly, include <stdint.h>
and do little more, I would guess a little of support in <stdint.h> to its C++
uses would make the life of the implementors *much* easier...

For the record, at the moment we are just defining the macros as part of
<cstdint>, at the top, before including <stdint.h>, but of course the solution
isn't too good, it breaks immediately if the user code for some reason includes
<stdint.h> before <cstdint> without defining the macros.


-- 

paolo dot carlini at oracle dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |paolo dot carlini at oracle
                   |                            |dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=448


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]