plutus-core-0.1.0.0: Language library for Plutus Core
Safe HaskellNone
LanguageHaskell2010

PlutusCore.Builtin.Emitter

Synopsis

Documentation

newtype Emitter a Source #

A monad for logging that does not hardcode any concrete first-order encoding and instead packs a Monad m constraint and a Text -> m () argument internally, so that built-in functions that do logging can work in any monad (for example, CkM or CekM), for which there exists a logging function.

Constructors

Emitter 

Fields

Instances

Instances details
Monad Emitter Source # 
Instance details

Defined in PlutusCore.Builtin.Emitter

Methods

(>>=) :: Emitter a -> (a -> Emitter b) -> Emitter b Source #

(>>) :: Emitter a -> Emitter b -> Emitter b Source #

return :: a -> Emitter a Source #

Functor Emitter Source # 
Instance details

Defined in PlutusCore.Builtin.Emitter

Methods

fmap :: (a -> b) -> Emitter a -> Emitter b Source #

(<$) :: a -> Emitter b -> Emitter a Source #

Applicative Emitter Source # 
Instance details

Defined in PlutusCore.Builtin.Emitter

Methods

pure :: a -> Emitter a Source #

(<*>) :: Emitter (a -> b) -> Emitter a -> Emitter b Source #

liftA2 :: (a -> b -> c) -> Emitter a -> Emitter b -> Emitter c Source #

(*>) :: Emitter a -> Emitter b -> Emitter b Source #

(<*) :: Emitter a -> Emitter b -> Emitter a Source #

KnownTypeIn uni val a => KnownTypeIn uni val (Emitter a) Source # 
Instance details

Defined in PlutusCore.Builtin.KnownType

Methods

makeKnown :: (MonadError (ErrorWithCause err cause) m, AsEvaluationFailure err) => (Text -> m ()) -> Maybe cause -> Emitter a -> m val Source #

readKnown :: (AsUnliftingError err, AsEvaluationFailure err) => Maybe cause -> val -> Either (ErrorWithCause err cause) (Emitter a) Source #

KnownTypeAst uni a => KnownTypeAst uni (Emitter a :: Type) Source # 
Instance details

Defined in PlutusCore.Builtin.KnownTypeAst

Associated Types

type ToHoles (Emitter a) :: [Hole] Source #

type ToBinds (Emitter a) :: [Some TyNameRep] Source #

Methods

toTypeAst :: proxy (Emitter a) -> Type0 TyName uni () Source #

type ToHoles (Emitter a :: Type) Source # 
Instance details

Defined in PlutusCore.Builtin.KnownTypeAst

type ToHoles (Emitter a :: Type) = '[TypeHole a :: Hole]
type ToBinds (Emitter a :: Type) Source # 
Instance details

Defined in PlutusCore.Builtin.KnownTypeAst

type ToBinds (Emitter a :: Type) = ToBinds a