Regression (of sorts) in 20021111 snapshot
Paul Koning
pkoning@equallogic.com
Fri Nov 15 15:34:00 GMT 2002
>>>>> "Jack" == Jack Lloyd <lloyd@acm.jhu.edu> writes:
Jack> The behaviour of g++ when facing long long constants that don't
Jack> have an LL suffix seems to be changing from release to
Jack> release. Specifically, some versions print a warning, some an
Jack> error, some ignore it.
Jack> egcs 1.1.2 - fine with it gcc 2.95.x - Error unless
Jack> -fpermissive/-pedantic is set, warning with gcc 3.[01].* - fine
Jack> gcc 3.2 - haven't checked 20021111 - same as gcc 2.95.x
Jack> This is annoying for me, because I know those constants are
Jack> bigger than a long, so a warning is not needed (particularly
Jack> when a single file has 1000s of such constants), and errors are
Jack> even more annoying. I had thought this behaviour was limited to
Jack> 2.95.x up until now, though (and have specific workarounds for
Jack> those compilers in my build stuff).
Jack> I would file a bug in GNATS, but the change seems entirely
Jack> intentional. I am just wondering the reason for the recent
Jack> change, and if there is a way to work around the problem
Jack> cleanly (ie my makefiles will continue to work with egcs 1.1.2,
Jack> etc), and preferably without a warning at compile time.
A recent (3.3-something) gcc spits out a warning. I'm not sure if
there is a way to turn it off.
As far as I'm concerned, this is an important feature. I would
strenuously object to it being removed. Whether it should be on by
default, or whether a switch should exist to turn it off if it's on by
default, is another matter.
I agree it shouldn't be an error (unless -Werror is set of course).
paul
More information about the Gcc
mailing list