functor-monad-0.1.1.1: FFunctor: functors on (the usual) Functors
Safe HaskellSafe-Inferred
LanguageHaskell2010

Data.Functor.Precompose

Synopsis

Documentation

type (:.:) = Compose Source #

Single-kinded type alias of Compose

newtype Precompose f g a Source #

Flipped-order Compose.

When f is a Monad, Precompose f is a FMonad in the similar way Compose is.

The only difference is Precompose f composes f to the right (_pre_compose) compared to Compose f which composes to the left (_post_compose).

Constructors

Precompose 

Fields

Instances

Instances details
Functor f => Adjunction (Lan f) (Precompose f) Source # 
Instance details

Defined in FFunctor.Adjunction

Methods

unit :: forall (g :: Type -> Type). Functor g => g ~> Precompose f (Lan f g) Source #

counit :: forall (g :: Type -> Type). Functor g => Lan f (Precompose f g) ~> g Source #

leftAdjunct :: forall (g :: Type -> Type) (h :: Type -> Type). (Functor g, Functor h) => (Lan f g ~> h) -> g ~> Precompose f h Source #

rightAdjunct :: forall (g :: Type -> Type) (h :: Type -> Type). (Functor g, Functor h) => (g ~> Precompose f h) -> Lan f g ~> h Source #

Comonad f => FComonad (Precompose f) Source # 
Instance details

Defined in Data.Functor.Precompose

Methods

fextract :: forall (g :: Type -> Type). Functor g => Precompose f g ~> g Source #

fextend :: forall (g :: Type -> Type) (h :: Type -> Type). (Functor g, Functor h) => (Precompose f g ~> h) -> Precompose f g ~> Precompose f h Source #

Functor f => FFunctor (Precompose f) Source # 
Instance details

Defined in Data.Functor.Precompose

Methods

ffmap :: forall (g :: Type -> Type) (h :: Type -> Type) x. (Functor g, Functor h) => (g ~> h) -> Precompose f g x -> Precompose f h x Source #

Monad f => FMonad (Precompose f) Source # 
Instance details

Defined in Data.Functor.Precompose

Methods

fpure :: forall (g :: Type -> Type). Functor g => g ~> Precompose f g Source #

fbind :: forall (g :: Type -> Type) (h :: Type -> Type) a. (Functor g, Functor h) => (g ~> Precompose f h) -> Precompose f g a -> Precompose f h a Source #

Functor f => FStrong (Precompose f) Source # 
Instance details

Defined in FStrong

Methods

fstrength :: forall (g :: Type -> Type) (h :: Type -> Type). Functor g => Day (Precompose f g) h ~> Precompose f (Day g h) Source #

mapCurried :: forall (g :: Type -> Type) (h :: Type -> Type). (Functor g, Functor h) => Curried g h ~> Curried (Precompose f g) (Precompose f h) Source #

Functor f => Adjunction (Precompose f) (Ran f) Source # 
Instance details

Defined in FFunctor.Adjunction

Methods

unit :: forall (g :: Type -> Type). Functor g => g ~> Ran f (Precompose f g) Source #

counit :: forall (g :: Type -> Type). Functor g => Precompose f (Ran f g) ~> g Source #

leftAdjunct :: forall (g :: Type -> Type) (h :: Type -> Type). (Functor g, Functor h) => (Precompose f g ~> h) -> g ~> Ran f h Source #

rightAdjunct :: forall (g :: Type -> Type) (h :: Type -> Type). (Functor g, Functor h) => (g ~> Ran f h) -> Precompose f g ~> h Source #

(Foldable g, Foldable f) => Foldable (Precompose f g) Source # 
Instance details

Defined in Data.Functor.Precompose

Methods

fold :: Monoid m => Precompose f g m -> m #

foldMap :: Monoid m => (a -> m) -> Precompose f g a -> m #

foldMap' :: Monoid m => (a -> m) -> Precompose f g a -> m #

foldr :: (a -> b -> b) -> b -> Precompose f g a -> b #

foldr' :: (a -> b -> b) -> b -> Precompose f g a -> b #

foldl :: (b -> a -> b) -> b -> Precompose f g a -> b #

foldl' :: (b -> a -> b) -> b -> Precompose f g a -> b #

