summaryrefslogtreecommitdiffstats
path: root/clang/lib/Parse/ParseDeclCXX.cpp
diff options
context:
space:
mode:
authorFariborz Jahanian <fjahanian@apple.com>2009-06-30 23:26:25 +0000
committerFariborz Jahanian <fjahanian@apple.com>2009-06-30 23:26:25 +0000
commit302bb6661f9b74dc2e29cbd4746b8348cf255339 (patch)
tree53fa63bf31c8385f53fc50edfe668c2bda3b66d6 /clang/lib/Parse/ParseDeclCXX.cpp
parentcfcdf5c1ac81180a0f6777cb695090bbe99e7e31 (diff)
downloadbcm5719-llvm-302bb6661f9b74dc2e29cbd4746b8348cf255339.tar.gz
bcm5719-llvm-302bb6661f9b74dc2e29cbd4746b8348cf255339.zip
Patch to support optional nested-name-specifier in in ctor-initializer
list. llvm-svn: 74571
Diffstat (limited to 'clang/lib/Parse/ParseDeclCXX.cpp')
-rw-r--r--clang/lib/Parse/ParseDeclCXX.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/clang/lib/Parse/ParseDeclCXX.cpp b/clang/lib/Parse/ParseDeclCXX.cpp
index 225f9261ef8..44cd5e6bc0c 100644
--- a/clang/lib/Parse/ParseDeclCXX.cpp
+++ b/clang/lib/Parse/ParseDeclCXX.cpp
@@ -1277,8 +1277,10 @@ void Parser::ParseConstructorInitializer(DeclPtrTy ConstructorDecl) {
/// '::'[opt] nested-name-specifier[opt] class-name
/// identifier
Parser::MemInitResult Parser::ParseMemInitializer(DeclPtrTy ConstructorDecl) {
- // FIXME: parse '::'[opt] nested-name-specifier[opt]
-
+ // parse '::'[opt] nested-name-specifier[opt]
+ CXXScopeSpec SS;
+ ParseOptionalCXXScopeSpecifier(SS);
+
if (Tok.isNot(tok::identifier)) {
Diag(Tok, diag::err_expected_member_or_base_name);
return true;
@@ -1306,7 +1308,7 @@ Parser::MemInitResult Parser::ParseMemInitializer(DeclPtrTy ConstructorDecl) {
SourceLocation RParenLoc = MatchRHSPunctuation(tok::r_paren, LParenLoc);
- return Actions.ActOnMemInitializer(ConstructorDecl, CurScope, II, IdLoc,
+ return Actions.ActOnMemInitializer(ConstructorDecl, CurScope, SS, II, IdLoc,
LParenLoc, ArgExprs.take(),
ArgExprs.size(), CommaLocs.data(),
RParenLoc);
OpenPOWER on IntegriCloud