def loop.step
ezx@1.11.0.0 · src/lock/run.bend:673
import ezx@1.11.0.0/src/lock/run.bend as Run
import Base
import ezx@1.11.0.0/src/lock/world.bend as W
import ezx@1.11.0.0/src/lock/up.bend as Up
import ezx@1.11.0.0/src/lock/plan.bend as Plan
import ezx@1.11.0.0/src/ws/up.bend as WsUp
673
674
675def loop.step(st: Plan.Step, +lib: String, back: WsUp.Back, world: W.World, go: W.World -> IO(Unit)) -> IO(Unit):
676 match st:
677 case Plan.Asking{asks, ups, names}:
678 do IO<Unit>:
679 rs : List<&2, W.Reply> <- answer.all(lib, asks)
680 us : List<&2, Up.Reply> <- answer.queries(lib, ups)
681 ns : List<&2, W.Reply> <- answer.all(lib, names)
682 go(more(world, List.append(&2, W.Reply, rs, ns), us))
683 case Plan.Run{_pl}:
684 exec.plan(lib, WsUp.plan(back, world))