mirror of
https://github.com/golang/go
synced 2024-10-01 01:28:32 -06:00
The Go programming language
50ff896a1c
For a 'definition' query on X in p.X, use special logic to load and parse package p and find the declaration of package member X, without using the type checker. Such queries now typically take under 10ms (faster than godef). The logic assumes that import "something/p" defines the name p. If this assumption is false, p.X could be a selection of a field or method X on a member p of the same package, defined in another file. So don't write code like that. Added missing test of 'definitions'. JSON tests now sanitize absolute $GOPATH filenames in the output. Fixes issue #15458 Change-Id: I21e75fcc9372aaedd56851cace444aef205c7a97 Reviewed-on: https://go-review.googlesource.com/22526 Reviewed-by: Dominik Honnef <dominik@honnef.co> Reviewed-by: Michael Matloob <matloob@golang.org> |
||
---|---|---|
benchmark/parse | ||
blog | ||
cmd | ||
container/intsets | ||
cover | ||
go | ||
godoc | ||
imports | ||
oracle | ||
playground | ||
present | ||
refactor | ||
.gitattributes | ||
.gitignore | ||
AUTHORS | ||
codereview.cfg | ||
CONTRIBUTING.md | ||
CONTRIBUTORS | ||
LICENSE | ||
PATENTS | ||
README |
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 oracle 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. To submit changes to this repository, see http://golang.org/doc/contribute.html.