summaryrefslogtreecommitdiffstats
path: root/clang/lib
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2009-03-11 02:22:59 +0000
committerTed Kremenek <kremenek@apple.com>2009-03-11 02:22:59 +0000
commit4e34f958f42abefd57dea9e4c13cc98bb9e292ab (patch)
treebb1eb0de34a537456f76ba45c2d1994959f06966 /clang/lib
parent39df18f6da323b145157fc33fb62187693835bb0 (diff)
downloadbcm5719-llvm-4e34f958f42abefd57dea9e4c13cc98bb9e292ab.tar.gz
bcm5719-llvm-4e34f958f42abefd57dea9e4c13cc98bb9e292ab.zip
Added method "canReasonAbout" to ConstraintManager. This method returns true if
a ConstraintManager can usefully reason about the given SVal. llvm-svn: 66624
Diffstat (limited to 'clang/lib')
-rw-r--r--clang/lib/Analysis/SimpleConstraintManager.cpp4
-rw-r--r--clang/lib/Analysis/SimpleConstraintManager.h3
2 files changed, 7 insertions, 0 deletions
diff --git a/clang/lib/Analysis/SimpleConstraintManager.cpp b/clang/lib/Analysis/SimpleConstraintManager.cpp
index c72f39c2fc2..82cc0bb7bc2 100644
--- a/clang/lib/Analysis/SimpleConstraintManager.cpp
+++ b/clang/lib/Analysis/SimpleConstraintManager.cpp
@@ -20,6 +20,10 @@ namespace clang {
SimpleConstraintManager::~SimpleConstraintManager() {}
+bool SimpleConstraintManager::canReasonAbout(SVal X) const {
+ return true;
+}
+
const GRState*
SimpleConstraintManager::Assume(const GRState* St, SVal Cond, bool Assumption,
bool& isFeasible) {
diff --git a/clang/lib/Analysis/SimpleConstraintManager.h b/clang/lib/Analysis/SimpleConstraintManager.h
index 02292a1cbc4..08ab66063af 100644
--- a/clang/lib/Analysis/SimpleConstraintManager.h
+++ b/clang/lib/Analysis/SimpleConstraintManager.h
@@ -26,6 +26,9 @@ public:
SimpleConstraintManager(GRStateManager& statemgr)
: StateMgr(statemgr) {}
virtual ~SimpleConstraintManager();
+
+ bool canReasonAbout(SVal X) const;
+
virtual const GRState* Assume(const GRState* St, SVal Cond, bool Assumption,
bool& isFeasible);
OpenPOWER on IntegriCloud