- From: Boris Zbarsky <notifications@github.com>
- Date: Thu, 12 Mar 2020 15:16:35 -0700
- To: heycam/webidl <webidl@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
Received on Thursday, 12 March 2020 22:16:48 UTC
bzbarsky approved this pull request. Thank you, this looks great! > + 1. If |P| [=is an array index=], then return the result of + [=observable array exotic object/setting the indexed value=] given |handler|, |P|, and |V|. + 1. Return [=?=] |O|.\[[Set]](|P|, |V|, |Receiver|). +</div> + +<h4 id="es-observable-array-abstract-operations">Abstract operations</h4> + +<div algorithm> + To <dfn for="observable array exotic object" lt="set the length|setting the length">set the length</dfn> + of an observable array exotic object given |handler| and |newLen|: + + 1. Let |uint32Len| be [=?=] [$ToUint32$](|newLen|). + 1. Let |numberLen| be [=?=] [$ToNumber$](|newLen|). + 1. If |uint32Len| ≠ |numberLen|, then throw a {{RangeError}} exception. + 1. Let |oldLen| be |handler|.\[[BackingList]]'s [=list/size=]. + 1. If |numberLen| > |oldLen|, then return <emu-val>false</emu-val>. Might be closer to the ES version to use uint32Len here and in the while loop condition. -- 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/840#pullrequestreview-373937559
Received on Thursday, 12 March 2020 22:16:48 UTC