Allen Wirfs-Brock (2014-07-24T17:45:32.000Z)
On Jul 24, 2014, at 10:38 AM, Nathan Wall wrote:

> Allen Wirfs-Brock wrote:
> > So going back to my original questions.  Given that we now have return()
> > available to close an abnormally discarded generator, when would somebody
> > (presumably implementing a control abstraction) actually want to apply
> > throw() rather than return() to an iterator?
> 
> Sorry, I may be misunderstanding, but what about the use from Task.js?
> 
> https://github.com/mozilla/task.js/blob/master/lib/task.js#L395
> 
> The above should log "from foo".  Wouldn't `throw()` be needed for that?

Right, that's the use case I was lookingor.  Also mentioned by Jeremy in an earlier response.

Allen

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20140724/6b81ea90/attachment.html>
domenic at domenicdenicola.com (2014-07-31T18:32:02.334Z)
On Jul 24, 2014, at 10:38 AM, Nathan Wall wrote:

> The above should log "from foo".  Wouldn't `throw()` be needed for that?

Right, that's the use case I was lookingor.  Also mentioned by Jeremy in an earlier response.