This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: [Bug c++/23139] [3.4/4.0/4.1 Regression] -pedantic -ffast-math breaks working code
- From: Gabriel Dos Reis <gdr at integrable-solutions dot net>
- To: gcc-bugzilla at gcc dot gnu dot org
- Cc: gcc-bugs at gcc dot gnu dot org
- Date: 06 Sep 2005 18:11:19 +0200
- Subject: Re: [Bug c++/23139] [3.4/4.0/4.1 Regression] -pedantic -ffast-math breaks working code
- References: <20050729205340.23139.thor@math.tu-berlin.de><20050906152936.18146.qmail@sourceware.org>
"mmitchel at gcc dot gnu dot org" <gcc-bugzilla@gcc.gnu.org> writes:
| The problem behind both diagnostics fact that the C++ front-end pre-lexes the
| entire source file. As a result, the lexing routines, which depends on the
| setting of pedantic to determine whether or not to issue errors, are
| called when pedantic is set, even though we are within an
| __extension__ block. Because the parsing of __extension__ blocks is
| complex, we need to either (a) eliminate the up-front lexing, or (b)
| defer issuing diagnostics until we are actually in
| position to know the correct value of pedantic.
In long term, I believe (b) is a better alternative.
-- Gaby