ladybird/Libraries/LibWeb/WebAssembly
Timothy Flynn 27d139e817 LibWeb: Define Wasm native errors correctly
1. Fix typos in some macro invocations of these error types. We now use
   a single xmacro to instantiate error definitions to prevent such
   errors in the future.

2. Use the "WebAssembly." prefix as needed.

3. Allocate the error constructors and prototypes with `realm.create`
   rather than `heap.allocate`. The latter does not invoke `initialize`
   methods. This exposed the next issue:

4. Use the correct intrinsic prototype in the error constructor. We were
   using the base native error prototype. We unfortunately cannot invoke
   OrdinaryCreateFromConstructor from LibJS directly with the correct
   prototype, so an implementation was added here.

5. Use intrinsic accessors to create the constructors. I don't think
   this one was actually a fix, but it makes the setup look more like
   other built-ins.
2025-07-19 16:48:01 -04:00
..
Global.cpp LibWeb: Only set prototype once for object with IDL interface 2025-04-20 18:43:11 +02:00
Global.h LibWeb: Add WebAssembly.Global and exports support for global instances 2024-12-24 15:20:28 +01:00
Global.idl LibWeb: Add WebAssembly.Global and exports support for global instances 2024-12-24 15:20:28 +01:00
Instance.cpp LibWeb: Only set prototype once for object with IDL interface 2025-04-20 18:43:11 +02:00
Instance.h LibGC+Everywhere: Factor out a LibGC from LibJS 2024-11-15 14:49:20 +01:00
Instance.idl Everywhere: Hoist the Libraries folder to the top-level 2024-11-10 12:50:45 +01:00
Memory.cpp LibWeb: Only set prototype once for object with IDL interface 2025-04-20 18:43:11 +02:00
Memory.h LibWeb: Support creation of shared memory in WebAssembly API 2024-12-08 22:10:45 +01:00
Memory.idl LibWeb: Support creation of shared memory in WebAssembly API 2024-12-08 22:10:45 +01:00
Module.cpp LibWeb/WebAssembly: Implement Module::customSections(module) 2025-04-22 08:43:46 -06:00
Module.h Meta: Enforce newlines around namespaces 2025-05-14 02:01:59 -06:00
Module.idl LibWeb/WebAssembly: Implement Module::customSections(module) 2025-04-22 08:43:46 -06:00
Table.cpp LibWeb: Only set prototype once for object with IDL interface 2025-04-20 18:43:11 +02:00
Table.h LibGC+Everywhere: Factor out a LibGC from LibJS 2024-11-15 14:49:20 +01:00
Table.idl Everywhere: Hoist the Libraries folder to the top-level 2024-11-10 12:50:45 +01:00
WebAssembly.cpp LibWeb: Define Wasm native errors correctly 2025-07-19 16:48:01 -04:00
WebAssembly.h LibWeb: Define Wasm native errors correctly 2025-07-19 16:48:01 -04:00
WebAssembly.idl LibWeb/WebAssembly: Define the hacky 'native' errors given in the spec 2025-05-08 03:35:11 -06:00