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

Add support for searching for workspace method symbols on binary classes as well. #2101

Closed
gayanper opened this issue May 24, 2022 · 1 comment

Comments

@gayanper
Copy link
Contributor

Today the method symbol on workspace search is only done for workspace sources. But with adding a prefix into the search token we could try to target both source and binary symbols as well.

For example searching foo will provide foo methods from the workspace sources. But if you search like +foo you would search both on source and binary. Since vscode fuzzy search use the symbol name, we need to append + for all symbol names from jdt.ls. The same strategy is used by Spring Tools for different kind of workspace symbol searches.

A more better way is to have this as part of LSP, But i'm not sure if this fits there since LSP tries to make the protocol more generic to fit larger group of languages.

WDYT about the idea ?

@rgrunber
Copy link
Contributor

Adding some kind of prefix might be a good way to reduce the number of results in some cases. With that said, the first step would be to just search the binary+source symbols together. When I introduced searching source methods, it was my goal to do it but the performance is not great. The symbol search in VS Code basically waits until all symbols are returned, but the LSP itself has the ability to return results incrementally.

See redhat-developer/vscode-java#1712 (comment) & #1712 for more information.
Closing this as a duplicate of that issue.

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

No branches or pull requests

2 participants