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

Function EnableOptionalSyntax

parser/options.go:138–143  ·  view source on GitHub ↗

EnableOptionalSyntax enables syntax for optional field and index selection.

(optionalSyntax bool)

Source from the content-addressed store, hash-verified

136
137// EnableOptionalSyntax enables syntax for optional field and index selection.
138func EnableOptionalSyntax(optionalSyntax bool) Option {
139 return func(opts *options) error {
140 opts.enableOptionalSyntax = optionalSyntax
141 return nil
142 }
143}
144
145// EnableIdentEscapeSyntax enables backtick (`) escaped field identifiers. This
146// supports extended types of characters in identifiers, e.g. foo.`baz-bar`.

Callers 12

TestPruneFunction · 0.92
programFunction · 0.92
TestCheckFunction · 0.92
BenchmarkCheckFunction · 0.92
TestCheckErrorDataFunction · 0.92
enableOptionalSyntaxFunction · 0.92
TestConvertExprFunction · 0.92
TestSourceInfoToProtoFunction · 0.92
mustTypeCheckFunction · 0.92
parser_test.goFile · 0.85
TestUnparseFunction · 0.85

Calls

no outgoing calls

Tested by 10

TestPruneFunction · 0.74
programFunction · 0.74
TestCheckFunction · 0.74
BenchmarkCheckFunction · 0.74
TestCheckErrorDataFunction · 0.74
TestConvertExprFunction · 0.74
TestSourceInfoToProtoFunction · 0.74
mustTypeCheckFunction · 0.74
TestUnparseFunction · 0.68