Home | History | Annotate | Download | only in SemaObjC
      1 // RUN: %clang_cc1 -fsyntax-only -verify %s
      2 
      3 typedef struct objc_class *Class;
      4 
      5 struct objc_class {
      6     Class isa;
      7 };
      8 
      9 typedef struct objc_object {
     10     Class isa;
     11 } *id;
     12 
     13 @interface XCActivityLogSection 
     14 + (unsigned)serializationFormatVersion;
     15 + (unsigned)sectionByDeserializingData;
     16 + (Class)retursClass;
     17 @end
     18 
     19 @implementation XCActivityLogSection
     20 
     21 + (unsigned)serializationFormatVersion
     22 {
     23 
     24     return 0;
     25 }
     26 + (unsigned)sectionByDeserializingData {
     27     unsigned version;
     28     return self.serializationFormatVersion;
     29 }
     30 
     31 + (Class)retursClass {
     32     Class version;
     33     // FIXIT. (*version).isa does not work. Results in compiler error.
     34     return version->isa;
     35 }
     36 
     37 @end
     38 
     39 
     40