Skip to content

Example in library doco for Control.Exception.handle is no longer supported in GHC 6.10

The library documentation for Control.Exception includes an example that does not compile in GHC 6.10:

Prelude Control.Exception System> do handle (\e -> exitWith (ExitFailure 1)) $ undefined

<interactive>:1:3:
    Ambiguous type variable `e' in the constraint:
      `Exception e'
        arising from a use of `handle' at <interactive>:1:3-41
    Probable fix: add a type signature that fixes these type variable(s)
Prelude Control.Exception System> 
Trac metadata
Trac field Value
Version 6.10.1
Type Bug
TypeOfFailure OtherFailure
Priority normal
Resolution Unresolved
Component Documentation
Test case
Differential revisions
BlockedBy
Related
Blocking
CC
Operating system
Architecture
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information