def ord.fill

yaml-for-bend@0.1.1.0 · compose.bend:117

import yaml-for-bend@0.1.1.0/compose.bend as Compose
import Base
import yaml-for-bend@0.1.1.0/value.bend as V

117# The entries whose keys aren't there yet.
118def ord.fill(es: List<&2, V.Entry>, +o: Ord) -> Ord:
119  match es:
120    case Nil{}:
121      o
122    case Con{e, rest}:
123      match e:
124        case V.Entry{+k, v}:
125          ord.fill(rest, Bool.pick(Ord, ord.has(o, k), o, ord.put(o, k, v)))

Uses (6)

Used by (2)