Author: snaroff
Date: Tue Apr 28 12:44:47 2009
New Revision: 70304
URL: http://llvm.org/viewvc/llvm-project?rev=70304&view=rev
Log:
Fix <rdar://problem/6632680> clang ObjC rewriter: unbalanced
objc_exception_try_throw in @synchronized.
Modified:
cfe/branches/Apple/objective-rewrite/tools/clang/Driver/RewriteObjC.cpp
Modified:
cfe/branches/Apple/objective-rewrite/tools/clang/Driver/RewriteObjC.cpp
URL:
http://llvm.org/viewvc/llvm-project/cfe/branches/Apple/objective-rewrite/tools/clang/Driver/RewriteObjC.cpp?rev=70304&r1=70303&r2=70304&view=diff
==============================================================================
--- cfe/branches/Apple/objective-rewrite/tools/clang/Driver/RewriteObjC.cpp
(original)
+++ cfe/branches/Apple/objective-rewrite/tools/clang/Driver/RewriteObjC.cpp Tue
Apr 28 12:44:47 2009
@@ -1488,6 +1488,8 @@
SourceLocation lastCurlyLoc = startLoc;
buf = "}\nelse {\n";
buf += " _rethrow = objc_exception_extract(&_stack);\n";
+ buf += "}\n";
+ buf += "{ /* implicit finally clause */\n";
buf += " if (!_rethrow) objc_exception_try_exit(&_stack);\n";
buf += " objc_sync_exit(";
Expr *syncExpr = new CStyleCastExpr(Context->getObjCIdType(),
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits