33 lines · plain
1// RUN: %clang_cc1 -rewrite-objc -fobjc-runtime=macosx-fragile-10.5 %s -o -2 3@interface MyList4- (id) allKeys;5@end6 7@implementation MyList8- (unsigned int)countByEnumeratingWithState: (struct __objcFastEnumerationState *)state objects: (id *)items count:(unsigned int)stackcount9{10 return 0;11}12- (id) allKeys { return 0; }13@end14 15@interface MyList (BasicTest)16- (void)compilerTestAgainst;17@end18 19int LOOP(void);20@implementation MyList (BasicTest)21- (void)compilerTestAgainst {22 MyList * el;23 for (el in [el allKeys]) { LOOP(); 24 }25 26 for (id el1 in[el allKeys]) { LOOP(); 27 }28 for (el in([el allKeys])) { LOOP(); 29 }30}31@end32 33