[commit: ghc] master: Generalise type of recently added System.Exit.die (bcd989d)

git at git.haskell.org git at git.haskell.org
Mon Apr 21 18:56:08 UTC 2014


Repository : ssh://git@git.haskell.org/ghc

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/bcd989d13072a189b49d9393b0d4b1bbaede9d36/ghc

>---------------------------------------------------------------

commit bcd989d13072a189b49d9393b0d4b1bbaede9d36
Author: Herbert Valerio Riedel <hvr at gnu.org>
Date:   Mon Apr 21 20:29:15 2014 +0200

    Generalise type of recently added System.Exit.die
    
    This is a follow-up to 77ea2eb0ab36d1a (re #9016) which added `die` with a
    return type of `IO ()` even though all other functions in System.Exit have
    the more general return type `IO a`. It is assumed this was an oversight in
    the original proposal.
    
    Acked-by: Edward Kmett <ekmett at gmail.com>
    Signed-off-by: Herbert Valerio Riedel <hvr at gnu.org>


>---------------------------------------------------------------

bcd989d13072a189b49d9393b0d4b1bbaede9d36
 libraries/base/System/Exit.hs |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libraries/base/System/Exit.hs b/libraries/base/System/Exit.hs
index 4f6eba6..932cbfb 100644
--- a/libraries/base/System/Exit.hs
+++ b/libraries/base/System/Exit.hs
@@ -79,5 +79,5 @@ exitSuccess = exitWith ExitSuccess
 -- | Write given error message to `stderr` and terminate with `exitFailure`.
 --
 -- /Since: 4.7.1.0/
-die :: String -> IO ()
+die :: String -> IO a
 die err = hPutStrLn stderr err >> exitFailure



More information about the ghc-commits mailing list