diff options
author | Steve Naroff <snaroff@apple.com> | 2008-10-08 17:01:13 +0000 |
---|---|---|
committer | Steve Naroff <snaroff@apple.com> | 2008-10-08 17:01:13 +0000 |
commit | 56ee6896f2efebffb4a2cce5a7610cdf1eddbbbe (patch) | |
tree | 27e5894e15c4faaea557fd1f88702f626aea2fed /lib/AST/DeclBase.cpp | |
parent | 178927517fa09ddbb04dc8ef725b5716c18aae21 (diff) |
- Add BlockDecl AST node.
- Modify BlockExpr to reference the BlockDecl.
This is "cleanup" necessary to improve our lookup semantics for blocks (to fix <rdar://problem/6272905> clang block rewriter: parameter to function not imported into block?).
Still some follow-up work to finish this (forthcoming).
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@57298 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/AST/DeclBase.cpp')
-rw-r--r-- | lib/AST/DeclBase.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/AST/DeclBase.cpp b/lib/AST/DeclBase.cpp index db179fec3e..b42950ffc0 100644 --- a/lib/AST/DeclBase.cpp +++ b/lib/AST/DeclBase.cpp @@ -49,6 +49,7 @@ static unsigned nObjCPropertyDecl = 0; static unsigned nObjCPropertyImplDecl = 0; static unsigned nLinkageSpecDecl = 0; static unsigned nFileScopeAsmDecl = 0; +static unsigned nBlockDecls = 0; static bool StatSwitch = false; @@ -77,6 +78,7 @@ const char *Decl::getDeclKindName() const { case Union: return "Union"; case Class: return "Class"; case Enum: return "Enum"; + case Block: return "Block"; } } @@ -221,6 +223,7 @@ void Decl::addDeclKind(Kind k) { case ObjCPropertyImpl: nObjCPropertyImplDecl++; break; case LinkageSpec: nLinkageSpecDecl++; break; case FileScopeAsm: nFileScopeAsmDecl++; break; + case Block: nBlockDecls++; break; case ImplicitParam: case TranslationUnit: break; |