Files
kotlin-fork/compiler/testData/diagnostics/tests/functionLiterals/kt6541_extensionForExtensionFunction.fir.kt
T
Denis Zharkov f97cc0b62d FIR: Rework receivers processing in resolution
- Put extensionReceiver to candidate even if it's explicit (for sake of clarity)
- Split CheckReceiver (dispatch part should only check nullability)
2020-11-16 15:50:39 +03:00

11 lines
244 B
Kotlin
Vendored

// !DIAGNOSTICS: -UNUSED_PARAMETER
interface Foo
fun (Foo.() -> Unit).invoke(b : Foo.() -> Unit) {}
object Z {
infix fun add(b : Foo.() -> Unit) : Z = Z
}
val t2 = Z <!INAPPLICABLE_CANDIDATE!>add<!> <!INAPPLICABLE_CANDIDATE!>{ } { }<!>