Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- data Cofun r b a = (:>-) {}
- type (>-) a r = Cofun r a
- type (-~) r b = r b
- (>-) :: (r ! b) -> a -> (b >- r) -~ a
- withCofun :: ((b >- r) -~ a) -> s ! ((r ! b) -> s ! a)
- elimCofun :: ((b ~~ r) ~> a) -> r ! ((a >- r) -~ b)
- runCofun :: (b -> a) -> r ! ((a >- r) -~ b)
- cocurry :: Disj d => (c -> a `d` b) -> (((b >- r) -~ c) ~~ r) ~> a
- uncocurry :: Disj d => ((((b >- r) -~ c) ~~ r) ~> a) -> (c ~~ r) ~> (a `d` b)
- coap :: Disj d => (c ~~ r) ~> (((b >- r) -~ c) `d` b)
Co-functions
Instances
Profunctor (Cofun r) Source # | |
Defined in Data.Profunctor.Cofun dimap :: (a -> b) -> (c -> d) -> Cofun r b c -> Cofun r a d lmap :: (a -> b) -> Cofun r b c -> Cofun r a c rmap :: (b -> c) -> Cofun r a b -> Cofun r a c (#.) :: forall a b c q. Coercible c b => q b c -> Cofun r a b -> Cofun r a c (.#) :: forall a b c q. Coercible b a => Cofun r b c -> q a b -> Cofun r a c |