{-# LANGUAGE Safe #-}
module Semigroupoids.Do
( fmap
, (<*)
, (*>)
, (<*>)
, (>>)
, (>>=)
, join
, pure
, return
, fail
)
where
import Prelude (String, fmap, pure, return)
import Data.Functor.Apply (Apply, (<.), (.>), (<.>))
import Data.Functor.Bind (Bind, (>>-), join)
import Data.Functor.Plus (Plus, zero)
(<*) :: Apply f => f a -> f b -> f a
<* :: forall (f :: * -> *) a b. Apply f => f a -> f b -> f a
(<*) = f a -> f b -> f a
forall a b. f a -> f b -> f a
forall (f :: * -> *) a b. Apply f => f a -> f b -> f a
(<.)
(*>) :: Apply f => f a -> f b -> f b
*> :: forall (f :: * -> *) a b. Apply f => f a -> f b -> f b
(*>) = f a -> f b -> f b
forall a b. f a -> f b -> f b
forall (f :: * -> *) a b. Apply f => f a -> f b -> f b
(.>)
(<*>) :: Apply f => f (a -> b) -> f a -> f b
<*> :: forall (f :: * -> *) a b. Apply f => f (a -> b) -> f a -> f b
(<*>) = f (a -> b) -> f a -> f b
forall a b. f (a -> b) -> f a -> f b
forall (f :: * -> *) a b. Apply f => f (a -> b) -> f a -> f b
(<.>)
(>>) :: Bind m => m a -> m b -> m b
>> :: forall (m :: * -> *) a b. Bind m => m a -> m b -> m b
(>>) = m a -> m b -> m b
forall a b. m a -> m b -> m b
forall (f :: * -> *) a b. Apply f => f a -> f b -> f b
(.>)
(>>=) :: Bind m => m a -> (a -> m b) -> m b
>>= :: forall (m :: * -> *) a b. Bind m => m a -> (a -> m b) -> m b
(>>=) = m a -> (a -> m b) -> m b
forall a b. m a -> (a -> m b) -> m b
forall (m :: * -> *) a b. Bind m => m a -> (a -> m b) -> m b
(>>-)
fail ::
(Plus m) =>
String ->
m a
fail :: forall (m :: * -> *) a. Plus m => String -> m a
fail String
_ = m a
forall a. m a
forall (f :: * -> *) a. Plus f => f a
zero