mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-02-06 09:36:56 +07:00
18 lines
374 B
Java
18 lines
374 B
Java
// "Replace loop with 'Arrays.fill()' method call" "true"
|
|
|
|
import java.util.Arrays;
|
|
|
|
public class Test {
|
|
|
|
public static String[] init(int n) {
|
|
String[] lines = new String[n];
|
|
String[] copy = getCopy(lines);
|
|
copy[0] = "foo";
|
|
Arrays.fill(lines, null);
|
|
return lines;
|
|
}
|
|
|
|
private static String[] getCopy(String[] original) {
|
|
return original;
|
|
}
|
|
} |