diff --git a/spec.html b/spec.html index 633a6a011c..259d171b8b 100644 --- a/spec.html +++ b/spec.html @@ -24145,7 +24145,7 @@

Runtime Semantics: Evaluation

1. Else, set _received_ to Completion(GeneratorYield(_innerResult_)). 1. Else, 1. NOTE: If _iterator_ does not have a `throw` method, this throw is going to terminate the `yield*` loop. But first we need to give _iterator_ a chance to clean up. - 1. Let _closeCompletion_ be Completion Record { [[Type]]: ~normal~, [[Value]]: ~empty~, [[Target]]: ~empty~ }. + 1. Let _closeCompletion_ be NormalCompletion(~empty~). 1. If _generatorKind_ is ~async~, perform ? AsyncIteratorClose(_iteratorRecord_, _closeCompletion_). 1. Else, perform ? IteratorClose(_iteratorRecord_, _closeCompletion_). 1. NOTE: The next step throws a *TypeError* to indicate that there was a `yield*` protocol violation: _iterator_ does not have a `throw` method. @@ -46053,8 +46053,8 @@

%AsyncFromSyncIteratorPrototype%.throw ( [ _value_ ] )

1. IfAbruptRejectPromise(_throw_, _promiseCapability_). 1. If _throw_ is *undefined*, then 1. NOTE: If _syncIterator_ does not have a `throw` method, close it to give it a chance to clean up before we reject the capability. - 1. Let _closeCompletion_ be Completion { [[Type]]: ~normal~, [[Value]]: ~empty~, [[Target]]: ~empty~ }. - 1. Set _result_ to IteratorClose(_syncIteratorRecord_, _closeCompletion_). + 1. Let _closeCompletion_ be NormalCompletion(~empty~). + 1. Let _result_ be Completion(IteratorClose(_syncIteratorRecord_, _closeCompletion_)). 1. IfAbruptRejectPromise(_result_, _promiseCapability_). 1. NOTE: The next step throws a *TypeError* to indicate that there was a protocol violation: _syncIterator_ does not have a `throw` method. 1. NOTE: If closing _syncIterator_ does not throw then the result of that operation is ignored, even if it yields a rejected promise. @@ -46111,7 +46111,7 @@

AsyncFromSyncIteratorContinuation ( _result_: an Object, _promiseCapability_: a PromiseCapability Record for an intrinsic %Promise%, - _syncIteratorRecord_: unknown, + _syncIteratorRecord_: an Iterator Record, _closeOnRejection_: a Boolean, ): a Promise

@@ -46126,7 +46126,7 @@

1. IfAbruptRejectPromise(_value_, _promiseCapability_). 1. Let _valueWrapper_ be Completion(PromiseResolve(%Promise%, _value_)). 1. If _valueWrapper_ is an abrupt completion, _done_ is *false*, and _closeOnRejection_ is *true*, then - 1. Set _valueWrapper_ to IteratorClose(_syncIteratorRecord_, _valueWrapper_). + 1. Set _valueWrapper_ to Completion(IteratorClose(_syncIteratorRecord_, _valueWrapper_)). 1. IfAbruptRejectPromise(_valueWrapper_, _promiseCapability_). 1. Let _unwrap_ be a new Abstract Closure with parameters (_v_) that captures _done_ and performs the following steps when called: 1. Return CreateIterResultObject(_v_, _done_). @@ -46137,7 +46137,7 @@

1. Else, 1. Let _closeIterator_ be a new Abstract Closure with parameters (_error_) that captures _syncIteratorRecord_ and performs the following steps when called: 1. Return ? IteratorClose(_syncIteratorRecord_, ThrowCompletion(_error_)). - 1. Let _onRejected_ be ! CreateBuiltinFunction(_closeIterator_, 1, *""*, « »). + 1. Let _onRejected_ be CreateBuiltinFunction(_closeIterator_, 1, *""*, « »). 1. NOTE: _onRejected_ is used to close the Iterator when the *"value"* property of an IteratorResult object it yields is a rejected promise. 1. Perform PerformPromiseThen(_valueWrapper_, _onFulfilled_, _onRejected_, _promiseCapability_). 1. Return _promiseCapability_.[[Promise]].