aboutsummaryrefslogtreecommitdiff
path: root/lib/Analysis/GRState.cpp
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2009-06-17 22:02:04 +0000
committerTed Kremenek <kremenek@apple.com>2009-06-17 22:02:04 +0000
commit67f28534c090650ffa123afa84ff4a96f56de14e (patch)
tree391a8953c3e6651b3712f1b0c363b99820609e80 /lib/Analysis/GRState.cpp
parent9cdda0cf8528e3d595be9bfa002f0450074beb4d (diff)
Start moving in the direction of removing GRStateRef. Now each
GRState object has a direct reference to its GRStateManager, making the functionality of GRStateRef redunandant. This will lead to some nice API cleanup and code shrinking across libAnalysis. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@73644 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis/GRState.cpp')
-rw-r--r--lib/Analysis/GRState.cpp11
1 files changed, 4 insertions, 7 deletions
diff --git a/lib/Analysis/GRState.cpp b/lib/Analysis/GRState.cpp
index e0e478c307..20e4d1f8a9 100644
--- a/lib/Analysis/GRState.cpp
+++ b/lib/Analysis/GRState.cpp
@@ -69,8 +69,7 @@ const GRState* GRStateManager::Unbind(const GRState* St, Loc LV) {
}
const GRState* GRStateManager::getInitialState() {
-
- GRState StateImpl(EnvMgr.getInitialEnvironment(),
+ GRState StateImpl(this, EnvMgr.getInitialEnvironment(),
StoreMgr->getInitialStore(),
GDMFactory.GetEmptyMap());
@@ -92,14 +91,12 @@ const GRState* GRStateManager::getPersistentState(GRState& State) {
return I;
}
-const GRState* GRStateManager::MakeStateWithStore(const GRState* St,
- Store store) {
- GRState NewSt = *St;
+const GRState* GRState::makeWithStore(Store store) const {
+ GRState NewSt = *this;
NewSt.St = store;
- return getPersistentState(NewSt);
+ return Mgr->getPersistentState(NewSt);
}
-
//===----------------------------------------------------------------------===//
// State pretty-printing.
//===----------------------------------------------------------------------===//