Documentation ¶
Overview ¶
Package ast implements abstruct-syntax-tree for anko.
Index ¶
- type AddOperator
- type AddrExpr
- type AnonCallExpr
- type ArrayExpr
- type BinaryOperator
- type BreakStmt
- type CForStmt
- type CallExpr
- type ChanExpr
- type CloseStmt
- type ComparisonOperator
- type ContinueStmt
- type DeleteStmt
- type DerefExpr
- type Expr
- type ExprImpl
- type ExprStmt
- type ForStmt
- type FuncExpr
- type GoroutineStmt
- type IdentExpr
- type IfStmt
- type IncludeExpr
- type ItemExpr
- type LenExpr
- type LetMapItemStmt
- type LetsExpr
- type LetsStmt
- type LiteralExpr
- type LoopStmt
- type MakeExpr
- type MakeTypeExpr
- type MapExpr
- type MemberExpr
- type ModuleStmt
- type MultiplyOperator
- type NilCoalescingOpExpr
- type OpExpr
- type Operator
- type OperatorImpl
- type ParenExpr
- type Pos
- type PosImpl
- type Position
- type ReturnStmt
- type SliceExpr
- type Stmt
- type StmtImpl
- type StmtsStmt
- type SwitchCaseStmt
- type SwitchStmt
- type TernaryOpExpr
- type ThrowStmt
- type Token
- type TryStmt
- type TypeKind
- type TypeStruct
- type UnaryExpr
- type VarStmt
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AddOperator ¶ added in v0.0.9
type AddOperator struct { OperatorImpl LHS Expr Operator string RHS Expr }
AddOperator provides add operation.
type AnonCallExpr ¶
AnonCallExpr provide anonymous calling expression. ex: func(){}().
type BinaryOperator ¶ added in v0.0.9
type BinaryOperator struct { OperatorImpl LHS Expr Operator string RHS Expr }
BinaryOperator provides binary operation.
type CallExpr ¶
type CallExpr struct { ExprImpl Func reflect.Value Name string SubExprs []Expr VarArg bool Go bool }
CallExpr provide calling expression.
type ComparisonOperator ¶ added in v0.0.9
type ComparisonOperator struct { OperatorImpl LHS Expr Operator string RHS Expr }
ComparisonOperator provides comparison operation.
type ContinueStmt ¶
type ContinueStmt struct {
StmtImpl
}
ContinueStmt provide "continue" expression statement.
type DeleteStmt ¶ added in v0.0.9
DeleteStmt provides statement of delete.
type ExprImpl ¶
type ExprImpl struct {
PosImpl // PosImpl provide Pos() function.
}
ExprImpl provide commonly implementations for Expr.
type GoroutineStmt ¶ added in v0.0.4
GoroutineStmt provide statement of groutine.
type IfStmt ¶
type IfStmt struct { StmtImpl If Expr Then Stmt ElseIf []Stmt // This is array of IfStmt Else Stmt }
IfStmt provide "if/else" statement.
type IncludeExpr ¶ added in v0.0.3
IncludeExpr provide in expression
type LetMapItemStmt ¶ added in v0.0.3
LetMapItemStmt provide statement of let for map item.
type LiteralExpr ¶ added in v0.0.9
LiteralExpr provide literal expression.
type MakeExpr ¶
type MakeExpr struct { ExprImpl TypeData *TypeStruct LenExpr Expr CapExpr Expr }
MakeExpr provide expression to make instance.
type MakeTypeExpr ¶
MakeTypeExpr provide expression to make type.
type MemberExpr ¶
MemberExpr provide expression to refer member.
type ModuleStmt ¶
ModuleStmt provide "module" expression statement.
type MultiplyOperator ¶ added in v0.0.9
type MultiplyOperator struct { OperatorImpl LHS Expr Operator string RHS Expr }
MultiplyOperator provides multiply operation.
type NilCoalescingOpExpr ¶ added in v0.0.5
NilCoalescingOpExpr provide if invalid operator expression.
type Operator ¶ added in v0.0.9
type Operator interface { Pos }
Operator provides interfaces for operators.
type OperatorImpl ¶ added in v0.0.9
type OperatorImpl struct {
PosImpl // PosImpl provide Pos() function.
}
OperatorImpl provides common implementations for Operator.
type Pos ¶
Pos interface provides two functions to get/set the position for expression or statement.
type PosImpl ¶
type PosImpl struct {
// contains filtered or unexported fields
}
PosImpl provides commonly implementations for Pos.
func (*PosImpl) SetPosition ¶
SetPosition is a function to specify position of the expression or statement.
type ReturnStmt ¶
ReturnStmt provide "return" expression statement.
type StmtImpl ¶
type StmtImpl struct {
PosImpl // PosImpl provide Pos() function.
}
StmtImpl provide commonly implementations for Stmt..
type SwitchCaseStmt ¶ added in v0.0.7
SwitchCaseStmt provide switch case statement.
type SwitchStmt ¶
SwitchStmt provide switch statement.
type TernaryOpExpr ¶
TernaryOpExpr provide ternary operator expression.
type TypeStruct ¶ added in v0.0.9
type TypeStruct struct { Kind TypeKind Env []string Name string Dimensions int SubType *TypeStruct Key *TypeStruct }
TypeStruct blah