On Tue, Apr 21, 2015 at 8:23 AM, Greg Weber <greg@gregweber.info> wrote:

On Tue, Apr 14, 2015 at 11:38 AM, Michael Sloan <mgsloan@gmail.com> wrote:
    data SomeException = forall e . Exception e =>
        SomeExceptionWithInfo e [SomeExceptionInfo]

    data SomeExceptionInfo = forall a . ExceptionInfo a =>
        SomeExceptionInfo a

Is it necessary for SomeExceptionWithInfo to have a list of a forall data type?
Are Exceptions really that mysterious, or can we more concretely describe the information that should be attached to an exception?

    SomeExceptionWithInfo e IsAsync CallStack ImplicitStack

I did consider this option, but I think as soon as a fixed set is selected, someone's going to put something else in it.  Usually we wouldn't want to use such a 'dynamic' mechanism in Haskell, but it's appropriate for something so global as the type used to throw exceptions.
 
I am still open to the idea of adding a forall data scratchpad, but can we at least try to specify some standard fields?

    SomeExceptionWithInfo e IsAsync CallStack ImplicitStack [SomeExceptionInfo]

This is an interesting idea.  I particularly see value in having 'IsAsync' be a part of the Exception.  This is because `throwIO` / `throw` would need to set this to False when rethrowing async exceptions.