shithub: MicroHs

ref: bf737faf9dd2219b202d4c3d1eb62b942202bc9f
dir: /lib/Debug/Trace.hs/

View raw version
module Debug.Trace(module Debug.Trace) where
import Prelude
import Primitives

trace :: forall a . String -> a -> a
trace msg a = primitive "IO.performIO" (
  do
    putStrLn msg
    return a
  )

traceM :: forall (m :: Type -> Type) a . Monad m => String -> m ()
traceM s = trace s (return ())