Documentation ¶
Index ¶
- type Assign
- type AssignmentNode
- type Block
- type Boolean
- type Break
- type Call
- type Case
- type Class
- type Compound
- type Continue
- type Expression
- type ExpressionNode
- type For
- type ForIn
- type Function
- type Identifier
- type If
- type Import
- type ImportFrom
- type Index
- type Infix
- type List
- type Map
- type Method
- type Node
- type Null
- type Number
- type Postfix
- type Prefix
- type Program
- type Property
- type Return
- type StatementNode
- type String
- type Switch
- type Ternary
- type This
- type Trait
- type Use
- type While
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Assign ¶
type Assign struct { StatementNode Token token.Token Name AssignmentNode Value ExpressionNode }
type AssignmentNode ¶
type AssignmentNode interface { Node }
type Block ¶
type Block struct { StatementNode Token token.Token Statements []StatementNode }
type Break ¶
type Break struct { ExpressionNode Token token.Token }
type Call ¶
type Call struct { ExpressionNode Token token.Token Callee ExpressionNode Arguments []ExpressionNode }
type Case ¶
type Case struct { ExpressionNode Token token.Token // The "case" token Default bool // Is this the default branch? Value []ExpressionNode // The value of the case we'll be matching against Body *Block // The block that will be evaluated if matched }
type Class ¶
type Class struct { ExpressionNode Token token.Token Name *Identifier Super *Identifier Body *Block }
type Compound ¶
type Compound struct { ExpressionNode Token token.Token Left ExpressionNode Operator string Right ExpressionNode }
type Continue ¶
type Continue struct { ExpressionNode Token token.Token }
type Expression ¶
type Expression struct { StatementNode Expression ExpressionNode }
type ExpressionNode ¶
type ExpressionNode interface { Node }
type For ¶
type For struct { ExpressionNode Token token.Token Identifier *Identifier Initializer StatementNode Condition ExpressionNode Increment StatementNode Block *Block }
type ForIn ¶
type ForIn struct { ExpressionNode Token token.Token // for Key *Identifier // key Value *Identifier // value Iterable ExpressionNode // list, map Block *Block // { ... } }
type Function ¶
type Function struct { ExpressionNode Token token.Token Name *Identifier Parameters []*Identifier Defaults map[string]ExpressionNode Body *Block }
type Identifier ¶
type Identifier struct { ExpressionNode AssignmentNode Token token.Token Value string }
type If ¶
type If struct { ExpressionNode Token token.Token Condition ExpressionNode Consequence *Block Alternative *Block }
type ImportFrom ¶
type ImportFrom struct { ExpressionNode Token token.Token Path *String Identifiers map[string]*Identifier Everything bool }
type Index ¶
type Index struct { ExpressionNode AssignmentNode Token token.Token Left ExpressionNode Index ExpressionNode }
type Infix ¶
type Infix struct { ExpressionNode Token token.Token Left ExpressionNode Operator string Right ExpressionNode }
type List ¶
type List struct { ExpressionNode Token token.Token Elements []ExpressionNode }
type Map ¶
type Map struct { ExpressionNode Token token.Token Pairs map[ExpressionNode]ExpressionNode }
type Method ¶
type Method struct { ExpressionNode Token token.Token Left ExpressionNode Method ExpressionNode Arguments []ExpressionNode }
type Null ¶
type Null struct { ExpressionNode Token token.Token }
type Prefix ¶
type Prefix struct { ExpressionNode Token token.Token Operator string Right ExpressionNode }
type Program ¶
type Program struct {
Statements []StatementNode
}
type Property ¶
type Property struct { ExpressionNode AssignmentNode Token token.Token Left ExpressionNode Property ExpressionNode }
type Return ¶
type Return struct { StatementNode Token token.Token Value ExpressionNode }
type StatementNode ¶
type StatementNode interface { Node }
type Switch ¶
type Switch struct { ExpressionNode Token token.Token // The "switch" token Value ExpressionNode // The value that will be used to determine the case Cases []*Case // The cases this switch statement will handle }
type Ternary ¶
type Ternary struct { ExpressionNode Token token.Token Condition ExpressionNode IfTrue ExpressionNode IfFalse ExpressionNode }
type This ¶
type This struct { ExpressionNode Token token.Token }
type Trait ¶ added in v1.0.7
type Trait struct { ExpressionNode Token token.Token Name *Identifier Body *Block }
type Use ¶ added in v1.0.7
type Use struct { ExpressionNode Token token.Token Traits []*Identifier }
type While ¶
type While struct { ExpressionNode Token token.Token Condition ExpressionNode Consequence *Block }
Source Files ¶
- assign.go
- ast.go
- block.go
- boolean.go
- break.go
- call.go
- case.go
- class.go
- compound.go
- continue.go
- expression.go
- for.go
- for_in.go
- function.go
- identifier.go
- if.go
- import.go
- import_from.go
- index.go
- infix.go
- list.go
- map.go
- method.go
- null.go
- number.go
- postfix.go
- prefix.go
- program.go
- property.go
- return.go
- string.go
- switch.go
- ternary.go
- this.go
- trait.go
- use.go
- while.go
Click to show internal directories.
Click to hide internal directories.