diff --git a/backend.native/compiler/ir/backend.native/src/org/jetbrains/kotlin/backend/konan/KonanLoweringPhases.kt b/backend.native/compiler/ir/backend.native/src/org/jetbrains/kotlin/backend/konan/KonanLoweringPhases.kt index 3ebc0afa6db..d42f9edd404 100644 --- a/backend.native/compiler/ir/backend.native/src/org/jetbrains/kotlin/backend/konan/KonanLoweringPhases.kt +++ b/backend.native/compiler/ir/backend.native/src/org/jetbrains/kotlin/backend/konan/KonanLoweringPhases.kt @@ -275,8 +275,11 @@ internal val compileTimeEvaluatePhase = makeKonanFileLoweringPhase( prerequisite = setOf(varargPhase) ) -internal val coroutinesPhase = makeKonanFileLoweringPhase( - ::NativeSuspendFunctionsLowering, +internal val coroutinesPhase = makeKonanFileOpPhase( + { context, irFile -> + NativeSuspendFunctionsLowering(context).lower(irFile) + RemoveSuspendLambdas().lower(irFile) + }, name = "Coroutines", description = "Coroutines lowering", prerequisite = setOf(localFunctionsPhase, finallyBlocksPhase)