Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Completion items in wrong order for overloaded methods #3206

Closed
charles-wangkai opened this issue Jul 18, 2023 · 1 comment · Fixed by eclipse-jdtls/eclipse.jdt.ls#2874
Closed

Comments

@charles-wangkai
Copy link

charles-wangkai commented Jul 18, 2023

In recent versions (from v1.17.0 to v1.20.0), the completion popup list shows overloaded methods from those with more complex parameters to those with fewer parameters from top to bottom. But what I want most times is the fewer parameters version, which leads to more "arrow down" key typing to select the expected item. It is annoying to impact coding productivity.

This seems a regression issue, since in early versions (up to v1.16.0) the order was reversed so that the fewer parameters version generally ranked higher and was placed at the top.

Environment
  • Operating System: All
  • JDK version: 17
  • Visual Studio Code version: 1.80.1
  • Java extension version: The issue first arose in recent versions (from v1.17.0 to v1.20.0), it was fine in early versions (up to v1.16.0)
Current Result

For example, the completion items show the three versions of Collectors.joining(...) in from complex to simple order, in the latest version v1.20.0:

Screenshot 2023-07-18 at 08 30 01
Expected Result

While the same three methods were displayed in from simple to complex order, in early versions (up to v1.16.0):

Screenshot 2023-07-18 at 08 31 47
@rgrunber
Copy link
Member

rgrunber commented Sep 6, 2023

I suspect this has a similar cause to eclipse-jdtls/eclipse.jdt.ls#2705 . After we introduced label detail support (which did produce nicer completion items), we regressed in certain ways (sorting, filter text). Maybe @hopehadfield can have a look here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

3 participants