llvm-project/clang/lib/Lex
Ilya Biryukov 929af67361 [Lex] Allow to consume tokens while preprocessing
Summary:
By adding a hook to consume all tokens produced by the preprocessor.
The intention of this change is to make it possible to consume the
expanded tokens without re-runnig the preprocessor with minimal changes
to the preprocessor and minimal performance penalty when preprocessing
without recording the tokens.

The added hook is very low-level and reconstructing the expanded token
stream requires more work in the client code, the actual algorithm to
collect the tokens using this hook can be found in the follow-up change.

Reviewers: rsmith

Reviewed By: rsmith

Subscribers: eraman, nemanjai, kbarton, jsji, riccibruno, cfe-commits

Tags: #clang

Differential Revision: https://reviews.llvm.org/D59885

llvm-svn: 361007
2019-05-17 09:32:05 +00:00
..
CMakeLists.txt PTH-- Remove feature entirely- 2018-12-04 14:34:09 +00:00
HeaderMap.cpp Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
HeaderSearch.cpp [clang][HeaderSuggestion] Handle the case of dotdot with an absolute path 2019-04-24 09:23:31 +00:00
Lexer.cpp Replace tok::angle_string_literal with new tok::header_name. 2019-03-19 22:09:55 +00:00
LiteralSupport.cpp [CUDA][HIP] Do not diagnose use of _Float16 2019-01-29 13:20:23 +00:00
MacroArgs.cpp [Lex] Allow to consume tokens while preprocessing 2019-05-17 09:32:05 +00:00
MacroInfo.cpp Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
ModuleMap.cpp [c++2a] Add semantic support for private module fragments. 2019-04-18 21:12:54 +00:00
PPCaching.cpp [Lex] Allow to consume tokens while preprocessing 2019-05-17 09:32:05 +00:00
PPCallbacks.cpp Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
PPConditionalDirectiveRecord.cpp Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
PPDirectives.cpp [Lex] Allow to consume tokens while preprocessing 2019-05-17 09:32:05 +00:00
PPExpressions.cpp Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
PPLexerChange.cpp [Lex] Allow to consume tokens while preprocessing 2019-05-17 09:32:05 +00:00
PPMacroExpansion.cpp [Lex] Allow to consume tokens while preprocessing 2019-05-17 09:32:05 +00:00
Pragma.cpp [Lex] Allow to consume tokens while preprocessing 2019-05-17 09:32:05 +00:00
PreprocessingRecord.cpp Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
Preprocessor.cpp [Lex] Allow to consume tokens while preprocessing 2019-05-17 09:32:05 +00:00
PreprocessorLexer.cpp Factor out repeated code parsing and concatenating header-names from 2019-03-19 01:51:19 +00:00
ScratchBuffer.cpp Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
TokenConcatenation.cpp [C++20] Implement context-sensitive header-name lexing and pp-import parsing in the preprocessor. 2019-04-11 21:18:23 +00:00
TokenLexer.cpp [Lex] Allow to consume tokens while preprocessing 2019-05-17 09:32:05 +00:00
UnicodeCharSets.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00