brintos

brintos / llvm-project-archived public Read only

0
0
Text · 581 B · dd63b7b Raw
48 lines · plain
1#import <objc/NSObject.h>2 3@interface ObjcClass : NSObject {4    int field;5}6 7@property int property;8 9+(ObjcClass*)createNew;10 11-(id)init;12 13-(int)method;14 15@end16 17@implementation ObjcClass18 19+(ObjcClass*)createNew {20    return [ObjcClass new];21}22 23-(id)init {24    self = [super init];25    if (self) {26        field = 1111;27        _property = 2222;28    }29    return self;30}31 32-(int)method {33    return 3333;34}35 36@end37 38int main()39{40    @autoreleasepool {41        ObjcClass* objcClass = [ObjcClass new];42        43        int field = 4444;44        45        return 0; // Break here46    }47}48