New Intention: Replace for loop with forEach
Replaces an expression of the form “for (i in list) { … }” with an
expression of the form “list.forEach { i -> … }”
This commit is contained in:
committed by
Mikhael Bogdanov
parent
dbb28c571b
commit
33fd82cf45
+4
@@ -0,0 +1,4 @@
|
||||
// WITH_RUNTIME
|
||||
fun main() {
|
||||
(1 rangeTo 2).forEach { x -> x }
|
||||
}
|
||||
Reference in New Issue
Block a user