Home | History | Annotate | Download | only in CodeGenObjC
      1 // 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 {
     19 id <X> IVAR_x;
     20 id <X, Y> IVAR_xy;
     21 id <X, Y, Z> IVAR_xyz;
     22 Foo <X, Y, Z> *IVAR_Fooxyz;
     23 }
     24 @end
     25 
     26 @implementation Intf 
     27 @dynamic x, xy, xyz, fooxyz;
     28 @end
     29 
     30 /**
     31 This protocol should generate the following metadata:
     32 struct 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 */
     44