Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- mapEffs :: (Union effs ~> Union effs') -> Eff effs ~> Eff effs'
- class UnderN as where
- underN :: (Union effs ~> Union effs') -> Union (as :++: effs) ~> Union (as :++: effs')
- under :: (Union effs ~> Union effs') -> Union (a ': effs) ~> Union (a ': effs')
- class CanWeakenEnd as effs where
- weakenEnd :: Union as ~> Union effs
- weakenUnder :: forall effs a b. Union (a ': effs) ~> Union (a ': (b ': effs))
- weakenNUnder :: forall effs' effs a. Weakens effs' => Union (a ': effs) ~> Union (a ': (effs' :++: effs))
- weakenMUnderN :: forall effs' as effs. (UnderN as, Weakens effs') => Union (as :++: effs) ~> Union (as :++: (effs' :++: effs))
- raiseEnd :: forall effs as. CanWeakenEnd as effs => Eff as ~> Eff effs
- raiseUnder :: forall effs a b. Eff (a ': effs) ~> Eff (a ': (b ': effs))
- raiseUnder2 :: forall effs a b c. Eff (a ': (b ': effs)) ~> Eff (a ': (b ': (c ': effs)))
- raise2Under :: forall effs a b c. Eff (a ': effs) ~> Eff (a ': (b ': (c ': effs)))
- raiseNUnder :: forall effs' effs a. Weakens effs' => Eff (a ': effs) ~> Eff (a ': (effs' :++: effs))
- raiseMUnderN :: forall effs' as effs. (UnderN as, Weakens effs') => Eff (as :++: effs) ~> Eff (as :++: (effs' :++: effs))
- handleZoomedState :: Member (State s2) effs => Lens' s2 s1 -> State s1 ~> Eff effs
- handleZoomedError :: Member (Error s2) effs => AReview s2 s1 -> Error s1 ~> Eff effs
- handleZoomedWriter :: Member (Writer s2) effs => AReview s2 s1 -> Writer s1 ~> Eff effs
- handleZoomedReader :: Member (Reader s2) effs => Getter s2 s1 -> Reader s1 ~> Eff effs
- writeIntoState :: (Monoid s1, Member (State s2) effs) => Setter' s2 s1 -> Writer s1 ~> Eff effs
- stateToMonadState :: MonadState s m => State s ~> m
- monadStateToState :: Member (State s) effs => State s a -> Eff effs a
- errorToMonadError :: MonadError e m => Error e ~> m
- wrapError :: forall e f effs. Member (Error f) effs => (e -> f) -> Eff (Error e ': effs) ~> Eff effs
change the list of effects
under functions
weaken functions
class CanWeakenEnd as effs where Source #
Instances
(effs ~ (a ': effs'), CanWeakenEnd (b ': as) effs') => CanWeakenEnd (a ': (b ': as)) effs Source # | |
Defined in Control.Monad.Freer.Extras.Modify | |
effs ~ (a ': effs') => CanWeakenEnd '[a] effs Source # | |
Defined in Control.Monad.Freer.Extras.Modify |
weakenUnder :: forall effs a b. Union (a ': effs) ~> Union (a ': (b ': effs)) Source #
weakenNUnder :: forall effs' effs a. Weakens effs' => Union (a ': effs) ~> Union (a ': (effs' :++: effs)) Source #
weakenMUnderN :: forall effs' as effs. (UnderN as, Weakens effs') => Union (as :++: effs) ~> Union (as :++: (effs' :++: effs)) Source #
raise functions
raiseEnd :: forall effs as. CanWeakenEnd as effs => Eff as ~> Eff effs Source #
raiseUnder :: forall effs a b. Eff (a ': effs) ~> Eff (a ': (b ': effs)) Source #
raiseUnder2 :: forall effs a b c. Eff (a ': (b ': effs)) ~> Eff (a ': (b ': (c ': effs))) Source #
raise2Under :: forall effs a b c. Eff (a ': effs) ~> Eff (a ': (b ': (c ': effs))) Source #
raiseNUnder :: forall effs' effs a. Weakens effs' => Eff (a ': effs) ~> Eff (a ': (effs' :++: effs)) Source #
raiseMUnderN :: forall effs' as effs. (UnderN as, Weakens effs') => Eff (as :++: effs) ~> Eff (as :++: (effs' :++: effs)) Source #
Raise m effects under the top n effects
zoom functions
handleZoomedState :: Member (State s2) effs => Lens' s2 s1 -> State s1 ~> Eff effs Source #
Handle a State
effect in terms of a "larger" State
effect from which we have a lens.
handleZoomedError :: Member (Error s2) effs => AReview s2 s1 -> Error s1 ~> Eff effs Source #
Handle an Error
effect in terms of a "larger" Error
effect from which we have a review.
handleZoomedWriter :: Member (Writer s2) effs => AReview s2 s1 -> Writer s1 ~> Eff effs Source #
Handle a Writer
effect in terms of a "larger" Writer
effect from which we have a review.
handleZoomedReader :: Member (Reader s2) effs => Getter s2 s1 -> Reader s1 ~> Eff effs Source #
Handle a Reader
effect in terms of a "larger" Reader
effect from which we have a getter.
manipulation
writeIntoState :: (Monoid s1, Member (State s2) effs) => Setter' s2 s1 -> Writer s1 ~> Eff effs Source #
Handle a Writer
effect in terms of a "larger" State
effect from which we have a setter.
stateToMonadState :: MonadState s m => State s ~> m Source #
Handle a State
effect in terms of a monadic effect which has a MonadState
instance.
monadStateToState :: Member (State s) effs => State s a -> Eff effs a Source #
errorToMonadError :: MonadError e m => Error e ~> m Source #
Handle an Error
effect in terms of a monadic effect which has a MonadError
instance.