def pair
import bendvy-ecs-core@0.1.0.4/ordinary_query_builder.bend as OrdinaryQueryBuilderimport Base
import bendvy-ecs-core@0.1.0.4/ordinary_query_observable.bend as O
import bendvy-ecs-core@0.1.0.4/inspector_query_projection.bend as P
import bendvy-ecs-core@0.1.0.4/inspector.bend as I
import bendvy-ecs-core@0.1.0.4/internal/query_read_session.bend as Session
45# Combine setup builders with conjunctive row selection and nested grants
46# (L & R); detached results use Product<LV,RV>. Both builders must share schema,
47# storage and owner. Nest pairs for larger shapes; no fixed arity limit is
48# introduced. No row traversal occurs during construction.
49def pair(~S:Data,~Store:Type,~Resource:Type,~E:Data,~H:Type,~L:Type,~R:Type,~LV:Data,~RV:Data,~left:Builder<S,Store,Resource,E,H,L,LV>,~right:Builder<S,Store,Resource,E,H,R,RV>) -> Builder<S,Store,Resource,E,H,L & R,P.Product<LV,RV>>:
50 Builder{_=>O.pair(~S,~H,~L,~R,~I.Frame<S,Store,Resource,E>,~LV,~RV,~ordinary(~S,~Store,~Resource,~E,~H,~L,~LV,left),~ordinary(~S,~Store,~Resource,~E,~H,~R,~RV,right)),_=>P.pair(~Session.Owner<S,Store>,~S,~LV,~RV,~session(~S,~Store,~Resource,~E,~H,~L,~LV,left),~session(~S,~Store,~Resource,~E,~H,~R,~RV,right))}
Uses (9)
Used by (0)
No other definition uses this definition.