diff options
Diffstat (limited to 'src/Haddock')
-rw-r--r-- | src/Haddock/Utils.hs | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/Haddock/Utils.hs b/src/Haddock/Utils.hs index 9ccca362..ee7bfd0a 100644 --- a/src/Haddock/Utils.hs +++ b/src/Haddock/Utils.hs @@ -300,7 +300,11 @@ bye :: String -> IO a bye s = putStr s >> exitSuccess -dieMsg :: String -> IO () +die :: String -> IO a +die s = hPutStr stderr s >> exitWith (ExitFailure 1) + + +dieMsg :: String -> IO a dieMsg s = getProgramName >>= \prog -> die (prog ++ ": " ++ s) |