diff options
author | Jordy Rose <jediknil@belkadan.com> | 2010-08-03 20:44:35 +0000 |
---|---|---|
committer | Jordy Rose <jediknil@belkadan.com> | 2010-08-03 20:44:35 +0000 |
commit | ddec0926410edfbdef9677577067f214840758fe (patch) | |
tree | 4eda6d5eaaac61c250b7da9740e837e7917a9fdf /clang/lib/Checker/RegionStore.cpp | |
parent | ad867b0aed3be69aa3f08d28c85c3991bf78f690 (diff) | |
download | bcm5719-llvm-ddec0926410edfbdef9677577067f214840758fe.tar.gz bcm5719-llvm-ddec0926410edfbdef9677577067f214840758fe.zip |
Makes GRState::makeWithStore private, to encourage clients to make store changes through GRState instead of directly accessing the StoreManager. Also adds cover methods for InvalidateRegion(s) and EnterStackFrame to GRState.
This is in preparation for proposed region change notifications. No functionality change.
llvm-svn: 110137
Diffstat (limited to 'clang/lib/Checker/RegionStore.cpp')
-rw-r--r-- | clang/lib/Checker/RegionStore.cpp | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/clang/lib/Checker/RegionStore.cpp b/clang/lib/Checker/RegionStore.cpp index f7e19f6f510..733254311f4 100644 --- a/clang/lib/Checker/RegionStore.cpp +++ b/clang/lib/Checker/RegionStore.cpp @@ -357,8 +357,7 @@ public: // Part of public interface to class. SymbolReaper& SymReaper, llvm::SmallVectorImpl<const MemRegion*>& RegionRoots); - const GRState *EnterStackFrame(const GRState *state, - const StackFrameContext *frame); + Store EnterStackFrame(const GRState *state, const StackFrameContext *frame); //===------------------------------------------------------------------===// // Region "extents". @@ -1841,8 +1840,8 @@ const GRState *RegionStoreManager::RemoveDeadBindings(GRState &state, } -GRState const *RegionStoreManager::EnterStackFrame(GRState const *state, - StackFrameContext const *frame) { +Store RegionStoreManager::EnterStackFrame(const GRState *state, + const StackFrameContext *frame) { FunctionDecl const *FD = cast<FunctionDecl>(frame->getDecl()); FunctionDecl::param_const_iterator PI = FD->param_begin(); Store store = state->getStore(); @@ -1866,9 +1865,9 @@ GRState const *RegionStoreManager::EnterStackFrame(GRState const *state, store = Bind(store, ValMgr.makeLoc(MRMgr.getVarRegion(*PI,frame)),ArgVal); } } else - assert(0 && "Unhandled call expression."); + llvm_unreachable("Unhandled call expression."); - return state->makeWithStore(store); + return store; } //===----------------------------------------------------------------------===// |