[cfe-commits] r91557 - /cfe/trunk/lib/Analysis/BasicStore.cpp

Ted Kremenek kremenek at apple.com
Wed Dec 16 11:46:44 PST 2009


Author: kremenek
Date: Wed Dec 16 13:46:44 2009
New Revision: 91557

URL: http://llvm.org/viewvc/llvm-project?rev=91557&view=rev
Log:
Temporarily revert 91553.

Modified:
    cfe/trunk/lib/Analysis/BasicStore.cpp

Modified: cfe/trunk/lib/Analysis/BasicStore.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Analysis/BasicStore.cpp?rev=91557&r1=91556&r2=91557&view=diff

==============================================================================
--- cfe/trunk/lib/Analysis/BasicStore.cpp (original)
+++ cfe/trunk/lib/Analysis/BasicStore.cpp Wed Dec 16 13:46:44 2009
@@ -479,11 +479,15 @@
       const Decl& CD = *InitLoc->getDecl();
       if (const ObjCMethodDecl* MD = dyn_cast<ObjCMethodDecl>(&CD)) {
         if (MD->getSelfDecl() == PD) {
-          // FIXME: Add type constraints (when they become available) to
-          // SelfRegion?  (i.e., it implements MD->getClassInterface()).
-          const MemRegion *SelfRegion = MRMgr.getVarRegion(PD, InitLoc);
-          St = BindInternal(St, ValMgr.makeLoc(SelfRegion),
-                            ValMgr.getRegionValueSymbolVal(SelfRegion));
+          // FIXME: Just use a symbolic region, and remove ObjCObjectRegion
+          // entirely.
+          const ObjCObjectRegion *SelfRegion =
+            MRMgr.getObjCObjectRegion(MD->getClassInterface(),
+                                      MRMgr.getHeapRegion());
+
+          St = BindInternal(St, ValMgr.makeLoc(MRMgr.getVarRegion(PD, InitLoc)),
+                            ValMgr.makeLoc(SelfRegion));
+
           // Scan the method for ivar references.  While this requires an
           // entire AST scan, the cost should not be high in practice.
           St = scanForIvars(MD->getBody(), PD, SelfRegion, St);





More information about the cfe-commits mailing list