[email protected] (2013-09-09T00:25:21.000Z)
> Tasks in C# throw the recorded exception when the Task is finalized by the
> GC if it hasn't been handled by user code, though I don't know if something
> similar could be supported for ES7 Promises nor whether or not that makes
> sense for ES7 promises either.


This is an interesting avenue. The problem is the chain-ability and value
like nature of promises. It is difficult to truly determine that the error
has not been handled. The error may be handled later down the chain or in a
separate context. When is the decision made that the error has not been
handled? Is the error determined not handled on garbage collection? Is
there a ttl on error handling? This is a curious case, but if feasible
would be the most elegant option.

rejectedPromise = promise.then(func)
    .then(func) //Error swallowed
    .then(func);

setTimeout(function () {
    rejectedPromise.then(func, errorHandler); //Finally handle it
}, 20000);
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20130908/c07d9219/attachment.html>
domenic at domenicdenicola.com (2013-09-18T19:12:15.320Z)
> Tasks in C# throw the recorded exception when the Task is finalized by the
> GC if it hasn't been handled by user code, though I don't know if something
> similar could be supported for ES7 Promises nor whether or not that makes
> sense for ES7 promises either.


This is an interesting avenue. The problem is the chain-ability and value
like nature of promises. It is difficult to truly determine that the error
has not been handled. The error may be handled later down the chain or in a
separate context. When is the decision made that the error has not been
handled? Is the error determined not handled on garbage collection? Is
there a ttl on error handling? This is a curious case, but if feasible
would be the most elegant option.

```JS
rejectedPromise = promise.then(func)
    .then(func) //Error swallowed
    .then(func);

setTimeout(function () {
    rejectedPromise.then(func, errorHandler); //Finally handle it
}, 20000);
```