def drive

bendvy-ecs-core@0.1.0.4 · relation_cleanup.bend:61

import bendvy-ecs-core@0.1.0.4/relation_cleanup.bend as RelationCleanup
import Base
import relation_types.bend as G
import relation_commands.bend as A
import world.bend as W

61def drive(~S: Data,~C: Type,~R: Type,~E: Data,~clear: C -> W.Handle<S> -> C & List<&2,A.Notice<S,E>>,~record: W.Handle<S> -> A.Notice<S,E>,fuel: Nat,frames: List<&2,G.CleanupFrame<S>>,world: W.World<S,A.Store<S,C>,R,A.Notice<S,E>>,+namespace: U32,+descriptors: List<&2,G.Descriptor<S>>) -> CleanupResult<S,C,R,E>:
62  match fuel frames:
63    case _ Nil{}: Complete{world}
64    case 0n frames: Incomplete{world,frames}
65    case 1n+rest Con{frame,frames}: resumed(~S,~C,~R,~E,step(~S,~C,~R,~E,~clear,~record,frame,world,namespace,descriptors,frames),world => frames => drive(~S,~C,~R,~E,~clear,~record,rest,frames,world,namespace,descriptors))

Uses (13)

Used by (2)