diff --git a/spec.html b/spec.html index 2c10ac3217..58ce385cde 100644 --- a/spec.html +++ b/spec.html @@ -49546,8 +49546,11 @@

1. If IsPromise(_x_) is *true*, then - 1. Let _xConstructor_ be ? Get(_x_, *"constructor"*). - 1. If SameValue(_xConstructor_, _C_) is *true*, return _x_. + 1. Assert: _x_ is an ordinary object. + 1. Let _xProto_ be ! _x_.[[GetPrototypeOf]](). + 1. Let _CPrototype_ be ? Get(_C_, *"prototype"*). + 1. NOTE: When _C_ is the intrinsic %Promise%, the above step cannot throw and always results in the intrinsic %Promise.prototype%. + 1. If SameValue(_xProto_, _CPrototype_) is *true*, return _x_. 1. Let _promiseCapability_ be ? NewPromiseCapability(_C_). 1. Perform ? Call(_promiseCapability_.[[Resolve]], *undefined*, « _x_ »). 1. Return _promiseCapability_.[[Promise]].