diff options
author | John McCall <rjmccall@apple.com> | 2010-05-21 20:45:30 +0000 |
---|---|---|
committer | John McCall <rjmccall@apple.com> | 2010-05-21 20:45:30 +0000 |
commit | aec0371e62be013a2e6466688ccf6a7460880262 (patch) | |
tree | 729e23bf5f2a846744510b6968055659a74ff3d4 /lib/Parse/ParseDecl.cpp | |
parent | 3f64a0e3be2c9408f8256bd3aa9f0ce9e268982c (diff) |
Propagate access specifiers to anonymous union members nested within classes.
Fixes <rdar://problem/7987650>.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@104376 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Parse/ParseDecl.cpp')
-rw-r--r-- | lib/Parse/ParseDecl.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/Parse/ParseDecl.cpp b/lib/Parse/ParseDecl.cpp index ec485d2d96..e7650eae84 100644 --- a/lib/Parse/ParseDecl.cpp +++ b/lib/Parse/ParseDecl.cpp @@ -364,7 +364,8 @@ Parser::DeclGroupPtrTy Parser::ParseSimpleDeclaration(unsigned Context, // declaration-specifiers init-declarator-list[opt] ';' if (Tok.is(tok::semi)) { if (RequireSemi) ConsumeToken(); - DeclPtrTy TheDecl = Actions.ParsedFreeStandingDeclSpec(CurScope, DS); + DeclPtrTy TheDecl = Actions.ParsedFreeStandingDeclSpec(CurScope, AS_none, + DS); DS.complete(TheDecl); return Actions.ConvertDeclToDeclGroup(TheDecl); } @@ -1676,7 +1677,7 @@ ParseStructDeclaration(DeclSpec &DS, FieldCallback &Fields) { // If there are no declarators, this is a free-standing declaration // specifier. Let the actions module cope with it. if (Tok.is(tok::semi)) { - Actions.ParsedFreeStandingDeclSpec(CurScope, DS); + Actions.ParsedFreeStandingDeclSpec(CurScope, AS_none, DS); return; } |