[whatwg/fetch] Editorial: Fix realmless ArrayBuffer creation (PR #1751)

Fixes https://github.com/whatwg/fetch/issues/1675, maybe.

@annevk in that issue also points out that the [extract a body [...]](https://fetch.spec.whatwg.org/#concept-bodyinit-extract) algorithm also creates a Uint8Array in an ad-hoc way, which I've also tried to fix. Unfortunately I don't know what realm to use there - unlike the original issue, these aren't method steps. I am guessing that when the realm is unspecified (which it very often isn't - for example, earlier in the same algorithm there is "set stream to a new ReadableStream object" without a realm argument), it's implicitly the current realm? But maybe we need to thread a realm argument into this algorithm (and quite a few others), or possibly just explicitly pass "the current realm".


<!--
    This comment and the below content is programmatically generated.
    You may add a comma-separated list of anchors you'd like a
    direct link to below (e.g. #idl-serializers, #idl-sequence):

    Don't remove this comment or modify anything below this line.
    If you don't want a preview generated for this pull request,
    just replace the whole of this comment's content by "no preview"
    and remove what's below.
-->
***
<a href="https://whatpr.org/fetch/1751.html" title="Last updated on May 4, 2024, 5:13 AM UTC (82a8d8d)">Preview</a> | <a href="https://whatpr.org/fetch/1751/14bad1d...82a8d8d.html" title="Last updated on May 4, 2024, 5:13 AM UTC (82a8d8d)">Diff</a>
You can view, comment on, or merge this pull request online at:

  https://github.com/whatwg/fetch/pull/1751

-- Commit Summary --

  * specify realm when creating arraybuffer
  * refer to algorithm for making Uint8Array

-- File Changes --

    M fetch.bs (8)

-- Patch Links --

https://github.com/whatwg/fetch/pull/1751.patch
https://github.com/whatwg/fetch/pull/1751.diff

-- 
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/fetch/pull/1751
You are receiving this because you are subscribed to this thread.

Message ID: <whatwg/fetch/pull/1751@github.com>

Received on Saturday, 4 May 2024 05:13:53 UTC