Skip to content

x/tools/gopls: jump to function definition via go:linkname #57312

@hitzhangjie

Description

@hitzhangjie

Is your feature request related to a problem? Please describe.
//go:linkname is one method to export one function as a different name or path.
I think we should support the jumping to/back navigation, it will be much more convenient to read the source code, especially go source.

Describe the solution you'd like
Go AST parser extracts this go:linkname directives and generate navigation link.
When user hovers on the function name, it display a link, so user can ctrl+click to jump to the definition location.

Describe alternatives you've considered
No alternatives considered now.

Additional context
No additional context now.

Metadata

Metadata

Assignees

Labels

FeatureRequestIssues asking for a new feature that does not need a proposal.FrozenDueToAgeToolsThis label describes issues relating to any tools in the x/tools repository.goplsIssues related to the Go language server, gopls.help wanted

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions