1
0
mirror of https://github.com/golang/go synced 2024-11-18 11:34:45 -07:00
go/gopls/internal/regtest
Peter Weinbergr 39188db588 internal/lsp: add support for RelatedInformation in diagnostics
The type checker sometimes emits secondary diagnostics. For instance,
if a function is defined twice, then when it sees the second definition
it emits a diagnostic at the second definition and a secondary diagnostic
pointing to the first diagnostic. Presently gopls treats these as two
separate diagnostics. The changed code still produces two diagnostics,
but now the secondary diagnostic is also converted into a
RelatedInformation so the user sees a xpointer to the earlier definition.

Updates https://github.com/golang/go/issues/39062.

Change-Id: Ic421ec91d2b46c28681ab3ec010d5b02c0442e68
Reviewed-on: https://go-review.googlesource.com/c/tools/+/251617
Run-TryBot: Peter Weinberger <pjw@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
2020-09-04 18:57:47 +00:00
..
bench_test.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
codelens_test.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
completion_test.go internal/lsp: support for package completion in all files 2020-09-04 14:04:24 +00:00
definition_test.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
diagnostics_test.go internal/lsp: add support for RelatedInformation in diagnostics 2020-09-04 18:57:47 +00:00
doc.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
env_test.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
env.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
fix_test.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
formatting_test.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
generate_test.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
imports_test.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
link_test.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
modfile_test.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
references_test.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
reg_test.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
runner.go gopls/internal/regtest: use gopls hooks and add a test for staticcheck 2020-09-03 18:57:44 +00:00
shared_test.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
stress_test.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
symbol_helper_test.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
symbol_test.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
unix_test.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
vendor_test.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
watch_test.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
workspace_test.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00
wrappers.go gopls/integration/regtest: move regtests to the gopls module 2020-09-03 18:25:45 +00:00