Add test for KT-46225
This commit is contained in:
committed by
TeamCityServer
parent
38f21b7139
commit
0621b79505
+6
@@ -12952,6 +12952,12 @@ public class FirBlackBoxCodegenTestGenerated extends AbstractFirBlackBoxCodegenT
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/callDefaultFromInitializer.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("captureInTailrec.kt")
|
||||
public void testCaptureInTailrec() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/captureInTailrec.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("complexInheritance.kt")
|
||||
public void testComplexInheritance() throws Exception {
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
// IGNORE_BACKEND: JS_IR
|
||||
// IGNORE_BACKEND: WASM
|
||||
|
||||
// KT-46225
|
||||
|
||||
class C
|
||||
|
||||
fun box(): String =
|
||||
C().foo("O")
|
||||
|
||||
tailrec fun C.foo(x: String, f: (String) -> String = { bar(it) }): String =
|
||||
if (x.length < 2) foo(f(x)) else x
|
||||
|
||||
fun C.bar(s: String): String =
|
||||
s + "K"
|
||||
+6
@@ -12874,6 +12874,12 @@ public class BlackBoxCodegenTestGenerated extends AbstractBlackBoxCodegenTest {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/callDefaultFromInitializer.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("captureInTailrec.kt")
|
||||
public void testCaptureInTailrec() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/captureInTailrec.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("complexInheritance.kt")
|
||||
public void testComplexInheritance() throws Exception {
|
||||
|
||||
+6
@@ -12952,6 +12952,12 @@ public class IrBlackBoxCodegenTestGenerated extends AbstractIrBlackBoxCodegenTes
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/callDefaultFromInitializer.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("captureInTailrec.kt")
|
||||
public void testCaptureInTailrec() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/captureInTailrec.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("complexInheritance.kt")
|
||||
public void testComplexInheritance() throws Exception {
|
||||
|
||||
+5
@@ -10433,6 +10433,11 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/callDefaultFromInitializer.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("captureInTailrec.kt")
|
||||
public void testCaptureInTailrec() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/captureInTailrec.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("complexInheritance.kt")
|
||||
public void testComplexInheritance() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/complexInheritance.kt");
|
||||
|
||||
js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/es6/semantics/IrJsCodegenBoxES6TestGenerated.java
Generated
+5
@@ -9267,6 +9267,11 @@ public class IrJsCodegenBoxES6TestGenerated extends AbstractIrJsCodegenBoxES6Tes
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/callDefaultFromInitializer.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("captureInTailrec.kt")
|
||||
public void testCaptureInTailrec() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/captureInTailrec.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("complexInheritance.kt")
|
||||
public void testComplexInheritance() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/complexInheritance.kt");
|
||||
|
||||
Generated
+5
@@ -8673,6 +8673,11 @@ public class IrJsCodegenBoxTestGenerated extends AbstractIrJsCodegenBoxTest {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/callDefaultFromInitializer.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("captureInTailrec.kt")
|
||||
public void testCaptureInTailrec() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/captureInTailrec.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("complexInheritance.kt")
|
||||
public void testComplexInheritance() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/complexInheritance.kt");
|
||||
|
||||
Generated
+5
@@ -8638,6 +8638,11 @@ public class JsCodegenBoxTestGenerated extends AbstractJsCodegenBoxTest {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/callDefaultFromInitializer.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("captureInTailrec.kt")
|
||||
public void testCaptureInTailrec() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/captureInTailrec.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("complexInheritance.kt")
|
||||
public void testComplexInheritance() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/complexInheritance.kt");
|
||||
|
||||
js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/wasm/semantics/IrCodegenBoxWasmTestGenerated.java
Generated
+5
@@ -5154,6 +5154,11 @@ public class IrCodegenBoxWasmTestGenerated extends AbstractIrCodegenBoxWasmTest
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/callDefaultFromInitializer.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("captureInTailrec.kt")
|
||||
public void testCaptureInTailrec() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/captureInTailrec.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("complexInheritance.kt")
|
||||
public void testComplexInheritance() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/defaultArguments/complexInheritance.kt");
|
||||
|
||||
Reference in New Issue
Block a user