graft-0.0.0
Safe HaskellSafe-Inferred
LanguageHaskell2010

Effect.Fail

Documentation

data MonadFailEffect :: Effect where Source #

Constructors

Fail :: forall (m :: Type -> Type) (a :: Type). String -> MonadFailEffect m a 

Instances

Instances details
((), MonadFail m) => InterpretEffect m MonadFailEffect Source # 
Instance details

Defined in Effect.Fail

Methods

interpretEffect :: forall (ops :: [Effect]) a. (forall b. AST ops b -> m b) -> MonadFailEffect (AST ops) a -> m a Source #

MonadFail m => InterpretEffectStateful x m MonadFailEffect Source #

A "passthough" instance for WriterEffects: Modifications are applied in all nested positions of Listen and Pass, but don't actually change the semantics of any WriterEffect.

Instance details

Defined in Effect.Fail.Passthrough

Methods

interpretEffectStateful :: forall (ops :: [Effect]) x0 a. (forall b y. x y -> AST ops b -> m (b, x y)) -> x x0 -> MonadFailEffect (AST ops) a -> m (a, x x0) Source #

Orphan instances

((), EffectInject MonadFailEffect ops) => MonadFail (AST ops) Source # 
Instance details

Methods

fail :: String -> AST ops a #