1
0
mirror of https://github.com/golang/go synced 2024-10-01 06:18:31 -06:00
go/internal/lsp/testdata/summary.txt.golden
Muir Manders 02335f11d5 internal/lsp: don't qualify literal candidates in *ast.SelectorExpr
Previously we unconditionally qualified literal candidate types with
their package. For example:

var buf *bytes.Buffer
buf = &bytes.Bu<>

would complete to:

buf = &bytes.bytes.Buffer{}

Now we don't qualify the type if the cursor position is in the
selector of an *ast.SelectorExpr. We only generate literal candidates
for type names, so if we are in a selector then we can assume it is a
package qualified type (as opposed to an object field).

We also handle the insertion of "&" for literal pointers better. If you are in
the selector of an *ast.SelectorExpr, we prepend the "&" to the beginning of the
expression rather than the selector. For example, you will end up with
"&bytes.Buffer{}" instead of "bytes.&Buffer{}".

Updates golang/go#34872.

Change-Id: I812aa809cd4e649a429853386789f80033412814
Reviewed-on: https://go-review.googlesource.com/c/tools/+/201200
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
2019-10-16 23:29:27 +00:00

24 lines
490 B
Plaintext

-- summary --
CompletionsCount = 178
CompletionSnippetCount = 39
UnimportedCompletionsCount = 1
DeepCompletionsCount = 5
FuzzyCompletionsCount = 6
RankedCompletionsCount = 1
CaseSensitiveCompletionsCount = 4
DiagnosticsCount = 21
FoldingRangesCount = 2
FormatCount = 6
ImportCount = 2
SuggestedFixCount = 1
DefinitionsCount = 38
TypeDefinitionsCount = 2
HighlightsCount = 2
ReferencesCount = 6
RenamesCount = 20
PrepareRenamesCount = 8
SymbolsCount = 1
SignaturesCount = 21
LinksCount = 4