(types []*cel.Type, template func(t *cel.Type) cel.FunctionOpt)
| 730 | } |
| 731 | |
| 732 | func templatedOverloads(types []*cel.Type, template func(t *cel.Type) cel.FunctionOpt) []cel.FunctionOpt { |
| 733 | overloads := make([]cel.FunctionOpt, len(types)) |
| 734 | for i, t := range types { |
| 735 | overloads[i] = template(t) |
| 736 | } |
| 737 | return overloads |
| 738 | } |
| 739 | |
| 740 | // estimateListSlice computes an O(n) slice operation with a cost factor of 1. |
| 741 | func estimateListSlice(estimator cost.Estimator, target *cost.AstNode, args []cost.AstNode) *cost.CallEstimate { |