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

Function ClearMacros

cel/options.go:156–161  ·  view source on GitHub ↗

ClearMacros options clears all parser macros. Clearing macros will ensure CEL expressions can only contain linear evaluation paths, as comprehensions such as `all` and `exists` are enabled only via macros.

()

Source from the content-addressed store, hash-verified

154// Clearing macros will ensure CEL expressions can only contain linear evaluation paths, as
155// comprehensions such as `all` and `exists` are enabled only via macros.
156func ClearMacros() EnvOption {
157 return func(e *Env) (*Env, error) {
158 e.macros = NoMacros
159 return e, nil
160 }
161}
162
163// CustomTypeAdapter swaps the default types.Adapter implementation with a custom one.
164//

Callers 2

initFunction · 0.92
TestMacroSubsetFunction · 0.85

Calls

no outgoing calls

Tested by 2

initFunction · 0.74
TestMacroSubsetFunction · 0.68