MCPcopy
hub / github.com/google/go-jsonnet / Node

Interface Node

ast/ast.go:33–46  ·  view source on GitHub ↗

Node represents a node in the AST.

Source from the content-addressed store, hash-verified

31
32// Node represents a node in the AST.
33type Node interface {
34 Context() Context
35 Loc() *LocationRange
36 FreeVariables() Identifiers
37 SetFreeVariables(Identifiers)
38 SetContext(Context)
39 // OpenFodder returns the fodder before the first token of an AST node.
40 // Since every AST node has opening fodder, it is defined here.
41 // If the AST node is left recursive (e.g. BinaryOp) then it is ambiguous
42 // where the fodder should be stored. This is resolved by storing it as
43 // far inside the tree as possible. OpenFodder returns a pointer to allow
44 // the caller to modify the fodder.
45 OpenFodder() *Fodder
46}
47
48// Nodes represents a Node slice.
49type Nodes []Node

Callers 24

rawevaluateMethod · 0.65
cloneNodeBaseFunction · 0.65
formatStaticMethod · 0.65
rawevaluateMethod · 0.65
evaluateAuxFunction · 0.65
preHookMethod · 0.65
BreakpointLocationsMethod · 0.65
StackTraceMethod · 0.65
locMethod · 0.65
findDependenciesMethod · 0.65
getCurrentEnvMethod · 0.65
rawevaluateMethod · 0.65

Implementers 1

NodeBaseast/ast.go

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…