def loop.step

ezx@1.11.0.0 · src/doctor/run.bend:98

import ezx@1.11.0.0/src/doctor/run.bend as Run
import Base
import ezx@1.11.0.0/src/lock/run.bend as Run
import ezx@1.11.0.0/src/doctor/world.bend as DW
import ezx@1.11.0.0/src/doctor/plan.bend as DP

98# the planner's step: its questions answered and the loop gone round again,
99# or its plan run
100def loop.step(st: DP.Step, +lib: String, world: DW.World, go: DW.World -> IO(Unit)) -> IO(Unit):
101  match st:
102    case DP.Asking{asks}:
103      do IO<Unit>:
104        rs : List<&2, DW.Reply> <- answer.all(lib, asks)
105        go(more(world, rs))
106    case DP.Run{pl}:
107      Run.exec.plan("", pl)

Uses (11)

Used by (1)