Files
openide/java/java-tests/testData/codeInsight/daemonCodeAnalyzer/quickFix/splitSwitchBranchWithSeveralCaseValues/afterConstantPatternGuard.java
Tagir Valeev efbff7c99c [java-highlighting] Move guard expression to switch label
Part of IDEA-326939 Support multi-pattern switch labels that define no variables

GitOrigin-RevId: c236438af58e1c74a2bf12a5985b33cedadb9cbb
2023-08-18 08:18:06 +00:00

10 lines
220 B
Java

// "Split values of 'switch' branch" "true-preview"
class C {
void foo(String o) {
switch (o) {
case "42" when s.isEmpty() -> {}
case String s when s.isEmpty() -> {}
}
}
}