Benchmarks game?

This works for me:

#if os(Linux) || os(FreeBSD)
import Glibc
#else
import Darwin
#endif

let f = fopen("./one", "w")
fclose(f)

Unfortunately conditional import is needed for reasons explained in this thread.

1 Like