Files
2024-02-16 10:19:38 +00:00

59 lines
707 B
Kotlin
Vendored

fun fn0(): Int {
return 1
}
fun fn1(x: Int): Int {
return 1
}
fun fnv(vararg xs: Int): Int {
return 1
}
fun test0() {
return useUnit0(fn = { // BLOCK
local fun fn0() {
fn0() /*~> Unit */
}
::fn0
})
}
fun test1() {
return useUnit1(fn = { // BLOCK
local fun fn1(p0: Int) {
fn1(x = p0) /*~> Unit */
}
::fn1
})
}
fun testV0() {
return useUnit0(fn = { // BLOCK
local fun fnv() {
fnv() /*~> Unit */
}
::fnv
})
}
fun testV1() {
return useUnit1(fn = { // BLOCK
local fun fnv(p0: Int) {
fnv(xs = [p0]) /*~> Unit */
}
::fnv
})
}
fun useUnit0(fn: Function0<Unit>) {
}
fun useUnit1(fn: Function1<Int, Unit>) {
}