Instead of returning whichever argument was NaN, return the canonical
NaN instead. The spec allows the old behavior:
"Following the recommendation that operators propagate NaN payloads
from their operands is permitted but not required."
But Chrome, Firefox and Safari do not propagate the operand payloads.
Fixes 448 WPT subtests in `wasm/core`.
Co-authored-by: Ali Mohammad Pur <ali.mpfard@gmail.com>
The spec tells us to reject the promise with a RuntimeError instead of a
LinkError whenever the module's start function fails during module
instantiation. Fixes 1 WPT subtest in `wasm/core`.
...instead of specially handling JS::Completion.
This makes it possible for LibWeb/LibJS to have full control over how
these things are made, stored, and visited (whenever).
Fixes an issue where we couldn't roundtrip a JS exception through Wasm.