diff options
author | Fariborz Jahanian <fjahanian@apple.com> | 2012-07-05 19:34:20 +0000 |
---|---|---|
committer | Fariborz Jahanian <fjahanian@apple.com> | 2012-07-05 19:34:20 +0000 |
commit | 39700f81c5b42e6be93be10275602915f872fc86 (patch) | |
tree | f9345dc6386be34cf3e264fd95881e59e17cb9bc /lib/Parse/ParseDecl.cpp | |
parent | d797a85866fd5ce62850dd145396b451364032a3 (diff) |
objective-c++ parsing. Turn off delayed parsing
of out-of-line c++ method definition which happens
to be inside an objc class implementation
until I can figure out how to do it. This is to fix
a broken project.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@159772 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Parse/ParseDecl.cpp')
-rw-r--r-- | lib/Parse/ParseDecl.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/Parse/ParseDecl.cpp b/lib/Parse/ParseDecl.cpp index a96e29556b..d91457c0d6 100644 --- a/lib/Parse/ParseDecl.cpp +++ b/lib/Parse/ParseDecl.cpp @@ -1322,7 +1322,9 @@ Parser::DeclGroupPtrTy Parser::ParseDeclGroup(ParsingDeclSpec &DS, // Look at the next token to make sure that this isn't a function // declaration. We have to check this because __attribute__ might be the // start of a function definition in GCC-extended K&R C. - !isDeclarationAfterDeclarator()) { + !isDeclarationAfterDeclarator() && + (!CurParsedObjCImpl || Tok.isNot(tok::l_brace) || + (getLangOpts().CPlusPlus && D.getCXXScopeSpec().isSet()))) { if (isStartOfFunctionDefinition(D)) { if (DS.getStorageClassSpec() == DeclSpec::SCS_typedef) { |