[K/N] Add lowered suspend function mangling to avoid clashes

This commit is contained in:
Pavel Kunyavskiy
2022-09-13 12:33:58 +02:00
committed by Space Team
parent 2d4c94a115
commit 95eaf3d234
4 changed files with 17 additions and 1 deletions
@@ -19,7 +19,7 @@ suspend fun suspendForever(): Int = suspendCoroutineUninterceptedOrReturn {
// CHECK-LABEL: define %struct.ObjHeader* @"kfun:$fooCOROUTINE
// CHECK-NOT: ; Function Attrs: {{.*}}noreturn
// CHECK-LABEL: define %struct.ObjHeader* @"kfun:#foo(){}kotlin.Nothing"
// CHECK-LABEL: define %struct.ObjHeader* @"kfun:#foo#suspend(kotlin.coroutines.Continuation<kotlin.Nothing>){}kotlin.Any"
suspend fun foo(): Nothing {
suspendForever()
throw Error()