essence-of-live-coding-0.2.6: General purpose live coding framework
Safe HaskellSafe-Inferred
LanguageHaskell2010

LiveCoding.CellExcept

Synopsis

Documentation

data CellExcept a b m e where Source #

Constructors

Return :: e -> CellExcept a b m e 
Bind :: CellExcept a b m e1 -> (e1 -> CellExcept a b m e2) -> CellExcept a b m e2 
Try :: (Data e, Finite e) => Cell (ExceptT e m) a b -> CellExcept a b m e 

Instances

Instances details
MFunctor (CellExcept a b :: (Type -> Type) -> Type -> Type) Source # 
Instance details

Defined in LiveCoding.CellExcept

Methods

hoist :: forall m n (b0 :: k). Monad m => (forall a0. m a0 -> n a0) -> CellExcept a b m b0 -> CellExcept a b n b0 #

Monad m => Monad (CellExcept a b m) Source # 
Instance details

Defined in LiveCoding.CellExcept

Methods

(>>=) :: CellExcept a b m a0 -> (a0 -> CellExcept a b m b0) -> CellExcept a b m b0 #

(>>) :: CellExcept a b m a0 -> CellExcept a b m b0 -> CellExcept a b m b0 #

return :: a0 -> CellExcept a b m a0 #

Monad m => Functor (CellExcept a b m) Source # 
Instance details

Defined in LiveCoding.CellExcept

Methods

fmap :: (a0 -> b0) -> CellExcept a b m a0 -> CellExcept a b m b0 #

(<$) :: a0 -> CellExcept a b m b0 -> CellExcept a b m a0 #

Monad m => Applicative (CellExcept a b m) Source # 
Instance details

Defined in LiveCoding.CellExcept

Methods

pure :: a0 -> CellExcept a b m a0 #

(<*>) :: CellExcept a b m (a0 -> b0) -> CellExcept a b m a0 -> CellExcept a b m b0 #

liftA2 :: (a0 -> b0 -> c) -> CellExcept a b m a0 -> CellExcept a b m b0 -> CellExcept a b m c #

(*>) :: CellExcept a b m a0 -> CellExcept a b m b0 -> CellExcept a b m b0 #

(<*) :: CellExcept a b m a0 -> CellExcept a b m b0 -> CellExcept a b m a0 #

runCellExcept :: Monad m => CellExcept a b m e -> Cell (ExceptT e m) a b Source #

try :: (Data e, Finite e) => Cell (ExceptT e m) a b -> CellExcept a b m e Source #

safely :: Monad m => CellExcept a b m Void -> Cell m a b Source #

discardVoid :: Functor m => ExceptT Void m a -> m a Source #

safe :: Monad m => Cell m a b -> CellExcept a b m Void Source #

once :: (Monad m, Data e, Finite e) => (a -> m e) -> CellExcept a arbitrary m e Source #

Run a monadic action and immediately raise its result as an exception.

once_ :: (Monad m, Data e, Finite e) => m e -> CellExcept a arbitrary m e Source #

Like once, but the action does not have an input.