type Map<k, v> = iterative choice { .entry => [k] (Option<v>) choice { .delete => self, .put => [v] self, }, .keys => (List<k>) self, .list => List<(k) v>, .size => (Nat) self, }
A linear ordered map interface.
.size— get the number of entries while keeping the map..keys— get the keys in map order while keeping the map..list— consume the map and return its entries as(key) valuepairs..entry(key)— inspect the currentOption<v>forkey, then choose.put(value)or.delete.
The map is linear: .list consumes it, while .size, .keys, and .entry
return a continuation for further use.