Summary
WebAssembly.AddressValue should be number | bigint instead of number
Expected vs. Actual Behavior
There are a bunch of APIs relying on the type definition of WebAssembly.AddressValue:
WebAssembly.Memory.grow()
WebAssembly.Table.*
- `WebAssembly.MemoryDescriptor.*
WebAssembly.TableDescriptor.*
With Wasm64 memory and tables can be 64-bit, requiring some of the parameters and properties to be bigint instead of number. Currently AddressValue is defines as number, but it should be number | bigint instead.
Maybe the API could be further improved with a separate table or memory type, in which the constructor with the help of WebAssembly.MemoryDescriptor or WebAssembly.TableDescriptor can determine which type we are dealing with.
Playground Link
No response
Browser Support
Have Tried The Latest Releases
Additional Context
This has been explicitly overwritten internally here.
Summary
WebAssembly.AddressValueshould benumber | bigintinstead ofnumberExpected vs. Actual Behavior
There are a bunch of APIs relying on the type definition of
WebAssembly.AddressValue:WebAssembly.Memory.grow()WebAssembly.Table.*WebAssembly.TableDescriptor.*With Wasm64 memory and tables can be 64-bit, requiring some of the parameters and properties to be
bigintinstead ofnumber. CurrentlyAddressValueis defines asnumber, but it should benumber | bigintinstead.Maybe the API could be further improved with a separate table or memory type, in which the constructor with the help of
WebAssembly.MemoryDescriptororWebAssembly.TableDescriptorcan determine which type we are dealing with.Playground Link
No response
Browser Support
Have Tried The Latest Releases
@types/web.Additional Context
This has been explicitly overwritten internally here.