mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-08-10 22:13:39 +00:00
all: format code according to Go 1.19 rules
Go 1.19 started reformatting code in a way that makes it more obvious how it will be rendered on pkg.go.dev. It gets it almost right, but not entirely. Therefore, I had to modify some of the comments so that they are formatted correctly.
This commit is contained in:
@@ -18,6 +18,7 @@ func usleep(usec uint) int
|
||||
// Note: off_t is defined as int64 because:
|
||||
// - musl (used on Linux) always defines it as int64
|
||||
// - darwin is practically always 64-bit anyway
|
||||
//
|
||||
//export mmap
|
||||
func mmap(addr unsafe.Pointer, length uintptr, prot, flags, fd int, offset int64) unsafe.Pointer
|
||||
|
||||
@@ -66,6 +67,7 @@ type timespec struct {
|
||||
var stackTop uintptr
|
||||
|
||||
// Entry point for Go. Initialize all packages and call main.main().
|
||||
//
|
||||
//export main
|
||||
func main(argc int32, argv *unsafe.Pointer) int {
|
||||
preinit()
|
||||
@@ -113,6 +115,7 @@ func os_runtime_args() []string {
|
||||
}
|
||||
|
||||
// Must be a separate function to get the correct stack pointer.
|
||||
//
|
||||
//go:noinline
|
||||
func runMain() {
|
||||
run()
|
||||
|
||||
Reference in New Issue
Block a user