[K/N] Extract const val initializers to place of usage
This would make behaviour more consistent with jvm. There is still a difference in behaviour about point where side effects happen. ^KT-52970
This commit is contained in:
+12
@@ -25251,6 +25251,18 @@ public class JsCodegenBoxTestGenerated extends AbstractJsCodegenBoxTest {
|
||||
public void testConstPropertyAccessor() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/properties/const/constPropertyAccessor.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("intermoduleInlineConst.kt")
|
||||
public void testIntermoduleInlineConst() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/properties/const/intermoduleInlineConst.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("kt52970.kt")
|
||||
public void testKt52970() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/properties/const/kt52970.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@Nested
|
||||
|
||||
+12
@@ -25245,6 +25245,18 @@ public class IrJsCodegenBoxTestGenerated extends AbstractIrJsCodegenBoxTest {
|
||||
public void testConstPropertyAccessor() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/properties/const/constPropertyAccessor.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("intermoduleInlineConst.kt")
|
||||
public void testIntermoduleInlineConst() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/properties/const/intermoduleInlineConst.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("kt52970.kt")
|
||||
public void testKt52970() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/properties/const/kt52970.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@Nested
|
||||
|
||||
+10
@@ -22532,6 +22532,16 @@ public class IrCodegenBoxWasmTestGenerated extends AbstractIrCodegenBoxWasmTest
|
||||
public void testConstPropertyAccessor() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/properties/const/constPropertyAccessor.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("intermoduleInlineConst.kt")
|
||||
public void testIntermoduleInlineConst() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/properties/const/intermoduleInlineConst.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt52970.kt")
|
||||
public void testKt52970() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/properties/const/kt52970.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/codegen/box/properties/lateinit")
|
||||
|
||||
Reference in New Issue
Block a user