mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-08-02 10:07:47 +00:00
7e7814a087
These functions were exported by accident, because the compiler had no
way of saying these functions shouldn't be exported.
This can be a big code size reduction for small programs. Before:
$ tinygo build -o test.wasm -target=wasi -no-debug -scheduler=none ./testdata/alias.go && ls -l test.wasm
-rwxrwxr-x 1 ayke ayke 2947 8 sep 13:47 test.wasm
After:
$ tinygo build -o test.wasm -target=wasi -no-debug -scheduler=none ./testdata/alias.go && ls -l test.wasm
-rwxrwxr-x 1 ayke ayke 968 8 sep 13:47 test.wasm
This is all because the GC isn't needed anymore.
This commit also adds support for using //go:wasm-module to set the
module name of an exported function (the default remains env).