- From: Mattias Buelens <notifications@github.com>
- Date: Thu, 21 Feb 2019 05:46:08 -0800
- To: whatwg/streams <streams@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
- Message-ID: <whatwg/streams/pull/994/review/206292546@github.com>
MattiasBuelens approved this pull request. > 1. Assert: Type(_result_) is Object. - 1. Let _value_ be ? Get(_result_, `"value"`). - 1. Let _done_ be ? Get(_result_, `"done"`). + 1. Let _done_ be ! Get(_result_, `"done"`). Interesting! If I understand correctly, this works because we know `result` has a `null` prototype, so we always go through [`Get`](https://www.ecma-international.org/ecma-262/9.0/index.html#sec-get-o-p) -> [`[[Get]]`](https://www.ecma-international.org/ecma-262/9.0/index.html#sec-ordinary-object-internal-methods-and-internal-slots-get-p-receiver) -> [`OrdinaryGet`](https://www.ecma-international.org/ecma-262/9.0/index.html#sec-ordinaryget) -> [`[[GetOwnProperty]]`](https://www.ecma-international.org/ecma-262/9.0/index.html#sec-ordinary-object-internal-methods-and-internal-slots-getownproperty-p) -> [`OrdinaryGetOwnProperty`](https://www.ecma-international.org/ecma-262/9.0/index.html#sec-ordinarygetownproperty), which cannot throw. For the same reason, I think we can also change `? Get` to `! Get` in [`ReadableStreamAsyncIteratorPrototype.next()`](https://streams.spec.whatwg.org/commit-snapshots/a441f59db468c3a40515cc2e7590abe381632f8d/#rs-asynciterator-prototype-next)? -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/whatwg/streams/pull/994#pullrequestreview-206292546
Received on Thursday, 21 February 2019 13:46:30 UTC