idris2-profunctors/Data/Profunctor/Functor.idr

21 lines
651 B
Idris
Raw Normal View History

2023-03-04 23:57:12 -05:00
module Data.Profunctor.Functor
import Data.Profunctor.Types
%default total
public export
interface ProfunctorFunctor (0 t : (Type -> Type -> Type) -> k -> k' -> Type) where
promap : Profunctor p => p :-> q -> t p :-> t q
public export
interface ProfunctorFunctor t => ProfunctorMonad (0 t : (Type -> Type -> Type) -> Type -> Type -> Type) where
propure : Profunctor p => p :-> t p
projoin : Profunctor p => t (t p) :-> t p
public export
interface ProfunctorFunctor t => ProfunctorComonad (0 t : (Type -> Type -> Type) -> Type -> Type -> Type) where
proextract : Profunctor p => t p :-> p
produplicate : Profunctor p => t p :-> t (t p)