HORIZON HASKELLDocslts/ghc-9.14.xd82dee82026-10-12Search names, modules, packages, or :: a typeCtrl K

GHC 9.14.1 · lts/ghc-9.14.x · d82dee8 · 2026-10-12

Moduleio-sim-1.8.0.1GHC2021

Data.List.Trace

  • 1 type
  • 11 values
  • Packageio-sim-1.8.0.1
  • Exports12
  • LanguageGHC2021
  • LicenceApache-2.0
  • SourceTrace.hs
datadata Trace a b
#

A cons list with polymorphic nil.

  • Trace Void a is an infinite stream

  • Trace () a is isomorphic to [a]

Usually used with a being a non empty sum type.

Constructors

Instances18Bifoldable, Bifunctor, Bitraversable, Monad, Functor, MonadFix, …
valuetake :: Int -> Trace a b -> Trace (Maybe a) b
#

Take the first n elements of a Trace, converting each to ().

valuetakeWhile :: (b -> Bool) -> Trace a b -> Trace (Maybe a) b
#

Take elements from the Trace while the predicate holds, converting each to ().