Fix order of fixing type variables for callable references. KT-25433 Fixed

This commit is contained in:
Dmitriy Novozhilov
2019-02-27 18:02:13 +03:00
parent 735f86a50e
commit 7072b9d179
7 changed files with 75 additions and 0 deletions
@@ -0,0 +1,17 @@
// !WITH_NEW_INFERENCE
// !DIAGNOSTICS: -UNUSED_PARAMETER
// Issue: KT-25433
import kotlin.reflect.*
fun <T, R> hidden(nameProp: KProperty1<T, R>, value: R) {}
fun <T, R> hiddenFun(nameFunc: KFunction1<T, R>, value: R) {}
class App(val nullable: String?) {
fun nullableFun(): String? = null
}
fun test() {
hidden(App::nullable, "foo")
hiddenFun(App::nullableFun, "foo")
}
@@ -0,0 +1,14 @@
package
public fun </*0*/ T, /*1*/ R> hidden(/*0*/ nameProp: kotlin.reflect.KProperty1<T, R>, /*1*/ value: R): kotlin.Unit
public fun </*0*/ T, /*1*/ R> hiddenFun(/*0*/ nameFunc: kotlin.reflect.KFunction1<T, R>, /*1*/ value: R): kotlin.Unit
public fun test(): kotlin.Unit
public final class App {
public constructor App(/*0*/ nullable: kotlin.String?)
public final val nullable: kotlin.String?
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 nullableFun(): kotlin.String?
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}