Safe Haskell | Safe |
---|---|
Language | Haskell2010 |
Documentation
class Covariant t => Extendable t where Source #
When providing a new instance, you should ensure it satisfies the three laws: * Duplication interchange: comap (comap f) . duplicate ≡ duplicate . comap f * Extension interchange: extend f ≡ comap f . duplicate
(=>>) :: t a -> (t a -> b) -> t b infixl 1 Source #
Infix and flipped version of extend
, the dual of >>=
(<<=) :: (t a -> b) -> t a -> t b infixr 1 Source #
Flipped version of >>=
, the dual of =<<
extend :: (t a -> b) -> t a -> t b Source #
Prefix and flipped version of =>>
, the dual of bind
duplicate :: t a -> (t :. t) := a Source #
Clone existing structure, the dual of join
(=<=) :: (t b -> c) -> (t a -> b) -> t a -> c infixr 1 Source #
Right-to-left Cokleisli composition
(=>=) :: (t a -> b) -> (t b -> c) -> t a -> c infixr 1 Source #
Left-to-right Cokleisli composition