Files
kotlin-fork/compiler/testData/diagnostics/tests/subtyping/kt-1457.kt
T
2017-08-29 18:01:36 +03:00

13 lines
240 B
Kotlin
Vendored

// !CHECK_TYPE
// JAVAC_EXPECTED_FILE
import java.util.ArrayList
class Pair<A, B>(val a: A, val b: B)
class MyListOfPairs<T> : ArrayList<Pair<T, T>>() { }
fun test() {
checkSubtype<ArrayList<Pair<Int, Int>>>(MyListOfPairs<Int>())
}