mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-18 09:34:34 +07:00
IDEA-200030 Quick-fix to remove unreachable should remove body only if previous branch has 'break' at the end
This commit is contained in:
+15
@@ -0,0 +1,15 @@
|
||||
// "Remove switch label '"two"'" "true"
|
||||
class Main {
|
||||
static void fff() {
|
||||
switch ("one") {
|
||||
case "one":
|
||||
System.out.println("one");
|
||||
// quick-fix removes body as well
|
||||
System.out.println("two");
|
||||
}
|
||||
}
|
||||
|
||||
public static void main(String[] args) {
|
||||
fff();
|
||||
}
|
||||
}
|
||||
+15
@@ -0,0 +1,15 @@
|
||||
// "Remove switch label '"two"'" "true"
|
||||
class Main {
|
||||
static void fff() {
|
||||
switch ("one") {
|
||||
case "one":
|
||||
System.out.println("one");
|
||||
case "<caret>two": // quick-fix removes body as well
|
||||
System.out.println("two");
|
||||
}
|
||||
}
|
||||
|
||||
public static void main(String[] args) {
|
||||
fff();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user