def plan_pair

bendvy-ecs-core@0.1.0.4 · ordinary_app_execution_recipe.bend:56

import bendvy-ecs-core@0.1.0.4/ordinary_app_execution_recipe.bend as OrdinaryAppExecutionRecipe
import Base
import bendvy-ecs-core@0.1.0.4/schedule_provision.bend as SP

56# Advanced ordered plan composition: call left then right with their respective
57# actual owners, returning both owners and SP.Sequence(before,after). No scheduling
58# conflict or registration validation is added by this adapter.
59def plan_pair(~S:Data,~L:Type,~R:Type,~left:L -> L & SP.Plan<S>,~right:R -> R & SP.Plan<S>,owners:L & R) -> (L & R) & SP.Plan<S>:
60  match owners:
61    case (a,b):plan_left(~S,~L,~R,~right,b,left(a))

Uses (4)

Used by (8)