Skip to content

Commit aa464fb

Browse files
committed
doc/next: add release notes for Wasm changes
Document wasmexport and WASI reactor/library mode. Also document that we now permit more types for wasmimport. Fixes #65199. Updates #66984. For #68545. Change-Id: Id26a8c9496650cd154daed679b82223af1848eea Reviewed-on: https://go-review.googlesource.com/c/go/+/634036 Reviewed-by: Dmitri Shuralyov <[email protected]> LUCI-TryBot-Result: Go LUCI <[email protected]> Reviewed-by: David Chase <[email protected]> Reviewed-by: Dmitri Shuralyov <[email protected]>
1 parent be297ba commit aa464fb

File tree

2 files changed

+16
-2
lines changed

2 files changed

+16
-2
lines changed

doc/next/7-ports.md

+16
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,21 @@ Go 1.25 will require macOS 12 Monterey or later.
1414

1515
### WebAssembly {#wasm}
1616

17+
<!-- go.dev/issue/65199, CL 603055 -->
18+
The `go:wasmexport` directive is added for Go programs to export functions to the WebAssembly host.
19+
20+
On WebAssembly System Interface Preview 1 (`GOOS=wasip1, GOARCH=wasm`), Go 1.24 supports
21+
building a Go program as a
22+
[reactor/library](https://github.com/WebAssembly/WASI/blob/63a46f61052a21bfab75a76558485cf097c0dbba/legacy/application-abi.md#current-unstable-abi),
23+
by specifying the `-buildmode=c-shared` build flag.
24+
25+
<!-- go.dev/issue/66984, CL 626615 -->
26+
More types are now permitted as argument or result types for `go:wasmimport` functions.
27+
Specifically, `bool`, `string`, `uintptr`, and pointers to certain types are allowed
28+
(see the [proposal](/issue/66984) for detail),
29+
along with 32-bit and 64-bit integer and float types, and `unsafe.Pointer`, which
30+
are already allowed.
31+
These types are also permitted as argument or result types for `go:wasmexport` functions.
32+
1733
<!-- go.dev/issue/68024 -->
1834
The support files for WebAssembly have been moved to `lib/wasm` from `misc/wasm`.

doc/next/9-todo.md

-2
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ accepted proposal https://go.dev/issue/26232 (from https://go.dev/cl/605256, htt
44
accepted proposal https://go.dev/issue/48429 (from https://go.dev/cl/521958, https://go.dev/cl/521959, https://go.dev/cl/534817, https://go.dev/cl/563175, https://go.dev/cl/613095, https://go.dev/cl/614555, https://go.dev/cl/630695) - cmd/go support for tracking tool dependencies in go.mod is tracked in proposal 48429 itself as a release blocker
55
accepted proposal https://go.dev/issue/50603 (from https://go.dev/cl/595376, https://go.dev/cl/596035, https://go.dev/cl/609155, https://go.dev/cl/611916, https://go.dev/cl/627295) - cmd/go support for stamping pseudo-version in go build is tracked in proposal 50603 itself as a release blocker
66
accepted proposal https://go.dev/issue/64127 (from https://go.dev/cl/597576) - mentioning the new vet check to report invalid Go versions in build tags is tracked in proposal 64127 itself as a release blocker
7-
accepted proposal https://go.dev/issue/65199 (from CL 603055, https://go.dev/cl/603836, https://go.dev/cl/604316, https://go.dev/cl/604975, https://go.dev/cl/606855, https://go.dev/cl/611315) - the new go:wasmexport directive is now tracked in proposal 65199 itself as a release blocker
87
accepted proposal https://go.dev/issue/66387 (from https://go.dev/cl/569955) - extending the copylock analyzer in cmd/vet is now tracked in proposal 66387 itself as a release blocker
98
accepted proposal https://go.dev/issue/69290 (from https://go.dev/cl/613095) - cmd/go caching link output binaries is now tracked in proposal 69290 itself as a release blocker
109
accepted proposal https://go.dev/issue/69393 (from https://go.dev/cl/630775) - automatic crypto/tls.CurvePreferences ordering is now tracked in proposal 69393 itself as a release blocker
@@ -13,7 +12,6 @@ accepted proposal https://go.dev/issue/69393 (from https://go.dev/cl/630775) - a
1312
<!-- Needs to be documented, but not currently tracked via a release-blocking issue.
1413
1514
accepted proposal https://go.dev/issue/66821 (from https://go.dev/cl/602495, https://go.dev/cl/602497, https://go.dev/cl/608175, https://go.dev/cl/608435, https://go.dev/cl/621979, https://go.dev/cl/622115) - crashing the process on error reading randomness (which should not have a path to happen) might need to be mentioned; commented at https://go.dev/issues/66821#issuecomment-2502069725 for next steps; Ian sent out CL 632036
16-
accepted proposal https://go.dev/issue/66984 (from CL 626615, https://go.dev/cl/627059) - relaxation of wasm function import signature type constraints might be something to mention in Go 1.24 release notes; commented at https://go.dev/issue/66984#issuecomment-2502079735 for next steps; Cherry plans to document this along with other Wasm changes
1715
-->
1816

1917
<!-- Maybe worth including or maybe fine not to include in Go 1.24 release notes. Someone more familiar with the change makes the call.

0 commit comments

Comments
 (0)