def parse.once
import shake@0.7.0.0/src/cli.bend as Cliimport Base
691# a flag or single-valued option given again is refused, whatever the walk
692# would have done with it; the walker keeps the rest of its state
693def parse.once(again: Bool, st: St, +name: String, +path: List<&2, String>) -> St:
694 match again:
695 case True{}:
696 St{_m, +args, +up, +subs, _p, +binds, +pos, +raw, +seen} = st
697 St{Dead{Repeated{path, name}}, args, up, subs, path, binds, pos, raw, seen}
698 case False{}:
699 st