1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

compiler: cache modules

This commit is contained in:
Alexander Medvednikov
2019-10-04 15:48:09 +03:00
committed by GitHub
parent f45d3f07ed
commit 52f4f4026b
10 changed files with 422 additions and 242 deletions

View File

@ -9,7 +9,6 @@ fn C.memmove(byteptr, byteptr, int)
//fn C.malloc(int) byteptr
fn C.realloc(byteptr, int) byteptr
pub fn exit(code int) {
C.exit(code)
}
@ -91,17 +90,17 @@ pub fn println(s string) {
pub fn eprintln(s string) {
if isnil(s.str) {
panic('eprintln(NIL)')
}
}
$if mac {
C.fprintf(stderr, '%.*s\n', s.len, s.str)
C.fflush(stderr)
return
}
return
}
$if linux {
C.fprintf(stderr, '%.*s\n', s.len, s.str)
C.fflush(stderr)
return
}
}
// TODO issues with stderr and cross compiling for Linux
println(s)
}