summaryrefslogtreecommitdiffstats
path: root/clang/lib/StaticAnalyzer/CFRefCount.cpp
diff options
context:
space:
mode:
authorJohn McCall <rjmccall@apple.com>2011-02-02 13:00:07 +0000
committerJohn McCall <rjmccall@apple.com>2011-02-02 13:00:07 +0000
commitc63de66c4f50973b54e3341194bf847e7bfefe1f (patch)
treedb578fef9737ff5f7d251069278373980f94fe22 /clang/lib/StaticAnalyzer/CFRefCount.cpp
parentfdfdbd091d663b1b3c12cf96064d755887b8aaa7 (diff)
downloadbcm5719-llvm-c63de66c4f50973b54e3341194bf847e7bfefe1f.tar.gz
bcm5719-llvm-c63de66c4f50973b54e3341194bf847e7bfefe1f.zip
An insomniac stab at making block declarations list the variables they close
on, as well as more reliably limiting invalid references to locals from nested scopes. llvm-svn: 124721
Diffstat (limited to 'clang/lib/StaticAnalyzer/CFRefCount.cpp')
-rw-r--r--clang/lib/StaticAnalyzer/CFRefCount.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/StaticAnalyzer/CFRefCount.cpp b/clang/lib/StaticAnalyzer/CFRefCount.cpp
index 3278c4a2bfa..2790d545206 100644
--- a/clang/lib/StaticAnalyzer/CFRefCount.cpp
+++ b/clang/lib/StaticAnalyzer/CFRefCount.cpp
@@ -3417,7 +3417,7 @@ void RetainReleaseChecker::PostVisitBlockExpr(CheckerContext &C,
// Scan the BlockDecRefExprs for any object the retain/release checker
// may be tracking.
- if (!BE->hasBlockDeclRefExprs())
+ if (!BE->getBlockDecl()->hasCaptures())
return;
const GRState *state = C.getState();
OpenPOWER on IntegriCloud