diff options
author | Fariborz Jahanian <fjahanian@apple.com> | 2011-08-30 17:10:52 +0000 |
---|---|---|
committer | Fariborz Jahanian <fjahanian@apple.com> | 2011-08-30 17:10:52 +0000 |
commit | e8cff36db2b6ec332ab39b1dbe7466e574a9362d (patch) | |
tree | 62a158bb215a41236e79eb4c9f5c4444a3bcd4e5 /lib/Parse/ParseDecl.cpp | |
parent | 3b84ab9f2adff42dcae3509c854a446b95917a10 (diff) |
objc - fixes a regression in declaring c decls nested in
objective-c containers due to recent changes to objc decl
contexts. // rdar://10041908
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@138803 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Parse/ParseDecl.cpp')
-rw-r--r-- | lib/Parse/ParseDecl.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/Parse/ParseDecl.cpp b/lib/Parse/ParseDecl.cpp index 9e2fb25947..5fd95f17fc 100644 --- a/lib/Parse/ParseDecl.cpp +++ b/lib/Parse/ParseDecl.cpp @@ -759,6 +759,9 @@ Parser::DeclGroupPtrTy Parser::ParseDeclaration(StmtVector &Stmts, SourceLocation &DeclEnd, ParsedAttributesWithRange &attrs) { ParenBraceBracketBalancer BalancerRAIIObj(*this); + // Must temporarily exit the objective-c container scope for + // parsing c none objective-c decls. + ObjCDeclContextSwitch ObjCDC(*this); Decl *SingleDecl = 0; Decl *OwnedType = 0; |