def invoke_owned

bendvy-ecs-core@0.1.0.3 · capabilities.bend:150

import bendvy-ecs-core@0.1.0.3/capabilities.bend as Capabilities
import Base

150# Args and output are fixed before opaque H; no Data restriction on owners.
151# Invoke the universally quantified body with affine arguments/output.
152# The callback consumes/returns H and consumes A exactly according to its
153# signature; any error/recovery branches belong to its own output contract.
154def invoke_owned(~Ops:Type -> Type,~A:Type,~U:Type,~body:@-H:Type -> @-caps:Ops(H) -> A -> H -> H & U,~H:Type,~caps:Ops(H),args:A,ctx:H) -> H & U:
155  body(H,caps,args,ctx)

Uses (1)

Used by (1)