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

Function isEmptyRangeComprehension

cel/validator.go:577–583  ·  view source on GitHub ↗
(e ast.NavigableExpr)

Source from the content-addressed store, hash-verified

575}
576
577func isEmptyRangeComprehension(e ast.NavigableExpr) bool {
578 if e.Kind() != ast.ComprehensionKind {
579 return false
580 }
581 iterRange := e.AsComprehension().IterRange()
582 return iterRange.Kind() == ast.ListKind && iterRange.AsList().Size() == 0
583}
584
585func isCelBind(e ast.NavigableExpr) bool {
586 if !isEmptyRangeComprehension(e) {

Callers 2

ValidateMethod · 0.85
isCelBindFunction · 0.85

Calls 5

KindMethod · 0.65
IterRangeMethod · 0.65
AsComprehensionMethod · 0.65
SizeMethod · 0.65
AsListMethod · 0.65

Tested by

no test coverage detected