Skip to content
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

TypedArray - Undocumented constructor errors #18764

Closed
ghost opened this issue Jul 25, 2022 · 0 comments · Fixed by #20025
Closed

TypedArray - Undocumented constructor errors #18764

ghost opened this issue Jul 25, 2022 · 0 comments · Fixed by #20025
Labels
Content:JS JavaScript docs

Comments

@ghost
Copy link

ghost commented Jul 25, 2022

MDN URL

https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray

What specific section or headline is this issue about?

No response

What information was incorrect, unhelpful, or incomplete?

There are a few errors that can be thrown from the TypedArray constructors, that remain undocumented.

What did you expect to see?

The following are documented, but ideally should be placed an "Exceptions" section to make it obvious:

  • Construction throws for BigInt <-> non-BigInt mismatch.
  • Construction throws for misaligned byte offset.
  • Construction throws for misaligned byte length.

The following are undocumented:

  • Construction throws for a detached buffer.
  • Construction throws for a byte offset that exceeds the bounds of the buffer.
  • Construction throws for a length that exceeds the bounds of the buffer.

Do you have any supporting links, references, or citations?

The specification: https://tc39.es/ecma262/multipage/indexed-collections.html#sec-initializetypedarrayfromarraybuffer.

Do you have anything more you want to share?

No response

MDN metadata

Page report details
@github-actions github-actions bot added needs triage Triage needed by staff and/or partners. Automatically applied when an issue is opened. Content:JS JavaScript docs labels Jul 25, 2022
@Josh-Cena Josh-Cena removed the needs triage Triage needed by staff and/or partners. Automatically applied when an issue is opened. label Jul 25, 2022
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 1, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Content:JS JavaScript docs
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant