definitive-base-2.6.3: A small Prelude wrapper to simplify my own Haskell developments

Safe HaskellNone
LanguageHaskell2010

Algebra.Classes

Synopsis

Documentation

class Functor f where Source #

Minimal complete definition

map

Methods

map :: (a -> b) -> f a -> f b Source #

Instances

Functor Strict Source # 

Methods

map :: (a -> b) -> Strict a -> Strict b Source #

Functor DeQue Source # 

Methods

map :: (a -> b) -> DeQue a -> DeQue b Source #

Functor TimeVal Source # 

Methods

map :: (a -> b) -> TimeVal a -> TimeVal b Source #

Functor (Increasing k) Source # 

Methods

map :: (a -> b) -> Increasing k a -> Increasing k b Source #

Functor (Const a) Source # 

Methods

map :: (a -> b) -> Const a a -> Const a b Source #

Functor f => Functor (Backwards f) Source # 

Methods

map :: (a -> b) -> Backwards f a -> Backwards f b Source #

Functor f => Functor (Zip f) Source # 

Methods

map :: (a -> b) -> Zip f a -> Zip f b Source #

Functor (ContT f) Source # 

Methods

map :: (a -> b) -> ContT f a -> ContT f b Source #

Functor w => Functor (Cofree w) Source # 

Methods

map :: (a -> b) -> Cofree w a -> Cofree w b Source #

Functor f => Functor (Free f) Source # 

Methods

map :: (a -> b) -> Free f a -> Free f b Source #

Functor m => Functor (StrictT m) Source # 

Methods

map :: (a -> b) -> StrictT m a -> StrictT m b Source #

Functor m => Functor (MaybeT m) Source # 

Methods

map :: (a -> b) -> MaybeT m a -> MaybeT m b Source #

Functor m => Functor (TreeT m) Source # 

Methods

map :: (a -> b) -> TreeT m a -> TreeT m b Source #

Functor m => Functor (ListT m) Source # 

Methods

map :: (a -> b) -> ListT m a -> ListT m b Source #

Functor (LogicT m) Source # 

Methods

map :: (a -> b) -> LogicT m a -> LogicT m b Source #

Functor (IOVar w) Source # 

Methods

map :: (a -> b) -> IOVar w a -> IOVar w b Source #

(Functor f, Functor g) => Functor ((:++:) f g) Source # 

Methods

map :: (a -> b) -> (f :++: g) a -> (f :++: g) b Source #

(Functor f, Functor g) => Functor ((:**:) f g) Source # 

Methods

map :: (a -> b) -> (f :**: g) a -> (f :**: g) b Source #

(Functor f, Functor g) => Functor ((:.:) f g) Source # 

Methods

map :: (a -> b) -> (f :.: g) a -> (f :.: g) b Source #

