Documentation ¶
Index ¶
- func BlockStmt(stmts ...ast.Stmt) *ast.BlockStmt
- func BoundsCheck(name string, pos int) *ast.AssignStmt
- func CallExpr(fun ast.Expr, args ...ast.Expr) *ast.CallExpr
- func DataToByteSlice(data []byte) *ast.CallExpr
- func ExprStmt(expr ast.Expr) *ast.ExprStmt
- func Float32Lit(value float32) *ast.BasicLit
- func Float64Lit(value float64) *ast.BasicLit
- func IndexExpr(name string, index ast.Expr) *ast.IndexExpr
- func IntLit(value int) *ast.BasicLit
- func LambdaCall(resultType ast.Expr, block *ast.BlockStmt) *ast.CallExpr
- func ReturnStmt(results ...ast.Expr) *ast.ReturnStmt
- func StringLit(value string) *ast.BasicLit
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BoundsCheck ¶
func BoundsCheck(name string, pos int) *ast.AssignStmt
BoundsCheck "_ = name[pos]"
func DataToByteSlice ¶
DataToByteSlice turns a byte slice like []byte{1, 2, 3} into an AST expression
func Float32Lit ¶
Float32Lit returns an ast.BasicLit of kind FLOAT, 32 bit
func Float64Lit ¶
Float64Lit returns an ast.BasicLit of kind FLOAT, 64 bit
func LambdaCall ¶
LambdaCall "func() resultType {block}()"
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.