| Safe Haskell | Safe-Inferred |
|---|---|
| Language | Haskell2010 |
Effectful.Internal.MTL
Contents
Description
Definitions and instances for MTL compatibility.
This module is intended for internal use only, and may change without warning in subsequent releases.
Documentation
data Error e :: Effect where Source #
Provide the ability to handle errors of type e.
Constructors
| ThrowErrorWith :: (e -> String) -> e -> Error e m a | Since: 2.4.0.0 |
| CatchError :: m a -> (CallStack -> e -> m a) -> Error e m a |
Instances
| type DispatchOf (Error e) Source # | |
Defined in Effectful.Internal.MTL | |
data Reader r :: Effect where Source #
Instances
| type DispatchOf (Reader r) Source # | |
Defined in Effectful.Internal.MTL | |
data State s :: Effect where Source #
Provide access to a mutable value of type s.
Constructors
| Get :: State s m s | |
| Put :: s -> State s m () | |
| State :: (s -> (a, s)) -> State s m a | |
| StateM :: (s -> m (a, s)) -> State s m a |
Instances
| type DispatchOf (State s) Source # | |
Defined in Effectful.Internal.MTL | |
data Writer w :: Effect where Source #
Provide access to a write only value of type w.
Instances
| type DispatchOf (Writer w) Source # | |
Defined in Effectful.Internal.MTL | |
Orphan instances
| (Show e, Error e :> es, MonadError e (Eff es)) => MonadError e (Eff es) Source # | Instance included for compatibility with existing code. |
| (Reader r :> es, MonadReader r (Eff es)) => MonadReader r (Eff es) Source # | Instance included for compatibility with existing code. |
| (State s :> es, MonadState s (Eff es)) => MonadState s (Eff es) Source # | Instance included for compatibility with existing code. |
| (Monoid w, Writer w :> es, MonadWriter w (Eff es)) => MonadWriter w (Eff es) Source # | Instance included for compatibility with existing code. |