-
Notifications
You must be signed in to change notification settings - Fork 22.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WebAssembly | Table - add undocumented details and update for externref #27018
Conversation
This comment was marked as resolved.
This comment was marked as resolved.
Co-authored-by: Brian Thomas Smith <[email protected]>
Co-authored-by: Brian Thomas Smith <[email protected]>
Co-authored-by: Brian Thomas Smith <[email protected]>
Co-authored-by: Brian Thomas Smith <[email protected]>
Co-authored-by: Brian Thomas Smith <[email protected]>
- {{jsxref("RangeError")}}: If the current size added with `elementIncrease` exceeds the Table instance's maximum size capacity. | ||
- {{jsxref("TypeError")}}: If `value` is not a value of the element type of the table. | ||
- {{jsxref("RangeError")}}: If there is insufficient memory. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- {{jsxref("RangeError")}}: If the current size added with `elementIncrease` exceeds the Table instance's maximum size capacity. | |
- {{jsxref("TypeError")}}: If `value` is not a value of the element type of the table. | |
- {{jsxref("RangeError")}}: If there is insufficient memory. | |
- {{jsxref("RangeError")}} | |
- : Thrown in one of the following cases: | |
- If the current size added with `elementIncrease` exceeds the Table instance's maximum size capacity. | |
- If there is insufficient memory. | |
- {{jsxref("TypeError")}} | |
- : Thrown if `value` is not a value of the element type of the table. |
...aren't the two RangeError
conditions talking about the same thing, anyway?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
...aren't the two
RangeError
conditions talking about the same thing, anyway?
No. Consider a Table
that doesn't have a set maximum capacity. It's the difference between the artificial check with respect to the array bounds, versus the user agent/client running out of RAM or page memory, or anything of that sort. You can set the maximum size to (2^32 - 1), but might not be able to reach that size in reality. The maximum is just an artificial preset cap, but the memory may not necessarily be pre-allocated.
I can attempt to tersely work this into the error explanations.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Josh-Cena Please confirm that the proceeding commit has appropriately settled any confusion regarding this.
Co-authored-by: Joshua Chen <[email protected]>
files/en-us/webassembly/javascript_interface/table/table/index.md
Outdated
Show resolved
Hide resolved
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@bsmth @Josh-Cena It's been a while - can I get another review here? |
Since this contains non-editorial content changes, it's better to get @bsmth to look at this since I can't claim to be familiar with Wasm docs. |
Ah, understood. |
This pull request has merge conflicts that must be resolved before it can be merged. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Super @vimirage - I've no other suggestions, so leaving a +1 and merging shortly. Thank you 👍🏻
lol I didn't use I'll do that within 24h and tag you in the PR, if you're okay with that. |
No problem, I'm happy to have a look then. |
Description
Removes indications that
WebAssembly.Table
only handles functions.Add undocumented details from the core specification that were not previous present.
Motivation
Keeping documentation up-to-date.