summaryrefslogtreecommitdiffstats
path: root/clang/lib/Frontend/RewriteObjC.cpp
diff options
context:
space:
mode:
authorFariborz Jahanian <fjahanian@apple.com>2010-02-26 19:05:20 +0000
committerFariborz Jahanian <fjahanian@apple.com>2010-02-26 19:05:20 +0000
commit5743d4d28095f352ae8f964edf6a225f5fff0035 (patch)
tree922f0333d3cdf6f60084faf57c05a749e3d8f8ed /clang/lib/Frontend/RewriteObjC.cpp
parentf8bd9413d55148b3e997cd232ffb21bebe968a92 (diff)
downloadbcm5719-llvm-5743d4d28095f352ae8f964edf6a225f5fff0035.tar.gz
bcm5719-llvm-5743d4d28095f352ae8f964edf6a225f5fff0035.zip
Rewriting of imported variable from outer
blocks's argument in the inner block requires special treatment. Fixes radar 7692419. llvm-svn: 97244
Diffstat (limited to 'clang/lib/Frontend/RewriteObjC.cpp')
-rw-r--r--clang/lib/Frontend/RewriteObjC.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/clang/lib/Frontend/RewriteObjC.cpp b/clang/lib/Frontend/RewriteObjC.cpp
index 0895585e796..26b32478b89 100644
--- a/clang/lib/Frontend/RewriteObjC.cpp
+++ b/clang/lib/Frontend/RewriteObjC.cpp
@@ -4374,6 +4374,7 @@ void RewriteObjC::GetInnerBlockDeclRefExprs(Stmt *S,
if (BlockDeclRefExpr *CDRE = dyn_cast<BlockDeclRefExpr>(S))
if (!isa<FunctionDecl>(CDRE->getDecl()) &&
!CDRE->isByRef() &&
+ !isa<ParmVarDecl>(CDRE->getDecl()) &&
!InnerBlockValueDecls.count(CDRE->getDecl())) {
InnerBlockValueDecls.insert(CDRE->getDecl());
InnerBlockDeclRefs.push_back(CDRE);
OpenPOWER on IntegriCloud