6e15ee8fea
synthetic_select<() -> T>(::foo) form allows to select better candidate than synthetic_select(::foo) with expect type `() -> T`
21 lines
262 B
Kotlin
Vendored
21 lines
262 B
Kotlin
Vendored
// FIR_IDENTICAL
|
|
// SKIP_TXT
|
|
|
|
// FILE: lib.kt
|
|
package lib
|
|
fun foo(x: Double): Double = x
|
|
|
|
// FILE: main.kt
|
|
|
|
import lib.*
|
|
|
|
fun foo(): Map<Int, String> = TODO()
|
|
|
|
var z: (x: Double) -> Double = { it }
|
|
|
|
fun bar() {
|
|
z = ::foo
|
|
}
|
|
|
|
fun baz(x: (Double) -> Double) {}
|