Skip to content

x/tools/gopls: missing placeholder names for function parameters #60269

@ShoshinNikita

Description

@ShoshinNikita

gopls version: master (242e5ed)

VSCode settings:

{
  "gopls": {
    "ui.completion.usePlaceholders": true,
    // ...
  }
}

Steps to reproduce:

  1. Enable gopls.ui.completion.usePlaceholders.
  2. Create a .go file without any imports.
  3. Try to complete a function call from some package (for example, log.Printf) - the completion response has placeholder but not their names.
  4. Try to complete the same function call (now with imported package) - the completion response has correct placeholders.
2023-05-17.20-01-03.mp4

Note: older versions of gopls didn't provide placeholders at all for cases when the package import was missing. Example:

2023-05-17.20-20-35.mp4

Metadata

Metadata

Assignees

Labels

FrozenDueToAgeToolsThis label describes issues relating to any tools in the x/tools repository.goplsIssues related to the Go language server, gopls.

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions