-
Notifications
You must be signed in to change notification settings - Fork 517
Open
Labels
Description
There are some unwanted changes made by the "Add throws declaration" Quick fix action.
If you use the QuickFix action Add throws declarat... the java extension will remove the fragment name of the second Template specification and the escaped backslashes from the string.
Before executing the QuickFix:
String someString = "Escaped\\Test\\Path";
@CheckedTemplate
static class Templates {
public static native TemplateInstance page();
public static native TemplateInstance page$content();
}After performing the QuickFix:
String someString = "Escaped\Test\Path";
@CheckedTemplate
static class Templates {
public static native TemplateInstance page();
public static native TemplateInstance page();
}Steps to reproduce:
- Clone reproducer repository: https://github.com/LukasLeppich/vscode-java-quickfix-bug
- Create a new VSCode Profile
- Install the
Extension Pack for Javaextension - Open the
SomePage.javaclass and perform theAdd throws declarat...Quick Fix on line 30service.test();
Tested with the following setup:
Vscode:
Version: 1.108.1 (user setup)
Commit: 585eba7c0c34fd6b30faac7c62a42050bfbc0086
Date: 2026-01-14T14:55:44.241Z
Extensions:
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]