Files
kotlin-fork/compiler/testData/codegen/box/functions/kt2739.kt
T
Alexander Udalov 41a416da60 Move blackBoxFile() testData to box/ directory
Delete all test methods (and empty test classes), since they'll be
auto-generated
2013-01-28 18:20:17 +04:00

11 lines
210 B
Kotlin

// KT-2739 Error type inferred for hashSet(Pair, Pair, Pair)
fun foo<T>(vararg ts: T): T? = null
class Pair<A>(a: A)
fun box(): String {
val v = foo(Pair(1))
return if (v == null) "OK" else "fail"
}