Files
kotlin-fork/compiler/testData/diagnostics/tests/callableReference/compatibilityResolveWithVarargAndOperatorCall.fir.kt
T
2020-06-19 16:21:24 +03:00

18 lines
330 B
Kotlin
Vendored

// !DIAGNOSTICS: -UNUSED_PARAMETER
fun interface IFoo {
fun foo(i: Int)
}
fun interface IFoo2 : IFoo
object A
operator fun A.get(i: IFoo) = 1
operator fun A.set(i: IFoo, newValue: Int) {}
fun withVararg(vararg xs: Int) = 42
fun test1() {
<!UNRESOLVED_REFERENCE!><!INAPPLICABLE_CANDIDATE!>A[::withVararg]<!> += 1<!>
}