Copyright | (C) 2014-2015 Edward Kmett |
---|---|
License | BSD-style (see the file LICENSE) |
Maintainer | Edward Kmett <ekmett@gmail.com> |
Stability | experimental |
Portability | portable |
Safe Haskell | Safe |
Language | Haskell2010 |
Data.Profunctor.Closed
Description
Synopsis
- class Profunctor p => Closed p where
- newtype Closure p a b = Closure {
- runClosure :: forall x. p (x -> a) (x -> b)
- close :: Closed p => (p :-> q) -> p :-> Closure q
- unclose :: Profunctor q => (p :-> Closure q) -> p :-> q
- data Environment p a b where
- Environment :: ((z -> y) -> b) -> p x y -> (a -> z -> x) -> Environment p a b
- curry' :: Closed p => p (a, b) c -> p a (b -> c)
Documentation
class Profunctor p => Closed p where Source #
A strong profunctor allows the monoidal structure to pass through.
A closed profunctor allows the closed structure to pass through.
Minimal complete definition
Methods
Instances
(Distributive f, Monad f) => Closed (Kleisli f) Source # | |
Functor f => Closed (Cokleisli f) Source # | |
Closed (Tagged :: * -> * -> *) Source # | |
Functor f => Closed (Costar f) Source # | |
Distributive f => Closed (Star f) Source # | |
Closed (Environment p) Source # | |
Methods closed :: Environment p a b -> Environment p (x -> a) (x -> b) Source # | |
Profunctor p => Closed (Closure p) Source # | |
Closed (FreeMapping p) Source # | |
Methods closed :: FreeMapping p a b -> FreeMapping p (x -> a) (x -> b) Source # | |
Profunctor p => Closed (CofreeMapping p) Source # | |
Methods closed :: CofreeMapping p a b -> CofreeMapping p (x -> a) (x -> b) Source # | |
Closed p => Closed (Coyoneda p) Source # | |
Closed p => Closed (Yoneda p) Source # | |
Closed ((->) :: * -> * -> *) Source # | |
(Closed p, Closed q) => Closed (Procompose p q) Source # | |
Methods closed :: Procompose p q a b -> Procompose p q (x -> a) (x -> b) Source # | |
(Closed p, Closed q) => Closed (Product p q) Source # | |
(Functor f, Closed p) => Closed (Tannen f p) Source # | |
newtype Closure p a b Source #
Closure
adjoins a Closed
structure to any Profunctor
.
Constructors
Closure | |
Fields
|
Instances
data Environment p a b where Source #
Constructors
Environment :: ((z -> y) -> b) -> p x y -> (a -> z -> x) -> Environment p a b |