diff options
Diffstat (limited to 'lib/Rewrite/RewriteObjC.cpp')
-rw-r--r-- | lib/Rewrite/RewriteObjC.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/Rewrite/RewriteObjC.cpp b/lib/Rewrite/RewriteObjC.cpp index 5018112699..6e8789f6db 100644 --- a/lib/Rewrite/RewriteObjC.cpp +++ b/lib/Rewrite/RewriteObjC.cpp @@ -4922,6 +4922,9 @@ void RewriteObjC::HandleDeclInMainFile(Decl *D) { // definitions using the same code. RewriteBlocksInFunctionProtoType(FD->getType(), FD); + if (!FD->isThisDeclarationADefinition()) + break; + // FIXME: If this should support Obj-C++, support CXXTryStmt if (CompoundStmt *Body = dyn_cast_or_null<CompoundStmt>(FD->getBody())) { CurFunctionDef = FD; |