summaryrefslogtreecommitdiffstats
path: root/clang/test/CodeGenObjC/runtime-abi-match.m
blob: ac8eea6cd421828c4439423a52cda1e91bd8c5d0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
// RUN: %clang_cc1 -triple thumbv7--windows-itanium -fobjc-runtime=ios -O1 -fexceptions -fobjc-exceptions -emit-llvm %s -o - | FileCheck %s
// REQUIRES: arm-registered-target

void (*f)(id);
void (*g)(void);
void h(void);

@interface NSNumber
+ (NSNumber *)numberWithInt:(int)i;
@end

void i(void) {
  @try {
    @throw(@1);
  } @catch (id i) {
    (*f)(i);
    (*g)();
  }
}

// CHECK: call arm_aapcs_vfpcc i8* @objc_begin_catch
// CHECK: call arm_aapcs_vfpcc void @objc_end_catch
// CHECK-NOT: call i8* @objc_begin_catch
// CHECK-NOT: call void @objc_end_catch

OpenPOWER on IntegriCloud