Err package:ghc-internal
The
GHC.Err module defines the code for the wired-in error
functions, which have a special type in the compiler (with "open
tyvars").
We cannot define these functions in a module where they might be used
(e.g.,
GHC.Base), because the magical wired-in type will get
confused with what the typechecker figures out.
This is thrown when the user calls
error. The
String
is the argument given to
error.
Historically, there was a second
String for the location, but
it was subsumed by the backtrace mechanisms (since base-4.22).
Deprecated: ErrorCallWithLocation has been deprecated in favour of
ErrorCall (which does not have a location). Backtraces are now handled
by the backtrace exception mechanisms exclusively.
C-specific Marshalling support: Handling of C "errno" error codes.
Haskell representation for
errno values. The implementation
is deliberately exposed, to allow users to add their own definitions
of
Errno values.
Routines for testing return values and raising a
userError
exception in case of values indicating an error state.
Throw an error when an illegal sequence is encountered
A description of a custom type error.
error stops execution and displays an error message.
A variant of
error that does not produce a stack trace.
Construct an
IOError based on the given
Errno value. The
optional information can be used to improve the accuracy of error
messages.
Deprecated: error appends the call stack now
maskUninterruptible# k s evaluates
k s such
that asynchronous exceptions are deferred until after evaluation has
finished.
Note that the result type here isn't quite as unrestricted as the
polymorphic type might suggest; see the section "RuntimeRep
polymorphism in continuation-style primops" for details.
Interrupts the current wait of the I/O manager if it is currently
blocked. This instructs it to re-read how much it should wait and to
process any pending events.
the state during
mask: asynchronous exceptions are masked, but
blocking operations may still be interrupted
the state during
uninterruptibleMask: asynchronous exceptions
are masked, and blocking operations may not be interrupted
A class method without a definition (neither a default definition, nor
a definition in the appropriate instance) was called. The
String gives information about which method it was.