From 806872f29587bb24d215cf2c4a94513376130fd1 Mon Sep 17 00:00:00 2001 From: Matthias Benkard Date: Mon, 18 Feb 2008 23:51:03 +0100 Subject: Fix class creation on the NeXT runtime. darcs-hash:41fdbaf243c97cf95045e036172deb5db1ff2fd3 --- Objective-C/libobjcl.m | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Objective-C') diff --git a/Objective-C/libobjcl.m b/Objective-C/libobjcl.m index 9531052..c228162 100644 --- a/Objective-C/libobjcl.m +++ b/Objective-C/libobjcl.m @@ -288,7 +288,7 @@ Class objcl_class_metaclass (Class class) { #ifdef __NEXT_RUNTIME__ - return objc_getMetaClass (objcl_class_name (class)); + return object_getClass (class); #else return class_get_meta_class (class); #endif @@ -686,8 +686,7 @@ objcl_create_class (const char *class_name, int i; Class class; - objc_allocateClassPair (superclass, class_name, 0); - class = objcl_find_class (class_name); + class = objc_allocateClassPair (superclass, class_name, 0); for (i = 0; i < ivar_number; i++) preclass_addIvar (class, @@ -811,7 +810,8 @@ objcl_finalise_class (Class class) { #ifdef __NEXT_RUNTIME__ /* FIXME: Should we do this if class is a metaclass? */ - objc_registerClassPair (class); + if (!objcl_object_is_meta_class (class)) + objc_registerClassPair (class); #else int i; int method_count; -- cgit v1.2.3