Documentation ¶
Index ¶
- type ArrayLiteral
- type Block
- type Boolean
- type CallExpression
- type Declaration
- type Expression
- type ExpressionStatement
- type FunctionLiteral
- type GroupedExpression
- type HashLiteral
- type Identifier
- type IfExpression
- type IndexExpression
- type InfixExpression
- type LetDeclaration
- type MacroLiteral
- type Modifier
- type Node
- type NumberLiteral
- type PrefixExpression
- type Program
- type ReturnStatement
- type Statement
- type StringLiteral
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ArrayLiteral ¶
type ArrayLiteral struct { Token token.Token // The token.LBRACKET token Elements []Expression }
func (*ArrayLiteral) String ¶
func (al *ArrayLiteral) String() string
func (*ArrayLiteral) TokenLexeme ¶
func (al *ArrayLiteral) TokenLexeme() string
type Block ¶
func (*Block) TokenLexeme ¶
type Boolean ¶
func (*Boolean) TokenLexeme ¶
type CallExpression ¶
type CallExpression struct { Token token.Token // The token.LPAREN token Function Expression // Identifier or FunctionLiteral Argument []Expression }
func (*CallExpression) String ¶
func (ce *CallExpression) String() string
func (*CallExpression) TokenLexeme ¶
func (ce *CallExpression) TokenLexeme() string
type Declaration ¶
type Declaration interface { Statement // contains filtered or unexported methods }
type Expression ¶
type Expression interface { Node // contains filtered or unexported methods }
type ExpressionStatement ¶
type ExpressionStatement struct { Token token.Token // The first token of the expression Expression Expression }
func (*ExpressionStatement) String ¶
func (es *ExpressionStatement) String() string
func (*ExpressionStatement) TokenLexeme ¶
func (es *ExpressionStatement) TokenLexeme() string
type FunctionLiteral ¶
type FunctionLiteral struct { Token token.Token // The token.FN token Parameters []*Identifier Body *Block }
func (*FunctionLiteral) String ¶
func (fl *FunctionLiteral) String() string
func (*FunctionLiteral) TokenLexeme ¶
func (fl *FunctionLiteral) TokenLexeme() string
type GroupedExpression ¶
type GroupedExpression struct { Token token.Token // The token.LPAREN token Expression Expression }
func (*GroupedExpression) String ¶
func (ge *GroupedExpression) String() string
func (*GroupedExpression) TokenLexeme ¶
func (ge *GroupedExpression) TokenLexeme() string
type HashLiteral ¶
type HashLiteral struct { Token token.Token // The token.LBRACE token Pairs map[Expression]Expression }
func (*HashLiteral) String ¶
func (hl *HashLiteral) String() string
func (*HashLiteral) TokenLexeme ¶
func (hl *HashLiteral) TokenLexeme() string
type Identifier ¶
func (*Identifier) String ¶
func (i *Identifier) String() string
func (*Identifier) TokenLexeme ¶
func (i *Identifier) TokenLexeme() string
type IfExpression ¶
type IfExpression struct { Token token.Token // The token.IF token Condition Expression Consequence *Block Alternative *Block }
func (*IfExpression) String ¶
func (ie *IfExpression) String() string
func (*IfExpression) TokenLexeme ¶
func (ie *IfExpression) TokenLexeme() string
type IndexExpression ¶
type IndexExpression struct { Token token.Token // The token.LBRACKET token Left Expression Index Expression }
func (*IndexExpression) String ¶
func (ie *IndexExpression) String() string
func (*IndexExpression) TokenLexeme ¶
func (ie *IndexExpression) TokenLexeme() string
type InfixExpression ¶
type InfixExpression struct { Token token.Token // The operator token, e.g. + Left Expression Operator string Right Expression }
func (*InfixExpression) String ¶
func (ie *InfixExpression) String() string
func (*InfixExpression) TokenLexeme ¶
func (ie *InfixExpression) TokenLexeme() string
type LetDeclaration ¶
type LetDeclaration struct { Token token.Token // The token.LET token Name *Identifier Value Expression }
func (*LetDeclaration) String ¶
func (ld *LetDeclaration) String() string
func (*LetDeclaration) TokenLexeme ¶
func (ld *LetDeclaration) TokenLexeme() string
type MacroLiteral ¶
type MacroLiteral struct { Token token.Token // The token.MACRO token Parameters []*Identifier Body *Block }
func (*MacroLiteral) String ¶
func (ml *MacroLiteral) String() string
func (*MacroLiteral) TokenLexeme ¶
func (ml *MacroLiteral) TokenLexeme() string
type NumberLiteral ¶
func (*NumberLiteral) String ¶
func (il *NumberLiteral) String() string
func (*NumberLiteral) TokenLexeme ¶
func (il *NumberLiteral) TokenLexeme() string
type PrefixExpression ¶
type PrefixExpression struct { Token token.Token // The operator token, e.g. ! Operator string Right Expression }
func (*PrefixExpression) String ¶
func (pe *PrefixExpression) String() string
func (*PrefixExpression) TokenLexeme ¶
func (pe *PrefixExpression) TokenLexeme() string
type ReturnStatement ¶
type ReturnStatement struct { Token token.Token // The token.RETURN token ReturnValue Expression }
func (*ReturnStatement) String ¶
func (rs *ReturnStatement) String() string
func (*ReturnStatement) TokenLexeme ¶
func (rs *ReturnStatement) TokenLexeme() string
type StringLiteral ¶
func (*StringLiteral) String ¶
func (sl *StringLiteral) String() string
func (*StringLiteral) TokenLexeme ¶
func (sl *StringLiteral) TokenLexeme() string
Click to show internal directories.
Click to hide internal directories.