Objective-C → Swift

/* iSwift is the coolest Objective-C to Swift converter */ #import <Cocoa/Cocoa.h> @interface aClass @property (strong) NSString* someStr; @end @implementation aClass - (void)someFunc:(int)param { for (int k=0; k<10; k++) { NSLog(@"K = %d", k); } } - (NSString*)process:(NSString*)str { return [str uppercaseString]; } @end

  
/* iSwift is the coolest Objective-C to Swift converter */ import Cocoa class aClass { var someStr: String? func someFunc(param: Int32) { for k in 0..<10 { print("K = \(k)") } } func process(str: String) -> String { return str.uppercaseString() } }

- Live compilation / Syntax Checking disabled
- Output restricted to first 25 lines of code