[Bug 23143] New: Add an "adopt" hook for Promises

https://www.w3.org/Bugs/Public/show_bug.cgi?id=23143
 Bug ID: 23143
 Summary: Add an "adopt" hook for Promises
 Classification: Unclassified
 Product: WebAppsWG
 Version: unspecified
 Hardware: PC
 OS: Linux
 Status: NEW
 Severity: normal
 Priority: P2
 Component: DOM
 Assignee: annevk@annevk.nl
 Reporter: jackalmage@gmail.com
 QA Contact: public-webapps-bugzilla@w3.org
 CC: mike@w3.org, www-dom@w3.org
The Promises spec currently has API hooks for fulfilling and rejecting a
promise. It should also have a hook for adopting a promise.
Use-case: I'm returning a promise from an operation in the Font Load Events
API. Sometimes it'll be rejected quickly and directly, so I need to have a
handle for the promise itself. If all goes well, though, the result should be
as if Promise.every() was called on a spec-defined list of other promises,
which requires me to have the original returned promise adopt the result of the
Promise.every() algorithm (once it's defined in a spec fashion that can be
safely invoked).
-- 
You are receiving this mail because:
You are on the CC list for the bug.

Received on Tuesday, 3 September 2013 21:50:29 UTC

AltStyle によって変換されたページ (->オリジナル) /