Source file
src/runtime/os_js.go
1
2
3
4
5
6
7 package runtime
8
9 import (
10 "unsafe"
11 )
12
13 func exit(code int32)
14
15 func write1(fd uintptr, p unsafe.Pointer, n int32) int32 {
16 if fd > 2 {
17 throw("runtime.write to fd > 2 is unsupported")
18 }
19 wasmWrite(fd, p, n)
20 return n
21 }
22
23
24
25 func wasmWrite(fd uintptr, p unsafe.Pointer, n int32)
26
27 func usleep(usec uint32) {
28
29 }
30
31
32
33 func getRandomData(r []byte)
34
35 func readRandom(r []byte) int {
36 getRandomData(r)
37 return len(r)
38 }
39
40 func goenvs() {
41 goenvs_unix()
42 }
43
View as plain text