On Wed, Jan 29, 2014 at 7:33 AM, Kevin Smith <[email protected]> wrote:
>>
>> It is, actually, more simplicity. The concept of `Promise.resolve` and
>> `Promise.chain` is simpler than `Promise.cast` and `Promise.then` (i.e.:
>> they represent orthogonal concepts, not "complected"). `Promise.cast` and
>> `Promise.then` may be, arguably, *easier* to work with, from a user POV,
>> since you don't need to make as many choices. I would argue that it would
>> make more sense to write `cast` and `then` in terms of `resolve` and
>> `chain`, however. But this seems to have already been decided.
>
>
> It does make more sense, and from my point of view it's not decided.  What
> is decided is the AP2 design.  That is:
>
> 1)  promises are fully parametric and,
> 2)  `then` recursively unwraps the *input* to its callbacks.
>
> For the sake of coherency (aka conceptual integrity), `then` needs to be
> written in terms of `chain`.  This issue needs to be resolved ASAP, however,
> since promises are making their way into engines now.

Resolving this would be much appreciated. Gecko recently turned on
Promises in our nightly builds, and already branched to our aurora
builds. I believe Chrome is in a similar situation.

/ Jonas
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to