For-loop range expression (collection) can not be null

This commit is contained in:
Andrey Breslav
2012-08-24 15:36:55 +04:00
parent b315bee7b2
commit 66faa0c03a
24 changed files with 39 additions and 60 deletions
@@ -17,7 +17,7 @@ fun <T> fff(x: T) : T { return x }
fun <T> id(value: T): T = value
fun foreach(array: Array<Int>?, action: (Int)-> Unit) {
fun foreach(array: Array<Int>, action: (Int)-> Unit) {
for (el in array) {
action(el) //exception through compilation (see below)
}