/** * One visit of a `flow` node: its callee walked under the call's visit path, * `spec/interview#3/ask_next`, from its first node to its last. * * The boundary is the memory scopes, the ledgers and the values: the callee * opens a `flow` scope of its own, closed when the visit ends, reads nothing * but the `input` it is handed, and hands back its last root node's output. * The world has none: the callee acts in the visit's tree, through the run's * ports. A callee that fails ends the call `child`, as any node failed by a * node inside it. */ import type { GitResult } from "../../git/index.ts"; import type { CheckedCallNode, CheckedFlow } from "../checked.ts"; import { type Ended, type Visited, type Walked } from "./ended.ts"; import type { Here, Walker } from "./walk.ts"; /** What a call visit needs from the run around it. */ export type CallingRun = { /** What `tree` changed since `HEAD`, when the call hands in `diff`. */ diff(tree: string | undefined): Promise>; /** The run one call further down: the callee's `model:` and `timeout:` first, its nodes told by their address through the call. */ called(node: CheckedCallNode): Walker; /** The call answered whole, when a dry run's script says so. */ whole(node: CheckedCallNode, path: string): Ended | undefined; }; /** Visits `node` at `path`. */ export declare function visitCall(run: CallingRun, node: CheckedCallNode, path: string, at: Here): Promise; /** * `flow` walked on `input` inside the visit `prefix`, in memory scopes of its * own, closed when it ends: the run's root, and every call. */ export declare function walkWhole(walker: Walker, flow: CheckedFlow, prefix: string, input: unknown, { cut, tree }: Pick): Promise; //# sourceMappingURL=call.d.ts.map