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

Method Configure

ext/bindings.go:157–161  ·  view source on GitHub ↗

Configure implements the ASTValidatorConfigurer interface and augments the list of functions to skip during homogeneous aggregate literal type-checks.

(config cel.MutableValidatorConfig)

Source from the content-addressed store, hash-verified

155// Configure implements the ASTValidatorConfigurer interface and augments the list of functions to skip
156// during homogeneous aggregate literal type-checks.
157func (blockValidationExemption) Configure(config cel.MutableValidatorConfig) error {
158 functions := config.GetOrDefault(cel.HomogeneousAggregateLiteralExemptFunctions, []string{}).([]string)
159 functions = append(functions, "cel.@block")
160 return config.Set(cel.HomogeneousAggregateLiteralExemptFunctions, functions)
161}
162
163// Validate is a no-op as the intent is to simply disable strong type-checks for list literals during
164// when they occur within cel.@block calls as the arg types have already been validated.

Callers

nothing calls this directly

Calls 2

GetOrDefaultMethod · 0.65
SetMethod · 0.65

Tested by

no test coverage detected