Simplify for now works even if no variables are declared inside loop #KT-12145 Fixed
This commit is contained in:
+10
@@ -0,0 +1,10 @@
|
||||
// WITH_RUNTIME
|
||||
|
||||
data class XY(val x: String, val y: String)
|
||||
fun test(xys: Array<XY>, base: XY) {
|
||||
for ((x, y) in xys) {
|
||||
if (x == base.x) {
|
||||
println(y)
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user