1
0
mirror of https://github.com/golang/go synced 2024-10-01 07:38:32 -06:00
go/internal/lsp/testdata/godef
Suzy Mueller b76e30ffa0 internal/lsp: fix references for type switch vars
Implicit local variables for type switches do not appear in the Uses
map and do not have objects associated with them.  This change
associates all of the different types objects for the same local type
switch declaration with one another in the declaration.

The identifier for the implicit local variable does not have a type but
does have declaration objects.

Find references for type switch vars will return references to all the
identifiers in all of the case clauses and the declaration.

Fixes golang/go#32584

Change-Id: I5563a2a48d31ca615c1e4e73b46eabca0f5dd72a
Reviewed-on: https://go-review.googlesource.com/c/tools/+/182462
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-06-19 18:18:01 +00:00
..
a internal/lsp: fix references for type switch vars 2019-06-19 18:18:01 +00:00
b internal/lsp: fix references for type switch vars 2019-06-19 18:18:01 +00:00
broken internal/lsp: enable enhanced hover by default 2019-05-16 17:30:22 +00:00