xref: /aosp_15_r20/external/clang/test/CodeGenObjC/encode-test-2.m (revision 67e74705e28f6214e480b399dd47ea732279e315)
1*67e74705SXin Li// RUN: %clang_cc1 -triple=i686-apple-darwin9 -emit-llvm -o %t %s
2*67e74705SXin Li// RUN: grep -e "@\\\22<X>\\\22" %t
3*67e74705SXin Li// RUN: grep -e "@\\\22<X><Y>\\\22" %t
4*67e74705SXin Li// RUN: grep -e "@\\\22<X><Y><Z>\\\22" %t
5*67e74705SXin Li// RUN: grep -e "@\\\22Foo<X><Y><Z>\\\22" %t
6*67e74705SXin Li// RUN: grep -e "{Intf=@@@@#}" %t
7*67e74705SXin Li
8*67e74705SXin Li@protocol X, Y, Z;
9*67e74705SXin Li@class Foo;
10*67e74705SXin Li
11*67e74705SXin Li@protocol Proto
12*67e74705SXin Li@end
13*67e74705SXin Li
14*67e74705SXin Li@interface Intf <Proto>
15*67e74705SXin Li{
16*67e74705SXin Liid <X> IVAR_x;
17*67e74705SXin Liid <X, Y> IVAR_xy;
18*67e74705SXin Liid <X, Y, Z> IVAR_xyz;
19*67e74705SXin LiFoo <X, Y, Z> *IVAR_Fooxyz;
20*67e74705SXin LiClass <X> IVAR_Classx;
21*67e74705SXin Li}
22*67e74705SXin Li@end
23*67e74705SXin Li
24*67e74705SXin Li@implementation Intf
25*67e74705SXin Li@end
26*67e74705SXin Li
27*67e74705SXin Liint main()
28*67e74705SXin Li{
29*67e74705SXin Li	const char * en = @encode(Intf);
30*67e74705SXin Li}
31