For any type A
, Promise[A]
is a bounded lattice on the set A ⊔ {0, 1}
(where "⊔" means "disjoint union") with 0
being the least element, 1
being the greatest element, and all elements of A
forming an antichain
(i.e. mutually incomparable). 0
represents an empty (incomplete) promise,
the elements of A
represent a completed promise, and 1
represents a
conflict (a promise completed multiple times with different values).
- See also:
- Companion:
- object