JVM_IR KT-45377 rewrite constants again after AddContinuationLowering
This commit is contained in:
committed by
TeamCityServer
parent
0f2aca3280
commit
4f250ed498
@@ -336,7 +336,7 @@ private val jvmFilePhases = listOf(
|
||||
functionReferencePhase,
|
||||
suspendLambdaPhase,
|
||||
propertyReferencePhase,
|
||||
constPhase,
|
||||
constPhase1,
|
||||
// TODO: merge the next three phases together, as visitors behave incorrectly between them
|
||||
// (backing fields moved out of companion objects are reachable by two paths):
|
||||
moveOrCopyCompanionObjectFieldsPhase,
|
||||
@@ -386,6 +386,7 @@ private val jvmFilePhases = listOf(
|
||||
|
||||
tailCallOptimizationPhase,
|
||||
addContinuationPhase,
|
||||
constPhase2, // handle const properties in default arguments of "original" suspend funs
|
||||
|
||||
innerClassesPhase,
|
||||
innerClassesMemberBodyPhase,
|
||||
|
||||
@@ -20,9 +20,15 @@ import org.jetbrains.kotlin.ir.types.isPrimitiveType
|
||||
import org.jetbrains.kotlin.ir.types.isStringClassType
|
||||
import org.jetbrains.kotlin.ir.visitors.IrElementTransformerVoid
|
||||
|
||||
internal val constPhase = makeIrFilePhase(
|
||||
internal val constPhase1 = makeIrFilePhase(
|
||||
::ConstLowering,
|
||||
name = "Const",
|
||||
name = "Const1",
|
||||
description = "Substitute calls to const properties with constant values"
|
||||
)
|
||||
|
||||
internal val constPhase2 = makeIrFilePhase(
|
||||
::ConstLowering,
|
||||
name = "Const2",
|
||||
description = "Substitute calls to const properties with constant values"
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user