mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-01 07:11:30 +07:00
GitOrigin-RevId: 6313e67d7bd5180a43d20faffb20c207f46452ae
33 lines
682 B
Java
33 lines
682 B
Java
// "Replace with old style 'switch' statement" "true"
|
|
import java.util.*;
|
|
|
|
class SwitchExpressionMigration {
|
|
private static void m(int x) {
|
|
/*4*/
|
|
/*1*/
|
|
/*2*/
|
|
/*3*/
|
|
int x;
|
|
switch (x +/*cond*/ x) {/*5*/
|
|
case 1:
|
|
if (true) {
|
|
x = 0;
|
|
break;
|
|
} else {
|
|
x = 1;
|
|
break;
|
|
}
|
|
case 2:
|
|
x = 2;
|
|
break;
|
|
case 3:
|
|
case 4:
|
|
System.out.println("asda");
|
|
x = 3;
|
|
break;
|
|
default:
|
|
x = 12/*6*/;
|
|
break;
|
|
}
|
|
}
|
|
} |