1
0
mirror of https://github.com/golang/go synced 2024-11-06 06:36:20 -07:00
go/misc/wasm
Richard Musiol 138bfc2809 syscall/js: make zero js.Value represent "undefined"
This commit changes the encoding of js.Value so that the zero js.Value
represents the JavaScript value "undefined". This is what users
intuitively expect.

Specifically, the encodings of "undefined" and the number zero have
been swapped.

Fixes #27592.

Change-Id: Icfc832c8cdf7a8a78bd69d20e00a04dbed0ccd10
Reviewed-on: https://go-review.googlesource.com/c/143137
Run-TryBot: Richard Musiol <neelance@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2018-10-18 15:20:30 +00:00
..
go_js_wasm_exec
wasm_exec.html misc/wasm: add mention of polyfill for Edge support 2018-10-02 17:25:11 +00:00
wasm_exec.js syscall/js: make zero js.Value represent "undefined" 2018-10-18 15:20:30 +00:00