It seems like it should be allowed, yet this fails to compile:
Copy code
interface Param
data class A<P : Param?>(val v: (P) -> Unit)
fun <P> create(v: (P) -> Unit) = A(v)
fun main() {
val a = create { _: Nothing? -> }
println(a.v(null)) // Null can not be a value of a non-null type Nothing
}