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

jump to definition on break/continue #1281

Merged
merged 1 commit into from
Nov 22, 2019
Merged

Conversation

snjeza
Copy link
Contributor

@snjeza snjeza commented Nov 19, 2019

Fixes redhat-developer/vscode-java#1145

Signed-off-by: Snjezana Peco [email protected]

@snjeza snjeza requested review from gorkem and fbricon November 19, 2019 15:49
@fbricon
Copy link
Contributor

fbricon commented Nov 22, 2019

If I open https://github.com/eclipse/eclipse.jdt.ls/pull/1281/files#diff-cf0a7da25e0081c3469ee576216a62ad in vscode, try to Go to Definition on either a break or continue keyword, without label, I can see the ranges returned cover multiple lines and nothing happens. We should jump to the start of the matching while loop.
It works for labels though.

@snjeza
Copy link
Contributor Author

snjeza commented Nov 22, 2019

I can see the ranges returned cover multiple lines and nothing happens

breakcontinue

@fbricon
Copy link
Contributor

fbricon commented Nov 22, 2019

I tried vscode insiders

@snjeza
Copy link
Contributor Author

snjeza commented Nov 22, 2019

I think, this is a bug in VS Code Insiders.

VS Code 1.40.1:
code

VS Code sends the document/definition command.

VS Code Insiders 1.41
code-insiders

VS Code Insiders sends the document/definition and document/references commands,

@fbricon
Copy link
Contributor

fbricon commented Nov 22, 2019

@snjeza see if you can reproduce with typescript, if you do then please open an issue upstream

@snjeza
Copy link
Contributor Author

snjeza commented Nov 22, 2019

see if you can reproduce with typescript, if you do then please open an issue upstream

I can reproduce the issue with typescript. I have created microsoft/vscode#85403

@fbricon
Copy link
Contributor

fbricon commented Nov 22, 2019

Thanks, I'll merge the PR then since it works with a proper version of vscode

@fbricon fbricon merged commit 4100467 into eclipse-jdtls:master Nov 22, 2019
@fbricon fbricon added this to the End November 2019 milestone Dec 2, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

jump to definition on break
2 participants