Files
kotlin-fork/compiler/testData/diagnostics/tests/inference/regressions/kt32862_both.fir.kt
T
Denis.Zharkov 2ecba6ac39 Remove WITH_NEW_INFERENCE directive from all tests
This directive anyway does not make test run twice with OI, and with NI
It only once run the test with specific settings (// LANGUAGE)
and ignores irrelevant (OI or NI tags)
2021-05-25 13:28:26 +03:00

16 lines
359 B
Kotlin
Vendored

// !DIAGNOSTICS: -UNUSED_PARAMETER
interface G<T> {
fun build(): G<T>
}
class V1<V>(val value: V)
class V2<V>(val value: V)
fun <V, T : V?> G<T>.foo(vararg values: V1<V>) = build()
fun <V, T : V?> G<T>.foo(vararg values: V2<V?>) = build()
fun forReference(ref: Any?) {}
fun test() {
forReference(G<Int?>::<!OVERLOAD_RESOLUTION_AMBIGUITY!>foo<!>)
}