semigroupoids-4.0: Semigroupoids: Category sans id

PortabilityMPTCs, GADTs
Stabilityexperimental
MaintainerEdward Kmett <ekmett@gmail.com>
Safe HaskellSafe-Inferred

Data.Semifunctor.Associative

Description

 

Documentation

class Semifunctor p (Product k k) k => Associative k p whereSource

Methods

associate :: k (p (p (a, b), c)) (p (a, p (b, c)))Source

Instances

kleisliAssociate :: (Monad m, Semifunctor p (Product (Kleisli m) (Kleisli m)) (Kleisli m), Associative (->) p) => Kleisli m (p (p (a, b), c)) (p (a, p (b, c)))Source

cokleisliAssociate :: (Comonad m, Semifunctor p (Product (Cokleisli m) (Cokleisli m)) (Cokleisli m), Associative (->) p) => Cokleisli m (p (p (a, b), c)) (p (a, p (b, c)))Source

class Semifunctor p (Product k k) k => Disassociative k p whereSource

Methods

disassociate :: k (p (a, p (b, c))) (p (p (a, b), c))Source

kleisliDisassociate :: (Monad m, Semifunctor p (Product (Kleisli m) (Kleisli m)) (Kleisli m), Disassociative (->) p) => Kleisli m (p (a, p (b, c))) (p (p (a, b), c))Source

cokleisliDisassociate :: (Comonad m, Semifunctor p (Product (Cokleisli m) (Cokleisli m)) (Cokleisli m), Disassociative (->) p) => Cokleisli m (p (a, p (b, c))) (p (p (a, b), c))Source