summaryrefslogtreecommitdiffstats
path: root/include/clang/Basic/LangOptions.h
diff options
context:
space:
mode:
authorAlexey Samsonov <vonosmas@gmail.com>2014-10-30 19:33:44 +0000
committerAlexey Samsonov <vonosmas@gmail.com>2014-10-30 19:33:44 +0000
commit845eee38deb08e4f8935aecc7b280cbaeb7edd10 (patch)
treecf9f7714eb3d128eb8476320ebb6bae287abfcec /include/clang/Basic/LangOptions.h
parent16b770cc78954ac7388012fcf02155437fd1c281 (diff)
Get rid of SanitizerOptions::Disabled global. NFC.
SanitizerOptions is not even a POD now, so having global variable of this type, is not nice. Instead, provide a regular constructor and clear() method, and let each CodeGenFunction has its own copy of SanitizerOptions it uses. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@220920 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Basic/LangOptions.h')
-rw-r--r--include/clang/Basic/LangOptions.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/include/clang/Basic/LangOptions.h b/include/clang/Basic/LangOptions.h
index f07c6c7d54..712af265dd 100644
--- a/include/clang/Basic/LangOptions.h
+++ b/include/clang/Basic/LangOptions.h
@@ -34,8 +34,10 @@ struct SanitizerOptions {
/// (files, functions, variables) should not be instrumented.
std::string BlacklistFile;
- /// \brief Cached set of sanitizer options with all sanitizers disabled.
- static const SanitizerOptions Disabled;
+ SanitizerOptions();
+
+ /// \brief Disable all sanitizers.
+ void clear();
};
/// Bitfields of LangOptions, split out from LangOptions in order to ensure that