https://kotlinlang.org logo
#announcements
Title
# announcements
a

alex2069

03/09/2017, 11:46 PM
Is it possible to get a function reference of a typed function?
Copy code
class Class {
    fun <T : Any> someFun(clazz: KClass<out T>) = Unit
    fun someOtherFun() {
        val f1 = this::someFun // type inference failed
        val f2: KFunction1<@ParameterName(name = "clazz") KClass<out Any>, Unit> = this::someFun // still fails
    }
}
📡 1
1
👍 1