kan-extensions-0.5.1: Kan extensions, the Yoneda lemma, and (co)density (co)monads

Portability GADTs, MPTCs, fundeps provisional Edward Kmett

Data.Functor.Yoneda.Contravariant

Description

Synopsis

# Documentation

data Yoneda f a whereSource

The contravariant Yoneda lemma applied to a covariant functor

Constructors

 Yoneda :: (b -> a) -> f b -> Yoneda f a

Instances

 ComonadTrans Yoneda MonadTrans Yoneda Monad m => Monad (Yoneda m) Functor (Yoneda f) MonadFix f => MonadFix (Yoneda f) MonadPlus f => MonadPlus (Yoneda f) Applicative f => Applicative (Yoneda f) Foldable f => Foldable (Yoneda f) Traversable f => Traversable (Yoneda f) Alternative f => Alternative (Yoneda f) Comonad w => Comonad (Yoneda w) Extend w => Extend (Yoneda w) Distributive f => Distributive (Yoneda f) Foldable1 f => Foldable1 (Yoneda f) Traversable1 f => Traversable1 (Yoneda f) Keyed f => Keyed (Yoneda f) (Functor f, Indexable f) => Indexable (Yoneda f) (Functor f, Lookup f) => Lookup (Yoneda f) FoldableWithKey f => FoldableWithKey (Yoneda f) FoldableWithKey1 f => FoldableWithKey1 (Yoneda f) TraversableWithKey f => TraversableWithKey (Yoneda f) TraversableWithKey1 f => TraversableWithKey1 (Yoneda f) Representable f => Representable (Yoneda f) Plus f => Plus (Yoneda f) Alt f => Alt (Yoneda f) Apply f => Apply (Yoneda f) Bind m => Bind (Yoneda m) Adjunction f g => Adjunction (Yoneda f) (Yoneda g) (Functor f, Eq (f a)) => Eq (Yoneda f a) (Functor f, Ord (f a)) => Ord (Yoneda f a) (Functor f, Read (f a)) => Read (Yoneda f a) (Functor f, Show (f a)) => Show (Yoneda f a)

liftYoneda :: f a -> Yoneda f aSource

lowerYoneda :: Functor f => Yoneda f a -> f aSource

lowerM :: Monad f => Yoneda f a -> f aSource