Copyright | (c) 2005 Amr Sabry Chung-chieh Shan Oleg Kiselyov and Daniel P. Friedman |
---|---|
License | GPLv2 or higher, see LICENSE.txt |
Maintainer | Mihai.Codescu@dfki.de |
Stability | provisional |
Portability | portable |
Safe Haskell | Safe |
Logic Monad Transformer: MonadPlusT with interleave, bindi, ifte and once Definition and implementation of generic operations, in terms of msplit
Documentation
class MonadTrans t => LogicT t where Source #
msplit :: (Monad m, MonadPlus (t m)) => t m a -> t m (Maybe (a, t m a)) Source #
interleave :: (Monad m, MonadPlus (t m)) => t m a -> t m a -> t m a Source #
gsuccess :: (Monad m, MonadPlus (t m)) => a -> t m a Source #
gfail :: (Monad m, MonadPlus (t m)) => t m a Source #
bindi :: (Monad m, MonadPlus (t m)) => t m a -> (a -> t m b) -> t m b Source #
ifte :: (Monad m, MonadPlus (t m)) => t m a -> (a -> t m b) -> t m b -> t m b Source #
once :: (Monad m, MonadPlus (t m)) => t m a -> t m a Source #
Instances
LogicT SFKT Source # | |
Defined in Common.SFKT msplit :: forall (m :: Type -> Type) a. (Monad m, MonadPlus (SFKT m)) => SFKT m a -> SFKT m (Maybe (a, SFKT m a)) Source # interleave :: forall (m :: Type -> Type) a. (Monad m, MonadPlus (SFKT m)) => SFKT m a -> SFKT m a -> SFKT m a Source # gsuccess :: forall (m :: Type -> Type) a. (Monad m, MonadPlus (SFKT m)) => a -> SFKT m a Source # gfail :: forall (m :: Type -> Type) a. (Monad m, MonadPlus (SFKT m)) => SFKT m a Source # bindi :: forall (m :: Type -> Type) a b. (Monad m, MonadPlus (SFKT m)) => SFKT m a -> (a -> SFKT m b) -> SFKT m b Source # ifte :: forall (m :: Type -> Type) a b. (Monad m, MonadPlus (SFKT m)) => SFKT m a -> (a -> SFKT m b) -> SFKT m b -> SFKT m b Source # once :: forall (m :: Type -> Type) a. (Monad m, MonadPlus (SFKT m)) => SFKT m a -> SFKT m a Source # |