1 // TEST_CFLAGS -Wno-deprecated-declarations
15 #include <objc/objc-gdb.h>
16 #include <objc/runtime.h>
25 // Class should not be realized yet
26 // fixme not true during class hash rearrangement
27 // result = NXMapGet(gdb_objc_realized_classes, "TestRoot");
28 // testassert(!result);
31 // Now class should be realized
33 result = (Class)objc_unretainedObject(NXMapGet(gdb_objc_realized_classes, "TestRoot"));
35 testassert(result == [TestRoot class]);
37 result = (Class)objc_unretainedObject(NXMapGet(gdb_objc_realized_classes, "DoesNotExist"));
42 struct objc_class query;
45 query.name = "TestRoot";
46 result = (Class)NXHashGet(_objc_debug_class_hash, &query);
48 testassert((id)result == [TestRoot class]);
50 query.name = "DoesNotExist";
51 result = (Class)NXHashGet(_objc_debug_class_hash, &query);