Older versions of the runtime don't like it when the root class
has a missing initialize method. They try to forward to an non-
existent super class resulting in a crash.
TODO: maybe we can diagnose this.
gcc/testsuite/ChangeLog:
* objc.dg/ivar-scope-4.m: Add inititialize method to the
root class.
int someivar;
}
++ (id) initialize;
+ (id) alloc;
- (id) init;
- (int) getGlobal;
@end
@implementation MyClass
++ (id) initialize
+{
+ return self;
+}
+
+ (id) alloc
{
return class_createInstance (self, 0);