swift tests: Port to Swift 3
Should remain compatible with Swift 2.2
This commit is contained in:
parent
62ec92c8b0
commit
efc986ee93
|
@ -1 +1 @@
|
||||||
printSomething("String from main")
|
printSomething(text:"String from main")
|
||||||
|
|
|
@ -4,7 +4,11 @@
|
||||||
import Glibc
|
import Glibc
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if swift(>=3.0)
|
||||||
|
let fname = CommandLine.arguments[1]
|
||||||
|
#else
|
||||||
let fname = Process.arguments[1]
|
let fname = Process.arguments[1]
|
||||||
|
#endif
|
||||||
let code = "public func getGenerated() -> Int {\n return 42\n}\n"
|
let code = "public func getGenerated() -> Int {\n return 42\n}\n"
|
||||||
|
|
||||||
let f = fopen(fname, "w")
|
let f = fopen(fname, "w")
|
||||||
|
|
Loading…
Reference in New Issue