summaryrefslogtreecommitdiffstats
path: root/clang/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp
diff options
context:
space:
mode:
authorAnna Zaks <ganna@apple.com>2013-03-06 20:25:59 +0000
committerAnna Zaks <ganna@apple.com>2013-03-06 20:25:59 +0000
commit6fe2fc633aa736253317340154127329bee73fe7 (patch)
tree14c1212a2090d0ed57b22c974558135cd479d900 /clang/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp
parentf58b12d8ebc6721956d1a873e9d775746dfd6fd0 (diff)
downloadbcm5719-llvm-6fe2fc633aa736253317340154127329bee73fe7.tar.gz
bcm5719-llvm-6fe2fc633aa736253317340154127329bee73fe7.zip
[analyzer] IDC: Add config option; perform the idc check on first “null node” rather than last “non-null”.
The second modification does not lead to any visible result, but, theoretically, is what we should have been looking at to begin with since we are checking if the node was assumed to be null in an inlined function. llvm-svn: 176576
Diffstat (limited to 'clang/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp')
-rw-r--r--clang/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/clang/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp b/clang/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp
index 5198f4973ad..dca68f71ab5 100644
--- a/clang/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp
+++ b/clang/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp
@@ -152,6 +152,12 @@ bool AnalyzerOptions::shouldAvoidSuppressingNullArgumentPaths() {
/* Default = */ false);
}
+bool AnalyzerOptions::shouldSuppressInlinedDefensiveChecks() {
+ return getBooleanOption(SuppressInlinedDefensiveChecks,
+ "suppress-inlined-defensive-checks",
+ /* Default = */ true);
+}
+
int AnalyzerOptions::getOptionAsInteger(StringRef Name, int DefaultVal) {
SmallString<10> StrBuf;
llvm::raw_svector_ostream OS(StrBuf);
OpenPOWER on IntegriCloud