Documentation
¶
Overview ¶
The prettyprint package visualises a Go AST, but only assignment nodes. In these nodes, it prints their position, the identifier and the identifier's declaration plus position.
It is used to visualise how assigncheck is checking for re-assignments.
To see it for yourself, run `go test -v .` in this directory.
$> go test -v . === RUN TestRun Assignment "x, y := 1, 2": 2958101 Ident "x": 2958101 Decl "x, y := 1, 2": 2958101 Ident "y": 2958104 Decl "x, y := 1, 2": 2958101 Assignment "y = 3": 2958115 Ident "y": 2958115 Decl "x, y := 1, 2": 2958101 --- PASS: TestRun (0.93s) PASS ok github.com/tommyknows/funcheck/prettyprint 1.088s
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Analyzer = &analysis.Analyzer{
Name: "prettyprint",
Doc: "prints positions",
Run: run,
}
Functions ¶
This section is empty.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.