This is the mail archive of the
mailing list for the GCC project.
Re: Why does -pedantic make long long an error in C++?
On Wed, Aug 13, 2003 at 05:18:57PM -0400, Andrew Pinski wrote:
> Issue all the warnings demanded by strict ISO C and ISO C++; reject all programs that use forbidden extensions, and some other programs that do not follow ISO C and ISO C++. For ISO C, follows the version of the ISO C standard specified by any -std option used.
> Valid ISO C and ISO C++ programs should compile properly with or without this option (though a rare few will require -ansi or a -std option specifying the required version of ISO C). However, without this option, certain GNU extensions and traditional C and C++ features are supported as well. With this option, they are rejected.
> I interpute this as it can error for "all programs that use forbidden extensions", long long looks like to be one of these.
That's not really a useful interpretation though. If I wanted that
behaviour, I could get it with -pedantic-errors or with -pedantic -Werror.
> Even though "long long" might become part of the C++ standard in C++0x is not really the issue at this point.
> Also mozilla is already fixed in the cvs versions any way as you can see by reading the mozilla bug report linked from GCC's bug report.
Just because the discoverer is now working around a bug in the compiler
doesn't mean the compiler bug shouldn't be fixed.
"It's not Hollywood. War is real, war is primarily not about defeat or
victory, it is about death. I've seen thousands and thousands of dead bodies.
Do you think I want to have an academic debate on this subject?" -- Robert Fisk