load-order1.m 205 B

123456789101112131415
  1. #include "test.h"
  2. extern int state2, state3;
  3. int state1 = 0;
  4. OBJC_ROOT_CLASS
  5. @interface One @end
  6. @implementation One
  7. +(void)load
  8. {
  9. testassert(state2 == 2 && state3 == 3);
  10. state1 = 1;
  11. }
  12. @end