mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-08 21:52:48 +07:00
GitOrigin-RevId: 4bcbf2d43bddca5ded941c2b1497715ff977ca0b
11 lines
224 B
Java
11 lines
224 B
Java
class Test {
|
|
void test(int x) {
|
|
if (x < 0 || x > 2) return;
|
|
int result = switch(x) {
|
|
case 0 -> 1;
|
|
case 1 -> 2;
|
|
case 2 -> 3;
|
|
default -> 0; // unreachable but required by compiler
|
|
};
|
|
}
|
|
} |