Open
Description
Hello again.
With gopls/company-mode I'm seeing eglot re-order the top completion candidate:
package main
func fooBar() {}
func _() {
var sbp string
var s struct { blah int }
var _ int = sb<>
}
Completing at <>
I expect to see "s.blah" as the top candidate (because the type matches) but I see "sbp".
[server-reply] (id:277) Tue Dec 22 09:32:34 2020:
(:jsonrpc "2.0" :result
(:isIncomplete t :items
[(:label "s.blah" :kind 5 :detail "int" :preselect t :sortText "00000" :filterText "s.blah" :insertTextFormat 2 :textEdit
(:range
(:start
(:line 6 :character 13)
:end
(:line 6 :character 15))
:newText "s.blah"))
(:label "sbp" :kind 9 :detail "\"github.com/go-playground/locales/sbp\"" :sortText "00001" :filterText "sbp" :insertTextFormat 2 :textEdit
(:range
(:start
(:line 6 :character 13)
:end
(:line 6 :character 15))
:newText "sbp")
:additionalTextEdits
[(:range
(:start
(:line 1 :character 0)
:end
(:line 1 :character 0))
:newText "\nimport \"github.com/go-playground/locales/sbp\"\n")])
(:label "sbp_TZ" :kind 9 :detail "\"github.com/go-playground/locales/sbp_TZ\"" :sortText "00002" :filterText "sbp_TZ" :insertTextFormat 2 :textEdit
(:range
(:start
(:line 6 :character 13)
:end
(:line 6 :character 15))
:newText "sbp_TZ")
:additionalTextEdits
[(:range
(:start
(:line 1 :character 0)
:end
(:line 1 :character 0))
:newText "\nimport \"github.com/go-playground/locales/sbp_TZ\"\n")])])
:id 277)
Metadata
Assignees
Labels
No labels