mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-16 22:51:17 +07:00
22 lines
487 B
Java
22 lines
487 B
Java
// "Convert field to local variable in constructor" "true-preview"
|
|
import java.util.ArrayList;
|
|
|
|
class ITest {
|
|
|
|
public IntelliJBugConvertToLocal(int x, int z) {
|
|
|
|
//my comment to keep in code
|
|
ArrayList<String> mayBeLocal = new ArrayList<String>();
|
|
if (x == 5) {
|
|
mayBeLocal.add("jjj");
|
|
}
|
|
|
|
if (x > z) {
|
|
useIt(mayBeLocal);
|
|
}
|
|
}
|
|
@SuppressWarnings("UnusedParameters")
|
|
private void useIt(Object data) {
|
|
System.out.println(data);
|
|
}
|
|
} |