def look.step
import ezx@1.11.0.0/src/pkg/pkg.bend as Pkgimport Base
733# one step of a lookup, with the head's answer in hand. The rest arrives as a
734# thunk, so a hit ends the search.
735def look.step(hit: Bool, text: String, rest: Unit -> Maybe<&2, String>) -> Maybe<&2, String>:
736 match hit:
737 case True{}:
738 Some{text}
739 case False{}:
740 rest(Unit{})