Swift: Make SwiftMix compatible with Swift 2

This commit is contained in:
Gregor Jasny 2015-09-03 15:26:06 +02:00
parent e7777cc563
commit 874a265c94
1 changed files with 4 additions and 2 deletions

View File

@ -1,8 +1,10 @@
@objc class SwiftMainClass {
import Foundation
@objc class SwiftMainClass : NSObject {
class func SwiftMain(argc:Int, argv:UnsafePointer<UnsafePointer<CChar>>) -> Int32 {
dump("argc: \(argc)")
for (var i = 0; i < argc; ++i) {
var argi = String.fromCString(argv[i])
let argi = String.fromCString(argv[i])
dump("arg[\(i)]: \(argi)");
}
return 0;