def counted
import bendvy-ecs-core@0.1.0.4/ordinary_binding_provision.bend as OrdinaryBindingProvisionimport Base
13# Consume the SAME operational Binding; no second identity/lens debug input.
14# Existing schema-authoring lenses remain trusted, not universal identity proofs.
15def counted(~C:Type,total:U32,next:C -> U32 -> C & U32,result:C & Bool) -> C & U32:
16 match result:
17 case (store,True{}):next(store,U32.add(total,1))
18 case (store,False{}):next(store,total)