Skip to content

DefinitionLink targetSelectionRange not working as expected #58649

@KamasamaK

Description

@KamasamaK

Issue Type: Bug

Scenario 1:

  1. Use Peek Definition on a symbol that has a DefinitionLink provided with targetSelectionRange defined.
  2. The range provided by DefinitionLink.targetRange is used for highlighting.

Scenario 2:

  1. Use Go to Definition on a symbol that has a DefinitionLink provided with targetSelectionRange defined.
  2. Navigates to beginning of DefinitionLink.targetRange

I am assuming that in at least one of the above scenarios, DefinitionLink.targetSelectionRange should be used instead of DefinitionLink.targetRange. It is not clear based on the documentation, so I am not sure in what case DefinitionLink.targetSelectionRange is supposed to be used, but I figure it must be used for something. I am expecting it to work similarly to DocumentSymbol.selectionRange.

VS Code version: Code 1.27.2 (f46c4c4, 2018-09-12T16:17:45.060Z)
OS version: Windows_NT x64 10.0.17134

Metadata

Metadata

Assignees

Labels

bugIssue identified by VS Code Team member as probable bugeditor-symbolsdefinitions, declarations, referencesverifiedVerification succeeded

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions