aboutsummaryrefslogtreecommitdiff
path: root/include/clang/Frontend
diff options
context:
space:
mode:
Diffstat (limited to 'include/clang/Frontend')
-rw-r--r--include/clang/Frontend/CompilerInvocation.h4
-rw-r--r--include/clang/Frontend/HeaderSearchOptions.h8
-rw-r--r--include/clang/Frontend/PreprocessorOptions.h7
3 files changed, 18 insertions, 1 deletions
diff --git a/include/clang/Frontend/CompilerInvocation.h b/include/clang/Frontend/CompilerInvocation.h
index 23ddc84304..f09c97ec3f 100644
--- a/include/clang/Frontend/CompilerInvocation.h
+++ b/include/clang/Frontend/CompilerInvocation.h
@@ -123,6 +123,10 @@ public:
static void setLangDefaults(LangOptions &Opts, InputKind IK,
LangStandard::Kind LangStd = LangStandard::lang_unspecified);
+ /// \brief Retrieve a module hash string that is suitable for uniquely
+ /// identifying the conditions under which the module was built.
+ std::string getModuleHash() const;
+
/// @}
/// @name Option Subgroups
/// @{
diff --git a/include/clang/Frontend/HeaderSearchOptions.h b/include/clang/Frontend/HeaderSearchOptions.h
index a81a0cb992..e0f80e3bdf 100644
--- a/include/clang/Frontend/HeaderSearchOptions.h
+++ b/include/clang/Frontend/HeaderSearchOptions.h
@@ -78,6 +78,12 @@ public:
/// \brief The directory used for the module cache.
std::string ModuleCachePath;
+ /// \brief Whether we should disable the use of the hash string within the
+ /// module cache.
+ ///
+ /// Note: Only used for testing!
+ unsigned DisableModuleHash : 1;
+
/// Include the compiler builtin includes.
unsigned UseBuiltinIncludes : 1;
@@ -95,7 +101,7 @@ public:
public:
HeaderSearchOptions(StringRef _Sysroot = "/")
- : Sysroot(_Sysroot), UseBuiltinIncludes(true),
+ : Sysroot(_Sysroot), DisableModuleHash(0), UseBuiltinIncludes(true),
UseStandardIncludes(true), UseStandardCXXIncludes(true), UseLibcxx(false),
Verbose(false) {}
diff --git a/include/clang/Frontend/PreprocessorOptions.h b/include/clang/Frontend/PreprocessorOptions.h
index 3df6512600..4065ae6ff6 100644
--- a/include/clang/Frontend/PreprocessorOptions.h
+++ b/include/clang/Frontend/PreprocessorOptions.h
@@ -195,10 +195,17 @@ public:
/// module.
void resetNonModularOptions() {
Macros.clear();
+ Includes.clear();
+ Modules.clear();
MacroIncludes.clear();
+ ChainedIncludes.clear();
DumpDeserializedPCHDecls = false;
+ ImplicitPCHInclude.clear();
+ ImplicitPTHInclude.clear();
TokenCache.clear();
RetainRemappedFileBuffers = true;
+ PrecompiledPreambleBytes.first = 0;
+ PrecompiledPreambleBytes.second = 0;
}
};