mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-17 21:43:33 +07:00
extract method: duplicates processing fixed (IDEA-105562)
This commit is contained in:
@@ -0,0 +1,10 @@
|
||||
class Test {
|
||||
String[] foos;
|
||||
|
||||
void test() {
|
||||
for (String foo : <selection>foos</selection>) {
|
||||
|
||||
}
|
||||
System.out.println(foos.length);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
class Test {
|
||||
String[] foos;
|
||||
|
||||
void test() {
|
||||
for (String foo : newMethod()) {
|
||||
|
||||
}
|
||||
System.out.println(newMethod().length);
|
||||
}
|
||||
|
||||
private String[] newMethod() {
|
||||
return foos;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user