mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-05-01 10:48:09 +07:00
isRemovable must be called before any modifications. Otherwise, previous modifications may affect its results. GitOrigin-RevId: d05be1e54ba62e5ac18003bf54dab2abb16124ce
16 lines
339 B
Java
16 lines
339 B
Java
// "Replace 'switch' with 'if'" "true"
|
|
class X {
|
|
void test(int x) {
|
|
if (x > 0) {
|
|
if (x == 1) {
|
|
if (Math.random() > 0.5) {
|
|
System.out.println(1);
|
|
} else {
|
|
}
|
|
} else if (x == 2) {
|
|
System.out.println(2);
|
|
}
|
|
}
|
|
System.out.println("Exit");
|
|
}
|
|
} |