def run

bendvy-ecs-core@0.1.0.3 · dependency_executor.bend:51

import bendvy-ecs-core@0.1.0.3/dependency_executor.bend as DependencyExecutor
import Base
import bendvy-ecs-core@0.1.0.3/dependency_plan.bend as Plan

51# State contains the actual World, registration, argument, condition and handler
52# owners. Closed providers move that state and never duplicate runtime callbacks.
53# The ordered interpreter chooses one valid order; parallel execution may choose
54# any order permitted by dependencies and access conflicts.
55def run(~State:Type,~Requirement:Data,~Error:Data,~Out:Data,~condition:State -> U32 -> State & Condition<Error>,~dispatch:State -> U32 -> State & Invocation<Error,Out>,~handler:State -> Error -> State & Handling,plan:Plan.Build<Requirement>,state:State) -> ExecutionResult<State,Requirement,Error,Out>:
56  match plan:
57    case Plan.Rejected{reason}:Invalid{state,reason}
58    case Plan.Planned{order,_}:execute(~State,~Requirement,~Error,~Out,~condition,~dispatch,~handler,order,state,[])

Uses (9)

Used by (1)