GSet
A grow-only set of E. add returns a Patch carrying a one-element set; piece is union. Once added, an element cannot be removed — for remove-supporting sets see TwoPhaseSet (tombstones) or ORSet (causal).
Samples
var set = GSet.empty<String>()
set = set.piece(set.add("alice"))
set = set.piece(set.add("bob"))
check(set.elements == setOf("alice", "bob"))Content copied to clipboard