aboutsummaryrefslogtreecommitdiff
path: root/std
diff options
context:
space:
mode:
Diffstat (limited to 'std')
-rw-r--r--std/common.cup8
1 files changed, 8 insertions, 0 deletions
diff --git a/std/common.cup b/std/common.cup
index 2f69354..b97c43a 100644
--- a/std/common.cup
+++ b/std/common.cup
@@ -40,6 +40,14 @@ fn wait(status: int*): int {
return syscall4(SYS_wait4, -1, status, 0, 0);
}
+fn lseek(fd: int, offset: int, whence: int): int {
+ return syscall3(SYS_lseek, fd, offset, whence);
+}
+
+fn mmap(addr: void*, len: int, prot: int, flags: int, fd: int, offset: int): void* {
+ return syscall6(SYS_mmap, addr, len, prot, flags, fd, offset);
+}
+
///////////////////////////////////////////////////////////////////////////////
// Strings