llvm-project
19 строк · 475.0 Байт
1// RUN: %clang_cc1 -emit-llvm -fobjc-arc -triple x86_64-apple-darwin10 %s -o - | FileCheck %s
2
3__attribute__((objc_root_class))
4@interface Root
5- (Root *)method __attribute__((objc_direct));
6@end
7
8@implementation Root
9// CHECK-LABEL: define internal ptr @"\01-[Root something]"(
10- (id)something {
11// CHECK: %{{[^ ]*}} = call {{.*}} @"\01-[Root method]"
12return [self method];
13}
14
15// CHECK-LABEL: define hidden ptr @"\01-[Root method]"(
16- (id)method {
17return self;
18}
19@end
20