proarrow
Safe HaskellNone
LanguageGHC2024

Proarrow.Optic.Day

Description

A third way to combine two flavors, alongside ProdFl and SumFl: via the Day convolution. Unlike those two, it keeps both witnesses in the same ambient categories j/k. It needs Monoidal structure there to split objects across the two witnesses, where the others pair/sum two independent categories.

Documentation

class DayFl (w1 :: FLAVOR j k) (w2 :: FLAVOR j k) (p :: k +-> k) (q :: j +-> j) Source Github #

Instances

Instances details
(CategoryOf k, CategoryOf j) => DayFl (w1 :: FLAVOR j k) (w2 :: FLAVOR j k) (Id :: k -> k -> Type) (Id :: j -> j -> Type) Source Github # 
Instance details

Defined in Proarrow.Optic.Day

(w1 p1 q1, w2 p2 q2) => DayFl (w1 :: (j1 +-> j1) -> (j2 +-> j2) -> Constraint) (w2 :: (j1 +-> j1) -> (j2 +-> j2) -> Constraint) (Day p1 p2 :: j1 -> j1 -> Type) (Day q1 q2 :: j2 -> j2 -> Type) Source Github # 
Instance details

Defined in Proarrow.Optic.Day

(DayFl w1 w2 f f', DayFl w1 w2 g g') => DayFl (w1 :: FLAVOR i1 i2) (w2 :: FLAVOR i1 i2) (f :.: g :: i2 -> i2 -> Type) (g' :.: f' :: i1 -> i1 -> Type) Source Github # 
Instance details

Defined in Proarrow.Optic.Day

dayOptic :: forall {j} {k} (w1 :: FLAVOR j k) (w2 :: FLAVOR j k) (s1 :: k) (t1 :: j) (a1 :: k) (b1 :: j) (s2 :: k) (t2 :: j) (a2 :: k) (b2 :: j). (Monoidal j, Monoidal k, Flavor w1, Flavor w2) => Optic (Prostrong w1) s1 t1 a1 b1 -> Optic (Prostrong w2) s2 t2 a2 b2 -> Optic (Prostrong (DayFl w1 w2)) (s1 ** s2) (t1 ** t2) (a1 ** a2) (b1 ** b2) Source Github #