]> granicus.if.org Git - clang/commitdiff
Minor code compaction. No functionality change.
authorTed Kremenek <kremenek@apple.com>
Thu, 5 Mar 2009 16:41:21 +0000 (16:41 +0000)
committerTed Kremenek <kremenek@apple.com>
Thu, 5 Mar 2009 16:41:21 +0000 (16:41 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66165 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Analysis/BasicStore.cpp

index c86eea8f0f412653dd8a96512f346a4a664e55ef..e9f57a6209ee5e6261bae19a70bc8d1adff8eb50 100644 (file)
@@ -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);
   }