3 ms·
GC has been a future goal since mid-2015 [1]. At some point in the future when (if?) that's supported then WASM may become a better target for compilers than JS
by munificent 9y ago
GC has been a future goal since mid-2015 [1]. At some point in the future when (if?) that's supported then WASM may become a better target for compilers than JS is today. Until then, I don't see WASM as super compelling.
Think of it like this: WASM is effectively a subset of JS. If you're compiling to run in a browser, by targeting that subset, you don't get to use any of the features outside of that subset that browsers already have high performance, battle-tested implementations of. Worse, you then have to reimplement those features yourself and ship them down with the application.
[1]: https://github.com/WebAssembly/design/commit/b2ea1983c0c0e9e03df96df0edc7e18beedd8229 https://github.com/WebAssembly/design/commit/b2ea1983c0c0e9e...