[cfe-commits] r54024 - /cfe/trunk/lib/Analysis/CheckObjCDealloc.cpp
Ted Kremenek
kremenek at apple.com
Fri Jul 25 10:04:50 PDT 2008
Author: kremenek
Date: Fri Jul 25 12:04:49 2008
New Revision: 54024
URL: http://llvm.org/viewvc/llvm-project?rev=54024&view=rev
Log:
Only warn about missing/incomplete -dealloc implementations when a class contains a non-SEL, non-IBOutlet ivar that references an ObjC object.
Modified:
cfe/trunk/lib/Analysis/CheckObjCDealloc.cpp
Modified: cfe/trunk/lib/Analysis/CheckObjCDealloc.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Analysis/CheckObjCDealloc.cpp?rev=54024&r1=54023&r2=54024&view=diff
==============================================================================
--- cfe/trunk/lib/Analysis/CheckObjCDealloc.cpp (original)
+++ cfe/trunk/lib/Analysis/CheckObjCDealloc.cpp Fri Jul 25 12:04:49 2008
@@ -71,12 +71,13 @@
ObjCIvarDecl* ID = *I;
QualType T = ID->getType();
- if ((T->isPointerType() || Ctx.isObjCObjectPointerType(T)) &&
- (ID->getAttr<IBOutletAttr>() == 0 && // Skip IBOutlets.
- !isSEL(T, SelII))) { // Skip SEL ivars.
- containsPointerIvar = true;
- break;
- }
+ if (!Ctx.isObjCObjectPointerType(T) ||
+ ID->getAttr<IBOutletAttr>() || // Skip IBOutlets.
+ isSEL(T, SelII)) // Skip SEL ivars.
+ continue;
+
+ containsPointerIvar = true;
+ break;
}
if (!containsPointerIvar)
More information about the cfe-commits
mailing list