FIR: Properly build nullable suspend function types, and aggregate

modifiers and annotations within KtTypeReference/REFERENCE_TYPE nodes.
This commit is contained in:
Mark Punzalan
2021-04-08 09:35:10 +00:00
committed by TeamCityServer
parent 9cf5ac1fbd
commit 9a4742c08d
35 changed files with 734 additions and 28 deletions
@@ -1,6 +1,12 @@
fun useSuspend(fn: SuspendFunction0<Unit>) {
}
fun useSuspendNullable(fn: SuspendFunction0<Unit>?) {
}
fun useSuspendNestedNullable(fn: SuspendFunction0<Unit>?) {
}
fun useSuspendInt(fn: SuspendFunction1<Int, Unit>) {
}
@@ -116,3 +122,22 @@ fun testWithBoundReceiver() {
})
}
fun testNullableParam() {
useSuspendNullable(fn = { // BLOCK
local suspend fun foo1() {
foo1()
}
::foo1
})
}
fun testNestedNullableParam() {
useSuspendNestedNullable(fn = { // BLOCK
local suspend fun foo1() {
foo1()
}
::foo1
})
}