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

Improve the signature help #2025

Closed
jdneo opened this issue Mar 16, 2022 · 0 comments · Fixed by #2039
Closed

Improve the signature help #2025

jdneo opened this issue Mar 16, 2022 · 0 comments · Fixed by #2039
Assignees

Comments

@jdneo
Copy link
Contributor

jdneo commented Mar 16, 2022

Currently the implementation of SignatureHelp could provide paramter hints for normal cases. I found that sometimes, it's not working properly.

Failure case 1

System.out.println("{,},(,),");

In this case, the signature help won't hint anything.

By reading the source code I found that the root cause is that in the implementation of SignatureHelpHandler#getContextInfomation() is not robust. For example, it's not taking the appearance of ( and ) in a string literal into consideration.

Failure case 2

For project spring-petclinic:
image

While the actual signature is: SpringApplication.run(Class<?> primarySource, String... args)

That means the varargs is not handled properly.

Failure case 3

image

While the actual signature is: SpringApplication.run(Class<?> primarySource, String... args)

That means when the parameter list is not complete, we cannot handle it properly.

I'm now trying to fix those problems recently. Hopefully, I can send a PR in around next week. :)

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

Successfully merging a pull request may close this issue.

2 participants