// ----------------------------------------------------------------------------- internal static string rb_class_name(Class klass) { return klass.class_real().class_path(); }
internal static Class rb_make_metaclass(Basic obj, Class super) //status: done { Class klass = new Class("meta->" + (obj is Class ? ((Class)obj)._name : "??"), super, Type.Singleton); obj.my_class = klass; klass.attached = obj; if (obj is Class && ((Class)obj)._type == Type.Singleton) { klass.my_class = klass; klass.super = ((Class)obj).super.class_real().my_class; } else { Class metasuper = super.class_real().my_class; if (metasuper != null) klass.my_class = metasuper; } return klass; }