Author: fjahanian
Date: Thu Jun 23 16:17:59 2011
New Revision: 133760

URL: http://llvm.org/viewvc/llvm-project?rev=133760&view=rev
Log:
Improve on warning when objc pointer is used in
c++ catch in fragile abi - per Eli's request.

Modified:
    cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td
    cfe/trunk/test/SemaObjCXX/exceptions-fragile.mm

Modified: cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td
URL: 
http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td?rev=133760&r1=133759&r2=133760&view=diff
==============================================================================
--- cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td (original)
+++ cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td Thu Jun 23 16:17:59 
2011
@@ -3154,7 +3154,7 @@
 def err_objc_pointer_cxx_catch_gnu : Error<
   "can't catch Objective C exceptions in C++ in the GNU runtime">;
 def warn_objc_pointer_cxx_catch_fragile : Warning<
-  "catching Objective C exceptions in C++ in the non-unified "
+  "can not catch an exception thrown with @throw in C++ in the non-unified "
   "exception model">, InGroup<ObjCNonUnifiedException>;
 def err_objc_object_catch : Error<
   "can't catch an Objective C object by value">;

Modified: cfe/trunk/test/SemaObjCXX/exceptions-fragile.mm
URL: 
http://llvm.org/viewvc/llvm-project/cfe/trunk/test/SemaObjCXX/exceptions-fragile.mm?rev=133760&r1=133759&r2=133760&view=diff
==============================================================================
--- cfe/trunk/test/SemaObjCXX/exceptions-fragile.mm (original)
+++ cfe/trunk/test/SemaObjCXX/exceptions-fragile.mm Thu Jun 23 16:17:59 2011
@@ -6,7 +6,7 @@
 namespace test0 {
   void test() {
     try {
-    } catch (NSException *e) { // expected-warning {{catching Objective C 
exceptions in C++ in the non-unified exception model 
[-Wobjc-nonunified-exceptions]}}
+    } catch (NSException *e) { // expected-warning {{can not catch an 
exception thrown with @throw in C++ in the non-unified exception model}}
     }
   }
 }


_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to