[Haskell-cafe] Where is the documentation on exception types kept?

timothyhobbs at seznam.cz timothyhobbs at seznam.cz
Wed Nov 7 22:03:00 CET 2012

I really like to be able to find these things in documentation and if not 
documentation than source code.  However thank you for your reply, in this 
case it has helped me :)


---------- Původní zpráva ----------
Od: Simon Hengel <sol at typeful.net>
Datum: 7. 11. 2012
Předmět: Re: [Haskell-cafe] Where is the documentation on exception types 

> I am trying to catch an "thread blocked on MVar indefinitely exception."  
> course I can use ::SomeException as explained in http://hackage.haskell.
> packages/archive/base/latest/doc/html/Control-Exception.html#g:3 but there

> is no explanation as to how to find the more case specific exceptions.  
> http://hackage.haskell.org/packages/archive/base/latest/doc/html/Control-
> Concurrent-MVar.html#t:MVar does not discuss exceptions at all!  Indeed, I

> don't know of any haddock pages that include descriptions of exception 
> :( :O

In this particular case it's easy:


But in general, figuring out the exception type is not straight forward.
Personally, I think an uncaught exception should print the type of that
exception (e.g. use a derived show instance). But most of them have a
show instance that is useful for end-users.

The upcoming 1.4.0 release of Hspec will print the type of uncaught
exceptions in test cases. So if you are into BDD/TDD that might be

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/haskell-cafe/attachments/20121107/f9f79da1/attachment.htm>

More information about the Haskell-Cafe mailing list