b045adf83a
There are several issues with unsafe desugaring for convention calls. Proper fix is not implemented here (see design proposal KT-30872). This commit only applies the old logic in the new inference. ^KT-30695 Fixed
19 lines
279 B
Kotlin
Vendored
19 lines
279 B
Kotlin
Vendored
class A {
|
|
val lambda: () -> Unit = TODO()
|
|
val memberInvoke: B = TODO()
|
|
val extensionInvoke: C = TODO()
|
|
}
|
|
|
|
class B {
|
|
operator fun invoke() {}
|
|
}
|
|
|
|
class C
|
|
operator fun C.invoke() {}
|
|
|
|
fun test(a: A?) {
|
|
a?.lambda()
|
|
a?.memberInvoke()
|
|
a?.extensionInvoke()
|
|
}
|