Documentation ¶
Index ¶
- func Apply(root ast.Node, pre, post ApplyFunc) (result ast.Node)
- func CopyExpr(node ast.Expr) (ast.Expr, bool)
- func Equal(a, b ast.Node) bool
- func GroupSpecs(fset *token.FileSet, specs []ast.Spec) [][]ast.Spec
- func IsBlank(id ast.Expr) bool
- func IsIdent(expr ast.Expr, ident string) bool
- func IsIntLiteral(expr ast.Expr, literal string) booldeprecated
- func IsZero(expr ast.Expr) booldeprecated
- func NegateDeMorgan(expr ast.Expr, recursive bool) ast.Expr
- func PathEnclosingInterval(root *ast.File, start, end token.Pos) (path []ast.Node, exact bool)
- func Preamble(f *ast.File) string
- func SimplifyParentheses(node ast.Expr) ast.Expr
- func Unparen(e ast.Expr) ast.Expr
- type ApplyFunc
- type Cursor
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CopyExpr ¶
CopyExpr creates a deep copy of an expression. It doesn't support copying FuncLits and returns ok == false when encountering one.
func IsBlank ¶
isBlank returns whether id is the blank identifier "_". If id == nil, the answer is false.
func IsIntLiteral
deprecated
func PathEnclosingInterval ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.