KT-9628 Intention&inspection to replace use of "set" operator function with []

#KT-9628 Fixed
This commit is contained in:
Valentin Kipyatkov
2015-10-20 16:01:04 +03:00
parent 852579e7f3
commit 66310806ca
51 changed files with 248 additions and 126 deletions
+2 -2
View File
@@ -3,13 +3,13 @@ import java.util.ArrayList
internal class C {
fun foo1(list: MutableList<String>) {
for (i in list.indices) {
list.set(i, "a")
list[i] = "a"
}
}
fun foo2(list: ArrayList<String>) {
for (i in list.indices) {
list.set(i, "a")
list[i] = "a"
}
}
}
+1 -1
View File
@@ -3,7 +3,7 @@ import java.util.ArrayList
internal class C {
fun foo(list: MutableList<String>) {
for (i in list.indices) {
list.set(i, "a")
list[i] = "a"
}
}
}