1
0
mirror of https://github.com/golang/go synced 2024-10-01 09:38:36 -06:00
go/internal/lsp/source
Muir Manders 63859f3815 internal/lsp: add definition support for packages
Now the "type" of a *ast.PkgName is the package it points to. Of
course, a package is not a real types.Type, but we can still jump you
there. We have to pick one of the package's files, so we choose the
longest one, hoping it is the most interesting.

Similarly, the "definition" of an *ast.ImportSpec is the package being
imported.

I also added a nil check for the package in SignatureHelp. This panics
for me occasionally.

Change-Id: Ide4640530a28bcec9da6de36723eb7f0e4cc941c
GitHub-Last-Rev: 8190baa0b908065db5b53f236de03d2f3bff39b5
GitHub-Pull-Request: golang/tools#92
Reviewed-on: https://go-review.googlesource.com/c/tools/+/174081
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
2019-05-10 15:10:30 +00:00
..
analysis.go internal/lsp: add more error propagation and logging for analyses 2019-04-24 02:44:48 +00:00
completion_format.go internal/lsp: add additional error handling for builtin packages 2019-05-10 13:52:03 +00:00
completion_snippet.go internal/lsp: add additional error handling for builtin packages 2019-05-10 13:52:03 +00:00
completion.go internal/lsp: support builtin types without hardcoding 2019-05-01 04:50:30 +00:00
diagnostics.go internal/lsp: propagate diagnostics for reverse dependencies 2019-05-10 13:52:23 +00:00
enums.go internal/lsp: switch completion item tests to using the enum strings 2019-04-17 17:57:43 +00:00
format.go internal/lsp: normalise and make public diff<->edit conversions 2019-04-15 20:31:36 +00:00
highlight.go internal/lsp: add support for document highlight 2019-03-26 19:08:20 +00:00
hover.go internal/lsp: add definition support for packages 2019-05-10 15:10:30 +00:00
identifier.go internal/lsp: add definition support for packages 2019-05-10 15:10:30 +00:00
signature_help.go internal/lsp: add definition support for packages 2019-05-10 15:10:30 +00:00
symbols.go internal/lsp: make interface methods children of the interface symbol 2019-04-24 02:46:01 +00:00
util.go internal/lsp: support builtin types without hardcoding 2019-05-01 04:50:30 +00:00
view.go internal/lsp: add definition support for packages 2019-05-10 15:10:30 +00:00