summaryrefslogtreecommitdiffstats
path: root/clang/lib
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2011-02-08 22:54:26 +0000
committerTed Kremenek <kremenek@apple.com>2011-02-08 22:54:26 +0000
commit1953f97ac90ebf33a9b98e5356f4f8bddb4f7e8f (patch)
tree0d3cf2704ce37d5918bfc8eed19c33db0b64e97c /clang/lib
parentc6236065b75a50933b4a2a69013ae140326b0108 (diff)
downloadbcm5719-llvm-1953f97ac90ebf33a9b98e5356f4f8bddb4f7e8f.tar.gz
bcm5719-llvm-1953f97ac90ebf33a9b98e5356f4f8bddb4f7e8f.zip
analyzer, retain/release checker: Remove hack where objects passed in message to 'self' are no longer tracked.
llvm-svn: 125130
Diffstat (limited to 'clang/lib')
-rw-r--r--clang/lib/StaticAnalyzer/Core/CFRefCount.cpp18
1 files changed, 0 insertions, 18 deletions
diff --git a/clang/lib/StaticAnalyzer/Core/CFRefCount.cpp b/clang/lib/StaticAnalyzer/Core/CFRefCount.cpp
index 2790d545206..e1a272e46b8 100644
--- a/clang/lib/StaticAnalyzer/Core/CFRefCount.cpp
+++ b/clang/lib/StaticAnalyzer/Core/CFRefCount.cpp
@@ -1385,24 +1385,6 @@ RetainSummaryManager::getInstanceMethodSummary(const ObjCMessage &msg,
// FIXME: The receiver could be a reference to a class, meaning that
// we should use the class method.
RetainSummary *Summ = getInstanceMethodSummary(msg, ID);
-
- // Special-case: are we sending a mesage to "self"?
- // This is a hack. When we have full-IP this should be removed.
- if (isa<ObjCMethodDecl>(LC->getDecl()) && Receiver) {
- if (const loc::MemRegionVal *L = dyn_cast<loc::MemRegionVal>(&receiverV)) {
- // Get the region associated with 'self'.
- if (const ImplicitParamDecl *SelfDecl = LC->getSelfDecl()) {
- SVal SelfVal = state->getSVal(state->getRegion(SelfDecl, LC));
- if (L->StripCasts() == SelfVal.getAsRegion()) {
- // Update the summary to make the default argument effect
- // 'StopTracking'.
- Summ = copySummary(Summ);
- Summ->setDefaultArgEffect(StopTracking);
- }
- }
- }
- }
-
return Summ ? Summ : getDefaultSummary();
}
OpenPOWER on IntegriCloud