std.category

Implementation of the Category type

Types

#[implicit]
type Category cat = {
    id : forall a . cat a a,
    compose : forall a b c . cat b c -> cat a b -> cat a c
}

Values

let id ?cat : forall cat a . [Category cat] -> cat a a

let compose ?cat : forall cat . forall a b c . [Category cat] -> cat b c -> cat a b -> cat a c

#[infix(right, 9)]
let << : forall cat . forall a b c . [Category cat] -> cat b c -> cat a b -> cat a c

Right-to-left composition. Alias for compose.

#[infix(left, 9)]
let >> f g : forall cat . forall a b c . [Category cat] -> cat a b -> cat b c -> cat a c

Left-to-right composition. Alias for compose, but with the arguments flipped.