Skip to content

Commit

Permalink
Don't warn on varaidic macros in C++0x mode.
Browse files Browse the repository at this point in the history
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@138257 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
eefriedman committed Aug 22, 2011
1 parent 58a7649 commit 70c7b10
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/Lex/PPDirectives.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1298,8 +1298,8 @@ bool Preprocessor::ReadMacroDefinitionArgList(MacroInfo *MI) {
Diag(Tok, diag::err_pp_expected_ident_in_arg_list);
return true;
case tok::ellipsis: // #define X(... -> C99 varargs
// Warn if use of C99 feature in non-C99 mode.
if (!Features.C99) Diag(Tok, diag::ext_variadic_macro);
if (!Features.C99 && !Features.CPlusPlus0x)
Diag(Tok, diag::ext_variadic_macro);

// Lex the token after the identifier.
LexUnexpandedToken(Tok);
Expand Down

0 comments on commit 70c7b10

Please sign in to comment.