-
Notifications
You must be signed in to change notification settings - Fork 510
Closed
Labels
Description
Description:
When navigating to a method or variable that has only one reference, VSCode Java extension should directly navigate to the target location instead of showing the reference list.
Current behavior:
- When using "Go to Definition" or "Find References" on a method/variable with single reference
- VSCode shows a reference list with only one item
- User needs to click on the reference to navigate
Expected behavior:
- When using "Go to Definition" or "Find References" on a method/variable with single reference
- VSCode should directly navigate to the target location
- No reference list should be shown
Benefits:
- Improves developer productivity
- Reduces unnecessary clicks
- Better user experience
- Consistent with common IDE behavior
Example:
// Current behavior
public class Example {
public void method() {
singleReference(); // Go to Definition shows reference list
}
private void singleReference() {
// implementation
}
}
// Expected behavior
public class Example {
public void method() {
singleReference(); // Go to Definition directly navigates
}
private void singleReference() {
// implementation
}
}Additional context:
- This feature would be particularly useful in large codebases
- It would make navigation more efficient
- It's a common feature in other IDEs like IntelliJ IDEA