Copyright | (c) Michael Szvetits 2020 |
---|---|
License | BSD3 (see the file LICENSE) |
Maintainer | typedbyte@qualified.name |
Stability | stable |
Portability | portable |
Safe Haskell | None |
Language | Haskell2010 |
This module defines an effect handler which handles tagging, retagging and untagging of effects.
Documentation
newtype Tagger tag new m a Source #
This type provides instances for effect type classes in order to enable
tagging, retagging and untagging of effects. Whenever this type is used as
handler of an effect, the effect previously tagged with tag
will be
tagged with new
instead.
You usually don't interact with this type directly, since the type class instances for this type are generated by the functions found in the module Control.Effect.Machinery.TH.
Instances
Map' new k3 v m => Map' (tag :: k2) k3 v (Tagger tag new m) Source # | |
Error' new e m => Error' (tag :: k2) e (Tagger tag new m) Source # | |
Defined in Control.Effect.Error throwError' :: e -> Tagger tag new m a Source # catchError' :: Tagger tag new m a -> (e -> Tagger tag new m a) -> Tagger tag new m a Source # | |
Reader' new r m => Reader' (tag :: k2) r (Tagger tag new m) Source # | |
State' new s m => State' (tag :: k2) s (Tagger tag new m) Source # | |
Writer' new w m => Writer' (tag :: k2) w (Tagger tag new m) Source # | |
Cont' new m => Cont' (tag :: k2) (Tagger tag new m) Source # | |
Resource' new m => Resource' (tag :: k2) (Tagger tag new m) Source # | |
MonadBase b m => MonadBase b (Tagger tag new m) Source # | |
Defined in Control.Effect.Machinery.Tagger | |
MonadBaseControl b m => MonadBaseControl b (Tagger tag new m) Source # | |
MonadTrans (Tagger tag new :: (Type -> Type) -> Type -> Type) Source # | |
Defined in Control.Effect.Machinery.Tagger | |
MonadTransControl (Tagger tag new :: (Type -> Type) -> Type -> Type) Source # | |
Monad m => Monad (Tagger tag new m) Source # | |
Functor m => Functor (Tagger tag new m) Source # | |
Applicative m => Applicative (Tagger tag new m) Source # | |
Defined in Control.Effect.Machinery.Tagger pure :: a -> Tagger tag new m a # (<*>) :: Tagger tag new m (a -> b) -> Tagger tag new m a -> Tagger tag new m b # liftA2 :: (a -> b -> c) -> Tagger tag new m a -> Tagger tag new m b -> Tagger tag new m c # (*>) :: Tagger tag new m a -> Tagger tag new m b -> Tagger tag new m b # (<*) :: Tagger tag new m a -> Tagger tag new m b -> Tagger tag new m a # | |
MonadIO m => MonadIO (Tagger tag new m) Source # | |
Defined in Control.Effect.Machinery.Tagger | |
type StT (Tagger tag new :: (Type -> Type) -> Type -> Type) a Source # | |
type StM (Tagger tag new m) a Source # | |
Defined in Control.Effect.Machinery.Tagger |