aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/compile/internal/syntax/dumper.go
AgeCommit message (Collapse)Author
2021-01-08[dev.typeparams] cmd/compile/internal/syntax: clean up node printing APIRobert Griesemer
Preparation for using the syntax printer as expression printer in types2. - Introduced Form to control printing format - Cleaned up/added String and ShortString convenience functions - Implemented ShortForm format which prints … for non-empty function and composite literal bodies - Added test to check write error handling Change-Id: Ie86e46d766fb60fcf07ef643c7788b2ef440ffa8 Reviewed-on: https://go-review.googlesource.com/c/go/+/282552 Trust: Robert Griesemer <gri@golang.org> Run-TryBot: Robert Griesemer <gri@golang.org> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Matthew Dempsky <mdempsky@google.com>
2017-03-06cmd/compile/internal/syntax: print position info for names in tree dumpRobert Griesemer
Debugging support. Change-Id: Ia518aaed36eaba76e6233306f718ad8aff3ce744 Reviewed-on: https://go-review.googlesource.com/37875 Reviewed-by: Matthew Dempsky <mdempsky@google.com>
2016-08-18cmd/compile/internal/syntax: fast Go syntax trees, initial commit.Robert Griesemer
Syntax tree nodes, scanner, parser, basic printers. Builds syntax trees for entire Go std lib at a rate of ~1.8M lines/s in warmed up state (MacMini, 2.3 GHz Intel Core i7, 8GB RAM): $ go test -run StdLib -fast parsed 1074617 lines (2832 files) in 579.66364ms (1853863 lines/s) allocated 282.212Mb (486.854Mb/s) PASS Change-Id: Ie26d9a7bf4e5ff07457aedfcc9b89f0eba72ae3f Reviewed-on: https://go-review.googlesource.com/27195 Run-TryBot: Matthew Dempsky <mdempsky@google.com> Reviewed-by: Robert Griesemer <gri@golang.org>