Safe Haskell | Safe |
---|---|
Language | Haskell2010 |
Synopsis
- type (+) = Either
- rgt :: (a -> b) -> (a + b) -> b
- rgt' :: (Void + b) -> b
- lft :: (b -> a) -> (a + b) -> a
- lft' :: (a + Void) -> a
- dup :: a -> (a, a)
- dedup :: (a + a) -> a
- swp :: (a1, a2) -> (a2, a1)
- swp' :: (a1 + a2) -> a2 + a1
- assocl :: (a, (b, c)) -> ((a, b), c)
- assocr :: ((a, b), c) -> (a, (b, c))
- assocl' :: (a + (b + c)) -> (a + b) + c
- assocr' :: ((a + b) + c) -> a + (b + c)
- eval :: (a, a -> b) -> b
- apply :: (b -> a, b) -> a
- coeval :: b -> ((b -> a) + a) -> a
- branch :: (a -> Bool) -> b -> c -> a -> b + c
- branch' :: (a -> Bool) -> a -> a + a
- fstrong :: Functor f => f a -> b -> f (a, b)
- fchoice :: Traversable f => f (a + b) -> f a + b
- pfirst :: Strong p => p a b -> p (a, c) (b, c)
- psecond :: Strong p => p a b -> p (c, a) (c, b)
- pleft :: Choice p => p a b -> p (a + c) (b + c)
- pright :: Choice p => p a b -> p (c + a) (c + b)
- pcurry :: Closed p => p (a, b) c -> p a (b -> c)
- puncurry :: Strong p => p a (b -> c) -> p (a, b) c
- peval :: Strong p => p a (a -> b) -> p a b
- constl :: Profunctor p => b -> p b c -> p a c
- constr :: Profunctor p => c -> p a b -> p a c
- shiftl :: Profunctor p => p (a + b) c -> p b (c + d)
- shiftr :: Profunctor p => p b (c, d) -> p (a, b) c
- coercer :: Profunctor p => Contravariant (p a) => p a c -> p a d
- coercer' :: Representable p => Contravariant (Rep p) => p a b -> p a c
- coercel :: Profunctor p => Bifunctor p => p a c -> p b c
- coercel' :: Corepresentable p => Contravariant (Corep p) => p a b -> p c b
- strong :: Strong p => ((a, b) -> c) -> p a b -> p a c
- costrong :: Costrong p => ((a, b) -> c) -> p c a -> p b a
- choice :: Choice p => (c -> a + b) -> p b a -> p c a
- cochoice :: Cochoice p => (c -> a + b) -> p a c -> p a b
- pull :: Strong p => p a b -> p a (a, b)
- parr :: Category p => Profunctor p => (a -> b) -> p a b
- punarr :: Comonad w => Sieve p w => p a b -> a -> b
- returnP :: Category p => Profunctor p => p a a
- ex1 :: Category p => Profunctor p => p (a, b) b
- ex2 :: Category p => Profunctor p => p (a, b) a
- inl :: Category p => Profunctor p => p a (a + b)
- inr :: Category p => Profunctor p => p b (a + b)
- braid :: Category p => Profunctor p => p (a, b) (b, a)
- braid' :: Category p => Profunctor p => p (a + b) (b + a)
- lift :: Representable p => ((a -> Rep p b) -> s -> Rep p t) -> p a b -> p s t
- lower :: Corepresentable p => ((Corep p a -> b) -> Corep p s -> t) -> p a b -> p s t
- (@@@) :: Profunctor p => (forall x. Applicative (p x)) => p a1 b1 -> p a2 b2 -> p (a1, a2) (b1, b2)
- pappend :: Profunctor p => (forall x. Applicative (p x)) => p a1 b1 -> p a2 b2 -> p (a1, a2) (b1, b2)
- pdivide :: Profunctor p => (forall x. Applicative (p x)) => (a -> (a1, a2)) -> p a1 b -> p a2 b -> p a b
- pdivided :: Profunctor p => (forall x. Applicative (p x)) => p a1 b -> p a2 b -> p (a1, a2) b
- papply :: Profunctor p => (forall x. Applicative (p x)) => p a (b -> c) -> p a b -> p a c
- pliftA2 :: Profunctor p => (forall x. Applicative (p x)) => ((b1, b2) -> b) -> p a b1 -> p a b2 -> p a b
- ppure :: Profunctor p => (forall x. Applicative (p x)) => b -> p a b
- pabsurd :: Profunctor p => (forall x. Divisible (p x)) => p Void a
Documentation
constl :: Profunctor p => b -> p b c -> p a c Source #
constr :: Profunctor p => c -> p a b -> p a c Source #
shiftr :: Profunctor p => p b (c, d) -> p (a, b) c Source #
coercer :: Profunctor p => Contravariant (p a) => p a c -> p a d Source #
coercer' :: Representable p => Contravariant (Rep p) => p a b -> p a c Source #
coercel :: Profunctor p => Bifunctor p => p a c -> p b c Source #
coercel' :: Corepresentable p => Contravariant (Corep p) => p a b -> p c b Source #
parr :: Category p => Profunctor p => (a -> b) -> p a b Source #
returnP :: Category p => Profunctor p => p a a Source #
ex1 :: Category p => Profunctor p => p (a, b) b Source #
ex2 :: Category p => Profunctor p => p (a, b) a Source #
braid :: Category p => Profunctor p => p (a, b) (b, a) Source #
(@@@) :: Profunctor p => (forall x. Applicative (p x)) => p a1 b1 -> p a2 b2 -> p (a1, a2) (b1, b2) infixr 3 Source #
TODO: Document
p * x ≡ dimap dup eval (p
@ x)
pappend :: Profunctor p => (forall x. Applicative (p x)) => p a1 b1 -> p a2 b2 -> p (a1, a2) (b1, b2) Source #
pdivide :: Profunctor p => (forall x. Applicative (p x)) => (a -> (a1, a2)) -> p a1 b -> p a2 b -> p a b Source #
Profunctor equivalent of divide
.
pdivided :: Profunctor p => (forall x. Applicative (p x)) => p a1 b -> p a2 b -> p (a1, a2) b Source #
Profunctor equivalent of divided
.
papply :: Profunctor p => (forall x. Applicative (p x)) => p a (b -> c) -> p a b -> p a c Source #
Profunctor equivalent of <*>
.
pliftA2 :: Profunctor p => (forall x. Applicative (p x)) => ((b1, b2) -> b) -> p a b1 -> p a b2 -> p a b Source #
Profunctor equivalent of liftA2
.
ppure :: Profunctor p => (forall x. Applicative (p x)) => b -> p a b Source #