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

Function StrictDecoding

common/env/io.go:403–407  ·  view source on GitHub ↗

StrictDecoding configures whether unknown fields in the YAML or JSON input cause a decoding error. By default, unknown fields are ignored.

(strict bool)

Source from the content-addressed store, hash-verified

401// StrictDecoding configures whether unknown fields in the YAML or JSON input cause a decoding error.
402// By default, unknown fields are ignored.
403func StrictDecoding(strict bool) DecodeOption {
404 return func(opts *decodeOptions) {
405 opts.strict = strict
406 }
407}
408
409func validateStrictJSON(v any, t reflect.Type) error {
410 for t.Kind() == reflect.Pointer {

Callers 2

TestStrictDecodingYAMLFunction · 0.85
TestStrictDecodingJSONFunction · 0.85

Calls

no outgoing calls

Tested by 2

TestStrictDecodingYAMLFunction · 0.68
TestStrictDecodingJSONFunction · 0.68