1
0
mirror of https://github.com/golang/go synced 2024-11-19 00:54:42 -07:00
go/internal/lsp/source
Muir Manders aa740d4807 internal/lsp: handle embedded struct pointer definitions
When jumping to definition of an embedded struct pointer, be sure to
unwrap the pointer type so you properly jump to the pointee type.

Also, fix jumping to definition of an embedded struct inside an
anonymous struct inside a struct. The embedded struct detection was
continuing too far and thinking it wasn't an embedded struct when it
saw the anonymous struct.

Fixes golang/go#31451

Change-Id: I96017764270712a2ae02a85306605495075d12e7
GitHub-Last-Rev: 9997f60855ebe37bcca2fecc1ba2a7b871f393d4
GitHub-Pull-Request: golang/tools#83
Reviewed-on: https://go-review.googlesource.com/c/tools/+/172583
Run-TryBot: Paul Jolly <paul@myitcv.org.uk>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Cottrell <iancottrell@google.com>
2019-04-20 18:18:00 +00:00
..
analysis.go internal/lsp: use new go/packages LoadMode to get TypesSizes 2019-03-29 21:52:04 +00:00
completion.go internal/lsp: improve signatureHelp in various cases 2019-04-17 18:10:49 +00:00
diagnostics.go internal/lsp: set the diagnostic source earlier 2019-04-17 00:57:43 +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: use ast.Nodes for hover information 2019-04-18 23:52:43 +00:00
identifier.go internal/lsp: handle embedded struct pointer definitions 2019-04-20 18:18:00 +00:00
signature_help.go internal/lsp: improve signatureHelp in various cases 2019-04-17 18:10:49 +00:00
symbols.go internal/lsp: fix crash when there is a type alias to a struct in the symbols code 2019-04-16 15:17:39 +00:00
view.go internal/lsp: use ast.Nodes for hover information 2019-04-18 23:52:43 +00:00