Conversation
| And then, if <a lt="an exception was thrown">an exception |exception| was thrown</a>: | ||
|
|
||
| 1. If there are steps that are required to be run if the promise was rejected, let | ||
| |result| be the result of performing those steps, given |exception|. |
There was a problem hiding this comment.
|result| is unused. Should it be returned, instead of throwing exception?
There was a problem hiding this comment.
Hm, good question. This matters if:
- we want to do a type conversion
- the returned promise is used (former "transforming")
- we want to do something else than passing the rejection along
Are you aware of an existing case to inform the decision? From #782 (comment), waitUntil/complete fail (1), respondWith/updateWith fail (2), WebAssembly fails (3).
Writing this, I'm realizing that we never actually pass the rejection along, the way WebAssembly needs. Should we pass undefined instead of onRejectedSteps if there's no steps?
There was a problem hiding this comment.
Are you aware of an existing case to inform the decision?
I'm not aware of any. However I generally think aligning with promise.then() will be more intuitive for spec authors, if we have that degree of freedom. So I'd prefer that if possible.
Writing this, I'm realizing that we never actually pass the rejection along, the way WebAssembly needs. Should we pass undefined instead of onRejectedSteps if there's no steps?
Definitely.
|
@Ms2ger do you plan to complete this? |
|
Probably not. |
Fixes #782.
Preview | Diff