New J2K: Fix existing test data

This commit is contained in:
Ilya Kirillov
2019-02-03 16:42:16 +03:00
committed by Ilya Kirillov
parent 7e30b9e7f5
commit f8b8d07621
27 changed files with 546 additions and 143 deletions
+15
View File
@@ -0,0 +1,15 @@
// ERROR: Unresolved reference: LinkedList
import java.util.ArrayList
class ForEach {
fun test() {
val xs: ArrayList<Any?> = ArrayList()
val ys: MutableList<Any?> = LinkedList<Any?>()
for (x in xs) {
ys.add(x)
}
for (y in ys) {
xs.add(y)
}
}
}
+17
View File
@@ -0,0 +1,17 @@
// ERROR: Unresolved reference: LinkedList
// ERROR: Null can not be a value of a non-null type Any
// ERROR: Null can not be a value of a non-null type Any
import java.util.ArrayList
class Lists {
fun test() {
val xs: MutableList<Any?> = ArrayList()
val ys: MutableList<Any?> = LinkedList<Any?>()
val zs: ArrayList<Any?> = ArrayList()
xs.add(null)
ys.add(null)
xs.clear()
ys.clear()
zs.add(null)
}
}