diff options
author | cornelk <[email protected]> | 2020-05-12 00:05:11 +0300 |
---|---|---|
committer | Ayke <[email protected]> | 2020-05-12 16:53:07 +0200 |
commit | e907db1481c73ef778b37b5c5478037e390768fc (patch) | |
tree | cb1af2a22ded7dac7e1d19305db512cec880f754 /src/os/proc.go | |
parent | 6b8940421e169a751dd039d8c7d1b1c4a1465fb2 (diff) | |
download | tinygo-e907db1481c73ef778b37b5c5478037e390768fc.tar.gz tinygo-e907db1481c73ef778b37b5c5478037e390768fc.zip |
os: add Args and stub it with mock data
Diffstat (limited to 'src/os/proc.go')
-rw-r--r-- | src/os/proc.go | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/os/proc.go b/src/os/proc.go index a7718c436..d3bfb1270 100644 --- a/src/os/proc.go +++ b/src/os/proc.go @@ -9,6 +9,15 @@ import ( "syscall" ) +// Args hold the command-line arguments, starting with the program name. +var Args []string + +func init() { + Args = runtime_args() +} + +func runtime_args() []string // in package runtime + // Exit causes the current program to exit with the given status code. // Conventionally, code zero indicates success, non-zero an error. // The program terminates immediately; deferred functions are not run. |