[cfe-commits] [PATCH] Produce -Wc++0x-compat warnings if C++98 code uses C++11 keywords

Richard Smith richard at metafoo.co.uk
Tue Oct 11 13:31:00 PDT 2011

On Tue, October 11, 2011 20:54, Douglas Gregor wrote:
> On Oct 11, 2011, at 10:59 AM, Richard Smith wrote:
>> The attached patch adds a -Wc++0x-compat warning if a C++11 keyword is used
>> when compiling in C++98 mode. The warning is provided only for the first
>> usage of each keyword. It has false negatives if the keyword comes from the
>> body of a macro, but covers the majority of cases. I'm not very familiar
>> with the lexer, so a review would be very much appreciated.

Thanks, in r141700.

More information about the cfe-commits mailing list