CursorVisitor: Pull ObjCMessageExpr and explicit casts into data-recursion algorithm.
[clang.git] / test / CodeGenObjC / link-errors.m
bloba82f0ceaf76dc55de7de37b226e56a5477be0479
1 // RUN: %clang_cc1 -triple i386-apple-darwin9 -emit-llvm -o %t %s
2 // RUN: grep '.lazy_reference .objc_class_name_A' %t | count 1
3 // RUN: grep '.lazy_reference .objc_class_name_Unknown' %t | count 1
4 // RUN: grep '.lazy_reference .objc_class_name_Protocol' %t | count 1
5 // RUN: %clang_cc1 -triple i386-apple-darwin9 -DWITH_IMPL -emit-llvm -o %t %s
6 // RUN: grep '.lazy_reference .objc_class_name_Root' %t | count 1
8 @interface Root
9 -(id) alloc;
10 -(id) init;
11 @end
13 @protocol P;
15 @interface A : Root
16 @end
18 @interface A (Category)
19 +(void) foo;
20 @end
22 #ifdef WITH_IMPL
23 @implementation A
24 @end
25 #endif
27 @interface Unknown
28 +test;
29 @end
32 int main() {
33   id x = @protocol(P);
34   [ A alloc ];
35   [ A foo ];
36   [ Unknown test ];
37   return 0;