Futures

Domenic Denicola domenic at domenicdenicola.com
Fri Apr 26 12:31:10 PDT 2013


From: Juan Ignacio Dopazo [dopazo.juan at gmail.com]

> 2013/4/26 Kevin Smith <zenparsing at gmail.com>
>>>> Oops yeah. I guess that should be fixed. :/
>>>>
>>> Fixing that would break compatibility with Promises/A+. To remain compatible with A+ and unwrap only one layer, the spec would need a way to discern promises from thenables.
>>>
>> I don't think so.  It has no bearing on Promises/A+, because A+ doesn't test the case where the promise's value is itself a promise. 

> Yes, sorry. It will on version 1.1: https://github.com/promises-aplus/promises-spec/#the-promise-resolution-procedure

To clarify: in 1.0, the behavior of returning a thenable was highly underspecified, in part because of a lack of clarity about promises vs. thenables. In 1.1, returning a thenable is now specified in the same detail as the rest of the spec, and (of course) has accompanying tests.






More information about the es-discuss mailing list