Skip to content

tools: replace go-outline with gopls #1020

Closed
@hyangah

Description

@hyangah

go-outline is no longer used for outline view when language server is enabled.
However, it's still being used by GoDocumentSymbolProvider that is used for

  • generate tests: goGenerateTests.ts
  • references codelens: goReferencesCodelens.ts
  • run test/benchmark codelenses: goRuntestCodelens.ts

They can be replaced with gopls's implementation LanguageClient.getFeatures("textDocument/documentSymbol") or with a direct invocation of vscode.commands.executeCommand('vscode.executeDocumentSymbolProvider', ...).

One difference between the gopls's document symbol provider and GoDocumentSymbolProvider is gopls version doesn't provide the file's package name info, so we need a different way to find the package name if the info is necessary. See golang/go#40514.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions