Add test for class property in category.
@interface Test (Property)
@property (readonly) int val;
+@property (class, readonly) int val2;
@end
@interface Test (Property2)
@implementation Test (Property)
+@dynamic val2;
- (int)val { return 0; }
@end
@@ -29,5 +31,11 @@ int main(int argc, char** argv)
prop = class_getProperty(test, "val2");
assert(prop);
assert(strcmp("Ti,R,D", property_getAttributes(prop)) == 0);
+#ifdef DGS_RUNTIME_V2
+ test = object_getClass(test);
+ objc_property_t prop = class_getProperty(test, "val2");
+ assert(prop);
+ assert(strcmp("Ti,R,D", property_getAttributes(prop)) == 0);
+#endif
}
