JVM_IR KT-36853 patch parents after tailrecPhase
This commit is contained in:
committed by
TeamCityServer
parent
34f8c7a68b
commit
ac6232b4ba
+18
@@ -12078,6 +12078,24 @@ public class FirBlackBoxCodegenTestGenerated extends AbstractFirBlackBoxCodegenT
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/inheritedFromInterfaceViaAbstractSuperclass.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("kt36853.kt")
|
||||
public void testKt36853() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("kt36853_nestedObject.kt")
|
||||
public void testKt36853_nestedObject() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853_nestedObject.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("kt36853a.kt")
|
||||
public void testKt36853a() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853a.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("kt36972_companion.kt")
|
||||
public void testKt36972_companion() throws Exception {
|
||||
|
||||
@@ -344,6 +344,7 @@ private val jvmFilePhases = listOf(
|
||||
remapObjectFieldAccesses,
|
||||
anonymousObjectSuperConstructorPhase,
|
||||
tailrecPhase,
|
||||
makePatchParentsPhase(1),
|
||||
|
||||
jvmStandardLibraryBuiltInsPhase,
|
||||
|
||||
@@ -352,7 +353,7 @@ private val jvmFilePhases = listOf(
|
||||
collectionStubMethodLowering,
|
||||
jvmInlineClassPhase,
|
||||
|
||||
makePatchParentsPhase(1),
|
||||
makePatchParentsPhase(2),
|
||||
|
||||
enumWhenPhase,
|
||||
singletonReferencesPhase,
|
||||
@@ -390,7 +391,7 @@ private val jvmFilePhases = listOf(
|
||||
innerClassesMemberBodyPhase,
|
||||
innerClassConstructorCallsPhase,
|
||||
|
||||
makePatchParentsPhase(2),
|
||||
makePatchParentsPhase(3),
|
||||
|
||||
enumClassPhase,
|
||||
objectClassPhase,
|
||||
@@ -415,7 +416,7 @@ private val jvmFilePhases = listOf(
|
||||
renameFieldsPhase,
|
||||
fakeInliningLocalVariablesLowering,
|
||||
|
||||
makePatchParentsPhase(3)
|
||||
makePatchParentsPhase(4)
|
||||
)
|
||||
|
||||
private val jvmLoweringPhases = NamedCompilerPhase(
|
||||
|
||||
@@ -0,0 +1,19 @@
|
||||
// IGNORE_BACKEND: JS_IR, WASM
|
||||
|
||||
interface IFoo {
|
||||
fun foo(): String
|
||||
}
|
||||
|
||||
tailrec fun tailrecDefault(
|
||||
fake: Int,
|
||||
x: IFoo = object : IFoo {
|
||||
override fun foo(): String = "OK"
|
||||
}
|
||||
): String {
|
||||
return if (fake == 0)
|
||||
tailrecDefault(1)
|
||||
else
|
||||
x.foo()
|
||||
}
|
||||
|
||||
fun box(): String = tailrecDefault(0)
|
||||
@@ -0,0 +1,33 @@
|
||||
// IGNORE_BACKEND: JS_IR, WASM
|
||||
|
||||
interface IFoo {
|
||||
fun foo(): String
|
||||
}
|
||||
|
||||
tailrec fun tailrecDefault(
|
||||
fake: Int,
|
||||
x: IFoo = object : IFoo {
|
||||
tailrec fun tailrecDefaultNested(
|
||||
b: Boolean,
|
||||
y: IFoo = object: IFoo {
|
||||
override fun foo() = "OK"
|
||||
}
|
||||
): String {
|
||||
return if (b)
|
||||
tailrecDefaultNested(false)
|
||||
else
|
||||
y.foo()
|
||||
}
|
||||
|
||||
override fun foo(): String {
|
||||
return tailrecDefaultNested(true)
|
||||
}
|
||||
}
|
||||
): String {
|
||||
return if (fake == 0)
|
||||
tailrecDefault(1)
|
||||
else
|
||||
x.foo()
|
||||
}
|
||||
|
||||
fun box(): String = tailrecDefault(0)
|
||||
@@ -0,0 +1,10 @@
|
||||
// IGNORE_BACKEND: JS_IR
|
||||
|
||||
tailrec fun tailrecDefault(fake: Int, fn: () -> String = { "OK" }): String {
|
||||
return if (fake == 0)
|
||||
tailrecDefault(1)
|
||||
else
|
||||
fn()
|
||||
}
|
||||
|
||||
fun box(): String = tailrecDefault(0)
|
||||
+18
@@ -12078,6 +12078,24 @@ public class BlackBoxCodegenTestGenerated extends AbstractBlackBoxCodegenTest {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/inheritedFromInterfaceViaAbstractSuperclass.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("kt36853.kt")
|
||||
public void testKt36853() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("kt36853_nestedObject.kt")
|
||||
public void testKt36853_nestedObject() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853_nestedObject.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("kt36853a.kt")
|
||||
public void testKt36853a() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853a.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("kt36972_companion.kt")
|
||||
public void testKt36972_companion() throws Exception {
|
||||
|
||||
+18
@@ -12078,6 +12078,24 @@ public class IrBlackBoxCodegenTestGenerated extends AbstractIrBlackBoxCodegenTes
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/inheritedFromInterfaceViaAbstractSuperclass.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("kt36853.kt")
|
||||
public void testKt36853() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("kt36853_nestedObject.kt")
|
||||
public void testKt36853_nestedObject() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853_nestedObject.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("kt36853a.kt")
|
||||
public void testKt36853a() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853a.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("kt36972_companion.kt")
|
||||
public void testKt36972_companion() throws Exception {
|
||||
|
||||
+20
-5
@@ -9803,6 +9803,21 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/inheritedFromInterfaceViaAbstractSuperclass.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt36853.kt")
|
||||
public void testKt36853() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt36853_nestedObject.kt")
|
||||
public void testKt36853_nestedObject() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853_nestedObject.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt36853a.kt")
|
||||
public void testKt36853a() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853a.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt36972_companion.kt")
|
||||
public void testKt36972_companion() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36972_companion.kt");
|
||||
@@ -15548,6 +15563,11 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
runTest("compiler/testData/codegen/box/inlineClasses/funInterface/argumentResult.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("returnIC.kt")
|
||||
public void ignoreReturnIC() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/inlineClasses/funInterface/returnIC.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("returnResult.kt")
|
||||
public void ignoreReturnResult() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/inlineClasses/funInterface/returnResult.kt");
|
||||
@@ -15575,11 +15595,6 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
public void testJavaSamReturnResult() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/inlineClasses/funInterface/javaSamReturnResult.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("returnIC.kt")
|
||||
public void testReturnIC() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/inlineClasses/funInterface/returnIC.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/codegen/box/inlineClasses/functionNameMangling")
|
||||
|
||||
js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/es6/semantics/IrJsCodegenBoxES6TestGenerated.java
Generated
+15
@@ -8726,6 +8726,21 @@ public class IrJsCodegenBoxES6TestGenerated extends AbstractIrJsCodegenBoxES6Tes
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/inheritedFromInterfaceViaAbstractSuperclass.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt36853.kt")
|
||||
public void testKt36853() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt36853_nestedObject.kt")
|
||||
public void testKt36853_nestedObject() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853_nestedObject.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt36853a.kt")
|
||||
public void testKt36853a() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853a.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt6382.kt")
|
||||
public void testKt6382() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt6382.kt");
|
||||
|
||||
Generated
+15
@@ -8183,6 +8183,21 @@ public class IrJsCodegenBoxTestGenerated extends AbstractIrJsCodegenBoxTest {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/inheritedFromInterfaceViaAbstractSuperclass.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt36853.kt")
|
||||
public void testKt36853() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt36853_nestedObject.kt")
|
||||
public void testKt36853_nestedObject() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853_nestedObject.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt36853a.kt")
|
||||
public void testKt36853a() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853a.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt6382.kt")
|
||||
public void testKt6382() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt6382.kt");
|
||||
|
||||
Generated
+15
@@ -8183,6 +8183,21 @@ public class JsCodegenBoxTestGenerated extends AbstractJsCodegenBoxTest {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/inheritedFromInterfaceViaAbstractSuperclass.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt36853.kt")
|
||||
public void testKt36853() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt36853_nestedObject.kt")
|
||||
public void testKt36853_nestedObject() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853_nestedObject.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt36853a.kt")
|
||||
public void testKt36853a() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853a.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt6382.kt")
|
||||
public void testKt6382() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt6382.kt");
|
||||
|
||||
js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/wasm/semantics/IrCodegenBoxWasmTestGenerated.java
Generated
+15
@@ -3884,6 +3884,21 @@ public class IrCodegenBoxWasmTestGenerated extends AbstractIrCodegenBoxWasmTest
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/inheritedFromInterfaceViaAbstractSuperclass.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt36853.kt")
|
||||
public void testKt36853() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt36853_nestedObject.kt")
|
||||
public void testKt36853_nestedObject() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853_nestedObject.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt36853a.kt")
|
||||
public void testKt36853a() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt36853a.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt6382.kt")
|
||||
public void testKt6382() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/kt6382.kt");
|
||||
|
||||
Reference in New Issue
Block a user