aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/library/lux/abstract/algebra.lux
blob: 0ed8b85a5fe687d2fce9380d06215d5f775086ae (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
(.using
  [library
   [lux "*"
    [control
     [functor {"+" Fix}]]]])

(type: .public (Algebra f a)
  (-> (f a) a))

(type: .public (CoAlgebra f a)
  (-> a (f a)))

(type: .public (RAlgebra f a)
  (-> (f (Tuple (Fix f) a)) a))

(type: .public (RCoAlgebra f a)
  (-> a (f (Or (Fix f) a))))