Commit bcd989d1 authored by Herbert Valerio Riedel's avatar Herbert Valerio Riedel 🕺

Generalise type of recently added System.Exit.die

This is a follow-up to 77ea2eb0 (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's avatarEdward Kmett <ekmett@gmail.com>
Signed-off-by: Herbert Valerio Riedel's avatarHerbert Valerio Riedel <hvr@gnu.org>
parent 4ab8fc55
......@@ -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
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment