Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Utility functions for enclosing a code segment with tracing events.
Synopsis
- type Enclosing = Enclosing' ()
- data Enclosing' a
- = RisingEdge
- | FallingEdgeWith !a
- type EnclosingTimed = Enclosing' DiffTime
- encloseTimedWith ∷ MonadMonotonicTime m ⇒ Tracer m EnclosingTimed → m a → m a
- encloseWith ∷ Applicative m ⇒ Tracer m Enclosing → m a → m a
- pattern FallingEdge ∷ Enclosing' ()
Documentation
type Enclosing = Enclosing' () Source #
data Enclosing' a Source #
RisingEdge | Preceding a specific code segment. |
FallingEdgeWith !a | Succeeding a specific code segment, with extra information. |
Instances
Show a ⇒ Show (Enclosing' a) Source # | |
Defined in Ouroboros.Consensus.Util.Enclose showsPrec ∷ Int → Enclosing' a → ShowS # show ∷ Enclosing' a → String # showList ∷ [Enclosing' a] → ShowS # | |
Eq a ⇒ Eq (Enclosing' a) Source # | |
Defined in Ouroboros.Consensus.Util.Enclose (==) ∷ Enclosing' a → Enclosing' a → Bool # (/=) ∷ Enclosing' a → Enclosing' a → Bool # | |
Ord a ⇒ Ord (Enclosing' a) Source # | |
Defined in Ouroboros.Consensus.Util.Enclose compare ∷ Enclosing' a → Enclosing' a → Ordering # (<) ∷ Enclosing' a → Enclosing' a → Bool # (<=) ∷ Enclosing' a → Enclosing' a → Bool # (>) ∷ Enclosing' a → Enclosing' a → Bool # (>=) ∷ Enclosing' a → Enclosing' a → Bool # max ∷ Enclosing' a → Enclosing' a → Enclosing' a # min ∷ Enclosing' a → Enclosing' a → Enclosing' a # |
type EnclosingTimed = Enclosing' DiffTime Source #
encloseTimedWith ∷ MonadMonotonicTime m ⇒ Tracer m EnclosingTimed → m a → m a Source #
encloseWith ∷ Applicative m ⇒ Tracer m Enclosing → m a → m a Source #
Enclose an action using the given Tracer
.
pattern FallingEdge ∷ Enclosing' () Source #