Files
openide/java/java-tests/testData/codeInsight/daemonCodeAnalyzer/quickFix/deleteSwitchLabel/afterUnwrapExpression5.java
Tagir Valeev dd689d3a39 [java-inspections] More tests for preview
GitOrigin-RevId: 6b6405ee4491ad1d58947547c40df6fb2d291ab7
2022-07-29 17:54:59 +00:00

22 lines
418 B
Java

// "Remove unreachable branches" "true-preview"
class Main {
void foo(int x) {
if (x == 42) {
System.out.println(switch (x) {
// 1
// 2
// 3
// 4
// 5
// 6
// 7
case 42 -> {
System.out.println("something");
yield "Six by nine"; // 42
}
default -> "and more"; // other
});
}
}
}