| Safe Haskell | Safe-Inferred |
|---|---|
| Language | Haskell2010 |
System.Exit.MonadThrow
Description
Functions to exit the program anywhere in MonadThrow monads.
Synopsis
- exitWith :: MonadThrow m => ExitCode -> m a
- exitFailure :: MonadThrow m => m a
- exitSuccess :: MonadThrow m => m a
- data ExitCode
Documentation
exitWith :: MonadThrow m => ExitCode -> m a Source #
A version of exitWith available in any MonadThrow context.
See exitWith for details
exitFailure :: MonadThrow m => m a Source #
A version of exitFailure available in any MonadThrow context.
See exitFailure for details
exitSuccess :: MonadThrow m => m a Source #
A version of exitSuccess available in any MonadThrow context.
See exitSuccess for details
Re-export from the original System.Exit module.
Defines the exit codes that a program can return.
Constructors
| ExitSuccess | indicates successful termination; |
| ExitFailure Int | indicates program failure with an exit code. The exact interpretation of the code is operating-system dependent. In particular, some values may be prohibited (e.g. 0 on a POSIX-compliant system). |
Instances
| Eq ExitCode | |
| Ord ExitCode | |
Defined in GHC.IO.Exception | |
| Read ExitCode | |
| Show ExitCode | |
| Generic ExitCode | |
| Exception ExitCode | Since: base-4.1.0.0 |
Defined in GHC.IO.Exception Methods toException :: ExitCode -> SomeException # fromException :: SomeException -> Maybe ExitCode # displayException :: ExitCode -> String # | |
| type Rep ExitCode | |
Defined in GHC.IO.Exception type Rep ExitCode = D1 ('MetaData "ExitCode" "GHC.IO.Exception" "base" 'False) (C1 ('MetaCons "ExitSuccess" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "ExitFailure" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Int))) | |