xref: /llvm-project/clang/test/SemaObjCXX/exceptions-fragile.mm (revision 025f428c7303c6b9e11d2a944fe68becd80b7449)
1*5fb5df9cSJohn McCall// RUN: %clang_cc1 -fcxx-exceptions -fexceptions -fobjc-runtime=macosx-fragile-10.5 -fsyntax-only -verify %s
22ca705ebSJohn McCall
32ca705ebSJohn McCall@interface NSException @end
42ca705ebSJohn McCallvoid opaque();
52ca705ebSJohn McCall
62ca705ebSJohn McCallnamespace test0 {
72ca705ebSJohn McCall  void test() {
82ca705ebSJohn McCall    try {
908e17b50SFariborz Jahanian    } catch (NSException *e) { // expected-warning {{cannot catch an exception thrown with @throw in C++ in the non-unified exception model}}
102ca705ebSJohn McCall    }
112ca705ebSJohn McCall  }
122ca705ebSJohn McCall}
13