foldr1 :: (a -> a -> a) -> Precompose f g a -> a #

foldl1 :: (a -> a -> a) -> Precompose f g a -> a #

toList :: Precompose f g a -> [a] #

null :: Precompose f g a -> Bool #

length :: Precompose f g a -> Int #

elem :: Eq a => a -> Precompose f g a -> Bool #

maximum :: Ord a => Precompose f g a -> a #

minimum :: Ord a => Precompose f g a -> a #

sum :: Num a => Precompose f g a -> a #

product :: Num a => Precompose f g a -> a #

(Eq1 f, Eq1 g) => Eq1 (Precompose f g) Source # 
Instance details

Defined in Data.Functor.Precompose

Methods

liftEq :: (a -> b -> Bool) -> Precompose f g a -> Precompose f g b -> Bool #

(Ord1 f, Ord1 g) => Ord1 (Precompose f g) Source # 
Instance details

Defined in Data.Functor.Precompose

Methods

liftCompare :: (a -> b -> Ordering) -> Precompose f g a -> Precompose f g b -> Ordering #

(Traversable f, Traversable g) => Traversable (Precompose f g) Source # 
Instance details

Defined in Data.Functor.Precompose

Methods

traverse :: Applicative f0 => (a -> f0 b) -> Precompose f g a -> f0 (Precompose f g b) #

sequenceA :: Applicative f0 => Precompose f g (f0 a) -> f0 (Precompose f g a) #

mapM :: Monad m => (a -> m b) -> Precompose f g a -> m (Precompose f g b) #

sequence :: Monad m => Precompose f g (m a) -> m (Precompose f g a) #

(Applicative f, Alternative g) => Alternative (Precompose f g) Source # 
Instance details

Defined in Data.Functor.Precompose

Methods

empty :: Precompose f g a #

(<|>) :: Precompose f g a -> Precompose f g a -> Precompose f g a #

some :: Precompose f g a -> Precompose f g [a] #

many :: Precompose f g a -> Precompose f g [a] #

(Applicative f, Applicative g) => Applicative (Precompose f g) Source # 
Instance details

Defined in Data.Functor.Precompose

Methods

pure :: a -> Precompose f g a #

(<*>) :: Precompose f g (a -> b) -> Precompose f g a -> Precompose f g b #

liftA2 :: (a -> b -> c) -> Precompose f g a -> Precompose f g b -> Precompose f g c #

(*>) :: Precompose f g a -> Precompose f g b -> Precompose f g b #

(<*) :: Precompose f g a -> Precompose f g b -> Precompose f g a #

(Functor g, Functor f) => Functor (Precompose f g) Source # 
Instance details

Defined in Data.Functor.Precompose

Methods

fmap :: (a -> b) -> Precompose f g a -> Precompose f g b #

(<$) :: a -> Precompose f g b -> Precompose f g a #

Read (g (f a)) => Read (Precompose f g a) Source # 
Instance details

Defined in Data.Functor.Precompose

Show (g (f a)) => Show (Precompose f g a) Source # 
Instance details

Defined in Data.Functor.Precompose

Methods

showsPrec :: Int -> Precompose f g a -> ShowS #

show :: Precompose f g a -> String #

showList :: [Precompose f g a] -> ShowS #

(Eq1 f, Eq1 g, Eq a) => Eq (Precompose f g a) Source # 
Instance details

Defined in Data.Functor.Precompose

Methods

(==) :: Precompose f g a -> Precompose f g a -> Bool #

(/=) :: Precompose f g a -> Precompose f g a -> Bool #

(Ord1 f, Ord1 g, Ord a) => Ord (Precompose f g a) Source # 
Instance details

Defined in Data.Functor.Precompose

Methods

compare :: Precompose f g a -> Precompose f g a -> Ordering #

(<) :: Precompose f g a -> Precompose f g a -> Bool #

(<=) :: Precompose f g a -> Precompose f g a -> Bool #

(>) :: Precompose f g a -> Precompose f g a -> Bool #

(>=) :: Precompose f g a -> Precompose f g a -> Bool #

max :: Precompose f g a -> Precompose f g a -> Precompose f g a #

min :: Precompose f g a -> Precompose f g a -> Precompose f g a #