builtin: define atoi & ftell

Alexander Medvednikov 2022-04-29 04:31:51 +03:00 committed by Jef Roosens
parent 893e2ff6cb
commit 23117e6802
Signed by: Jef Roosens
GPG Key ID: B75D4F293C7052DB
1 changed files with 6 additions and 0 deletions

View File

@ -1,5 +1,7 @@
module builtin
// struct C.FILE {}
// <string.h>
fn C.memcpy(dest voidptr, const_src voidptr, n usize) voidptr
@ -12,6 +14,8 @@ fn C.memset(str voidptr, c int, n usize) voidptr
[trusted]
fn C.calloc(int, int) &u8
fn C.atoi(&char) int
fn C.malloc(int) &u8
fn C.realloc(a &u8, b int) &u8
@ -120,6 +124,8 @@ fn C.chdir(path &char) int
fn C.rewind(stream &C.FILE) int
fn C.ftell(&C.FILE) int
fn C.stat(&char, voidptr) int
fn C.lstat(path &char, buf &C.stat) int