proarrow
Safe HaskellNone
LanguageGHC2024

Proarrow.Squares.Terminal

Description

Pointwise terminal objects as empty weighted limits.

Synopsis

Documentation

type Terminal = TerminalProfunctor :: k -> j -> Type Source Github #

The pointwise terminal functor.

type Diagram = Rep (Absurd :: VOID +-> k) Source Github #

The empty represented diagram.

terminal :: (CategoryOf j, HasTerminalObject k) => Sq (Rep (Absurd :: VOID +-> j) '::: ('Nil :: Path j j)) ('Nil :: Path k k) ((Terminal :: k -> j -> Type) '::: ('Nil :: Path k k)) ((Diagram :: k -> VOID -> Type) '::: ('Nil :: Path k k)) Source Github #

The empty cone, weighted by the empty functor.

J----empty----0
|      |      |
T>-----@----->d
|             |
K-------------K

Here T = Terminal and d = Diagram. The indexing category 0 has no objects.

terminate :: forall {j} {k} (p :: j +-> k). (HasTerminalObject k, Representable p) => Sq (Rep (Absurd :: VOID +-> j) '::: ('Nil :: Path j j)) ('Nil :: Path k k) (p '::: ('Nil :: Path k k)) ((Diagram :: k -> VOID -> Type) '::: ('Nil :: Path k k)) -> Sq ('Nil :: Path j j) ('Nil :: Path k k) (p '::: ('Nil :: Path k k)) ((Terminal :: k -> j -> Type) '::: ('Nil :: Path k k)) Source Github #

Factor an empty cone through the terminal functor, uniquely.