mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-12 00:21:32 +00:00
KT-531 Support nullable iterator in for()
This commit is contained in:
@@ -10,5 +10,10 @@ fun box() : String {
|
||||
}
|
||||
if(sum != 10) return "a failed"
|
||||
|
||||
val b : IntArray? = null
|
||||
for (el in b) {
|
||||
sum = sum + el
|
||||
}
|
||||
|
||||
return "OK"
|
||||
}
|
||||
Reference in New Issue
Block a user