blob: 0db0cb85bc265698af7636d711222f461092a2f7 [file] [log] [blame]
Shih-wei Liaoea285162010-06-04 12:34:56 -07001// RUN: %clang_cc1 -triple=i686-apple-darwin9 -emit-llvm -o %t %s
2// RUN: grep -e "T@\\\22<X>\\\22" %t
3// RUN: grep -e "T@\\\22<X><Y>\\\22" %t
4// RUN: grep -e "T@\\\22<X><Y><Z>\\\22" %t
5// RUN: grep -e "T@\\\22Foo<X><Y><Z>\\\22" %t
6
7@protocol X, Y, Z;
8@class Foo;
9
10@protocol Proto
11@property (copy) id <X> x;
12@property (copy) id <X, Y> xy;
13@property (copy) id <X, Y, Z> xyz;
14@property(copy) Foo <X, Y, Z> *fooxyz;
15@end
16
17@interface Intf <Proto>
18{
19id <X> IVAR_x;
20id <X, Y> IVAR_xy;
21id <X, Y, Z> IVAR_xyz;
22Foo <X, Y, Z> *IVAR_Fooxyz;
23}
24@end
25
26@implementation Intf
27@dynamic x, xy, xyz, fooxyz;
28@end
29
30/**
31This protocol should generate the following metadata:
32struct objc_property_list __Protocol_Test_metadata = {
33 sizeof(struct objc_property), 4,
34 {
35 { "x", "T@\"<X>\"" },
36 { "xy", "T@\"<X><Y>\"" },
37 { "xyz", "T@\"<X><Y><Z>\"" },
38 { "fooxyz", "T@\"Foo<X><Y><Z>\"" }
39 }
40};
41
42"T@\"<X><Y><Z>\",D
43*/