-Wtraditional, integer constants and C99
Joseph S. Myers
jsm28@cam.ac.uk
Mon Sep 18 14:25:00 GMT 2000
-Wtraditional gives warnings about integer constants that changed their
sign between traditional C and C89. In C99, decimal integer constants
with no 'u' or 'U' suffix again cannot be unsigned: so, when in C99 mode
and implementing the C99 type rules, but with -Wtraditional specified,
should the compiler make any attempt to give warnings relating to the C89
rules, or only to compare the C99 type with the traditional one? (The
simplest solution is just to compare the C99 type with the traditional
one; but this would reduce the value of -Wtraditional as a portability
tool when C99 mode is eventually made the default.)
--
Joseph S. Myers
jsm28@cam.ac.uk
More information about the Gcc
mailing list