Fix debugger-related tests after dead code elimination improvements
This commit is contained in:
Vendored
-14
@@ -1,14 +0,0 @@
|
|||||||
fun box() {
|
|
||||||
lookAtMe {
|
|
||||||
12
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
inline fun lookAtMe(f: () -> Int): Int {
|
|
||||||
val a = 42
|
|
||||||
a + f() // Even this line already has meaningful instraction nop is still generated
|
|
||||||
return 13
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO: Less NOPs is better
|
|
||||||
// 2 NOP
|
|
||||||
+4
-2
@@ -1,7 +1,9 @@
|
|||||||
fun foo() {
|
fun foo() {
|
||||||
if (0 < 1) {
|
if (flag) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 2 3 5
|
val flag = true
|
||||||
|
|
||||||
|
// 2 3 5 7 7
|
||||||
+5
-3
@@ -1,15 +1,17 @@
|
|||||||
fun foo() {
|
fun foo() {
|
||||||
if (0 < 1) {
|
if (flag) {
|
||||||
System.out?.println()
|
System.out?.println()
|
||||||
} else {
|
} else {
|
||||||
System.out?.println()
|
System.out?.println()
|
||||||
}
|
}
|
||||||
|
|
||||||
val b = if (1 < 2) {
|
val b = if (flag) {
|
||||||
System.out?.println()
|
System.out?.println()
|
||||||
} else {
|
} else {
|
||||||
System.out?.println()
|
System.out?.println()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 2 3 5 6 +8 9 11 8 13
|
val flag = true
|
||||||
|
|
||||||
|
// 2 3 5 6 +8 9 11 8 13 15 15
|
||||||
@@ -1415,12 +1415,6 @@ public class BytecodeTextTestGenerated extends AbstractBytecodeTextTest {
|
|||||||
doTest(fileName);
|
doTest(fileName);
|
||||||
}
|
}
|
||||||
|
|
||||||
@TestMetadata("linenumberForNoParametersArgumentCallInExpression.kt")
|
|
||||||
public void testLinenumberForNoParametersArgumentCallInExpression() throws Exception {
|
|
||||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/bytecodeText/inline/linenumberForNoParametersArgumentCallInExpression.kt");
|
|
||||||
doTest(fileName);
|
|
||||||
}
|
|
||||||
|
|
||||||
@TestMetadata("linenumberForOneParametersArgumentCall.kt")
|
@TestMetadata("linenumberForOneParametersArgumentCall.kt")
|
||||||
public void testLinenumberForOneParametersArgumentCall() throws Exception {
|
public void testLinenumberForOneParametersArgumentCall() throws Exception {
|
||||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/bytecodeText/inline/linenumberForOneParametersArgumentCall.kt");
|
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/bytecodeText/inline/linenumberForOneParametersArgumentCall.kt");
|
||||||
|
|||||||
Reference in New Issue
Block a user