def KCounter.inc.at

bend-kit-crdt@0.2.0.0 · crdt.bend:274

import bend-kit-crdt@0.2.0.0/crdt.bend as Crdt
import Base

274# ok is false when n wrapped to 0.
275def KCounter.inc.at(-K: Data, ok: Bool, x: K, n: U32, r: KCounter<K>) -> Maybe<&2, KCounter<K>>:
276  match ok:
277    case True{}:
278      Some{KCon{x, n, r}}
279    case False{}:
280      None{}

Uses (4)

Used by (1)