- From: Domenic Denicola <notifications@github.com>
- Date: Wed, 20 May 2020 09:00:22 -0700
- To: heycam/webidl <webidl@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
Received on Wednesday, 20 May 2020 16:00:34 UTC
The use of undefined as a sentinel for the end of iteration was problematic for value iterators, where the possible value space could contain undefined.
@TimothyGu, could you take a look?
There's another issue lurking here which is that promises should only be resolved with either Web IDL values (if these are Web IDL `Promise<T>`s) or JS values (if these are JS promises). I considered adding a note explaining that end-of-iteration could be represented as a unique Web IDL/JS object with identity, and a pair could be represented as an appropriate Web IDL dictionary/JS null-prototype object, but I couldn't decide what type of promise these were. I guess we can figure that out as a followup, if we really want to.
You can view, comment on, or merge this pull request online at:
https://github.com/heycam/webidl/pull/885
-- Commit Summary --
* Use an "end of iteration" signal instead of undefined
-- File Changes --
M index.bs (10)
-- Patch Links --
https://github.com/heycam/webidl/pull/885.patch
https://github.com/heycam/webidl/pull/885.diff
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/heycam/webidl/pull/885
Received on Wednesday, 20 May 2020 16:00:34 UTC