(Functor f, Functor g) => Functor (Compose' f g) Source # 

Methods

map :: (a -> b) -> Compose' f g a -> Compose' f g b Source #

Functor f => Functor (Kleisli f a) Source # 

Methods

map :: (a -> b) -> Kleisli f a a -> Kleisli f a b Source #

Functor m => Functor (EitherT e m) Source # 

Methods

map :: (a -> b) -> EitherT e m a -> EitherT e m b Source #

Functor m => Functor (ReaderT r m) Source # 

Methods

map :: (a -> b) -> ReaderT r m a -> ReaderT r m b Source #

Functor m => Functor (StateT s m) Source # 

Methods

map :: (a -> b) -> StateT s m a -> StateT s m b Source #

Functor m => Functor (WriterT w m) Source # 

Methods

map :: (a -> b) -> WriterT w m a -> WriterT w m b Source #

Functor (ProbT t m) Source # 

Methods

map :: (a -> b) -> ProbT t m a -> ProbT t m b Source #

Functor (Queue push pop) Source # 

Methods

map :: (a -> b) -> Queue push pop a -> Queue push pop b Source #

Functor m => Functor (CounterT w acc m) Source # 

Methods

map :: (a -> b) -> CounterT w acc m a -> CounterT w acc m b Source #

Functor f => Functor (RWST r w s f) Source # 

Methods

map :: (a -> b) -> RWST r w s f a -> RWST r w s f b Source #

class Functor f => SemiApplicative f where Source #

Methods

(<*>) :: f (a -> b) -> f a -> f b infixl 1 Source #

(<*>) :: Monad f => f (a -> b) -> f a -> f b infixl 1 Source #

Instances

SemiApplicative Strict Source # 

Methods

(<*>) :: Strict (a -> b) -> Strict a -> Strict b Source #

SemiApplicative TimeVal Source # 

Methods

(<*>) :: TimeVal (a -> b) -> TimeVal a -> TimeVal b Source #

Monoid a => SemiApplicative (Const a) Source # 

Methods

(<*>) :: Const a (a -> b) -> Const a a -> Const a b Source #

SemiApplicative f => SemiApplicative (Backwards f) Source # 

Methods

(<*>) :: Backwards f (a -> b) -> Backwards f a -> Backwards f b Source #

SemiApplicative (Zip []) Source # 

Methods

(<*>) :: Zip [] (a -> b) -> Zip [] a -> Zip [] b Source #

SemiApplicative (Zip Maybe) Source # 

Methods

(<*>) :: Zip Maybe (a -> b) -> Zip Maybe a -> Zip Maybe b Source #

SemiApplicative (Zip Tree) Source # 

Methods

(<*>) :: Zip Tree (a -> b) -> Zip Tree a -> Zip Tree b Source #

(Functor f, SemiApplicative (Zip f)) => SemiApplicative (Zip (Free f)) Source # 

Methods

(<*>) :: Zip (Free f) (a -> b) -> Zip (Free f) a -> Zip (Free f) b Source #

SemiApplicative (ContT m) Source # 

Methods

(<*>) :: ContT m (a -> b) -> ContT m a -> ContT m b Source #

Applicative m => SemiApplicative (Cofree m) Source # 

Methods

(<*>) :: Cofree m (a -> b) -> Cofree m a -> Cofree m b Source #

Functor f => SemiApplicative (Free f) Source # 

Methods

(<*>) :: Free f (a -> b) -> Free f a -> Free f b Source #

SemiApplicative m => SemiApplicative (StrictT m) Source # 

Methods

(<*>) :: StrictT m (a -> b) -> StrictT m a -> StrictT m b Source #

SemiApplicative m => SemiApplicative (MaybeT m) Source # 

Methods

(<*>) :: MaybeT m (a -> b) -> MaybeT m a -> MaybeT m b Source #

SemiApplicative m => SemiApplicative (TreeT m) Source # 

Methods

(<*>) :: TreeT m (a -> b) -> TreeT m a -> TreeT m b Source #

SemiApplicative m => SemiApplicative (ListT m) Source # 

Methods

(<*>) :: ListT m (a -> b) -> ListT m a -> ListT m b Source #

SemiApplicative (LogicT m) Source # 

Methods

(<*>) :: LogicT m (a -> b) -> LogicT m a -> LogicT m b Source #

SemiApplicative (IOVar w) Source # 

Methods

(<*>) :: IOVar w (a -> b) -> IOVar w a -> IOVar w b Source #

(SemiApplicative f, SemiApplicative g) => SemiApplicative (Compose' f g) Source # 

Methods

(<*>) :: Compose' f g (a -> b) -> Compose' f g a -> Compose' f g b Source #

SemiApplicative m => SemiApplicative (EitherT e m) Source # 

Methods

(<*>) :: EitherT e m (a -> b) -> EitherT e m a -> EitherT e m b Source #

Monad m => SemiApplicative (ReaderT r m) Source # 

Methods

(<*>) :: ReaderT r m (a -> b) -> ReaderT r m a -> ReaderT r m b Source #

Monad m => SemiApplicative (StateT s m) Source # 

Methods

(<*>) :: StateT s m (a -> b) -> StateT s m a -> StateT s m b Source #

(Monad m, Monoid w) => SemiApplicative (WriterT w m) Source # 

Methods

(<*>) :: WriterT w m (a -> b) -> WriterT w m a -> WriterT w m b Source #

Ring t => SemiApplicative (ProbT t m) Source # 

Methods

(<*>) :: ProbT t m (a -> b) -> ProbT t m a -> ProbT t m b Source #

(Monad m, Monoid w) => SemiApplicative (CounterT w acc m) Source # 

Methods

(<*>) :: CounterT w acc m (a -> b) -> CounterT w acc m a -> CounterT w acc m b Source #

(Monoid w, Monad m) => SemiApplicative (RWST r w s m) Source # 

Methods

(<*>) :: RWST r w s m (a -> b) -> RWST r w s m a -> RWST r w s m b Source #

class Applicative m => Monad m where Source #

Methods

join :: m (m a) -> m a Source #

(>>=) :: m a -> (a -> m b) -> m b infixl 1 Source #

Instances

Monad Strict Source # 

Methods

join :: Strict (Strict a) -> Strict a Source #

(>>=) :: Strict a -> (a -> Strict b) -> Strict b Source #

Monad TimeVal Source # 

Methods

join :: TimeVal (TimeVal a) -> TimeVal a Source #

(>>=) :: TimeVal a -> (a -> TimeVal b) -> TimeVal b Source #

Monad (ContT m) Source # 

Methods

join :: ContT m (ContT m a) -> ContT m a Source #

(>>=) :: ContT m a -> (a -> ContT m b) -> ContT m b Source #

Applicative m => Monad (Cofree m) Source # 

Methods

join :: Cofree m (Cofree m a) -> Cofree m a Source #

(>>=) :: Cofree m a -> (a -> Cofree m b) -> Cofree m b Source #

Functor f => Monad (Free f) Source # 

Methods

join :: Free f (Free f a) -> Free f a Source #

(>>=) :: Free f a -> (a -> Free f b) -> Free f b Source #

Monad m => Monad (StrictT m) Source # 

Methods

join :: StrictT m (StrictT m a) -> StrictT m a Source #

(>>=) :: StrictT m a -> (a -> StrictT m b) -> StrictT m b Source #

Monad m => Monad (MaybeT m) Source # 

Methods

join :: MaybeT m (MaybeT m a) -> MaybeT m a Source #

(>>=) :: MaybeT m a -> (a -> MaybeT m b) -> MaybeT m b Source #

Monad m => Monad (TreeT m) Source # 

Methods

join :: TreeT m (TreeT m a) -> TreeT m a Source #

(>>=) :: TreeT m a -> (a -> TreeT m b) -> TreeT m b Source #

Monad m => Monad (ListT m) Source # 

Methods

join :: ListT m (ListT m a) -> ListT m a Source #

(>>=) :: ListT m a -> (a -> ListT m b) -> ListT m b Source #

Monad (LogicT m) Source # 

Methods

join :: LogicT m (LogicT m a) -> LogicT m a Source #

(>>=) :: LogicT m a -> (a -> LogicT m b) -> LogicT m b Source #

Monad (IOVar w) Source # 

Methods

join :: IOVar w (IOVar w a) -> IOVar w a Source #

(>>=) :: IOVar w a -> (a -> IOVar w b) -> IOVar w b Source #

(Monad f, Monad g, Traversable f) => Monad (Compose' f g) Source # 

Methods

join :: Compose' f g (Compose' f g a) -> Compose' f g a Source #

(>>=) :: Compose' f g a -> (a -> Compose' f g b) -> Compose' f g b Source #

Monad m => Monad (EitherT e m) Source # 

Methods

join :: EitherT e m (EitherT e m a) -> EitherT e m a Source #

(>>=) :: EitherT e m a -> (a -> EitherT e m b) -> EitherT e m b Source #

Monad m => Monad (ReaderT r m) Source # 

Methods

join :: ReaderT r m (ReaderT r m a) -> ReaderT r m a Source #

(>>=) :: ReaderT r m a -> (a -> ReaderT r m b) -> ReaderT r m b Source #

Monad m => Monad (StateT s m) Source # 

Methods

join :: StateT s m (StateT s m a) -> StateT s m a Source #

(>>=) :: StateT s m a -> (a -> StateT s m b) -> StateT s m b Source #

(Monoid w, Monad m) => Monad (WriterT w m) Source # 

Methods

join :: WriterT w m (WriterT w m a) -> WriterT w m a Source #

(>>=) :: WriterT w m a -> (a -> WriterT w m b) -> WriterT w m b Source #

Ring t => Monad (ProbT t m) Source # 

Methods

join :: ProbT t m (ProbT t m a) -> ProbT t m a Source #

(>>=) :: ProbT t m a -> (a -> ProbT t m b) -> ProbT t m b Source #

(Monoid w, Monad m) => Monad (CounterT w a m) Source # 

Methods

join :: CounterT w a m (CounterT w a m a) -> CounterT w a m a Source #

(>>=) :: CounterT w a m a -> (a -> CounterT w a m b) -> CounterT w a m b Source #

(Monoid w, Monad m) => Monad (RWST r w s m) Source # 

Methods

join :: RWST r w s m (RWST r w s m a) -> RWST r w s m a Source #

(>>=) :: RWST r w s m a -> (a -> RWST r w s m b) -> RWST r w s m b Source #

class Counit w where Source #

Minimal complete definition

extract

Methods

extract :: w a -> a Source #

Instances

Counit (Cofree w) Source # 

Methods

extract :: Cofree w a -> a Source #

Counit f => Counit (Free f) Source # 

Methods

extract :: Free f a -> a Source #

class (Functor w, Counit w) => Comonad w where Source #

Methods

duplicate :: w a -> w (w a) Source #

(=>>) :: w a -> (w a -> b) -> w b infixl 1 Source #

Instances

Functor w => Comonad (Cofree w) Source # 

Methods

duplicate :: Cofree w a -> Cofree w (Cofree w a) Source #

(=>>) :: Cofree w a -> (Cofree w a -> b) -> Cofree w b Source #

Comonad f => Comonad (Free f) Source # 

Methods

duplicate :: Free f a -> Free f (Free f a) Source #

(=>>) :: Free f a -> (Free f a -> b) -> Free f b Source #

class Functor f => Foldable f where Source #

Minimal complete definition

fold

Methods

fold :: Monoid m => f m -> m Source #

Instances

Foldable DeQue Source # 

Methods

fold :: Monoid m => DeQue m -> m Source #

Foldable TimeVal Source # 

Methods

fold :: Monoid m => TimeVal m -> m Source #

Foldable f => Foldable (Zip f) Source # 

Methods

fold :: Monoid m => Zip f m -> m Source #

Foldable w => Foldable (Cofree w) Source # 

Methods

fold :: Monoid m => Cofree w m -> m Source #

Foldable f => Foldable (Free f) Source # 

Methods

fold :: Monoid m => Free f m -> m Source #

Foldable m => Foldable (StrictT m) Source # 

Methods

fold :: Monoid m => StrictT m m -> m Source #

Foldable m => Foldable (MaybeT m) Source # 

Methods

fold :: Monoid m => MaybeT m m -> m Source #

Foldable m => Foldable (TreeT m) Source # 

Methods

fold :: Monoid m => TreeT m m -> m Source #

Foldable m => Foldable (ListT m) Source # 

Methods

fold :: Monoid m => ListT m m -> m Source #

(Monad m, Foldable m) => Foldable (LogicT m) Source # 

Methods

fold :: Monoid m => LogicT m m -> m Source #

(Foldable f, Foldable g) => Foldable (Compose' f g) Source # 

Methods

fold :: Monoid m => Compose' f g m -> m Source #

Foldable m => Foldable (EitherT e m) Source # 

Methods

fold :: Monoid m => EitherT e m m -> m Source #

Foldable m => Foldable (WriterT w m) Source # 

Methods

fold :: Monoid m => WriterT w m m -> m Source #

Foldable (Queue push pop) Source # 

Methods

fold :: Monoid m => Queue push pop m -> m Source #

Foldable m => Foldable (RWST Void w Void m) Source # 

Methods

fold :: Monoid m => RWST Void w Void m m -> m Source #

class Functor t => Traversable t where Source #

Minimal complete definition

sequence

Methods

sequence :: Applicative f => t (f a) -> f (t a) Source #

Instances

Traversable DeQue Source # 

Methods

sequence :: Applicative f => DeQue (f a) -> f (DeQue a) Source #

Traversable TimeVal Source # 

Methods

sequence :: Applicative f => TimeVal (f a) -> f (TimeVal a) Source #

Traversable w => Traversable (Cofree w) Source # 

Methods

sequence :: Applicative f => Cofree w (f a) -> f (Cofree w a) Source #

Traversable f => Traversable (Free f) Source # 

Methods

sequence :: Applicative f => Free f (f a) -> f (Free f a) Source #

Traversable m => Traversable (StrictT m) Source # 

Methods

sequence :: Applicative f => StrictT m (f a) -> f (StrictT m a) Source #

Traversable m => Traversable (MaybeT m) Source # 

Methods

sequence :: Applicative f => MaybeT m (f a) -> f (MaybeT m a) Source #

Traversable m => Traversable (TreeT m) Source # 

Methods

sequence :: Applicative f => TreeT m (f a) -> f (TreeT m a) Source #

Traversable m => Traversable (ListT m) Source # 

Methods

sequence :: Applicative f => ListT m (f a) -> f (ListT m a) Source #

(Monad m, Traversable m) => Traversable (LogicT m) Source # 

Methods

sequence :: Applicative f => LogicT m (f a) -> f (LogicT m a) Source #

(Traversable g, Traversable f) => Traversable (Compose' f g) Source # 

Methods

sequence :: Applicative f => Compose' f g (f a) -> f (Compose' f g a) Source #

Traversable m => Traversable (EitherT e m) Source # 

Methods

sequence :: Applicative f => EitherT e m (f a) -> f (EitherT e m a) Source #

Traversable m => Traversable (WriterT e m) Source # 

Methods

sequence :: Applicative f => WriterT e m (f a) -> f (WriterT e m a) Source #

Traversable (Queue push pop) Source # 

Methods

sequence :: Applicative f => Queue push pop (f a) -> f (Queue push pop a) Source #

Traversable m => Traversable (RWST Void w Void m) Source # 

Methods

sequence :: Applicative f => RWST Void w Void m (f a) -> f (RWST Void w Void m a) Source #

class Monad m => MonadFix m where Source #

The class of all monads that have a fixpoint

Minimal complete definition

mfix

Methods

mfix :: (a -> m a) -> m a Source #

Instances

MonadFix m => MonadFix (ContT m) Source # 

Methods

mfix :: (a -> ContT m a) -> ContT m a Source #

MonadFix f => MonadFix (Free f) Source # 

Methods

mfix :: (a -> Free f a) -> Free f a Source #

MonadFix m => MonadFix (StrictT m) Source # 

Methods

mfix :: (a -> StrictT m a) -> StrictT m a Source #

MonadFix m => MonadFix (MaybeT m) Source # 

Methods

mfix :: (a -> MaybeT m a) -> MaybeT m a Source #

MonadFix m => MonadFix (TreeT m) Source # 

Methods

mfix :: (a -> TreeT m a) -> TreeT m a Source #

MonadFix m => MonadFix (ListT m) Source # 

Methods

mfix :: (a -> ListT m a) -> ListT m a Source #

MonadFix m => MonadFix (LogicT m) Source # 

Methods

mfix :: (a -> LogicT m a) -> LogicT m a Source #

(Monad f, Traversable f, MonadFix g) => MonadFix (Compose' f g) Source # 

Methods

mfix :: (a -> Compose' f g a) -> Compose' f g a Source #

MonadFix m => MonadFix (EitherT e m) Source # 

Methods

mfix :: (a -> EitherT e m a) -> EitherT e m a Source #

MonadFix m => MonadFix (ReaderT r m) Source # 

Methods

mfix :: (a -> ReaderT r m a) -> ReaderT r m a Source #

MonadFix m => MonadFix (StateT s m) Source # 

Methods

mfix :: (a -> StateT s m a) -> StateT s m a Source #

(MonadFix m, Monoid w) => MonadFix (WriterT w m) Source # 

Methods

mfix :: (a -> WriterT w m a) -> WriterT w m a Source #

(Ring t, MonadFix m) => MonadFix (ProbT t m) Source # 

Methods

mfix :: (a -> ProbT t m a) -> ProbT t m a Source #

(MonadFix m, Monoid w) => MonadFix (CounterT w acc m) Source # 

Methods

mfix :: (a -> CounterT w acc m a) -> CounterT w acc m a Source #

(Monoid w, MonadFix m) => MonadFix (RWST r w s m) Source # 

Methods

mfix :: (a -> RWST r w s m a) -> RWST r w s m a Source #

class MonadTrans t where Source #

Minimal complete definition

lift

Methods

lift :: Monad m => m a -> t m a Source #

Instances

MonadTrans ContT Source # 

Methods

lift :: Monad m => m a -> ContT m a Source #

MonadTrans Free Source # 

Methods

lift :: Monad m => m a -> Free m a Source #

MonadTrans StrictT Source # 

Methods

lift :: Monad m => m a -> StrictT m a Source #

MonadTrans MaybeT Source # 

Methods

lift :: Monad m => m a -> MaybeT m a Source #

MonadTrans TreeT Source # 

Methods

lift :: Monad m => m a -> TreeT m a Source #

MonadTrans ListT Source # 

Methods

lift :: Monad m => m a -> ListT m a Source #

MonadTrans LogicT Source # 

Methods

lift :: Monad m => m a -> LogicT m a Source #

Monad m => MonadTrans (Compose' m) Source # 

Methods

lift :: Monad m => m a -> Compose' m m a Source #

MonadTrans (EitherT e) Source # 

Methods

lift :: Monad m => m a -> EitherT e m a Source #

MonadTrans (ReaderT r) Source # 

Methods

lift :: Monad m => m a -> ReaderT r m a Source #

MonadTrans (StateT s) Source # 

Methods

lift :: Monad m => m a -> StateT s m a Source #

Monoid w => MonadTrans (WriterT w) Source # 

Methods

lift :: Monad m => m a -> WriterT w m a Source #

Monoid w => MonadTrans (CounterT w acc) Source # 

Methods

lift :: Monad m => m a -> CounterT w acc m a Source #

Monoid w => MonadTrans (RWST r w s) Source # 

Methods

lift :: Monad m => m a -> RWST r w s m a Source #

class MonadTrans t => ConcreteMonad t where Source #

Minimal complete definition

generalize

Methods

generalize :: Monad m => t Id a -> t m a Source #

Instances

ConcreteMonad Free Source # 

Methods

generalize :: Monad m => Free Id a -> Free m a Source #

Monad m => ConcreteMonad (Compose' m) Source # 

Methods

generalize :: Monad m => Compose' m Id a -> Compose' m m a Source #

ConcreteMonad (StateT s) Source # 

Methods

generalize :: Monad m => StateT s Id a -> StateT s m a Source #

Monoid w => ConcreteMonad (WriterT w) Source # 

Methods

generalize :: Monad m => WriterT w Id a -> WriterT w m a Source #

Monoid w => ConcreteMonad (CounterT w acc) Source # 

Methods

generalize :: Monad m => CounterT w acc Id a -> CounterT w acc m a Source #

Monoid w => ConcreteMonad (RWST r w s) Source # 

Methods

generalize :: Monad m => RWST r w s Id a -> RWST r w s m a Source #

class Monad m => MonadState s m | m -> s where Source #

Minimal complete definition

get

Methods

get :: m s Source #

put :: s -> m () Source #

modify :: (s -> s) -> m () Source #

Instances

MonadState s m => MonadState s (Free m) Source # 

Methods

get :: Free m s Source #

put :: s -> Free m () Source #

modify :: (s -> s) -> Free m () Source #

MonadState s m => MonadState s (ListT m) Source # 

Methods

get :: ListT m s Source #

put :: s -> ListT m () Source #

modify :: (s -> s) -> ListT m () Source #

MonadState s m => MonadState s (TreeT m) Source # 

Methods

get :: TreeT m s Source #

put :: s -> TreeT m () Source #

modify :: (s -> s) -> TreeT m () Source #

MonadState s m => MonadState s (MaybeT m) Source # 

Methods

get :: MaybeT m s Source #

put :: s -> MaybeT m () Source #

modify :: (s -> s) -> MaybeT m () Source #

MonadState s m => MonadState s (StrictT m) Source # 

Methods

get :: StrictT m s Source #

put :: s -> StrictT m () Source #

modify :: (s -> s) -> StrictT m () Source #

MonadState s m => MonadState s (LogicT m) Source # 

Methods

get :: LogicT m s Source #

put :: s -> LogicT m () Source #

modify :: (s -> s) -> LogicT m () Source #

(Traversable f, Monad f, MonadState s g) => MonadState s (Compose' f g) Source # 

Methods

get :: Compose' f g s Source #

put :: s -> Compose' f g () Source #

modify :: (s -> s) -> Compose' f g () Source #

MonadState s m => MonadState s (ReaderT r m) Source # 

Methods

get :: ReaderT r m s Source #

put :: s -> ReaderT r m () Source #

modify :: (s -> s) -> ReaderT r m () Source #

Monad m => MonadState s (StateT s m) Source # 

Methods

get :: StateT s m s Source #

put :: s -> StateT s m () Source #

modify :: (s -> s) -> StateT s m () Source #

(Monoid w, MonadState r m) => MonadState r (WriterT w m) Source # 

Methods

get :: WriterT w m r Source #

put :: r -> WriterT w m () Source #

modify :: (r -> r) -> WriterT w m () Source #

(MonadState s m, Monoid w) => MonadState s (CounterT w acc m) Source # 

Methods

get :: CounterT w acc m s Source #

put :: s -> CounterT w acc m () Source #

modify :: (s -> s) -> CounterT w acc m () Source #

(Monad m, Monoid w) => MonadState s (RWST r w s m) Source # 

Methods

get :: RWST r w s m s Source #

put :: s -> RWST r w s m () Source #

modify :: (s -> s) -> RWST r w s m () Source #

class Monad m => MonadReader r m | m -> r where Source #

Minimal complete definition

ask, local

Methods

ask :: m r Source #

local :: (r -> r) -> m a -> m a Source #

Instances

MonadReader r m => MonadReader r (Free m) Source # 

Methods

ask :: Free m r Source #

local :: (r -> r) -> Free m a -> Free m a Source #

MonadReader r m => MonadReader r (TreeT m) Source # 

Methods

ask :: TreeT m r Source #

local :: (r -> r) -> TreeT m a -> TreeT m a Source #

MonadReader r m => MonadReader r (MaybeT m) Source # 

Methods

ask :: MaybeT m r Source #

local :: (r -> r) -> MaybeT m a -> MaybeT m a Source #

MonadReader r m => MonadReader r (StrictT m) Source # 

Methods

ask :: StrictT m r Source #

local :: (r -> r) -> StrictT m a -> StrictT m a Source #

MonadReader r m => MonadReader r (LogicT m) Source # 

Methods

ask :: LogicT m r Source #

local :: (r -> r) -> LogicT m a -> LogicT m a Source #

(Traversable f, Monad f, MonadReader r g) => MonadReader r (Compose' f g) Source # 

Methods

ask :: Compose' f g r Source #

local :: (r -> r) -> Compose' f g a -> Compose' f g a Source #

Monad m => MonadReader r (ReaderT r m) Source # 

Methods

ask :: ReaderT r m r Source #

local :: (r -> r) -> ReaderT r m a -> ReaderT r m a Source #

MonadReader r m => MonadReader r (StateT s m) Source # 

Methods

ask :: StateT s m r Source #

local :: (r -> r) -> StateT s m a -> StateT s m a Source #

(Monoid w, MonadReader r m) => MonadReader r (WriterT w m) Source # 

Methods

ask :: WriterT w m r Source #

local :: (r -> r) -> WriterT w m a -> WriterT w m a Source #

(Monad m, Monoid w) => MonadReader r (RWST r w s m) Source # 

Methods

ask :: RWST r w s m r Source #

local :: (r -> r) -> RWST r w s m a -> RWST r w s m a Source #

class (Monad m, Monoid w) => MonadWriter w m | m -> w where Source #

Minimal complete definition

tell, listen, censor

Methods

tell :: w -> m () Source #

listen :: m a -> m (w, a) Source #

censor :: m (a, w -> w) -> m a Source #

Instances

MonadWriter w m => MonadWriter w (Free m) Source # 

Methods

tell :: w -> Free m () Source #

listen :: Free m a -> Free m (w, a) Source #

censor :: Free m (a, w -> w) -> Free m a Source #

MonadWriter w m => MonadWriter w (ListT m) Source # 

Methods

tell :: w -> ListT m () Source #

listen :: ListT m a -> ListT m (w, a) Source #

censor :: ListT m (a, w -> w) -> ListT m a Source #

MonadWriter w m => MonadWriter w (TreeT m) Source # 

Methods

tell :: w -> TreeT m () Source #

listen :: TreeT m a -> TreeT m (w, a) Source #

censor :: TreeT m (a, w -> w) -> TreeT m a Source #

MonadWriter w m => MonadWriter w (MaybeT m) Source # 

Methods

tell :: w -> MaybeT m () Source #

listen :: MaybeT m a -> MaybeT m (w, a) Source #

censor :: MaybeT m (a, w -> w) -> MaybeT m a Source #

MonadWriter w m => MonadWriter w (StrictT m) Source # 

Methods

tell :: w -> StrictT m () Source #

listen :: StrictT m a -> StrictT m (w, a) Source #

censor :: StrictT m (a, w -> w) -> StrictT m a Source #

MonadWriter w m => MonadWriter w (LogicT m) Source # 

Methods

tell :: w -> LogicT m () Source #

listen :: LogicT m a -> LogicT m (w, a) Source #

censor :: LogicT m (a, w -> w) -> LogicT m a Source #

(Traversable f, Monad f, MonadWriter w g) => MonadWriter w (Compose' f g) Source # 

Methods

tell :: w -> Compose' f g () Source #

listen :: Compose' f g a -> Compose' f g (w, a) Source #

censor :: Compose' f g (a, w -> w) -> Compose' f g a Source #

MonadWriter w m => MonadWriter w (ReaderT r m) Source # 

Methods

tell :: w -> ReaderT r m () Source #

listen :: ReaderT r m a -> ReaderT r m (w, a) Source #

censor :: ReaderT r m (a, w -> w) -> ReaderT r m a Source #

MonadWriter w m => MonadWriter w (StateT s m) Source # 

Methods

tell :: w -> StateT s m () Source #

listen :: StateT s m a -> StateT s m (w, a) Source #

censor :: StateT s m (a, w -> w) -> StateT s m a Source #

(Monoid w, Monad m) => MonadWriter w (WriterT w m) Source # 

Methods

tell :: w -> WriterT w m () Source #

listen :: WriterT w m a -> WriterT w m (w, a) Source #

censor :: WriterT w m (a, w -> w) -> WriterT w m a Source #

(Monad m, SubSemi acc w, Monoid w) => MonadWriter w (CounterT w acc m) Source # 

Methods

tell :: w -> CounterT w acc m () Source #

listen :: CounterT w acc m a -> CounterT w acc m (w, a) Source #

censor :: CounterT w acc m (a, w -> w) -> CounterT w acc m a Source #

(Monad m, Monoid w) => MonadWriter w (RWST r w s m) Source # 

Methods

tell :: w -> RWST r w s m () Source #

listen :: RWST r w s m a -> RWST r w s m (w, a) Source #

censor :: RWST r w s m (a, w -> w) -> RWST r w s m a Source #

Ring t => MonadWriter (Product t) (ProbT t m) Source # 

Methods

tell :: Product t -> ProbT t m () Source #

listen :: ProbT t m a -> ProbT t m (Product t, a) Source #

censor :: ProbT t m (a, Product t -> Product t) -> ProbT t m a Source #

class (SubSemi acc w, MonadWriter w m) => MonadCounter w acc m | m -> acc where Source #

Minimal complete definition

getCounter, setCounter

Methods

getCounter :: m acc Source #

setCounter :: acc -> m () Source #

Instances

MonadCounter w a m => MonadCounter w a (Free m) Source # 

Methods

getCounter :: Free m a Source #

setCounter :: a -> Free m () Source #

MonadCounter w acc m => MonadCounter w acc (ReaderT r m) Source # 

Methods

getCounter :: ReaderT r m acc Source #

setCounter :: acc -> ReaderT r m () Source #

MonadCounter w acc m => MonadCounter w acc (StateT s m) Source # 

Methods

getCounter :: StateT s m acc Source #

setCounter :: acc -> StateT s m () Source #

(Monad m, Monoid w, SubSemi acc w) => MonadCounter w acc (CounterT w acc m) Source # 

Methods

getCounter :: CounterT w acc m acc Source #

setCounter :: acc -> CounterT w acc m () Source #

class Monad m => MonadIO m where Source #

Methods

liftIO :: IO a -> m a Source #

liftIO :: (MonadTrans t, MonadIO n, t n a ~ m a) => IO a -> m a Source #

Instances

MonadIO m => MonadIO (Free m) Source # 

Methods

liftIO :: IO a -> Free m a Source #

class Monad m => MonadList m where Source #

Minimal complete definition

choose

Methods

choose :: [a] -> m a Source #

Instances

MonadList m => MonadList (Free m) Source # 

Methods

choose :: [a] -> Free m a Source #

Monad m => MonadList (ListT m) Source # 

Methods

choose :: [a] -> ListT m a Source #

MonadList m => MonadList (ReaderT r m) Source # 

Methods

choose :: [a] -> ReaderT r m a Source #

MonadList m => MonadList (StateT s m) Source # 

Methods

choose :: [a] -> StateT s m a Source #

(MonadList m, Monoid w) => MonadList (WriterT w m) Source # 

Methods

choose :: [a] -> WriterT w m a Source #

(Monad m, Invertible t) => MonadList (ProbT t m) Source # 

Methods

choose :: [a] -> ProbT t m a Source #

(Monoid w, MonadList m) => MonadList (RWST r w s m) Source # 

Methods

choose :: [a] -> RWST r w s m a Source #

class Monad m => MonadCont m where Source #

Minimal complete definition

callCC

Methods

callCC :: (forall b. (a -> m b) -> m b) -> m a Source #

Instances

MonadCont (ContT m) Source # 

Methods

callCC :: (forall b. (a -> ContT m b) -> ContT m b) -> ContT m a Source #

MonadCont m => MonadCont (ReaderT r m) Source # 

Methods

callCC :: (forall b. (a -> ReaderT r m b) -> ReaderT r m b) -> ReaderT r m a Source #

MonadCont m => MonadCont (StateT s m) Source # 

Methods

callCC :: (forall b. (a -> StateT s m b) -> StateT s m b) -> StateT s m a Source #

(MonadCont m, Monoid w) => MonadCont (WriterT w m) Source # 

Methods

callCC :: (forall b. (a -> WriterT w m b) -> WriterT w m b) -> WriterT w m a Source #

(Monoid w, MonadCont m) => MonadCont (RWST r w s m) Source # 

Methods

callCC :: (forall b. (a -> RWST r w s m b) -> RWST r w s m b) -> RWST r w s m a Source #

class Monad m => MonadError e m | m -> e where Source #

Minimal complete definition

throw, catch

Methods

throw :: e -> m a Source #

catch :: (e -> m a) -> m a -> m a Source #

Instances

MonadError e m => MonadError e (Free m) Source # 

Methods

throw :: e -> Free m a Source #

catch :: (e -> Free m a) -> Free m a -> Free m a Source #

Monad m => MonadError Void (ListT m) Source # 

Methods

throw :: Void -> ListT m a Source #

catch :: (Void -> ListT m a) -> ListT m a -> ListT m a Source #

Monad m => MonadError Void (LogicT m) Source # 

Methods

throw :: Void -> LogicT m a Source #

catch :: (Void -> LogicT m a) -> LogicT m a -> LogicT m a Source #

MonadError e m => MonadError e (StateT s m) Source # 

Methods

throw :: e -> StateT s m a Source #

catch :: (e -> StateT s m a) -> StateT s m a -> StateT s m a Source #

(Monoid w, MonadError e m) => MonadError e (RWST r w s m) Source # 

Methods

throw :: e -> RWST r w s m a Source #

catch :: (e -> RWST r w s m a) -> RWST r w s m a -> RWST r w s m a Source #

class Monad m => MonadLogic m l | l -> m where Source #

Minimal complete definition

deduce, induce

Methods

deduce :: l a -> m (Maybe (a, l a)) Source #

induce :: m (Maybe (a, l a)) -> l a Source #

Instances

Monad m => MonadLogic m (LogicT m) Source # 

Methods

deduce :: LogicT m a -> m (Maybe (a, LogicT m a)) Source #

induce :: m (Maybe (a, LogicT m a)) -> LogicT m a Source #

MonadLogic m l => MonadLogic (ReaderT r m) (ReaderT r l) Source # 

Methods

deduce :: ReaderT r l a -> ReaderT r m (Maybe (a, ReaderT r l a)) Source #

induce :: ReaderT r m (Maybe (a, ReaderT r l a)) -> ReaderT r l a Source #

MonadLogic l m => MonadLogic (StateT s l) (StateT s m) Source # 

Methods

deduce :: StateT s m a -> StateT s l (Maybe (a, StateT s m a)) Source #

induce :: StateT s l (Maybe (a, StateT s m a)) -> StateT s m a Source #

(Monoid w, MonadLogic m l) => MonadLogic (WriterT w m) (WriterT w l) Source # 

Methods

deduce :: WriterT w l a -> WriterT w m (Maybe (a, WriterT w l a)) Source #

induce :: WriterT w m (Maybe (a, WriterT w l a)) -> WriterT w l a Source #

(Monoid w, MonadLogic l m) => MonadLogic (RWST r w s l) (RWST r w s m) Source # 

Methods

deduce :: RWST r w s m a -> RWST r w s l (Maybe (a, RWST r w s m a)) Source #

induce :: RWST r w s l (Maybe (a, RWST r w s m a)) -> RWST r w s m a Source #

coerceDeduce :: forall l m l' m' a. MonadLogic m l => (forall b. l b -> l' b) -> (forall b. m b -> m' b) -> l' a -> m' (Maybe (a, l' a)) Source #

coerceInduce :: forall l m l' m' a. MonadLogic m l => (forall b. l b -> l' b) -> (forall b. m b -> m' b) -> m' (Maybe (a, l' a)) -> l' a Source #

class MonadFix t => MonadFuture m t | t -> m where Source #

Minimal complete definition

future

Methods

future :: m a -> t a Source #

Instances

MonadFuture m t => MonadFuture m (Free t) Source # 

Methods

future :: m a -> Free t a Source #

(Monad m, MonadFuture n m) => MonadFuture n (ReaderT r m) Source # 

Methods

future :: n a -> ReaderT r m a Source #

(Monad m, MonadFuture n m) => MonadFuture n (StateT s m) Source # 

Methods

future :: n a -> StateT s m a Source #

(Monad m, Monoid w, MonadFuture n m) => MonadFuture n (WriterT w m) Source # 

Methods

future :: n a -> WriterT w m a Source #

(Monad m, Monoid w, MonadFuture n m) => MonadFuture n (CounterT w acc m) Source # 

Methods

future :: n a -> CounterT w acc m a Source #

(Monad m, Monoid w, MonadFuture n m) => MonadFuture n (RWST r w s m) Source # 

Methods

future :: n a -> RWST r w s m a Source #