Files
kotlin-fork/compiler/testData/diagnostics/tests/generics/projectionsScope/unsafeVarianceStar.kt
T
2017-11-29 02:54:26 +03:00

11 lines
197 B
Kotlin
Vendored

// !WITH_NEW_INFERENCE
interface A<out K> {
fun foo(x: @UnsafeVariance K): Unit
}
fun test(a: A<*>) {
a.foo(<!NI;NULL_FOR_NONNULL_TYPE!>null<!>)
a.foo(<!NI;TYPE_MISMATCH!>Any()<!>)
}