14 #ifndef LLVM_CLANG_LEX_PRAGMA_H 15 #define LLVM_CLANG_LEX_PRAGMA_H 18 #include "llvm/ADT/StringMap.h" 19 #include "llvm/ADT/StringRef.h" 24 class PragmaNamespace;
67 StringRef
getName()
const {
return Name; }
69 Token &FirstToken) = 0;
83 Token &FirstToken)
override;
93 llvm::StringMap<PragmaHandler *> Handlers;
104 bool IgnoreNull =
true)
const;
113 bool IsEmpty()
const {
return Handlers.empty(); }
116 Token &FirstToken)
override;
123 #endif // LLVM_CLANG_LEX_PRAGMA_H
virtual void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer, Token &FirstToken)=0
The pragma was introduced via the Microsoft __pragma(token-string).
The pragma was introduced via the C99 _Pragma(string-literal).
Token - This structure provides full information about a lexed token.
Forward-declares and imports various common LLVM datatypes that clang wants to use unqualified...
PragmaIntroducerKind
Describes how the pragma was introduced, e.g., with #pragma, _Pragma, or __pragma.
EmptyPragmaHandler - A pragma handler which takes no action, which can be used to ignore particular p...
PragmaNamespace * getIfNamespace() override
getIfNamespace - If this is a namespace, return it.
Dataflow Directional Tag Classes.
The pragma was introduced via #pragma.
virtual PragmaNamespace * getIfNamespace()
getIfNamespace - If this is a namespace, return it.
PragmaHandler - Instances of this interface defined to handle the various pragmas that the language f...
PragmaNamespace - This PragmaHandler subdivides the namespace of pragmas, allowing hierarchical pragm...
PragmaNamespace(StringRef Name)
PragmaHandler(StringRef name)
StringRef getName() const
Engages in a tight little dance with the lexer to efficiently preprocess tokens.