2 Variant on fakeRealizedClass which tests a fake class with no superclass rdar://problem/67692760
6 objc\[\d+\]: realized class 0x[0-9a-fA-F]+ has corrupt data pointer 0x[0-9a-fA-F]+
13 #include <objc/NSObject.h>
15 #define RW_REALIZED (1U<<31)
18 struct ObjCClass * __ptrauth_objc_isa_pointer isa;
19 struct ObjCClass * __ptrauth_objc_super_pointer superclass;
27 uint32_t instanceStart;
28 uint32_t instanceSize;
34 const uint8_t * ivarLayout;
35 struct ObjCClass * nonMetaClass;
39 struct ObjCMethodList * __ptrauth_objc_method_list_pointer baseMethodList;
40 struct protocol_list_t * baseProtocols;
41 const struct ivar_list_t * ivars;
43 const uint8_t * weakIvarLayout;
44 struct property_list_t *baseProperties;
47 extern struct ObjCClass OBJC_METACLASS_$_NSObject;
48 extern struct ObjCClass OBJC_CLASS_$_NSObject;
50 struct ObjCClass_ro FakeSuperclassRO = {
54 struct ObjCClass FakeSuperclass = {
55 &OBJC_METACLASS_$_NSObject,
59 (uintptr_t)&FakeSuperclassRO
62 struct ObjCClass_ro FakeSubclassRO;
64 struct ObjCClass FakeSubclass = {
69 (uintptr_t)&FakeSubclassRO
72 static struct ObjCClass *class_ptr __attribute__((used)) __attribute((section("__DATA,__objc_nlclslist"))) = &FakeSubclass;