MCPcopy Create free account
hub / github.com/cel-expr/cel-go / listSetOpCostModel

Function listSetOpCostModel

ext/lists.go:1350–1355  ·  view source on GitHub ↗
(id string, costFactor float64)

Source from the content-addressed store, hash-verified

1348}
1349
1350func listSetOpCostModel(id string, costFactor float64) cost.OverloadModel {
1351 return cost.MemberOverload(id,
1352 cost.EvalCost(cost.Sum(cost.Const(cost.CallCost),
1353 cost.Scale(cost.Mul(cost.Length(cost.Target()), cost.Length(cost.Arg(0))), costFactor))),
1354 )
1355}

Callers 1

CompileOptionsMethod · 0.85

Calls 9

MemberOverloadFunction · 0.92
EvalCostFunction · 0.92
SumFunction · 0.92
ConstFunction · 0.92
ScaleFunction · 0.92
MulFunction · 0.92
LengthFunction · 0.92
TargetFunction · 0.92
ArgFunction · 0.92

Tested by

no test coverage detected