| Safe Haskell | Safe-Inferred |
|---|---|
| Language | Haskell2010 |
Debug.Trace.Linear
Description
A thin wrapper on top of Debug.Trace, providing linear versions of tracing functions.
It only contains minimal amount of documentation; you should consult the original Debug.Trace module for more detailed information.
Synopsis
- trace :: String %1 -> a %1 -> a
- traceShow :: Show a => a -> b %1 -> b
- traceId :: String %1 -> String
- traceStack :: String %1 -> a %1 -> a
- traceIO :: String %1 -> IO ()
- traceM :: Applicative f => String %1 -> f ()
- traceShowM :: (Show a, Applicative f) => a -> f ()
- traceEvent :: String %1 -> a %1 -> a
- traceEventIO :: String %1 -> IO ()
- traceMarker :: String %1 -> a %1 -> a
- traceMarkerIO :: String %1 -> IO ()
Tracing
trace :: String %1 -> a %1 -> a Source #
The trace function outputs the trace message given as its first
argument, before returning the second argument as its result.
traceStack :: String %1 -> a %1 -> a Source #
Like trace, but additionally prints a call stack if one is
available.
traceIO :: String %1 -> IO () Source #
The traceIO function outputs the trace message from the IO monad.
This sequences the output with respect to other IO actions.
traceM :: Applicative f => String %1 -> f () Source #
Like trace but returning unit in an arbitrary Applicative
context. Allows for convenient use in do-notation.
traceShowM :: (Show a, Applicative f) => a -> f () Source #
Eventlog tracing
traceEvent :: String %1 -> a %1 -> a Source #
The traceEvent function behaves like trace with the difference
that the message is emitted to the eventlog, if eventlog profiling is
available and enabled at runtime.
traceEventIO :: String %1 -> IO () Source #
The traceEventIO function emits a message to the eventlog, if
eventlog profiling is available and enabled at runtime.
Execution phase markers
traceMarker :: String %1 -> a %1 -> a Source #
The traceMarker function emits a marker to the eventlog, if eventlog
profiling is available and enabled at runtime. The String is the name
of the marker. The name is just used in the profiling tools to help you
keep clear which marker is which.
traceMarkerIO :: String %1 -> IO () Source #
The traceMarkerIO function emits a marker to the eventlog, if
eventlog profiling is available and enabled at runtime.