Hoogle Search
Within LTS Haskell 24.52 (ghc-9.10.3)
Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.
-
protolude Protolude This is thrown when the user calls error. The first String is the argument given to error, second String is the location.
pattern
ErrorCall :: String -> ErrorCallprotolude Protolude No documentation available.
ErrorCallWithLocation :: String -> String -> ErrorCallprotolude Protolude No documentation available.
-
protolude Protolude Thrown when the program attempts to call atomically, from the stm package, inside another call to atomically.
NestedAtomically :: NestedAtomicallyprotolude Protolude No documentation available.
callStack :: HasCallStack => CallStackprotolude Protolude Return the current CallStack. Does *not* include the call-site of callStack.
currentCallStack :: IO [String]protolude Protolude Returns a [String] representing the current call stack. This can be useful for debugging. The implementation uses the call-stack simulation maintained by the profiler, so it only works if the program was compiled with -prof and contains suitable SCC annotations (e.g. by using -fprof-auto). Otherwise, the list returned is likely to be empty or uninformative.
finally :: IO a -> IO b -> IO aprotolude Protolude A specialised variant of bracket with just a computation to run afterward.
forkFinally :: IO a -> (Either SomeException a -> IO ()) -> IO ThreadIdprotolude Protolude Fork a thread and call the supplied function when the thread is about to terminate, with an exception or a returned value. The function is called with asynchronous exceptions masked.
forkFinally action and_then = mask $ \restore -> forkIO $ try (restore action) >>= and_then
This function is useful for informing the parent when a child terminates, for example.getCallStack :: CallStack -> [([Char], SrcLoc)]protolude Protolude Extract a list of call-sites from the CallStack. The list is ordered by most recent call.