10 #ifndef LLVM_CLANG_LEX_PREPROCESSOROPTIONS_H_ 11 #define LLVM_CLANG_LEX_PREPROCESSOROPTIONS_H_ 14 #include "llvm/ADT/StringRef.h" 15 #include "llvm/ADT/StringSet.h" 45 std::vector<std::pair<std::string,
bool>>
Macros;
51 bool UsePredefines =
true;
55 bool DetailedRecord =
false;
59 bool PCHWithHdrStop =
false;
65 bool PCHWithHdrStopCreate =
false;
82 bool DisablePCHValidation =
false;
85 bool AllowPCHWithCompilerErrors =
false;
88 bool DumpDeserializedPCHDecls =
false;
106 bool GeneratePreamble =
false;
111 bool WriteCommentListToPCH =
true;
118 bool SingleFileParseMode =
false;
121 bool LexEditorPlaceholders =
true;
125 bool RemappedFilesKeepOriginalName =
true;
144 bool RetainRemappedFileBuffers =
false;
153 llvm::StringSet<> Failed;
157 return Failed.count(module) > 0;
161 Failed.insert(module);
176 void addMacroDef(StringRef Name) { Macros.emplace_back(Name,
false); }
180 RemappedFiles.emplace_back(From, To);
184 RemappedFileBuffers.emplace_back(From, To);
188 RemappedFiles.clear();
189 RemappedFileBuffers.clear();
196 MacroIncludes.clear();
197 ChainedIncludes.clear();
198 DumpDeserializedPCHDecls =
false;
199 ImplicitPCHInclude.clear();
200 SingleFileParseMode =
false;
201 LexEditorPlaceholders =
true;
202 RetainRemappedFileBuffers =
true;
203 PrecompiledPreambleBytes.first = 0;
204 PrecompiledPreambleBytes.second =
false;
210 #endif // LLVM_CLANG_LEX_PREPROCESSOROPTIONS_H_ std::vector< std::pair< std::string, bool > > Macros
void addMacroUndef(StringRef Name)
ObjCXXARCStandardLibraryKind
Enumerate the kinds of standard library that.
DominatorTree GraphTraits specialization so the DominatorTree can be iterable by generic graph iterat...
std::vector< std::string > Includes
PreprocessorOptions - This class is used for passing the various options used in preprocessor initial...
std::shared_ptr< FailedModulesSet > FailedModules
The set of modules that failed to build.
void addRemappedFile(StringRef From, StringRef To)
void addRemappedFile(StringRef From, llvm::MemoryBuffer *To)
void addFailed(StringRef module)
Forward-declares and imports various common LLVM datatypes that clang wants to use unqualified...
std::vector< std::pair< std::string, llvm::MemoryBuffer * > > RemappedFileBuffers
The set of file-to-buffer remappings, which take existing files on the system (the first part of each...
std::vector< std::string > ChainedIncludes
Headers that will be converted to chained PCHs in memory.
std::set< std::string > DeserializedPCHDeclsToErrorOn
This is a set of names for decls that we do not want to be deserialized, and we emit an error if they...
std::string ImplicitPCHInclude
The implicit PCH included at the start of the translation unit, or empty.
void resetNonModularOptions()
Reset any options that are not considered when building a module.
std::string PCHThroughHeader
If non-empty, the filename used in an #include directive in the primary source file (or command-line ...
void addMacroDef(StringRef Name)
std::vector< std::string > MacroIncludes
Dataflow Directional Tag Classes.
bool hasAlreadyFailed(StringRef module)
std::vector< std::pair< std::string, std::string > > RemappedFiles
The set of file remappings, which take existing files on the system (the first part of each pair) and...
std::pair< unsigned, bool > PrecompiledPreambleBytes
If non-zero, the implicit PCH include is actually a precompiled preamble that covers this number of b...
void clearRemappedFiles()
Records the set of modules.