-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathos.wu
More file actions
19 lines (15 loc) · 830 Bytes
/
os.wu
File metadata and controls
19 lines (15 loc) · 830 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
# Wu standard library
# Copyright: 2018 wu-lang, MIT License
# Author: evolbug <github.com/evolbug>
# Lua OS wrapper
clock: extern fun() -> int = "os.clock"
date: extern fun(str?, float?) -> any = "os.date"
difftime: extern fun(float, float) -> int = "os.difftime"
execute: extern fun(str?) -> int = "os.execute"
exit: extern fun(float?) = "os.exit"
getenv: extern fun(str) -> str? = "os.getenv"
remove: extern fun(str) -> ...? = "os.remove" # (int?, str?)
rename: extern fun(str, str) -> ...? = "os.rename" # (int?, str?)
setlocale: extern fun(str?, str?) -> str? = "os.setlocale"
time: extern fun(any?) -> int = "os.time"
tmpname: extern fun() -> str = "os.tmpname"