more-extensible-effects-0.1.0.1: Initial project template from stack

Safe HaskellNone
LanguageHaskell2010

Control.Monad.Eff.NdetEff

Contents

Synopsis

Documentation

makeChoiceA :: Alternative f => Eff (NdetEff ': r) a -> Eff r (f a) Source #

An interpreter The following is very simple, but leaks a lot of memory The cause probably is mapping every failure to empty It takes then a lot of timne and space to store those empty

msplit :: Member NdetEff r => Eff r a -> Eff r (Maybe (a, Eff r a)) Source #

unmsplit :: Member NdetEff r => Maybe (a, Eff r a) -> Eff r a Source #

called reflect in the LogicT paper

ifte :: Member NdetEff r => Eff r a -> (a -> Eff r b) -> Eff r b -> Eff r b Source #

Other committed choice primitives can be implemented in terms of msplit The following implementations are directly from the LogicT paper

once :: Member NdetEff r => Eff r a -> Eff r a Source #

Orphan instances

Member NdetEff r => Alternative (Eff r) Source # 

Methods

empty :: Eff r a #

(<|>) :: Eff r a -> Eff r a -> Eff r a #

some :: Eff r a -> Eff r [a] #

many :: Eff r a -> Eff r [a] #

Member NdetEff r => MonadPlus (Eff r) Source # 

Methods

mzero :: Eff r a #

mplus :: Eff r a -> Eff r a -> Eff r a #