Documentation ¶
Overview ¶
Package ast implements abstruct-syntax-tree for anko.
Index ¶
- type AddrExpr
- type AnonCallExpr
- type ArrayCount
- type ArrayExpr
- type AssocExpr
- type BinOpExpr
- type BreakStmt
- type CForStmt
- type CallExpr
- type CaseStmt
- type ChanExpr
- type ConstExpr
- type ContinueStmt
- type DefaultStmt
- type DeleteExpr
- type DerefExpr
- type Expr
- type ExprImpl
- type ExprStmt
- type ForStmt
- type FuncExpr
- type IdentExpr
- type IfStmt
- type ItemExpr
- type LenExpr
- type LetExpr
- type LetsExpr
- type LetsStmt
- type LoopStmt
- type MakeChanExpr
- type MakeExpr
- type MakeTypeExpr
- type MapExpr
- type MemberExpr
- type ModuleStmt
- type NewExpr
- type NumberExpr
- type PairExpr
- type ParenExpr
- type Pos
- type PosImpl
- type Position
- type ReturnStmt
- type SliceExpr
- type Stmt
- type StmtImpl
- type StringExpr
- type SwitchStmt
- type TernaryOpExpr
- type ThrowStmt
- type Token
- type TryStmt
- type UnaryExpr
- type VarStmt
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AnonCallExpr ¶
AnonCallExpr provide anonymous calling expression. ex: func(){}().
type ArrayCount ¶
type ArrayCount struct {
Count int
}
ArrayCount is used in MakeExpr to provide Dimensions
type CallExpr ¶
type CallExpr struct { ExprImpl Func reflect.Value Name string SubExprs []Expr VarArg bool Go bool }
CallExpr provide calling expression.
type ContinueStmt ¶
type ContinueStmt struct {
StmtImpl
}
ContinueStmt provide "continue" expression statement.
type DefaultStmt ¶
DefaultStmt provide switch/default statement.
type DeleteExpr ¶ added in v0.0.2
DeleteExpr provide `delete(map, key)` expression
type Expr ¶
type Expr interface { Pos // contains filtered or unexported methods }
Expr provides all of interfaces for expression.
type ExprImpl ¶
type ExprImpl struct {
PosImpl // ExprImpl provide Pos() function.
}
ExprImpl provide commonly implementations for Expr.
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 MakeChanExpr ¶
MakeChanExpr provide expression to make chan 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 NumberExpr ¶
NumberExpr provide Number expression.
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 Stmt ¶
type Stmt interface { Pos // contains filtered or unexported methods }
Stmt provides all of interfaces for statement.
type StmtImpl ¶
type StmtImpl struct {
PosImpl // StmtImpl provide Pos() function.
}
StmtImpl provide commonly implementations for Stmt..
type StringExpr ¶
StringExpr provide String expression.
type SwitchStmt ¶
SwitchStmt provide switch statement.
type TernaryOpExpr ¶
TernaryOpExpr provide ternary operator expression.