• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1// RUN: %clang_cc1 -x objective-c -Wno-return-type -fblocks -fms-extensions -rewrite-objc %s -o %t-rw.cpp
2// RUN: %clang_cc1 -fsyntax-only -fcxx-exceptions -fexceptions  -Wno-address-of-temporary -D"id=void*" -D"SEL=void*" -D"__declspec(X)=" %t-rw.cpp
3
4void foo(id arg);
5
6@interface NSException
7@end
8
9@interface Foo
10@end
11
12@implementation Foo
13- (void)bar {
14    @try {
15    } @catch (NSException *e) {
16	foo(e);
17    }
18    @catch (Foo *f) {
19    }
20    @catch (...) {
21      @try {
22      }
23      @catch (Foo *f1) {
24	foo(f1);
25      }
26      @catch (id pid) {
27	foo(pid);
28      }
29    }
30}
31@end
32