Files
openide/java/java-tests/testData/codeInsight/daemonCodeAnalyzer/quickFix/deleteSwitchLabel19/beforeUnwrapDeconstructionPattern.java
Andrey.Cherkasov 347fd05cd9 [java-intentions] UnwrapSwitchLabelFix produces red code when unwrapping case labels with deconstruction patterns
IDEA-297387

GitOrigin-RevId: cfdbdec0e83af90c325d41d583c749963686fd71
2022-08-02 08:33:45 +00:00

17 lines
402 B
Java

// "Remove unreachable branches" "true"
class Test {
void test(R r) {
switch (r) {
case R(int i, String str, double ignored)<caret> -> {
System.out.println(i);
i = 42;
System.out.println(str + i);
}
case R ignored when false -> {
}
}
}
record R(int i, String s, double ignored) {
}
}