forked from OSchip/llvm-project
1013fe7451
Previously these would be transformed into annotation tokens and the preprocessor would then assume they were real tokens with source locations and assert/UB. Other pragmas that produce annotation tokens aren't a problem because they aren't handled if the parser isn't hooked up - ParsePragma.cpp registers those handlers & isn't run for pure preprocessing. So they're treated as unknown pragmas & printed verbatim by the preprocessor. Perhaps these pragmas should be treated the same way? But they got mixed in with other __debug pragmas that do need to be handled during preprocessing. The third __debug pragma that produces an annotation token is 'captured' - which had its own fix for this issue - by not inserting the annotation token in the first place if it detected that it was in preprocessing mode. I've removed that fix (from Lex/Pragma.cpp) in favor of the more general one in Frontend/PrintPreprocessedOutput.cpp. llvm-svn: 346928 |
||
---|---|---|
.. | ||
CMakeLists.txt | ||
HeaderMap.cpp | ||
HeaderSearch.cpp | ||
Lexer.cpp | ||
LiteralSupport.cpp | ||
MacroArgs.cpp | ||
MacroInfo.cpp | ||
ModuleMap.cpp | ||
PPCaching.cpp | ||
PPCallbacks.cpp | ||
PPConditionalDirectiveRecord.cpp | ||
PPDirectives.cpp | ||
PPExpressions.cpp | ||
PPLexerChange.cpp | ||
PPMacroExpansion.cpp | ||
PTHLexer.cpp | ||
Pragma.cpp | ||
PreprocessingRecord.cpp | ||
Preprocessor.cpp | ||
PreprocessorLexer.cpp | ||
ScratchBuffer.cpp | ||
TokenConcatenation.cpp | ||
TokenLexer.cpp | ||
UnicodeCharSets.h |