def scan.go
import bend-kit-regex@0.8.0.0/regex.bend as Regeximport Base
1105def scan.go(stop: Bool, th: Th, +prog: Trie<Inst>, c: Maybe<&2, Char>, +any: Bool, items: List<&2, Th>, best: Maybe<&2, List<&2, Maybe<&2, U32>>>) -> Sc:
1106 match stop:
1107 case True{}:
1108 Sc{items, best, True{}}
1109 case False{}:
1110 Th{+pc, caps} = th
1111 scan.inst(trie.at(Inst, prog, pc), c, any, pc, caps, items, best)