Safe Haskell | Safe-Inferred |
---|---|
Language | GHC2021 |
a Logging effect and utility functions using it
logging log messages as an effect
a single line of a logging message
data Logging m r where Source #
the logging effect
Instances
(Algebra sig m, MonadIO m) => Algebra (Logging :+: sig) (GenericLoggingC m) Source # | |
Defined in Control.Carrier.Logging.Generic alg :: forall ctx (n :: Type -> Type) a. Functor ctx => Handler ctx n (GenericLoggingC m) -> (Logging :+: sig) n a -> ctx () -> GenericLoggingC m (ctx a) # | |
(Algebra sig m, MonadIO m) => Algebra (Logging :+: sig) (RefLoggingC m) Source # | |
Defined in Control.Carrier.Logging.Ref alg :: forall ctx (n :: Type -> Type) a. Functor ctx => Handler ctx n (RefLoggingC m) -> (Logging :+: sig) n a -> ctx () -> RefLoggingC m (ctx a) # | |
Algebra sig m => Algebra (Logging :+: sig) (SilentLoggingC m) Source # | |
Defined in Control.Carrier.Logging.Silent alg :: forall ctx (n :: Type -> Type) a. Functor ctx => Handler ctx n (SilentLoggingC m) -> (Logging :+: sig) n a -> ctx () -> SilentLoggingC m (ctx a) # |
loggerLog :: forall msg sig m. (Has Logging sig m, ToLogStr msg) => Loc -> LogLevel -> msg -> m () Source #