Maintain subclass list when dealing with hidden classes
Updated 1 year, 5 months ago
| Truls Becken | Reviewers | ||
| EtoileCore | |||
| None | Etoile trunk (etoile/trunk/Etoile) | ||
Maintain the subclass list when creating / destroying hidden classes, so that updating the dtable works recusively. Some lines were reorganized to make the class and metaclass construction code more similar (easier to read). Other than that, the class for the meta class was set wrongly. It should be that of Object's meta class, which means that all meta classes have the same class, so cls->class_pointer->class_pointer should be correct.
Looks good. Please commit.
-
Frameworks/EtoileFoundation/Source/NSObject+Prototypes.m (Diff revision 1) -
Can't you add the new class at the head of this list, instead of the tail, and avoid this loop?
-
Frameworks/EtoileFoundation/Source/NSObject+Prototypes.m (Diff revision 1) -
Is there not a CLS_SETMETA() macro you should use here? If not, please add one with the CLS_SETHIDDEN() one.
-
Frameworks/EtoileFoundation/Source/NSObject+Prototypes.m (Diff revision 1) -
Same here. CLS_SETCLASS() (Possibly doesn't exist; add it if not)