Skip to content

Commit

Permalink
fix another test now that we don't access the IteratorResult value
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelficarra authored and ptomato committed Dec 9, 2024
1 parent f3a90fc commit b2e8828
Showing 1 changed file with 11 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,15 @@ info: |
a. For each Record iterable of iterables, do
...
v. Repeat, while innerAlive is true,
1. Let innerValue be ? IteratorStepValue(iteratorRecord).
...
1. Let iteratorResult be ? IteratorStep(iteratorRecord).
2. If iteratorResult is done, then
a. Perform ? IteratorValue(iteratorResult).
b. Set innerAlive to false.
3. Else,
a. Let completion be Completion(GeneratorYield(iteratorResult)).
b. If completion is an abrupt completion, then
i. Return ? IteratorClose(iteratorRecord, completion).
...
features: [iterator-sequencing]
---*/

Expand All @@ -39,7 +46,8 @@ let iterable = {
};

let iterator = Iterator.concat(iterable);
let iteratorResult = iterator.next();

assert.throws(Test262Error, function() {
iterator.next();
iteratorResult.value;
});

0 comments on commit b2e8828

Please sign in to comment.