commit | b2e691980a9da0a76f6d85624b7065f4eccfeef4 | [log] [tgz] |
---|---|---|
author | Rebecca Stambler <rstambler@golang.org> | Sun Apr 05 23:48:22 2020 -0400 |
committer | Rebecca Stambler <rstambler@golang.org> | Mon Apr 06 21:19:59 2020 +0000 |
tree | d1b86830f4a6fed537ca7ee57abc4d624d981254 | |
parent | 486f59bc617f48a749d07017d8aedace04a21f95 [diff] |
internal/lsp: make sure that `gofmt -s` analyses don't modify AST The code for `gofmt -s` directly modifies the AST, since the ASTs are not long-lived. Some of this code made it into our analysis implementations, causing very strange bugs to manifest. Added a regression test for this specific case. Fixes golang/go#38267 Change-Id: I235620adcbf2bbc7027c6d83ff2c7fe74729062e Reviewed-on: https://go-review.googlesource.com/c/tools/+/227299 Run-TryBot: Rebecca Stambler <rstambler@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Heschi Kreinick <heschi@google.com> (cherry picked from commit 1fd976651f4da6cc8c239c50463fb2d82641fa77) Reviewed-on: https://go-review.googlesource.com/c/tools/+/227354 Reviewed-by: Robert Findley <rfindley@google.com>
This subrepository holds the source for various packages and tools that support the Go programming language.
Some of the tools, godoc
and vet
for example, are included in binary Go distributions.
Others, including the Go guru
and the test coverage tool, can be fetched with go get
.
Packages include a type-checker for Go and an implementation of the Static Single Assignment form (SSA) representation for Go programs.
The easiest way to install is to run go get -u golang.org/x/tools/...
. You can also manually git clone the repository to $GOPATH/src/golang.org/x/tools
.
This repository uses Gerrit for code changes. To learn how to submit changes to this repository, see https://golang.org/doc/contribute.html.
The main issue tracker for the tools repository is located at https://github.com/golang/go/issues. Prefix your issue with “x/tools/(your subdir):” in the subject line, so it is easy to find.