diff options
author | Ted Kremenek <kremenek@apple.com> | 2009-03-05 16:41:21 +0000 |
---|---|---|
committer | Ted Kremenek <kremenek@apple.com> | 2009-03-05 16:41:21 +0000 |
commit | 39fc715e6a33da2b452dc0a908e934eb575f1b15 (patch) | |
tree | 5b5dcf9ef980e22762bba7ad9b873fc47467eb29 /lib/Analysis/BasicStore.cpp | |
parent | 2c8e7881bd21bbd9d92ea25fe5b88c6f9640a13d (diff) |
Minor code compaction. No functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66165 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis/BasicStore.cpp')
-rw-r--r-- | lib/Analysis/BasicStore.cpp | 16 |
1 files changed, 5 insertions, 11 deletions
diff --git a/lib/Analysis/BasicStore.cpp b/lib/Analysis/BasicStore.cpp index c86eea8f0f..e9f57a6209 100644 --- a/lib/Analysis/BasicStore.cpp +++ b/lib/Analysis/BasicStore.cpp @@ -28,8 +28,7 @@ public: BasicStoreSubRegionMap() {} bool iterSubRegions(const MemRegion* R, Visitor& V) const { - // Do nothing. No subregions. - return true; + return true; // Do nothing. No subregions. } }; @@ -54,8 +53,7 @@ public: SVal Retrieve(const GRState *state, Loc loc, QualType T = QualType()); const GRState* Bind(const GRState* St, Loc L, SVal V) { - Store store = St->getStore(); - store = BindInternal(store, L, V); + Store store = BindInternal(St->getStore(), L, V); return StateMgr.MakeStateWithStore(St, store); } @@ -95,9 +93,7 @@ public: /// getSelfRegion - Returns the region for the 'self' (Objective-C) or /// 'this' object (C++). When used when analyzing a normal function this /// method returns NULL. - const MemRegion* getSelfRegion(Store) { - return SelfRegion; - } + const MemRegion* getSelfRegion(Store) { return SelfRegion; } /// RemoveDeadBindings - Scans a BasicStore of 'state' for dead values. /// It returns a new Store with these values removed, and populates LSymbols @@ -110,14 +106,12 @@ public: void iterBindings(Store store, BindingsHandler& f); const GRState* BindDecl(const GRState* St, const VarDecl* VD, SVal InitVal) { - Store store = St->getStore(); - store = BindDeclInternal(store, VD, &InitVal); + Store store = BindDeclInternal(St->getStore(), VD, &InitVal); return StateMgr.MakeStateWithStore(St, store); } const GRState* BindDeclWithNoInit(const GRState* St, const VarDecl* VD) { - Store store = St->getStore(); - store = BindDeclInternal(store, VD, 0); + Store store = BindDeclInternal(St->getStore(), VD, 0); return StateMgr.MakeStateWithStore(St, store); } |