Debian Codegraph @

clang/test/CodeGenObjC/exceptions-nonfragile.m

raw
1 // RUN: %clang_cc1 -triple x86_64-apple-darwin10 -emit-llvm -fexceptions -fobjc-exceptions -o - %s | FileCheck %s
2
3 // CHECK: declare void @objc_exception_rethrow()
4
5 void protos(void) {
6 extern void foo(void);
7 @try {
8 foo();
9 } @catch (id e) {
10 @throw;
11 }
12 }
13
14 void throwing(void) {
15 @throw(@"error!");
16 }
17
18 void die(void) __attribute__((nothrow, noreturn));
19 void test2(void) {
20 @try {
21 die();
22 } @finally {
23 extern void test2_helper(void);
24 test2_helper();
25 }
26
27 // CHECK-LABEL: define{{.*}} void @test2()
28 // CHECK-NOT: call void @test2_helper()
29 }