go/internal/lsp/testdata/append
Muir Manders 68c6cab8b7 lsp/completion: improve append() param type inference
In cases like:

    append([]string{}, foo<>)

we now prefer objects of type string at <>. Previously we had no
preference. In particular, we now try to infer the slice type from the
first append() arg instead of only from the outer context of the
append() call.

Fixes golang/go#43240.

Change-Id: I59dfa3b18892c5c87fc5ff53109f51f50ee03d26
Reviewed-on: https://go-review.googlesource.com/c/tools/+/316849
Run-TryBot: Muir Manders <muir@mnd.rs>
gopls-CI: kokoro <noreply+kokoro@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Trust: Heschi Kreinick <heschi@google.com>
Trust: Rebecca Stambler <rstambler@golang.org>
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
2021-05-05 20:44:55 +00:00
..
append.go lsp/completion: improve append() param type inference 2021-05-05 20:44:55 +00:00
append2.go.in internal/lsp: remove multi-module support in tests 2020-09-22 16:28:30 +00:00