[clang] [clang] Change representation of CurLexerKind (PR #70381)
via cfe-commits
cfe-commits at lists.llvm.org
Thu Oct 26 23:03:30 PDT 2023
================
@@ -751,13 +751,8 @@ class Preprocessor {
std::unique_ptr<TokenLexer> CurTokenLexer;
/// The kind of lexer we're currently working with.
- enum CurLexerKind {
- CLK_Lexer,
- CLK_TokenLexer,
- CLK_CachingLexer,
- CLK_DependencyDirectivesLexer,
- CLK_LexAfterModuleImport
- } CurLexerKind = CLK_Lexer;
+ typedef bool (*CurLexerKindType)(Preprocessor &, Token &);
+ CurLexerKindType CurLexerKind = &CLK_Lexer;
----------------
cor3ntin wrote:
```suggestion
LexerCallback CurLexerCallback = &CLK_Lexer;
```
https://github.com/llvm/llvm-project/pull/70381
More information about the cfe-commits
mailing list