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

Method AddIdent

checker/scopes.go:69–71  ·  view source on GitHub ↗

AddIdent adds the ident Decl in the current scope. Note: If the name collides with an existing identifier in the scope, the Decl is overwritten.

(decl *decls.VariableDecl)

Source from the content-addressed store, hash-verified

67// AddIdent adds the ident Decl in the current scope.
68// Note: If the name collides with an existing identifier in the scope, the Decl is overwritten.
69func (s *Scopes) AddIdent(decl *decls.VariableDecl) {
70 s.scopes.idents[decl.Name()] = decl
71}
72
73// FindIdentInScope finds the first ident Decl with a matching name in the current Scopes value, or
74// nil if one does not exist.

Callers 1

addIdentMethod · 0.80

Calls 1

NameMethod · 0.65

Tested by

no test coverage detected