From eea231afc5891a880fead754e0d1ec6bb2d1e435 Mon Sep 17 00:00:00 2001 From: rubenporras <43636626+rubenporras@users.noreply.github.com> Date: Wed, 14 Aug 2024 17:11:04 +0200 Subject: [PATCH] Use the URI as the human readable name of the change instead of the path (#1053) in the filesystem to support files which are only in the Eclipse filesystem (not in the IO filesystem) --- org.eclipse.lsp4e/src/org/eclipse/lsp4e/LSPEclipseUtils.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/org.eclipse.lsp4e/src/org/eclipse/lsp4e/LSPEclipseUtils.java b/org.eclipse.lsp4e/src/org/eclipse/lsp4e/LSPEclipseUtils.java index cb889b959..087dfafe9 100644 --- a/org.eclipse.lsp4e/src/org/eclipse/lsp4e/LSPEclipseUtils.java +++ b/org.eclipse.lsp4e/src/org/eclipse/lsp4e/LSPEclipseUtils.java @@ -1260,7 +1260,7 @@ private static Change toChanges(URI uri, List textEdits) { Comparator.comparingInt(Position::getLine).thenComparingInt(Position::getCharacter).reversed())); LSPTextChange[] changes = textEdits.stream().map(te -> new LSPTextChange("Line: %d".formatted(te.getRange().getStart().getLine() + 1), uri, te)) //$NON-NLS-1$ .toArray(LSPTextChange[]::new); - CompositeChange cc = new CompositeChange(Paths.get(uri).toString(), changes); + CompositeChange cc = new CompositeChange(uri.toString(), changes); return cc; }