[FIR] Fix overload conflicts resolution for callable references with defaults

This commit is contained in:
Dmitriy Novozhilov
2021-05-13 12:40:58 +03:00
committed by teamcityserver
parent e3b92fd561
commit 1a3b5657c7
8 changed files with 77 additions and 1 deletions
@@ -0,0 +1,29 @@
// FIR_IDENTICAL
class ShortenReferences {
companion object {
val DEFAULT = ShortenReferences()
}
fun process(
element: String,
elementFilter: (String) -> Int = { 10 },
actionRunningMode: String = ""
): String {
return "hello"
}
fun process(
element: String,
elementFilter: (String) -> Int = { 10 },
): String {
return "hello"
}
}
fun takeReference(block: (String) -> Unit) {}
fun test() {
takeReference(ShortenReferences.DEFAULT::process)
}
@@ -0,0 +1,21 @@
package
public fun takeReference(/*0*/ block: (kotlin.String) -> kotlin.Unit): kotlin.Unit
public fun test(): kotlin.Unit
public final class ShortenReferences {
public constructor ShortenReferences()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final fun process(/*0*/ element: kotlin.String, /*1*/ elementFilter: (kotlin.String) -> kotlin.Int = ...): kotlin.String
public final fun process(/*0*/ element: kotlin.String, /*1*/ elementFilter: (kotlin.String) -> kotlin.Int = ..., /*2*/ actionRunningMode: kotlin.String = ...): kotlin.String
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
public companion object Companion {
private constructor Companion()
public final val DEFAULT: ShortenReferences
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
}