The only similarity, really, is that they're both binary formats.
Just like Unity is already doing with their Lightweight Components and HPC#.
I don't follow. Why would losing optimizations from one language prevent optimizations from being done in an IL? Are you saying that Web Assembly can't be as fast as JavaScript? If so, why?
> There is literally no benefit, aside from being able to implement non-backwards-compatible features
You ignored the benefit I outlined above. Why would you want a single scripting language to be the only one to ever be used in a web browser? Heck, web assembly can even make the ECMAScript iteration loop tighter if you really wanted to.
I'm having trouble seeing the downsides to this approach.
It will be a long time for it to be possible for JavaScript to "just be compiled" to WebAssembly while keeping the same performance characteristics, if it ever happens.
[0] https://github.com/WebAssembly/gc/issues/32 has some concerns from language implementors.
Even if WASM had APIs for GC, interaction with the DOM and browser APIs, interop with JS, etc, you would still have to compile the JS ahead of time into a static binary, and so the browser would not be able to apply its JIT magic to your code.
I'm all for the dream of running any arbitrary language in the browser, but it's simply not realistic for any language that has a large runtime, which is most dynamic languages.
They also unveiled Autocad running on WebAssembly.
... and I didn't spot any mention of "WebAssembly 2.0", whatever that might mean...
Or how the Autocad guy explains the C++ code is exactly the same as on the core product.
We might loose the battle against Electron, but in the end the browser will be just yet another general purpose VM.