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

Method IsLocalVariable

interpreter/activation.go:138–148  ·  view source on GitHub ↗

IsLocalVariable reports whether the variable name is locally bound in the hierarchical activation.

(name string)

Source from the content-addressed store, hash-verified

136
137// IsLocalVariable reports whether the variable name is locally bound in the hierarchical activation.
138func (a *hierarchicalActivation) IsLocalVariable(name string) bool {
139 if holder, ok := a.child.(localVariableHolder); ok {
140 if holder.IsLocalVariable(name) {
141 return true
142 }
143 }
144 if holder, ok := a.parent.(localVariableHolder); ok {
145 return holder.IsLocalVariable(name)
146 }
147 return false
148}
149
150// AsPartialActivation checks the child first via direct type assertion (to
151// avoid recursion through the folder → frame → hierarchicalActivation cycle),

Callers

nothing calls this directly

Calls 1

IsLocalVariableMethod · 0.65

Tested by

no test coverage detected