relude-0.7.0.0: Safe, performant, user-friendly and lightweight Haskell Standard Library

Copyright(c) 2016 Stephen Diehl
(c) 2016-2018 Serokell
(c) 2018-2020 Kowainik
LicenseMIT
MaintainerKowainik <xrom.xkov@gmail.com>
StabilityStable
PortabilityPortable
Safe HaskellSafe
LanguageHaskell2010

Relude.Lifted.Exit

Description

Lifted versions of functions that work with exit processes.

Synopsis

Documentation

exitWith :: MonadIO m => ExitCode -> m a Source #

Lifted version of exitWith.

>>> exitWith (ExitFailure 3)
*** Exception: ExitFailure 3
>>> exitWith ExitSuccess
*** Exception: ExitSuccess

exitFailure :: MonadIO m => m a Source #

Lifted version of exitFailure.

>>> exitFailure
*** Exception: ExitFailure 1

exitSuccess :: MonadIO m => m a Source #

Lifted version of exitSuccess.

>>> exitSuccess
*** Exception: ExitSuccess

die :: MonadIO m => String -> m a Source #

Lifted version of die.

>>> die "Goodbye!"
Goodbye!
*** Exception: ExitFailure 1