Skip to content

Commit

Permalink
Rename "addressType" to "address" in the JS API (#92)
Browse files Browse the repository at this point in the history
  • Loading branch information
bvisness authored Oct 21, 2024
1 parent 4056ff9 commit 9e107e0
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions document/js-api/index.bs
Original file line number Diff line number Diff line change
Expand Up @@ -679,7 +679,7 @@ Note: The use of this synchronous API is discouraged, as some implementations so
dictionary MemoryDescriptor {
required AddressValue initial;
AddressValue maximum;
AddressType addressType;
AddressType address;
};

[LegacyNamespace=WebAssembly, Exposed=*]
Expand Down Expand Up @@ -748,7 +748,7 @@ which can be simultaneously referenced by multiple {{Instance}} objects. Each

<div algorithm>
The <dfn constructor for="Memory">Memory(|descriptor|)</dfn> constructor, when invoked, performs the following steps:
1. If |descriptor|["addressType"] [=map/exists=], let |addrtype| be |descriptor|["addressType"]; otherwise, let |addrtype| be "i32".
1. If |descriptor|["address"] [=map/exists=], let |addrtype| be |descriptor|["address"]; otherwise, let |addrtype| be "i32".
1. Let |initial| be [=?=] [=AddressValueToU64=](|descriptor|["initial"], |addrtype|).
1. If |descriptor|["maximum"] [=map/exists=], let |maximum| be [=?=] [=AddressValueToU64=](|descriptor|["maximum"], |addrtype|); otherwise, let |maximum| be empty.
1. If |maximum| is not empty and |maximum| &lt; |initial|, throw a {{RangeError}} exception.
Expand Down Expand Up @@ -875,7 +875,7 @@ dictionary TableDescriptor {
required TableKind element;
required AddressValue initial;
AddressValue maximum;
AddressType addressType;
AddressType address;
};

[LegacyNamespace=WebAssembly, Exposed=*]
Expand Down Expand Up @@ -915,7 +915,7 @@ Each {{Table}} object has a \[[Table]] internal slot, which is a [=table address
1. Let |elementtype| be [=ToValueType=](|descriptor|["element"]).
1. If |elementtype| is not a [=reftype=],
1. [=Throw=] a {{TypeError}} exception.
1. If |descriptor|["addressType"] [=map/exists=], let |addrtype| be |descriptor|["addressType"]; otherwise, let |addrtype| be "i32".
1. If |descriptor|["address"] [=map/exists=], let |addrtype| be |descriptor|["address"]; otherwise, let |addrtype| be "i32".
1. Let |initial| be [=?=] [=AddressValueToU64=](|descriptor|["initial"], |addrtype|).
1. If |descriptor|["maximum"] [=map/exists=], let |maximum| be [=?=] [=AddressValueToU64=](|descriptor|["maximum"], |addrtype|); otherwise, let |maximum| be empty.
1. If |maximum| is not empty and |maximum| &lt; |initial|, throw a {{RangeError}} exception.
Expand Down

0 comments on commit 9e107e0

Please sign in to comment.