aboutsummaryrefslogtreecommitdiff
path: root/lib/Analysis/ArrayBoundChecker.cpp
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2009-11-23 23:23:26 +0000
committerTed Kremenek <kremenek@apple.com>2009-11-23 23:23:26 +0000
commitc3120769b3b5b3d86fd7bf83fbff8fb60369c213 (patch)
tree30d5fff0f7dfd3be98431fe33cadab7c71396f63 /lib/Analysis/ArrayBoundChecker.cpp
parent19d67b52b73c04ef8eb663980330a1de2b47c845 (diff)
After performing a bounds check in ArrayBoundChecker, record the fact that a bounds check succeeded by transitioning the ExplodedGraph.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89712 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis/ArrayBoundChecker.cpp')
-rw-r--r--lib/Analysis/ArrayBoundChecker.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/Analysis/ArrayBoundChecker.cpp b/lib/Analysis/ArrayBoundChecker.cpp
index 3d8b3b3d1b..5ab2337a8e 100644
--- a/lib/Analysis/ArrayBoundChecker.cpp
+++ b/lib/Analysis/ArrayBoundChecker.cpp
@@ -80,5 +80,11 @@ void ArrayBoundChecker::VisitLocation(CheckerContext &C, const Stmt *S, SVal l){
report->addRange(S->getSourceRange());
C.EmitReport(report);
+ return;
}
+
+ // Array bound check succeeded. From this point forward the array bound
+ // should always succeed.
+ assert(StInBound);
+ C.addTransition(StInBound);
}