On Jun 9, 2015, at 9:53 AM, C. Scott Ananian wrote:
On Tue, Jun 9, 2015 at 12:38 PM, Mark S. Miller erig...@google.com wrote:
Do you ever test that the object returned by `Promise#timeout(n)` is
something other than a plain promise?
Responded on the other thread.
Let's keep this one
On Wed, Jun 10, 2015 at 10:37 AM, Allen Wirfs-Brock al...@wirfs-brock.com
wrote:
However, I think that Promise.reject should parallel Promise.resolve and
hence it should not use species.
I agree.
--scott
___
es-discuss mailing list
On Wed, Jun 10, 2015 at 7:37 AM, Allen Wirfs-Brock al...@wirfs-brock.com
wrote:
On Jun 9, 2015, at 9:53 AM, C. Scott Ananian wrote:
On Tue, Jun 9, 2015 at 12:38 PM, Mark S. Miller erig...@google.com
wrote:
Do you ever test that the object returned by `Promise#timeout(n)` is
something
https://people.mozilla.org/~jorendorff/es6-draft.html#sec-performpromiseall
https://people.mozilla.org/~jorendorff/es6-draft.html#sec-performpromiseall
I’m wondering: Is it OK that PerformPromiseAll invokes `resolve()` via
`C.resolve()` (versus `this.resolve()`) with `C` determined via
On Tue, Jun 9, 2015 at 11:11 AM, Mark S. Miller erig...@google.com wrote:
Ok, thanks for the example. I understand your rationale. This is what I
asked for but not what I was really looking for. Can we come up with an
example where class and species usefully differ where neither is Promise?
the
potential problems with `Promise.all` and `Promise.race`.
--scott
On Tue, Jun 9, 2015 at 6:46 AM, Axel Rauschmayer a...@rauschma.de wrote:
https://people.mozilla.org/~jorendorff/es6-draft.html#sec-performpromiseall
I’m wondering: Is it OK that PerformPromiseAll invokes `resolve()` via
spec, so perhaps I'm rationalizing away the
potential problems with `Promise.all` and `Promise.race`.
--scott
On Tue, Jun 9, 2015 at 6:46 AM, Axel Rauschmayer a...@rauschma.de wrote:
https://people.mozilla.org/~jorendorff/es6-draft.html#sec-performpromiseall
I’m wondering: Is it OK
Mark: I outlined two of these use cases in
https://esdiscuss.org/topic/subclassing-es6-objects-with-es5-syntax#content-50
One is `WeakPromise` which is a promise holding a weak reference to its
resolved value. This is the closest analogy with the canonical Smalltalk
motivating example for
On Jun 9, 2015, at 7:30 AM, C. Scott Ananian wrote:
`Promise.resolve` doesn't use the species pattern any more:
https://esdiscuss.org/topic/fixing-promise-resolve
The rationale was that `resolve` is more like a constructor than a mutator.
I don't have a strong opinion about `Promise.all`,
On Tue, Jun 9, 2015 at 7:58 AM, C. Scott Ananian ecmascr...@cscott.net
wrote:
Mark: I outlined two of these use cases in
https://esdiscuss.org/topic/subclassing-es6-objects-with-es5-syntax#content-50
One is `WeakPromise` which is a promise holding a weak reference to its
resolved value.
I know I'm being picky here, but if timeout-ness is not intended to
propagate, which seems sensible, then why would I ever want to invent a
TimeoutPromise subclass rather than using a combinator like delay or race
on a plain Promise?
___
es-discuss
On Tue, Jun 9, 2015 at 12:38 PM, Mark S. Miller erig...@google.com wrote:
Do you ever test that the object returned by `Promise#timeout(n)` is
something other than a plain promise?
Responded on the other thread.
Let's keep this one focused on: do we need to tweak the definitions of
Mark: The `prfun` library in fact uses `Promise#timeout(n)` instead of a
`TimeoutPromise` subclass. But this is really a language-design question.
You might as well ask why we have `WeakMap()` as a constructor instead of
using `Map#weak()` or `weakmapify(map)`. The fundamental reason is so you
On Tue, Jun 9, 2015 at 9:29 AM, C. Scott Ananian ecmascr...@cscott.net
wrote:
Mark: The `prfun` library in fact uses `Promise#timeout(n)` instead of a
`TimeoutPromise` subclass. But this is really a language-design question.
You might as well ask why we have `WeakMap()` as a constructor
14 matches
Mail list logo