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

Support linked correction proposals through LSP snippet syntax #3229

Merged
merged 9 commits into from
Sep 3, 2024

Conversation

hopehadfield
Copy link
Contributor

@hopehadfield hopehadfield commented Jul 31, 2024

Copy link
Contributor

@rgrunber rgrunber left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just some minor things to fix.

Copy link
Contributor

@rgrunber rgrunber left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is ready for merging after we release. We've tested quite a bit and there's some subsequent changes that would depend on this (not to mention maybe upstreaming the snippet edit class into lsp4j, applying your RHS type-mismatch, and expanding the set of things that can correctly use this.

@rgrunber
Copy link
Contributor

retest this please.

@rgrunber rgrunber merged commit 4324c68 into eclipse-jdtls:master Sep 3, 2024
6 checks passed
@rgrunber rgrunber changed the title Add LinkedProposalModel -> snippet conversion to support linked proposals Support linked correction proposals through LSP snippet syntax Sep 3, 2024
@@ -195,6 +195,10 @@ public boolean isWorkspaceApplyEditSupported() {
return capabilities.getWorkspace() != null && isTrue(capabilities.getWorkspace().getApplyEdit());
}

public boolean isWorkspaceSnippetEditSupported() {
return Boolean.parseBoolean(extendedClientCapabilities.getOrDefault("snippetEditSupport", "false").toString());
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would it be possible to use the standard workspaceEdit.snippetEditSupport capability here to make this work out of the box for clients supporting the 3.18 spec addition?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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.

Support linked correction proposals
3 participants