Manna updated this revision to Diff 554810. Manna added a comment. This patch splits all predicates and updates assert messages.
CHANGES SINCE LAST ACTION https://reviews.llvm.org/D158293/new/ https://reviews.llvm.org/D158293 Files: clang/lib/Lex/PPDirectives.cpp Index: clang/lib/Lex/PPDirectives.cpp =================================================================== --- clang/lib/Lex/PPDirectives.cpp +++ clang/lib/Lex/PPDirectives.cpp @@ -491,7 +491,9 @@ llvm::SaveAndRestore SARSkipping(SkippingExcludedConditionalBlock, true); ++NumSkipped; - assert(!CurTokenLexer && CurPPLexer && "Lexing a macro, not a file?"); + assert(!CurTokenLexer && "Conditional PP block cannot appear in a macro!"); + assert(CurPPLexer && "Conditional PP block must be in a file!"); + assert(CurLexer && "Conditional PP block but no current lexer set!"); if (PreambleConditionalStack.reachedEOFWhileSkipping()) PreambleConditionalStack.clearSkipInfo();
Index: clang/lib/Lex/PPDirectives.cpp =================================================================== --- clang/lib/Lex/PPDirectives.cpp +++ clang/lib/Lex/PPDirectives.cpp @@ -491,7 +491,9 @@ llvm::SaveAndRestore SARSkipping(SkippingExcludedConditionalBlock, true); ++NumSkipped; - assert(!CurTokenLexer && CurPPLexer && "Lexing a macro, not a file?"); + assert(!CurTokenLexer && "Conditional PP block cannot appear in a macro!"); + assert(CurPPLexer && "Conditional PP block must be in a file!"); + assert(CurLexer && "Conditional PP block but no current lexer set!"); if (PreambleConditionalStack.reachedEOFWhileSkipping()) PreambleConditionalStack.clearSkipInfo();
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits