chore: remove unused break statements from inlined functions bodies.
This commit is contained in:
@@ -4844,6 +4844,12 @@ public class BoxJsTestGenerated extends AbstractBoxJsTest {
|
||||
runTest("js/js.translator/testData/box/inline/lambdaReassignmentWithCapture.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("lastLabeledReturn.kt")
|
||||
public void testLastLabeledReturn() throws Exception {
|
||||
runTest("js/js.translator/testData/box/inline/lastLabeledReturn.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("localDeclarationsClash.kt")
|
||||
public void testLocalDeclarationsClash() throws Exception {
|
||||
|
||||
+6
@@ -5222,6 +5222,12 @@ public class IrBoxJsTestGenerated extends AbstractIrBoxJsTest {
|
||||
runTest("js/js.translator/testData/box/inline/lambdaReassignmentWithCapture.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("lastLabeledReturn.kt")
|
||||
public void testLastLabeledReturn() throws Exception {
|
||||
runTest("js/js.translator/testData/box/inline/lastLabeledReturn.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("localDeclarationsClash.kt")
|
||||
public void testLocalDeclarationsClash() throws Exception {
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
inline fun foo(l: () -> Unit) { l() }
|
||||
inline fun bar(l: () -> Unit) { l() }
|
||||
|
||||
fun box(): String {
|
||||
foo {
|
||||
bar {
|
||||
return@foo;
|
||||
}
|
||||
return "Failed: labeled return was not added"
|
||||
}
|
||||
return "OK"
|
||||
}
|
||||
Reference in New Issue
Block a user