Documentation
¶
Index ¶
- func ApplyPatches(node *Node)
- func LetChain(node *Node) (bindings []*Node, body *Node)
- func RenameVar(node *Node, oldName, newName string)
- func ReplaceNext(node *Node, replacement *Node)
- func ReportError(reason string, line, column int)
- func ResolveModules(root *Node)
- func Stringify(node *Node) string
- type ErrorOutput
- type Node
- type TypeInfo
- type ValueKind
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ApplyPatches ¶
func ApplyPatches(node *Node)
func LetChain ¶
LetChain returns the bindings in a consecutive, well-formed let chain and the first body that is not another let. Keeping this shape traversal in one place lets passes process long lexical scopes without consuming one Go stack frame per binding.
func ReplaceNext ¶
func ReportError ¶
func ResolveModules ¶
func ResolveModules(root *Node)
Types ¶
type ErrorOutput ¶
type Node ¶
type Node struct {
Type string
Value string
Children []*Node
Line int
Column int
Filename string
Inferred TypeInfo
}
func ApplyWithContext ¶
type TypeInfo ¶
type TypeInfo struct {
Kind ValueKind
Name string
Size uint64
Align uint64
Pointer bool
Key *TypeInfo
Element *TypeInfo
Fields map[string]TypeInfo
FieldOffsets map[string]uint64
}
TypeInfo describes both the source-level type and its native layout. Size and Align are zero for Unknown/Any because no backend-safe layout is known.
Click to show internal directories.
Click to hide internal directories.