diff --git a/compiler/testData/debug/localVariables/assignment.kt b/compiler/testData/debug/localVariables/assignment.kt index 42df0b49887..89e1db19e70 100644 --- a/compiler/testData/debug/localVariables/assignment.kt +++ b/compiler/testData/debug/localVariables/assignment.kt @@ -13,7 +13,7 @@ fun box(): String { return o + k } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:8 box: // test.kt:6 box: // test.kt:11 box: o:java.lang.String="O":java.lang.String diff --git a/compiler/testData/debug/localVariables/catchClause.kt b/compiler/testData/debug/localVariables/catchClause.kt index 9a5b36e7e10..d8498f43f08 100644 --- a/compiler/testData/debug/localVariables/catchClause.kt +++ b/compiler/testData/debug/localVariables/catchClause.kt @@ -10,7 +10,7 @@ fun box() { } } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:3 box: // test.kt:4 box: // test.kt:5 box: a:int=1:int diff --git a/compiler/testData/debug/localVariables/constructors/multipleConstructors.kt b/compiler/testData/debug/localVariables/constructors/multipleConstructors.kt index 4e97abd7255..9b6c343e3bc 100644 --- a/compiler/testData/debug/localVariables/constructors/multipleConstructors.kt +++ b/compiler/testData/debug/localVariables/constructors/multipleConstructors.kt @@ -14,16 +14,14 @@ fun box() { Derived(4, 5) } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:13 box: // test.kt:5 : p:int=3:int // test.kt:4 : // test.kt:2 : i:int=1:int // test.kt:4 : // test.kt:6 : p:int=3:int -// EXPECTATIONS JVM_IR // test.kt:7 : p:int=3:int, a:int=2:int -// EXPECTATIONS JVM JVM_IR // test.kt:13 box: // test.kt:14 box: // test.kt:9 : p1:int=4:int, p2:int=5:int diff --git a/compiler/testData/debug/localVariables/constructors/property.kt b/compiler/testData/debug/localVariables/constructors/property.kt index 6b237ab3f4a..ad5a3b70739 100644 --- a/compiler/testData/debug/localVariables/constructors/property.kt +++ b/compiler/testData/debug/localVariables/constructors/property.kt @@ -5,7 +5,7 @@ fun box() { F("foo") } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:5 box: // test.kt:2 : a:java.lang.String="foo":java.lang.String // test.kt:5 box: diff --git a/compiler/testData/debug/localVariables/copyFunction.kt b/compiler/testData/debug/localVariables/copyFunction.kt index a86e40c515e..2afa26045f4 100644 --- a/compiler/testData/debug/localVariables/copyFunction.kt +++ b/compiler/testData/debug/localVariables/copyFunction.kt @@ -7,7 +7,7 @@ fun box() { val b = a.copy(b = 3.0) } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:6 box: // test.kt:3 : a:double=1.0:double, b:double=2.0:double // test.kt:6 box: diff --git a/compiler/testData/debug/localVariables/destructuring/assignment.kt b/compiler/testData/debug/localVariables/destructuring/assignment.kt index 44f8d2450f6..b1b285b5c00 100644 --- a/compiler/testData/debug/localVariables/destructuring/assignment.kt +++ b/compiler/testData/debug/localVariables/destructuring/assignment.kt @@ -9,7 +9,7 @@ fun box(): String { return o + k } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:5 box: // test.kt:7 box: p:kotlin.Pair=kotlin.Pair // test.kt:9 box: p:kotlin.Pair=kotlin.Pair, o:java.lang.String="O":java.lang.String, k:java.lang.String="K":java.lang.String diff --git a/compiler/testData/debug/localVariables/destructuring/assignmentCustomComponentNs.kt b/compiler/testData/debug/localVariables/destructuring/assignmentCustomComponentNs.kt index 5b6ddd26491..c7a60442e21 100644 --- a/compiler/testData/debug/localVariables/destructuring/assignmentCustomComponentNs.kt +++ b/compiler/testData/debug/localVariables/destructuring/assignmentCustomComponentNs.kt @@ -15,7 +15,7 @@ fun box(): String { return o + k } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:13 box: // test.kt:2 : x:java.lang.String="X":java.lang.String, y:java.lang.String="Y":java.lang.String // test.kt:13 box: @@ -23,11 +23,7 @@ fun box(): String { // test.kt:4 component1: // test.kt:14 box: p:MyPair=MyPair // test.kt:8 component2: -// EXPECTATIONS JVM -// test.kt:14 box: p:MyPair=MyPair -// EXPECTATIONS JVM_IR // test.kt:14 box: p:MyPair=MyPair, o:java.lang.String="O":java.lang.String -// EXPECTATIONS JVM JVM_IR // test.kt:15 box: p:MyPair=MyPair, o:java.lang.String="O":java.lang.String, k:java.lang.String="K":java.lang.String // EXPECTATIONS JS_IR diff --git a/compiler/testData/debug/localVariables/destructuring/assignmentCustomComponentNsMultiline.kt b/compiler/testData/debug/localVariables/destructuring/assignmentCustomComponentNsMultiline.kt index c3e9c4e0859..afc37e3f4be 100644 --- a/compiler/testData/debug/localVariables/destructuring/assignmentCustomComponentNsMultiline.kt +++ b/compiler/testData/debug/localVariables/destructuring/assignmentCustomComponentNsMultiline.kt @@ -24,7 +24,7 @@ fun box(): String { return o + k } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:15 box: // test.kt:4 : x:java.lang.String="X":java.lang.String, y:java.lang.String="Y":java.lang.String // test.kt:15 box: @@ -32,11 +32,7 @@ fun box(): String { // test.kt:6 component1: // test.kt:18 box: p:MyPair=MyPair // test.kt:10 component2: -// EXPECTATIONS JVM -// test.kt:20 box: p:MyPair=MyPair -// EXPECTATIONS JVM_IR // test.kt:20 box: p:MyPair=MyPair, o:java.lang.String="O":java.lang.String -// EXPECTATIONS JVM JVM_IR // test.kt:24 box: p:MyPair=MyPair, o:java.lang.String="O":java.lang.String, k:java.lang.String="K":java.lang.String // EXPECTATIONS JS_IR diff --git a/compiler/testData/debug/localVariables/destructuring/assignmentMultiline.kt b/compiler/testData/debug/localVariables/destructuring/assignmentMultiline.kt index 794b2d46b2f..34c4aeb4ce7 100644 --- a/compiler/testData/debug/localVariables/destructuring/assignmentMultiline.kt +++ b/compiler/testData/debug/localVariables/destructuring/assignmentMultiline.kt @@ -17,15 +17,11 @@ fun box(): String { return o + k } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:6 box: // test.kt:15 box: p:kotlin.Pair=kotlin.Pair // test.kt:10 box: p:kotlin.Pair=kotlin.Pair -// EXPECTATIONS JVM -// test.kt:12 box: p:kotlin.Pair=kotlin.Pair -// EXPECTATIONS JVM_IR // test.kt:12 box: p:kotlin.Pair=kotlin.Pair, o:java.lang.String="O":java.lang.String -// EXPECTATIONS JVM JVM_IR // test.kt:17 box: p:kotlin.Pair=kotlin.Pair, o:java.lang.String="O":java.lang.String, k:java.lang.String="K":java.lang.String // EXPECTATIONS JS_IR diff --git a/compiler/testData/debug/localVariables/destructuring/assignmentUnderscoreNames.kt b/compiler/testData/debug/localVariables/destructuring/assignmentUnderscoreNames.kt index fb337e4a668..177eb9e088d 100644 --- a/compiler/testData/debug/localVariables/destructuring/assignmentUnderscoreNames.kt +++ b/compiler/testData/debug/localVariables/destructuring/assignmentUnderscoreNames.kt @@ -9,7 +9,7 @@ fun box(): String { return o + k } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:5 box: // test.kt:7 box: p:kotlin.Triple=kotlin.Triple // test.kt:9 box: p:kotlin.Triple=kotlin.Triple, o:java.lang.String="O":java.lang.String, k:java.lang.String="K":java.lang.String diff --git a/compiler/testData/debug/localVariables/destructuring/assignmentUnderscoreNamesMultiline.kt b/compiler/testData/debug/localVariables/destructuring/assignmentUnderscoreNamesMultiline.kt index 3e53e8804f1..ecdfb1c7e27 100644 --- a/compiler/testData/debug/localVariables/destructuring/assignmentUnderscoreNamesMultiline.kt +++ b/compiler/testData/debug/localVariables/destructuring/assignmentUnderscoreNamesMultiline.kt @@ -19,15 +19,11 @@ fun box(): String { return o + k } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:6 box: // test.kt:17 box: p:kotlin.Triple=kotlin.Triple // test.kt:12 box: p:kotlin.Triple=kotlin.Triple -// EXPECTATIONS JVM -// test.kt:14 box: p:kotlin.Triple=kotlin.Triple -// EXPECTATIONS JVM_IR // test.kt:14 box: p:kotlin.Triple=kotlin.Triple, o:java.lang.String="O":java.lang.String -// EXPECTATIONS JVM JVM_IR // test.kt:19 box: p:kotlin.Triple=kotlin.Triple, o:java.lang.String="O":java.lang.String, k:java.lang.String="K":java.lang.String // EXPECTATIONS JS_IR diff --git a/compiler/testData/debug/localVariables/destructuring/forLoop.kt b/compiler/testData/debug/localVariables/destructuring/forLoop.kt index aa02ad94c08..bb3be7d2ee1 100644 --- a/compiler/testData/debug/localVariables/destructuring/forLoop.kt +++ b/compiler/testData/debug/localVariables/destructuring/forLoop.kt @@ -8,7 +8,7 @@ fun box() { } } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:5 box: // test.kt:6 box: map:java.util.Map=java.util.Collections$SingletonMap // test.kt:7 box: map:java.util.Map=java.util.Collections$SingletonMap, a:java.lang.String="1":java.lang.String, b:java.lang.String="23":java.lang.String diff --git a/compiler/testData/debug/localVariables/destructuring/forLoopMultiline.kt b/compiler/testData/debug/localVariables/destructuring/forLoopMultiline.kt index dca8e5db65f..a8c75e36672 100644 --- a/compiler/testData/debug/localVariables/destructuring/forLoopMultiline.kt +++ b/compiler/testData/debug/localVariables/destructuring/forLoopMultiline.kt @@ -1,5 +1,5 @@ // WITH_STDLIB -// IGNORE_BACKEND: JVM_IR +// IGNORE_BACKEND_K2: JVM_IR // FILE: test.kt fun box() { val map: Map = mapOf("1" to "23") @@ -19,25 +19,15 @@ fun box() { } } -// EXPECTATIONS JVM +// EXPECTATIONS JVM_IR // test.kt:5 box: // test.kt:15 box: map:java.util.Map=java.util.Collections$SingletonMap -// test.kt:7 box: map:java.util.Map=java.util.Collections$SingletonMap // test.kt:10 box: map:java.util.Map=java.util.Collections$SingletonMap -// test.kt:12 box: map:java.util.Map=java.util.Collections$SingletonMap +// test.kt:12 box: map:java.util.Map=java.util.Collections$SingletonMap, a:java.lang.String="1":java.lang.String // test.kt:18 box: map:java.util.Map=java.util.Collections$SingletonMap, a:java.lang.String="1":java.lang.String, b:java.lang.String="23":java.lang.String -// test.kt:7 box: map:java.util.Map=java.util.Collections$SingletonMap +// test.kt:15 box: map:java.util.Map=java.util.Collections$SingletonMap // test.kt:20 box: map:java.util.Map=java.util.Collections$SingletonMap -// EXPECTATIONS JVM_IR -// test.kt:6 box: -// test.kt:16 box: map:java.util.Map=java.util.Collections$SingletonMap -// test.kt:11 box: map:java.util.Map=java.util.Collections$SingletonMap -// test.kt:13 box: map:java.util.Map=java.util.Collections$SingletonMap, a:java.lang.String="1":java.lang.String -// test.kt:19 box: map:java.util.Map=java.util.Collections$SingletonMap, a:java.lang.String="1":java.lang.String, b:java.lang.String="23":java.lang.String -// test.kt:8 box: map:java.util.Map=java.util.Collections$SingletonMap -// test.kt:21 box: map:java.util.Map=java.util.Collections$SingletonMap - // EXPECTATIONS JS_IR // test.kt:5 box: // test.kt:5 box: diff --git a/compiler/testData/debug/localVariables/destructuring/lambda.kt b/compiler/testData/debug/localVariables/destructuring/lambda.kt index 9bb6622321a..9273130acfd 100644 --- a/compiler/testData/debug/localVariables/destructuring/lambda.kt +++ b/compiler/testData/debug/localVariables/destructuring/lambda.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND: JVM_IR + // FILE: test.kt data class A(val x: String, val y: Int) @@ -8,26 +8,16 @@ fun box() { foo(A("O", 123)) { (x, y) -> x + y } } -// EXPECTATIONS JVM +// EXPECTATIONS JVM_IR // test.kt:8 box: // test.kt:3 : x:java.lang.String="O":java.lang.String, y:int=123:int // test.kt:8 box: // test.kt:5 foo: a:A=A, block:kotlin.jvm.functions.Function1=TestKt$box$1 -// test.kt:8 invoke: $dstr$x$y:A=A +// test.kt:8 invoke: // test.kt:5 foo: a:A=A, block:kotlin.jvm.functions.Function1=TestKt$box$1 // test.kt:8 box: // test.kt:9 box: -// EXPECTATIONS JVM_IR -// test.kt:9 box: -// test.kt:4 : x:java.lang.String="O":java.lang.String, y:int=123:int -// test.kt:9 box: -// test.kt:6 foo: a:A=A, block:kotlin.jvm.functions.Function1=TestKt$box$1 -// test.kt:9 invoke: x:java.lang.String="O":java.lang.String, y:int=123:int -// test.kt:6 foo: a:A=A, block:kotlin.jvm.functions.Function1=TestKt$box$1 -// test.kt:9 box: -// test.kt:10 box: - // EXPECTATIONS JS_IR // test.kt:8 box: // test.kt:3 : x="O":kotlin.String, y=123:number @@ -40,4 +30,4 @@ fun box() { // test.kt:8 box$lambda: x="O":kotlin.String // test.kt:1 component2: // test.kt:8 box$lambda: x="O":kotlin.String, y=123:number -// test.kt:9 box: \ No newline at end of file +// test.kt:9 box: diff --git a/compiler/testData/debug/localVariables/destructuring/lambdaCustomComponentNs.kt b/compiler/testData/debug/localVariables/destructuring/lambdaCustomComponentNs.kt index c8b64a5c3e7..71f8a948189 100644 --- a/compiler/testData/debug/localVariables/destructuring/lambdaCustomComponentNs.kt +++ b/compiler/testData/debug/localVariables/destructuring/lambdaCustomComponentNs.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND: JVM_IR + // FILE: test.kt class MyPair(val x: String, val y: String) { operator fun component1(): String { @@ -16,34 +16,20 @@ fun box() { foo(MyPair("X", "Y")) { (x, y) -> x + y } } -// EXPECTATIONS JVM +// EXPECTATIONS JVM_IR // test.kt:16 box: // test.kt:3 : x:java.lang.String="X":java.lang.String, y:java.lang.String="Y":java.lang.String // test.kt:16 box: // test.kt:13 foo: a:MyPair=MyPair, block:kotlin.jvm.functions.Function1=TestKt$box$1 -// test.kt:16 invoke: $dstr$x$y:MyPair=MyPair +// test.kt:16 invoke: // test.kt:5 component1: -// test.kt:16 invoke: $dstr$x$y:MyPair=MyPair +// test.kt:16 invoke: // test.kt:9 component2: -// test.kt:16 invoke: $dstr$x$y:MyPair=MyPair +// test.kt:16 invoke: x:java.lang.String="O":java.lang.String // test.kt:13 foo: a:MyPair=MyPair, block:kotlin.jvm.functions.Function1=TestKt$box$1 // test.kt:16 box: // test.kt:17 box: -// EXPECTATIONS JVM_IR -// test.kt:17 box: -// test.kt:4 : x:java.lang.String="X":java.lang.String, y:java.lang.String="Y":java.lang.String -// test.kt:17 box: -// test.kt:14 foo: a:MyPair=MyPair, block:kotlin.jvm.functions.Function1=TestKt$box$1 -// test.kt:17 invoke: -// test.kt:6 component1: -// test.kt:17 invoke: -// test.kt:10 component2: -// test.kt:17 invoke: x:java.lang.String="O":java.lang.String, y:java.lang.String="K":java.lang.String -// test.kt:14 foo: a:MyPair=MyPair, block:kotlin.jvm.functions.Function1=TestKt$box$1 -// test.kt:17 box: -// test.kt:18 box: - // EXPECTATIONS JS_IR // test.kt:16 box: // test.kt:3 : x="X":kotlin.String, y="Y":kotlin.String @@ -56,4 +42,4 @@ fun box() { // test.kt:16 box$lambda: x="O":kotlin.String // test.kt:9 component2: // test.kt:16 box$lambda: x="O":kotlin.String, y="K":kotlin.String -// test.kt:17 box: \ No newline at end of file +// test.kt:17 box: diff --git a/compiler/testData/debug/localVariables/destructuring/lambdaCustomComponentNsMultiline.kt b/compiler/testData/debug/localVariables/destructuring/lambdaCustomComponentNsMultiline.kt index becf7266c62..fef555a5ad5 100644 --- a/compiler/testData/debug/localVariables/destructuring/lambdaCustomComponentNsMultiline.kt +++ b/compiler/testData/debug/localVariables/destructuring/lambdaCustomComponentNsMultiline.kt @@ -26,21 +26,6 @@ fun box() { } } -// EXPECTATIONS JVM -// test.kt:17 box: -// test.kt:4 : x:java.lang.String="X":java.lang.String, y:java.lang.String="Y":java.lang.String -// test.kt:18 box: -// test.kt:17 box: -// test.kt:14 foo: a:MyPair=MyPair, block:kotlin.jvm.functions.Function1=TestKt$box$1 -// test.kt:25 invoke: $dstr$x$y:MyPair=MyPair -// test.kt:6 component1: -// test.kt:25 invoke: $dstr$x$y:MyPair=MyPair -// test.kt:10 component2: -// test.kt:25 invoke: $dstr$x$y:MyPair=MyPair -// test.kt:14 foo: a:MyPair=MyPair, block:kotlin.jvm.functions.Function1=TestKt$box$1 -// test.kt:17 box: -// test.kt:27 box: - // EXPECTATIONS JVM_IR // test.kt:17 box: // test.kt:4 : x:java.lang.String="X":java.lang.String, y:java.lang.String="Y":java.lang.String diff --git a/compiler/testData/debug/localVariables/destructuring/lambdaMultiline.kt b/compiler/testData/debug/localVariables/destructuring/lambdaMultiline.kt index 767841542ec..e378ea42e1a 100644 --- a/compiler/testData/debug/localVariables/destructuring/lambdaMultiline.kt +++ b/compiler/testData/debug/localVariables/destructuring/lambdaMultiline.kt @@ -20,17 +20,6 @@ fun box() { return } -// EXPECTATIONS JVM -// test.kt:9 box: -// test.kt:4 : x:java.lang.String="O":java.lang.String, y:int=123:int -// test.kt:10 box: -// test.kt:9 box: -// test.kt:6 foo: a:A=A, block:kotlin.jvm.functions.Function1=TestKt$box$1 -// test.kt:17 invoke: $dstr$x$y:A=A -// test.kt:6 foo: a:A=A, block:kotlin.jvm.functions.Function1=TestKt$box$1 -// test.kt:9 box: -// test.kt:20 box: - // EXPECTATIONS JVM_IR // test.kt:9 box: // test.kt:4 : x:java.lang.String="O":java.lang.String, y:int=123:int diff --git a/compiler/testData/debug/localVariables/destructuring/lambdaMultipleDestructs.kt b/compiler/testData/debug/localVariables/destructuring/lambdaMultipleDestructs.kt index a392586c1b5..a61a3e0b4ee 100644 --- a/compiler/testData/debug/localVariables/destructuring/lambdaMultipleDestructs.kt +++ b/compiler/testData/debug/localVariables/destructuring/lambdaMultipleDestructs.kt @@ -8,18 +8,6 @@ fun box() { foo(A("O", 123), A("K", 877)) { (x, y), (z, w) -> (x + z) + (y + w) } } -// EXPECTATIONS JVM -// test.kt:8 box: -// test.kt:3 : x:java.lang.String="O":java.lang.String, y:int=123:int -// test.kt:8 box: -// test.kt:3 : x:java.lang.String="K":java.lang.String, y:int=877:int -// test.kt:8 box: -// test.kt:5 foo: a:A=A, b:A=A, block:kotlin.jvm.functions.Function2=TestKt$box$1 -// test.kt:8 invoke: $dstr$x$y:A=A, $dstr$z$w:A=A -// test.kt:5 foo: a:A=A, b:A=A, block:kotlin.jvm.functions.Function2=TestKt$box$1 -// test.kt:8 box: -// test.kt:9 box: - // EXPECTATIONS JVM_IR // test.kt:9 box: // test.kt:4 : x:java.lang.String="O":java.lang.String, y:int=123:int @@ -52,4 +40,4 @@ fun box() { // test.kt:8 box$lambda: x="O":kotlin.String, y=123:number, z="K":kotlin.String // test.kt:1 component2: // test.kt:8 box$lambda: x="O":kotlin.String, y=123:number, z="K":kotlin.String, w=877:number -// test.kt:9 box: \ No newline at end of file +// test.kt:9 box: diff --git a/compiler/testData/debug/localVariables/directInvoke.kt b/compiler/testData/debug/localVariables/directInvoke.kt index c097e35b41b..5d9853d5bae 100644 --- a/compiler/testData/debug/localVariables/directInvoke.kt +++ b/compiler/testData/debug/localVariables/directInvoke.kt @@ -5,16 +5,9 @@ fun box() { }("O", "K") } -// EXPECTATIONS JVM JVM_IR // EXPECTATIONS JVM_IR // test.kt:5 box: // test.kt:4 box: a:java.lang.String="O":java.lang.String, b:java.lang.String="K":java.lang.String -// EXPECTATIONS JVM -// test.kt:3 box: -// test.kt:5 box: -// test.kt:4 invoke: a:java.lang.String="O":java.lang.String, b:java.lang.String="K":java.lang.String -// test.kt:5 box: -// EXPECTATIONS JVM JVM_IR // test.kt:6 box: // EXPECTATIONS JS_IR diff --git a/compiler/testData/debug/localVariables/doWhile.kt b/compiler/testData/debug/localVariables/doWhile.kt index 8d6afc9a9ef..227734e6453 100644 --- a/compiler/testData/debug/localVariables/doWhile.kt +++ b/compiler/testData/debug/localVariables/doWhile.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND: JVM + // FILE: test.kt fun shouldContinue(i: Int) = i < 1 @@ -16,7 +16,7 @@ fun box() { } while (x < z) } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:6 box: // test.kt:8 box: x:int=0:int // test.kt:9 box: x:int=0:int, z:int=2:int diff --git a/compiler/testData/debug/localVariables/forLoopMultiline.kt b/compiler/testData/debug/localVariables/forLoopMultiline.kt index 32eb76a5e77..f0469d2bfb3 100644 --- a/compiler/testData/debug/localVariables/forLoopMultiline.kt +++ b/compiler/testData/debug/localVariables/forLoopMultiline.kt @@ -1,5 +1,5 @@ // WITH_STDLIB -// IGNORE_BACKEND: JVM_IR + // FILE: test.kt fun box() { val map: Map = mapOf("1" to "23") @@ -15,20 +15,12 @@ fun box() { } } -// EXPECTATIONS JVM -// test.kt:5 box: -// test.kt:11 box: map:java.util.Map=java.util.Collections$SingletonMap -// test.kt:7 box: map:java.util.Map=java.util.Collections$SingletonMap -// test.kt:14 box: map:java.util.Map=java.util.Collections$SingletonMap, e:java.util.Map$Entry=java.util.AbstractMap$SimpleImmutableEntry -// test.kt:7 box: map:java.util.Map=java.util.Collections$SingletonMap -// test.kt:16 box: map:java.util.Map=java.util.Collections$SingletonMap - // EXPECTATIONS JVM_IR // test.kt:5 box: // test.kt:11 box: map:java.util.Map=java.util.Collections$SingletonMap -// test.kt:7 box: map:java.util.Map=java.util.Collections$SingletonMap +// test.kt:9 box: map:java.util.Map=java.util.Collections$SingletonMap // test.kt:14 box: map:java.util.Map=java.util.Collections$SingletonMap, e:java.util.Map$Entry=java.util.AbstractMap$SimpleImmutableEntry -// test.kt:7 box: map:java.util.Map=java.util.Collections$SingletonMap +// test.kt:11 box: map:java.util.Map=java.util.Collections$SingletonMap // test.kt:16 box: map:java.util.Map=java.util.Collections$SingletonMap // EXPECTATIONS JS_IR diff --git a/compiler/testData/debug/localVariables/inlineFunInObject.kt b/compiler/testData/debug/localVariables/inlineFunInObject.kt index e1445597158..841812e8939 100644 --- a/compiler/testData/debug/localVariables/inlineFunInObject.kt +++ b/compiler/testData/debug/localVariables/inlineFunInObject.kt @@ -37,7 +37,7 @@ fun box() { } } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:31 box: // test.kt:3 box: $i$f$foo:int=0:int // test.kt:3 : @@ -47,11 +47,7 @@ fun box() { // test.kt:26 baz: param:int=5:int, a:int=1:int, $i$f$inlineCall:int=0:int // test.kt:27 baz: param:int=5:int, a:int=1:int, $i$f$inlineCall:int=0:int, e$iv:int=5:int // test.kt:7 baz: param:int=5:int, a:int=1:int, $i$f$inlineCall:int=0:int, e$iv:int=5:int, $i$a$-inlineCall-TestKt$foo$1$baz$1:int=0:int -// EXPECTATIONS JVM_IR // test.kt:8 baz: param:int=5:int, a:int=1:int, $i$f$inlineCall:int=0:int, e$iv:int=5:int, $i$a$-inlineCall-TestKt$foo$1$baz$1:int=0:int, f:int=6:int -// EXPECTATIONS JVM -// test.kt:8 baz: param:int=5:int, a:int=1:int, $i$f$inlineCall:int=0:int, e$iv:int=5:int, $i$a$-inlineCall-TestKt$foo$1$baz$1:int=0:int -// EXPECTATIONS JVM JVM_IR // test.kt:27 baz: param:int=5:int, a:int=1:int, $i$f$inlineCall:int=0:int, e$iv:int=5:int // test.kt:28 baz: param:int=5:int, a:int=1:int, $i$f$inlineCall:int=0:int, e$iv:int=5:int // test.kt:9 baz: param:int=5:int, a:int=1:int @@ -63,21 +59,13 @@ fun box() { // test.kt:16 baz: param:int=6:int // test.kt:17 baz: param:int=6:int, b:int=2:int // test.kt:36 baz: param:int=6:int, b:int=2:int, $i$a$-bar-TestKt$box$2:int=0:int -// EXPECTATIONS JVM_IR // test.kt:37 baz: param:int=6:int, b:int=2:int, $i$a$-bar-TestKt$box$2:int=0:int, d:int=4:int -// EXPECTATIONS JVM -// test.kt:37 baz: param:int=6:int, b:int=2:int, $i$a$-bar-TestKt$box$2:int=0:int -// EXPECTATIONS JVM JVM_IR // test.kt:17 baz: param:int=6:int, b:int=2:int // test.kt:18 baz: param:int=6:int, b:int=2:int // test.kt:26 baz: param:int=6:int, b:int=2:int, $i$f$inlineCall:int=0:int // test.kt:27 baz: param:int=6:int, b:int=2:int, $i$f$inlineCall:int=0:int, e$iv:int=5:int // test.kt:19 baz: param:int=6:int, b:int=2:int, $i$f$inlineCall:int=0:int, e$iv:int=5:int, $i$a$-inlineCall-TestKt$bar$1$baz$1:int=0:int -// EXPECTATIONS JVM_IR // test.kt:20 baz: param:int=6:int, b:int=2:int, $i$f$inlineCall:int=0:int, e$iv:int=5:int, $i$a$-inlineCall-TestKt$bar$1$baz$1:int=0:int, g:int=7:int -// EXPECTATIONS JVM -// test.kt:20 baz: param:int=6:int, b:int=2:int, $i$f$inlineCall:int=0:int, e$iv:int=5:int, $i$a$-inlineCall-TestKt$bar$1$baz$1:int=0:int -// EXPECTATIONS JVM JVM_IR // test.kt:27 baz: param:int=6:int, b:int=2:int, $i$f$inlineCall:int=0:int, e$iv:int=5:int // test.kt:28 baz: param:int=6:int, b:int=2:int, $i$f$inlineCall:int=0:int, e$iv:int=5:int // test.kt:21 baz: param:int=6:int, b:int=2:int diff --git a/compiler/testData/debug/localVariables/inlineProperty.kt b/compiler/testData/debug/localVariables/inlineProperty.kt index 789d99704c5..402a9e26fd8 100644 --- a/compiler/testData/debug/localVariables/inlineProperty.kt +++ b/compiler/testData/debug/localVariables/inlineProperty.kt @@ -10,7 +10,7 @@ fun box() { y++ } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:8 box: // test.kt:2 : // test.kt:8 box: diff --git a/compiler/testData/debug/localVariables/jvmOverloads.kt b/compiler/testData/debug/localVariables/jvmOverloads.kt index cfe0dc53ea8..b3967176938 100644 --- a/compiler/testData/debug/localVariables/jvmOverloads.kt +++ b/compiler/testData/debug/localVariables/jvmOverloads.kt @@ -10,7 +10,7 @@ fun box() { C().foo(4) } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:10 box: // test.kt:4 : // test.kt:10 box: diff --git a/compiler/testData/debug/localVariables/lambdaInObject.kt b/compiler/testData/debug/localVariables/lambdaInObject.kt index 7dedeb9cc9d..beb4cd4fd5b 100644 --- a/compiler/testData/debug/localVariables/lambdaInObject.kt +++ b/compiler/testData/debug/localVariables/lambdaInObject.kt @@ -26,7 +26,7 @@ fun box() { } } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:20 box: // test.kt:3 box: $i$f$foo:int=0:int // test.kt:3 : @@ -41,11 +41,7 @@ fun box() { // test.kt:13 baz: param:int=6:int // test.kt:14 baz: param:int=6:int, b:int=2:int // test.kt:25 baz: param:int=6:int, b:int=2:int, $i$a$-bar-TestKt$box$2:int=0:int -// EXPECTATIONS JVM_IR // test.kt:26 baz: param:int=6:int, b:int=2:int, $i$a$-bar-TestKt$box$2:int=0:int, d:int=4:int -// EXPECTATIONS JVM -// test.kt:26 baz: param:int=6:int, b:int=2:int, $i$a$-bar-TestKt$box$2:int=0:int -// EXPECTATIONS JVM JVM_IR // test.kt:14 baz: param:int=6:int, b:int=2:int // test.kt:15 baz: param:int=6:int, b:int=2:int // test.kt:17 box: $i$f$bar:int=0:int diff --git a/compiler/testData/debug/localVariables/lambdaWithLambdaParameter.kt b/compiler/testData/debug/localVariables/lambdaWithLambdaParameter.kt index 3d2b1cd71df..bd6e4cfea42 100644 --- a/compiler/testData/debug/localVariables/lambdaWithLambdaParameter.kt +++ b/compiler/testData/debug/localVariables/lambdaWithLambdaParameter.kt @@ -22,13 +22,11 @@ fun box() { foo.start() } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:21 box: // test.kt:3 : // test.kt:4 : -// EXPECTATIONS JVM_IR // test.kt:3 : -// EXPECTATIONS JVM JVM_IR // test.kt:21 box: // test.kt:22 box: foo:Foo=Foo // test.kt:13 start: diff --git a/compiler/testData/debug/localVariables/localFun.kt b/compiler/testData/debug/localVariables/localFun.kt index 120156a7021..91857c00a80 100644 --- a/compiler/testData/debug/localVariables/localFun.kt +++ b/compiler/testData/debug/localVariables/localFun.kt @@ -13,38 +13,12 @@ fun box() { foo() } -// Local functions are compiled to private static functions on the class -// containing the local funtion. This has a number of consequences observable -// from a debugging perspective, for this test specifically: -// - local functions do not figure in the LVT of the outer function, as they -// are not instantiated. -// - the _declaration_ of the local function does not figure in the byte code -// of the outer function and hence, has no line number -// - captures are treated differently, according to the implementation -// strategy: on the IR, captures are passed as arguments to the static -// function, on the old backend, they are added to fields on the lambda -// object. Hence, for debugging purposes, captures are "just" -// variables local to the function, and hence need no name mangling to -// properly figure in the debugger. - -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:13 box: // test.kt:5 foo: -// EXPECTATIONS JVM -// test.kt:6 foo: x:int=1:int -// test.kt:9 foo: x:int=1:int, $fun$bar$1:TestKt$foo$1=TestKt$foo$1 -// EXPECTATIONS JVM_IR // test.kt:9 foo: x:int=1:int -// EXPECTATIONS JVM -// test.kt:7 invoke: -// test.kt:8 invoke: y:int=1:int -// EXPECTATIONS JVM_IR // test.kt:7 foo$bar: x:int=1:int // test.kt:8 foo$bar: x:int=1:int, y:int=1:int -// EXPECTATIONS JVM -// test.kt:10 foo: x:int=1:int, $fun$bar$1:TestKt$foo$1=TestKt$foo$1 -// test.kt:14 box: -// EXPECTATIONS JVM_IR // test.kt:10 foo: x:int=1:int // test.kt:14 box: diff --git a/compiler/testData/debug/localVariables/localFunUnused.kt b/compiler/testData/debug/localVariables/localFunUnused.kt index 60e7dcd2ee8..733185758e9 100644 --- a/compiler/testData/debug/localVariables/localFunUnused.kt +++ b/compiler/testData/debug/localVariables/localFunUnused.kt @@ -10,21 +10,7 @@ fun box() { foo() } -// Local functions are compiled to private static functions on the class -// containing the local funtion. This has a number of consequences observable -// from a debugging perspective, for this test specically: -// - local functions do not figure in the LVT of the outer function, as they -// are not instantiated. -// - the _declaration_ of the local function does not figure in the byte code -// of the outer function and hence, has no line number - -// EXPECTATIONS JVM -// test.kt:10 box: -// test.kt:5 foo: -// test.kt:7 foo: $fun$bar$1:TestKt$foo$1=TestKt$foo$1 -// test.kt:11 box: - -// EXPECTATIONS JVM_IR JS_IR +// EXPECTATIONS // test.kt:10 box: // test.kt:7 foo: // test.kt:11 box: diff --git a/compiler/testData/debug/localVariables/receiverMangling/capturedThisField.kt b/compiler/testData/debug/localVariables/receiverMangling/capturedThisField.kt index 69eb2e6f868..08896d4a7fa 100644 --- a/compiler/testData/debug/localVariables/receiverMangling/capturedThisField.kt +++ b/compiler/testData/debug/localVariables/receiverMangling/capturedThisField.kt @@ -9,7 +9,7 @@ fun box() { x.Bar() } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:8 box: // test.kt:2 : // test.kt:8 box: diff --git a/compiler/testData/debug/localVariables/receiverMangling/labeledThisParameterLabel.kt b/compiler/testData/debug/localVariables/receiverMangling/labeledThisParameterLabel.kt index 2959aa158d4..950d73a01d9 100644 --- a/compiler/testData/debug/localVariables/receiverMangling/labeledThisParameterLabel.kt +++ b/compiler/testData/debug/localVariables/receiverMangling/labeledThisParameterLabel.kt @@ -10,7 +10,7 @@ fun box() { } } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:8 box: // test.kt:5 blockFun: blockArg:kotlin.jvm.functions.Function1=TestKt$box$1 // test.kt:9 invoke: $this$blockFun:java.lang.String="OK":java.lang.String diff --git a/compiler/testData/debug/localVariables/receiverMangling/lambdaWithExtensionReceiver.kt b/compiler/testData/debug/localVariables/receiverMangling/lambdaWithExtensionReceiver.kt index 937f7163457..87c57425f62 100644 --- a/compiler/testData/debug/localVariables/receiverMangling/lambdaWithExtensionReceiver.kt +++ b/compiler/testData/debug/localVariables/receiverMangling/lambdaWithExtensionReceiver.kt @@ -10,7 +10,7 @@ fun box() { } } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:8 box: // test.kt:4 foo: block:kotlin.jvm.functions.Function1=TestKt$box$1 // test.kt:9 invoke: $this$foo:long=1:long diff --git a/compiler/testData/debug/localVariables/receiverMangling/receiverParameter.kt b/compiler/testData/debug/localVariables/receiverMangling/receiverParameter.kt index cbcd5aa6c9a..58fdaa2373b 100644 --- a/compiler/testData/debug/localVariables/receiverMangling/receiverParameter.kt +++ b/compiler/testData/debug/localVariables/receiverMangling/receiverParameter.kt @@ -7,7 +7,7 @@ fun box() { "OK".test() } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:7 box: // test.kt:4 test: $this$test:java.lang.String="OK":java.lang.String // test.kt:8 box: diff --git a/compiler/testData/debug/localVariables/receiverMangling/simple.kt b/compiler/testData/debug/localVariables/receiverMangling/simple.kt index e79bbccf150..6e6946d7c8b 100644 --- a/compiler/testData/debug/localVariables/receiverMangling/simple.kt +++ b/compiler/testData/debug/localVariables/receiverMangling/simple.kt @@ -7,7 +7,7 @@ fun box() { "OK".foo(42) } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:7 box: // test.kt:4 foo: $this$foo:java.lang.String="OK":java.lang.String, a:int=42:int // test.kt:8 box: diff --git a/compiler/testData/debug/localVariables/receiverMangling/simpleCapturedReceiver.kt b/compiler/testData/debug/localVariables/receiverMangling/simpleCapturedReceiver.kt index 2959aa158d4..950d73a01d9 100644 --- a/compiler/testData/debug/localVariables/receiverMangling/simpleCapturedReceiver.kt +++ b/compiler/testData/debug/localVariables/receiverMangling/simpleCapturedReceiver.kt @@ -10,7 +10,7 @@ fun box() { } } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:8 box: // test.kt:5 blockFun: blockArg:kotlin.jvm.functions.Function1=TestKt$box$1 // test.kt:9 invoke: $this$blockFun:java.lang.String="OK":java.lang.String diff --git a/compiler/testData/debug/localVariables/receiverMangling/simpleCapturedReceiverWithLabel.kt b/compiler/testData/debug/localVariables/receiverMangling/simpleCapturedReceiverWithLabel.kt index feb6d28072e..25f2c34f860 100644 --- a/compiler/testData/debug/localVariables/receiverMangling/simpleCapturedReceiverWithLabel.kt +++ b/compiler/testData/debug/localVariables/receiverMangling/simpleCapturedReceiverWithLabel.kt @@ -10,7 +10,7 @@ fun box() { } } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:8 box: // test.kt:5 blockFun: blockArg:kotlin.jvm.functions.Function1=TestKt$box$1 // test.kt:9 invoke: $this$label:java.lang.String="OK":java.lang.String diff --git a/compiler/testData/debug/localVariables/receiverMangling/simpleCapturedReceiverWithParenthesis.kt b/compiler/testData/debug/localVariables/receiverMangling/simpleCapturedReceiverWithParenthesis.kt index 78b6db52518..bd316ebb711 100644 --- a/compiler/testData/debug/localVariables/receiverMangling/simpleCapturedReceiverWithParenthesis.kt +++ b/compiler/testData/debug/localVariables/receiverMangling/simpleCapturedReceiverWithParenthesis.kt @@ -10,7 +10,7 @@ fun box() { }) } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:8 box: // test.kt:5 blockFun: blockArg:kotlin.jvm.functions.Function1=TestKt$box$1 // test.kt:9 invoke: $this$blockFun:java.lang.String="OK":java.lang.String diff --git a/compiler/testData/debug/localVariables/suspend/completion/nonStaticSimple.kt b/compiler/testData/debug/localVariables/suspend/completion/nonStaticSimple.kt index ee1e917259c..e970008fa65 100644 --- a/compiler/testData/debug/localVariables/suspend/completion/nonStaticSimple.kt +++ b/compiler/testData/debug/localVariables/suspend/completion/nonStaticSimple.kt @@ -1,5 +1,5 @@ -// Code generation problem with JVM backend. -// IGNORE_BACKEND: JVM + + // FILE: test.kt class A { suspend fun foo() {} @@ -9,7 +9,7 @@ suspend fun box() { A().foo() } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:9 box: $completion:kotlin.coroutines.Continuation=Generated_Box_MainKt$main$1 // test.kt:4 : // test.kt:9 box: $completion:kotlin.coroutines.Continuation=Generated_Box_MainKt$main$1 diff --git a/compiler/testData/debug/localVariables/suspend/completion/nonStaticStateMachine.kt b/compiler/testData/debug/localVariables/suspend/completion/nonStaticStateMachine.kt index 8d8d5a74399..2166d9227bd 100644 --- a/compiler/testData/debug/localVariables/suspend/completion/nonStaticStateMachine.kt +++ b/compiler/testData/debug/localVariables/suspend/completion/nonStaticStateMachine.kt @@ -1,5 +1,5 @@ -// Code generation problem with JVM backend. -// IGNORE_BACKEND: JVM + + // FILE: test.kt class A { suspend fun foo() {} @@ -14,7 +14,7 @@ suspend fun box() { A().foo1(42) } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:14 box: $completion:kotlin.coroutines.Continuation=Generated_Box_MainKt$main$1 // test.kt:4 : // test.kt:14 box: $completion:kotlin.coroutines.Continuation=Generated_Box_MainKt$main$1 diff --git a/compiler/testData/debug/localVariables/suspend/completion/staticSimple.kt b/compiler/testData/debug/localVariables/suspend/completion/staticSimple.kt index 6ac91ff63ec..9cbaf7ae601 100644 --- a/compiler/testData/debug/localVariables/suspend/completion/staticSimple.kt +++ b/compiler/testData/debug/localVariables/suspend/completion/staticSimple.kt @@ -1,10 +1,10 @@ -// Code generation problem with JVM backend. -// IGNORE_BACKEND: JVM + + // FILE: test.kt suspend fun box() {} -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:4 box: $completion:kotlin.coroutines.Continuation=Generated_Box_MainKt$main$1 // EXPECTATIONS JS_IR diff --git a/compiler/testData/debug/localVariables/suspend/completion/staticSimpleReceiver.kt b/compiler/testData/debug/localVariables/suspend/completion/staticSimpleReceiver.kt index f0c5c5bcda7..e13037dacb2 100644 --- a/compiler/testData/debug/localVariables/suspend/completion/staticSimpleReceiver.kt +++ b/compiler/testData/debug/localVariables/suspend/completion/staticSimpleReceiver.kt @@ -1,5 +1,5 @@ -// Code generation problem with JVM backend. -// IGNORE_BACKEND: JVM + + // FILE: test.kt class A @@ -10,7 +10,7 @@ suspend fun box() { } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:9 box: $completion:kotlin.coroutines.Continuation=Generated_Box_MainKt$main$1 // test.kt:4 : // test.kt:9 box: $completion:kotlin.coroutines.Continuation=Generated_Box_MainKt$main$1 diff --git a/compiler/testData/debug/localVariables/suspend/completion/staticStateMachine.kt b/compiler/testData/debug/localVariables/suspend/completion/staticStateMachine.kt index 9e097811469..7305ba1c696 100644 --- a/compiler/testData/debug/localVariables/suspend/completion/staticStateMachine.kt +++ b/compiler/testData/debug/localVariables/suspend/completion/staticStateMachine.kt @@ -1,5 +1,5 @@ -// Code generation problem with JVM backend. -// IGNORE_BACKEND: JVM + + // FILE: test.kt suspend fun foo() {} suspend fun foo1(l: Long) { @@ -12,7 +12,7 @@ suspend fun box() { foo1(42) } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:12 box: $completion:kotlin.coroutines.Continuation=Generated_Box_MainKt$main$1 // test.kt:5 foo1: // test.kt:6 foo1: $continuation:kotlin.coroutines.Continuation=TestKt$foo1$1, $result:java.lang.Object=null, l:long=42:long diff --git a/compiler/testData/debug/localVariables/suspend/completion/staticStateMachineReceiver.kt b/compiler/testData/debug/localVariables/suspend/completion/staticStateMachineReceiver.kt index 6cade55fff7..6e5d49ad2f3 100644 --- a/compiler/testData/debug/localVariables/suspend/completion/staticStateMachineReceiver.kt +++ b/compiler/testData/debug/localVariables/suspend/completion/staticStateMachineReceiver.kt @@ -1,5 +1,5 @@ -// Code generation problem with JVM backend. -// IGNORE_BACKEND: JVM + + // FILE: test.kt class A @@ -14,9 +14,7 @@ suspend fun box() { A().foo1(42) } -// The lambda object constructor has a local variables table on the IR backend. - -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:14 box: $completion:kotlin.coroutines.Continuation=Generated_Box_MainKt$main$1 // test.kt:4 : // test.kt:14 box: $completion:kotlin.coroutines.Continuation=Generated_Box_MainKt$main$1 diff --git a/compiler/testData/debug/localVariables/suspend/inlineLocalsStateMachineTransform.kt b/compiler/testData/debug/localVariables/suspend/inlineLocalsStateMachineTransform.kt index 28811f87f1e..39642dfe17b 100644 --- a/compiler/testData/debug/localVariables/suspend/inlineLocalsStateMachineTransform.kt +++ b/compiler/testData/debug/localVariables/suspend/inlineLocalsStateMachineTransform.kt @@ -18,7 +18,7 @@ suspend fun box() { hasLocal() } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:10 box: // test.kt:12 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null // test.kt:8 h: $completion:kotlin.coroutines.Continuation=TestKt$box$1 diff --git a/compiler/testData/debug/localVariables/suspend/localsStateMachineTransform.kt b/compiler/testData/debug/localVariables/suspend/localsStateMachineTransform.kt index b17593501ad..a3830dbf56e 100644 --- a/compiler/testData/debug/localVariables/suspend/localsStateMachineTransform.kt +++ b/compiler/testData/debug/localVariables/suspend/localsStateMachineTransform.kt @@ -1,5 +1,5 @@ -// The JVM backend does not have `x` visible in the locals table for the for loop at all. -// IGNORE_BACKEND: JVM + + // WITH_STDLIB // FILE: test.kt @@ -20,7 +20,7 @@ suspend fun box() { } } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:10 box: // test.kt:12 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null // test.kt:6 h: $completion:kotlin.coroutines.Continuation=TestKt$box$1 diff --git a/compiler/testData/debug/localVariables/suspend/mergeLvt.kt b/compiler/testData/debug/localVariables/suspend/mergeLvt.kt index 2ca9ab5a806..a9a54ed7800 100644 --- a/compiler/testData/debug/localVariables/suspend/mergeLvt.kt +++ b/compiler/testData/debug/localVariables/suspend/mergeLvt.kt @@ -29,14 +29,10 @@ suspend fun box() { // FIXME(JS_IR): KT-54657 -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:26 box: // test.kt:27 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null // test.kt:20 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$suspendBar:int=0:int -// EXPECTATIONS JVM -// test.kt:20 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$suspendBar:int=0:int -// test.kt:15 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$suspendBar:int=0:int, $this$extensionFun$iv$iv:AtomicInt=AtomicInt, $i$f$extensionFun:int=0:int -// EXPECTATIONS JVM JVM_IR // test.kt:15 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$suspendBar:int=0:int, $this$extensionFun$iv$iv:AtomicInt=AtomicInt, $i$f$extensionFun:int=0:int // test.kt:16 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$suspendBar:int=0:int, $this$extensionFun$iv$iv:AtomicInt=AtomicInt, $i$f$extensionFun:int=0:int // test.kt:7 getValue: @@ -45,10 +41,10 @@ suspend fun box() { // test.kt:21 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$suspendBar:int=0:int // test.kt:22 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$suspendBar:int=0:int, $i$a$-suspendCoroutineUninterceptedOrReturn-TestKt$suspendBar$2$iv:int=0:int -// EXPECTATIONS ClassicFrontend JVM JVM_IR +// EXPECTATIONS ClassicFrontend JVM_IR // test.kt:23 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$suspendBar:int=0:int, $i$a$-suspendCoroutineUninterceptedOrReturn-TestKt$suspendBar$2$iv:int=0:int -// EXPECTATIONS ClassicFrontend FIR JVM JVM_IR +// EXPECTATIONS ClassicFrontend FIR JVM_IR // test.kt:21 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$suspendBar:int=0:int // test.kt:24 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$suspendBar:int=0:int // test.kt:27 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null @@ -66,7 +62,7 @@ suspend fun box() { // test.kt:15 doResume: // test.kt:12 $accessor$1gle43a: // test.kt:12 : -// test.kt:38 doResume: -// test.kt:38 doResume: +// test.kt:37 doResume: +// test.kt:37 doResume: // test.kt:27 doResume: // test.kt:28 doResume: a=Unit diff --git a/compiler/testData/debug/localVariables/suspend/nestedInsideSuspendUnintercepted.kt b/compiler/testData/debug/localVariables/suspend/nestedInsideSuspendUnintercepted.kt index 1d23f9f0903..b8aa71e24ea 100644 --- a/compiler/testData/debug/localVariables/suspend/nestedInsideSuspendUnintercepted.kt +++ b/compiler/testData/debug/localVariables/suspend/nestedInsideSuspendUnintercepted.kt @@ -30,7 +30,7 @@ suspend fun box() { val a = baz() } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:29 box: // test.kt:30 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null // test.kt:26 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int @@ -45,17 +45,13 @@ suspend fun box() { // test.kt:13 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$foo:int=0:int, $i$a$-suspendCoroutineUninterceptedOrReturn-TestKt$foo$2$iv$iv:int=0:int, $i$f$bar:int=0:int, c$iv$iv$iv:int=1:int, $i$a$-bar-TestKt$foo$2$1$iv$iv:int=0:int, b$iv$iv:int=2:int // test.kt:7 id: obj:java.lang.Object=java.lang.Integer // test.kt:13 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$foo:int=0:int, $i$a$-suspendCoroutineUninterceptedOrReturn-TestKt$foo$2$iv$iv:int=0:int, $i$f$bar:int=0:int, c$iv$iv$iv:int=1:int, $i$a$-bar-TestKt$foo$2$1$iv$iv:int=0:int, b$iv$iv:int=2:int -// EXPECTATIONS JVM_IR // test.kt:14 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$foo:int=0:int, $i$a$-suspendCoroutineUninterceptedOrReturn-TestKt$foo$2$iv$iv:int=0:int, $i$f$bar:int=0:int, c$iv$iv$iv:int=1:int, $i$a$-bar-TestKt$foo$2$1$iv$iv:int=0:int, b$iv$iv:int=2:int -// EXPECTATIONS JVM -// test.kt:14 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$foo:int=0:int, $i$a$-suspendCoroutineUninterceptedOrReturn-TestKt$foo$2$iv$iv:int=0:int, $i$f$bar:int=0:int, c$iv$iv$iv:int=1:int, $i$a$-bar-TestKt$foo$2$1$iv$iv:int=0:int -// EXPECTATIONS JVM JVM_IR // test.kt:22 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$foo:int=0:int, $i$a$-suspendCoroutineUninterceptedOrReturn-TestKt$foo$2$iv$iv:int=0:int, $i$f$bar:int=0:int, c$iv$iv$iv:int=1:int // test.kt:23 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$foo:int=0:int, $i$a$-suspendCoroutineUninterceptedOrReturn-TestKt$foo$2$iv$iv:int=0:int, $i$f$bar:int=0:int, c$iv$iv$iv:int=1:int // test.kt:15 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$foo:int=0:int, $i$a$-suspendCoroutineUninterceptedOrReturn-TestKt$foo$2$iv$iv:int=0:int -// EXPECTATIONS ClassicFrontend JVM JVM_IR +// EXPECTATIONS ClassicFrontend JVM_IR // test.kt:16 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$foo:int=0:int, $i$a$-suspendCoroutineUninterceptedOrReturn-TestKt$foo$2$iv$iv:int=0:int -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:10 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$foo:int=0:int // test.kt:17 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$foo:int=0:int // test.kt:27 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int @@ -69,7 +65,7 @@ suspend fun box() { // test.kt:12 doResume: c=1:number // test.kt:13 doResume: c=1:number, b=2:number // test.kt:7 id: obj=2:number -// test.kt:38 doResume: c=1:number, b=2:number -// test.kt:38 doResume: c=1:number, b=2:number +// test.kt:39 doResume: c=1:number, b=2:number +// test.kt:39 doResume: c=1:number, b=2:number // test.kt:30 doResume: c=1:number, b=2:number // test.kt:31 doResume: c=1:number, b=2:number, a=Unit diff --git a/compiler/testData/debug/localVariables/suspend/nestedSuspendUnintercepted.kt b/compiler/testData/debug/localVariables/suspend/nestedSuspendUnintercepted.kt index c135da1465c..59056a29970 100644 --- a/compiler/testData/debug/localVariables/suspend/nestedSuspendUnintercepted.kt +++ b/compiler/testData/debug/localVariables/suspend/nestedSuspendUnintercepted.kt @@ -22,16 +22,16 @@ suspend fun box() { val a = baz() } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:21 box: // test.kt:22 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null // test.kt:18 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int // test.kt:14 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$bar:int=0:int // test.kt:8 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$bar:int=0:int, $i$f$foo:int=0:int // test.kt:9 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$bar:int=0:int, $i$f$foo:int=0:int, $i$a$-suspendCoroutineUninterceptedOrReturn-TestKt$foo$2$iv$iv$iv:int=0:int -// EXPECTATIONS ClassicFrontend JVM JVM_IR +// EXPECTATIONS ClassicFrontend JVM_IR // test.kt:10 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$bar:int=0:int, $i$f$foo:int=0:int, $i$a$-suspendCoroutineUninterceptedOrReturn-TestKt$foo$2$iv$iv$iv:int=0:int -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:8 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$bar:int=0:int, $i$f$foo:int=0:int // test.kt:11 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$bar:int=0:int, $i$f$foo:int=0:int // test.kt:15 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$bar:int=0:int diff --git a/compiler/testData/debug/localVariables/suspend/nestedSuspendUninterceptedWithDeepLambdaCall.kt b/compiler/testData/debug/localVariables/suspend/nestedSuspendUninterceptedWithDeepLambdaCall.kt index 088d6df959b..739479b1b97 100644 --- a/compiler/testData/debug/localVariables/suspend/nestedSuspendUninterceptedWithDeepLambdaCall.kt +++ b/compiler/testData/debug/localVariables/suspend/nestedSuspendUninterceptedWithDeepLambdaCall.kt @@ -36,7 +36,7 @@ suspend fun box() { } } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:32 box: // test.kt:33 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null // test.kt:27 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int @@ -63,22 +63,13 @@ suspend fun box() { // test.kt:35 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$bar:int=0:int, $i$f$foo:int=0:int, $i$a$-suspendCoroutineUninterceptedOrReturn-TestKt$foo$2$iv$iv$iv:int=0:int, b$iv$iv$iv:int=2:int, $i$a$-baz-TestKt$box$result$1:int=0:int, e:int=5:int // test.kt:7 id: obj:java.lang.Object=java.lang.Integer // test.kt:35 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$bar:int=0:int, $i$f$foo:int=0:int, $i$a$-suspendCoroutineUninterceptedOrReturn-TestKt$foo$2$iv$iv$iv:int=0:int, b$iv$iv$iv:int=2:int, $i$a$-baz-TestKt$box$result$1:int=0:int, e:int=5:int -// EXPECTATIONS JVM_IR // test.kt:36 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$bar:int=0:int, $i$f$foo:int=0:int, $i$a$-suspendCoroutineUninterceptedOrReturn-TestKt$foo$2$iv$iv$iv:int=0:int, b$iv$iv$iv:int=2:int, $i$a$-baz-TestKt$box$result$1:int=0:int, e:int=5:int -// EXPECTATIONS JVM -// test.kt:36 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$bar:int=0:int, $i$f$foo:int=0:int, $i$a$-suspendCoroutineUninterceptedOrReturn-TestKt$foo$2$iv$iv$iv:int=0:int, b$iv$iv$iv:int=2:int, $i$a$-baz-TestKt$box$result$1:int=0:int -// EXPECTATIONS JVM JVM_IR // test.kt:15 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$bar:int=0:int, $i$f$foo:int=0:int, $i$a$-suspendCoroutineUninterceptedOrReturn-TestKt$foo$2$iv$iv$iv:int=0:int, b$iv$iv$iv:int=2:int // test.kt:16 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$bar:int=0:int, $i$f$foo:int=0:int, $i$a$-suspendCoroutineUninterceptedOrReturn-TestKt$foo$2$iv$iv$iv:int=0:int, b$iv$iv$iv:int=2:int // EXPECTATIONS ClassicFrontend JVM_IR // test.kt:17 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$bar:int=0:int, $i$f$foo:int=0:int, $i$a$-suspendCoroutineUninterceptedOrReturn-TestKt$foo$2$iv$iv$iv:int=0:int, b$iv$iv$iv:int=2:int -// EXPECTATIONS FIR JVM_IR +// EXPECTATIONS JVM_IR // test.kt:12 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$bar:int=0:int, $i$f$foo:int=0:int -// EXPECTATIONS JVM -// test.kt:17 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$bar:int=0:int, $i$f$foo:int=0:int, $i$a$-suspendCoroutineUninterceptedOrReturn-TestKt$foo$2$iv$iv$iv:int=0:int -// EXPECTATIONS ClassicFrontend JVM JVM_IR -// test.kt:12 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$bar:int=0:int, $i$f$foo:int=0:int -// EXPECTATIONS JVM JVM_IR // test.kt:18 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$bar:int=0:int, $i$f$foo:int=0:int // test.kt:24 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int, $i$f$bar:int=0:int // test.kt:30 box: $continuation:kotlin.coroutines.Continuation=TestKt$box$1, $result:java.lang.Object=null, $i$f$baz:int=0:int diff --git a/compiler/testData/debug/localVariables/suspend/simple.kt b/compiler/testData/debug/localVariables/suspend/simple.kt index ea1e0e5ceae..fbacbfc577b 100644 --- a/compiler/testData/debug/localVariables/suspend/simple.kt +++ b/compiler/testData/debug/localVariables/suspend/simple.kt @@ -5,7 +5,7 @@ suspend fun box() { var x = 1 } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:5 box: $completion:kotlin.coroutines.Continuation=Generated_Box_MainKt$main$1 // test.kt:6 box: $completion:kotlin.coroutines.Continuation=Generated_Box_MainKt$main$1, x:int=1:int diff --git a/compiler/testData/debug/localVariables/suspend/underscoreNames.kt b/compiler/testData/debug/localVariables/suspend/underscoreNames.kt index 373a09bc93f..9517662d755 100644 --- a/compiler/testData/debug/localVariables/suspend/underscoreNames.kt +++ b/compiler/testData/debug/localVariables/suspend/underscoreNames.kt @@ -13,29 +13,17 @@ suspend fun box() = foo(A()) { (x_param, _, y_param) -> x_param + y_param } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:12 box: $completion:kotlin.coroutines.Continuation=Generated_Box_MainKt$main$1 // test.kt:4 : // test.kt:12 box: $completion:kotlin.coroutines.Continuation=Generated_Box_MainKt$main$1 // test.kt:10 foo: a:A=A, block:kotlin.jvm.functions.Function2=TestKt$box$2, $completion:kotlin.coroutines.Continuation=Generated_Box_MainKt$main$1 // test.kt:5 component1: -// EXPECTATIONS JVM -// test.kt:12 invokeSuspend: $result:java.lang.Object=kotlin.Unit, $dstr$x_param$_u24__u24$y_param:A=A -// EXPECTATIONS JVM_IR // test.kt:12 invokeSuspend: $result:java.lang.Object=kotlin.Unit -// EXPECTATIONS JVM JVM_IR // test.kt:7 component3: -// EXPECTATIONS JVM_IR // test.kt:12 invokeSuspend: $result:java.lang.Object=kotlin.Unit, x_param:java.lang.String="O":java.lang.String // test.kt:13 invokeSuspend: $result:java.lang.Object=kotlin.Unit, x_param:java.lang.String="O":java.lang.String, y_param:java.lang.String="K":java.lang.String -// EXPECTATIONS JVM -// test.kt:12 invokeSuspend: $result:java.lang.Object=kotlin.Unit, $dstr$x_param$_u24__u24$y_param:A=A -// test.kt:13 invokeSuspend: $result:java.lang.Object=kotlin.Unit, $dstr$x_param$_u24__u24$y_param:A=A, x_param:java.lang.String="O":java.lang.String, y_param:java.lang.String="K":java.lang.String -// EXPECTATIONS JVM_IR // test.kt:-1 invoke: p1:A=A, p2:kotlin.coroutines.Continuation=Generated_Box_MainKt$main$1 -// EXPECTATIONS JVM -// test.kt:-1 invoke: -// EXPECTATIONS JVM JVM_IR // test.kt:10 foo: a:A=A, block:kotlin.jvm.functions.Function2=TestKt$box$2, $completion:kotlin.coroutines.Continuation=Generated_Box_MainKt$main$1 // test.kt:14 box: $completion:kotlin.coroutines.Continuation=Generated_Box_MainKt$main$1 diff --git a/compiler/testData/debug/localVariables/tryFinally.kt b/compiler/testData/debug/localVariables/tryFinally.kt index 2588f5619fb..f25af9967c5 100644 --- a/compiler/testData/debug/localVariables/tryFinally.kt +++ b/compiler/testData/debug/localVariables/tryFinally.kt @@ -1,5 +1,5 @@ -// The old backend has the local y covering the finally block as well. -// IGNORE_BACKEND: JVM + + // WITH_STDLIB // FILE: test.kt @@ -18,7 +18,7 @@ fun box() { } } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:7 box: // test.kt:8 box: result:java.lang.String="":java.lang.String // test.kt:9 box: result:java.lang.String="":java.lang.String, x:java.lang.String="A":java.lang.String diff --git a/compiler/testData/debug/localVariables/tryFinally10.kt b/compiler/testData/debug/localVariables/tryFinally10.kt index 5cc5c5a9c60..b0954f1a157 100644 --- a/compiler/testData/debug/localVariables/tryFinally10.kt +++ b/compiler/testData/debug/localVariables/tryFinally10.kt @@ -1,5 +1,5 @@ -// The local variables `y` and `i` are visible in the finally block with old backend. -// IGNORE_BACKEND: JVM + + // WITH_STDLIB // FILE: test.kt @@ -36,7 +36,7 @@ fun box() { val localX = x } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:35 box: // test.kt:20 compute: // test.kt:21 compute: diff --git a/compiler/testData/debug/localVariables/tryFinally11.kt b/compiler/testData/debug/localVariables/tryFinally11.kt index 85c1156b8d0..7103b246126 100644 --- a/compiler/testData/debug/localVariables/tryFinally11.kt +++ b/compiler/testData/debug/localVariables/tryFinally11.kt @@ -1,5 +1,5 @@ -// The local variables `z` and `y` are visible in the finally block with old backend. -// IGNORE_BACKEND: JVM + + // WITH_STDLIB // FILE: test.kt @@ -23,7 +23,7 @@ fun box(): String { return "FAIL" } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:7 box: // test.kt:8 box: // test.kt:9 box: i:int=0:int diff --git a/compiler/testData/debug/localVariables/tryFinally12.kt b/compiler/testData/debug/localVariables/tryFinally12.kt index 54d99fef4cc..22a2e9da167 100644 --- a/compiler/testData/debug/localVariables/tryFinally12.kt +++ b/compiler/testData/debug/localVariables/tryFinally12.kt @@ -1,5 +1,5 @@ -// The local variables `z` and `y` are visible in the finally block with old backend. -// IGNORE_BACKEND: JVM + + // WITH_STDLIB // FILE: test.kt @@ -23,7 +23,7 @@ fun box(): String { return "FAIL" } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:7 box: // test.kt:8 box: // test.kt:9 box: i:int=0:int diff --git a/compiler/testData/debug/localVariables/tryFinally13.kt b/compiler/testData/debug/localVariables/tryFinally13.kt index d19a8343274..b513fde06d4 100644 --- a/compiler/testData/debug/localVariables/tryFinally13.kt +++ b/compiler/testData/debug/localVariables/tryFinally13.kt @@ -1,5 +1,5 @@ -// The local variables `y` and `i` are visible in finally blocks with old backend. -// IGNORE_BACKEND: JVM + + // WITH_STDLIB // FILE: test.kt @@ -22,7 +22,7 @@ fun box(): String { return "FAIL3" } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:7 box: // test.kt:8 box: // test.kt:9 box: i:int=0:int diff --git a/compiler/testData/debug/localVariables/tryFinally14.kt b/compiler/testData/debug/localVariables/tryFinally14.kt index f9c76e65aaa..669cce04439 100644 --- a/compiler/testData/debug/localVariables/tryFinally14.kt +++ b/compiler/testData/debug/localVariables/tryFinally14.kt @@ -16,7 +16,7 @@ fun box(): String { return "FAIL" } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:4 box: // test.kt:5 box: // test.kt:6 box: i:int=0:int diff --git a/compiler/testData/debug/localVariables/tryFinally15.kt b/compiler/testData/debug/localVariables/tryFinally15.kt index fd07b4d8621..6245d7cf757 100644 --- a/compiler/testData/debug/localVariables/tryFinally15.kt +++ b/compiler/testData/debug/localVariables/tryFinally15.kt @@ -16,18 +16,14 @@ fun box(): String { return "FAIL" } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:4 box: // test.kt:5 box: // test.kt:6 box: i:int=0:int // test.kt:7 box: i:int=0:int // test.kt:8 box: i:int=0:int, x:java.lang.String="x":java.lang.String // test.kt:10 box: i:int=0:int -// EXPECTATIONS JVM // test.kt:5 box: i:int=0:int -// EXPECTATIONS JVM_IR -// test.kt:5 box: i:int=0:int -// EXPECTATIONS JVM JVM_IR // test.kt:14 box: // EXPECTATIONS JS_IR diff --git a/compiler/testData/debug/localVariables/tryFinally16.kt b/compiler/testData/debug/localVariables/tryFinally16.kt index ccd650fe36a..b242edfa74a 100644 --- a/compiler/testData/debug/localVariables/tryFinally16.kt +++ b/compiler/testData/debug/localVariables/tryFinally16.kt @@ -1,5 +1,5 @@ -// The local `i` is visible in the finally block with old backend. -// IGNORE_BACKEND: JVM + + // WITH_STDLIB // FILE: test.kt fun box(): String { @@ -18,7 +18,7 @@ fun box(): String { return "FAIL2" } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:6 box: // test.kt:7 box: // test.kt:8 box: i:int=0:int diff --git a/compiler/testData/debug/localVariables/tryFinally17.kt b/compiler/testData/debug/localVariables/tryFinally17.kt index 958b74aad65..eeece528940 100644 --- a/compiler/testData/debug/localVariables/tryFinally17.kt +++ b/compiler/testData/debug/localVariables/tryFinally17.kt @@ -1,6 +1,6 @@ -// IGNORE_BACKEND: JVM -// The old backend steps on line 4, 5, 9, and 8. No step on the throw, and a step on the end -// brace of the finally before going into the actual finally code. + + + // FILE: test.kt @@ -14,7 +14,7 @@ fun box(): String { return "FAIL" } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:8 box: // test.kt:9 box: // test.kt:10 box: x:java.lang.String="x":java.lang.String diff --git a/compiler/testData/debug/localVariables/tryFinally2.kt b/compiler/testData/debug/localVariables/tryFinally2.kt index 7cf01e9951a..d93cc4c0aec 100644 --- a/compiler/testData/debug/localVariables/tryFinally2.kt +++ b/compiler/testData/debug/localVariables/tryFinally2.kt @@ -1,5 +1,5 @@ -// The old backend has the local y covering the finally block as well. -// IGNORE_BACKEND: JVM + + // WITH_STDLIB // FILE: test.kt fun box() { @@ -17,7 +17,7 @@ fun box() { } } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:6 box: // test.kt:7 box: result:java.lang.String="":java.lang.String // test.kt:8 box: result:java.lang.String="":java.lang.String, x:java.lang.String="A":java.lang.String diff --git a/compiler/testData/debug/localVariables/tryFinally3.kt b/compiler/testData/debug/localVariables/tryFinally3.kt index 193ec6ddcd5..d4451292c69 100644 --- a/compiler/testData/debug/localVariables/tryFinally3.kt +++ b/compiler/testData/debug/localVariables/tryFinally3.kt @@ -1,5 +1,5 @@ -// The old backend has the local y covering the finally block as well. -// IGNORE_BACKEND: JVM + + // WITH_STDLIB // FILE: test.kt @@ -23,7 +23,7 @@ fun box() { compute() } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:23 box: // test.kt:7 compute: // test.kt:8 compute: result:java.lang.String="":java.lang.String diff --git a/compiler/testData/debug/localVariables/tryFinally4.kt b/compiler/testData/debug/localVariables/tryFinally4.kt index a9d795cfa45..afd85931842 100644 --- a/compiler/testData/debug/localVariables/tryFinally4.kt +++ b/compiler/testData/debug/localVariables/tryFinally4.kt @@ -1,5 +1,5 @@ -// The old backend gets the local variables for finally blocks wrong. -// IGNORE_BACKEND: JVM + + // WITH_STDLIB // FILE: test.kt @@ -29,7 +29,7 @@ fun box() { compute() } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:29 box: // test.kt:7 compute: // test.kt:8 compute: result:java.lang.String="":java.lang.String diff --git a/compiler/testData/debug/localVariables/tryFinally5.kt b/compiler/testData/debug/localVariables/tryFinally5.kt index b06a591d9cd..0c0e58bf555 100644 --- a/compiler/testData/debug/localVariables/tryFinally5.kt +++ b/compiler/testData/debug/localVariables/tryFinally5.kt @@ -1,5 +1,5 @@ -// JVM backend has the `a` local covering the finally block. It shouldn't. -// IGNORE_BACKEND: JVM + + // WITH_STDLIB // FILE: test.kt @@ -29,7 +29,7 @@ fun box() { val localX = x } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:28 box: // test.kt:13 compute: // test.kt:14 compute: diff --git a/compiler/testData/debug/localVariables/tryFinally6_1.kt b/compiler/testData/debug/localVariables/tryFinally6_1.kt index 25aa717a5c2..04f89e745f2 100644 --- a/compiler/testData/debug/localVariables/tryFinally6_1.kt +++ b/compiler/testData/debug/localVariables/tryFinally6_1.kt @@ -1,5 +1,5 @@ // IGNORE_INLINER: IR -// IGNORE_BACKEND: JVM + // WITH_STDLIB // FILE: test.kt @@ -43,7 +43,7 @@ fun box() { val localX = x } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:42 box: // test.kt:27 compute: // test.kt:28 compute: diff --git a/compiler/testData/debug/localVariables/tryFinally6_2.kt b/compiler/testData/debug/localVariables/tryFinally6_2.kt index b44b1585da4..2cdeae4c027 100644 --- a/compiler/testData/debug/localVariables/tryFinally6_2.kt +++ b/compiler/testData/debug/localVariables/tryFinally6_2.kt @@ -31,7 +31,7 @@ fun box() { val localX = x } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:30 box: // test.kt:17 compute: // test.kt:18 compute: diff --git a/compiler/testData/debug/localVariables/tryFinally7.kt b/compiler/testData/debug/localVariables/tryFinally7.kt index cfd77add59f..50edf60de35 100644 --- a/compiler/testData/debug/localVariables/tryFinally7.kt +++ b/compiler/testData/debug/localVariables/tryFinally7.kt @@ -1,5 +1,5 @@ -// The old backend has `y` and `j` visible on the finally block. -// IGNORE_BACKEND: JVM + + // WITH_STDLIB // FILE: test.kt @@ -33,7 +33,7 @@ fun box() { val localX = x } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:32 box: // test.kt:13 compute: // test.kt:14 compute: diff --git a/compiler/testData/debug/localVariables/tryFinally8.kt b/compiler/testData/debug/localVariables/tryFinally8.kt index 2e7e1729cb4..6f01fa5b1f3 100644 --- a/compiler/testData/debug/localVariables/tryFinally8.kt +++ b/compiler/testData/debug/localVariables/tryFinally8.kt @@ -1,5 +1,5 @@ -// The old backend has `y` and `i` visible on the finally block. -// IGNORE_BACKEND: JVM + + // WITH_STDLIB // FILE: test.kt @@ -35,7 +35,7 @@ fun box() { val localX = x } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:34 box: // test.kt:20 compute: // test.kt:21 compute: diff --git a/compiler/testData/debug/localVariables/tryFinally9.kt b/compiler/testData/debug/localVariables/tryFinally9.kt index 6fbdb01d9d1..73c41088f13 100644 --- a/compiler/testData/debug/localVariables/tryFinally9.kt +++ b/compiler/testData/debug/localVariables/tryFinally9.kt @@ -1,5 +1,5 @@ -// The local variables in the try and finally blocks are not removed for the finally block with the old backend. -// IGNORE_BACKEND: JVM + + // WITH_STDLIB // FILE: test.kt @@ -38,7 +38,7 @@ fun box() { val localX = x } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:37 box: // test.kt:13 compute: // test.kt:14 compute: diff --git a/compiler/testData/debug/localVariables/underscoreNames.kt b/compiler/testData/debug/localVariables/underscoreNames.kt index cac7358ffce..76328fd4712 100644 --- a/compiler/testData/debug/localVariables/underscoreNames.kt +++ b/compiler/testData/debug/localVariables/underscoreNames.kt @@ -23,41 +23,22 @@ fun box() { } } -// EXPECTATIONS JVM JVM_IR +// EXPECTATIONS JVM_IR // test.kt:12 box: // test.kt:4 : x:double=1.0:double, y:java.lang.String="":java.lang.String, z:char=0:char // test.kt:12 box: // test.kt:6 foo: a:A=A, block:kotlin.jvm.functions.Function3=TestKt$box$1 -// EXPECTATIONS JVM_IR // test.kt:13 invoke: w:int=1:int // test.kt:15 invoke: w:int=1:int, x:double=1.0:double, y:char=0:char -// EXPECTATIONS JVM -// test.kt:15 invoke: $dstr$x$_u24__u24$y:A=A, $noName_1:java.lang.String="":java.lang.String, w:int=1:int -// EXPECTATIONS JVM JVM_IR // test.kt:4 : x:double=1.0:double, y:java.lang.String="":java.lang.String, z:char=0:char -// EXPECTATIONS JVM -// test.kt:15 invoke: $dstr$x$_u24__u24$y:A=A, $noName_1:java.lang.String="":java.lang.String, w:int=1:int, x:double=1.0:double, y:char=0:char -// test.kt:16 invoke: $dstr$x$_u24__u24$y:A=A, $noName_1:java.lang.String="":java.lang.String, w:int=1:int, x:double=1.0:double, y:char=0:char, a:double=1.0:double, c:char=0:char -// EXPECTATIONS JVM_IR // test.kt:15 invoke: w:int=1:int, x:double=1.0:double, y:char=0:char // test.kt:16 invoke: w:int=1:int, x:double=1.0:double, y:char=0:char, a:double=1.0:double, c:char=0:char -// EXPECTATIONS JVM JVM_IR // test.kt:4 : x:double=1.0:double, y:java.lang.String="":java.lang.String, z:char=0:char -// EXPECTATIONS JVM -// test.kt:16 invoke: $dstr$x$_u24__u24$y:A=A, $noName_1:java.lang.String="":java.lang.String, w:int=1:int, x:double=1.0:double, y:char=0:char, a:double=1.0:double, c:char=0:char -// test.kt:18 invoke: $dstr$x$_u24__u24$y:A=A, $noName_1:java.lang.String="":java.lang.String, w:int=1:int, x:double=1.0:double, y:char=0:char, a:double=1.0:double, c:char=0:char, _:java.lang.String="":java.lang.String, d:char=0:char -// EXPECTATIONS JVM_IR // test.kt:16 invoke: w:int=1:int, x:double=1.0:double, y:char=0:char, a:double=1.0:double, c:char=0:char // test.kt:18 invoke: w:int=1:int, x:double=1.0:double, y:char=0:char, a:double=1.0:double, c:char=0:char, _:java.lang.String="":java.lang.String, d:char=0:char -// EXPECTATIONS JVM JVM_IR // test.kt:8 getArrayOfA: -// EXPECTATIONS JVM -// test.kt:18 invoke: $dstr$x$_u24__u24$y:A=A, $noName_1:java.lang.String="":java.lang.String, w:int=1:int, x:double=1.0:double, y:char=0:char, a:double=1.0:double, c:char=0:char, _:java.lang.String="":java.lang.String, d:char=0:char -// test.kt:22 invoke: $dstr$x$_u24__u24$y:A=A, $noName_1:java.lang.String="":java.lang.String, w:int=1:int, x:double=1.0:double, y:char=0:char, a:double=1.0:double, c:char=0:char, _:java.lang.String="":java.lang.String, d:char=0:char -// EXPECTATIONS JVM_IR // test.kt:18 invoke: w:int=1:int, x:double=1.0:double, y:char=0:char, a:double=1.0:double, c:char=0:char, _:java.lang.String="":java.lang.String, d:char=0:char // test.kt:22 invoke: w:int=1:int, x:double=1.0:double, y:char=0:char, a:double=1.0:double, c:char=0:char, _:java.lang.String="":java.lang.String, d:char=0:char -// EXPECTATIONS JVM JVM_IR // test.kt:6 foo: a:A=A, block:kotlin.jvm.functions.Function3=TestKt$box$1 // test.kt:12 box: // test.kt:24 box: diff --git a/compiler/tests-common-new/tests-gen/org/jetbrains/kotlin/test/runners/codegen/LocalVariableTestGenerated.java b/compiler/tests-common-new/tests-gen/org/jetbrains/kotlin/test/runners/codegen/LocalVariableTestGenerated.java deleted file mode 100644 index dd8d0bca6cb..00000000000 --- a/compiler/tests-common-new/tests-gen/org/jetbrains/kotlin/test/runners/codegen/LocalVariableTestGenerated.java +++ /dev/null @@ -1,497 +0,0 @@ -/* - * Copyright 2010-2023 JetBrains s.r.o. and Kotlin Programming Language contributors. - * Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file. - */ - -package org.jetbrains.kotlin.test.runners.codegen; - -import com.intellij.testFramework.TestDataPath; -import org.jetbrains.kotlin.test.util.KtTestUtil; -import org.jetbrains.kotlin.test.TargetBackend; -import org.jetbrains.kotlin.test.TestMetadata; -import org.junit.jupiter.api.Nested; -import org.junit.jupiter.api.Test; - -import java.io.File; -import java.util.regex.Pattern; - -/** This class is generated by {@link org.jetbrains.kotlin.test.generators.GenerateCompilerTestsKt}. DO NOT MODIFY MANUALLY */ -@SuppressWarnings("all") -@TestMetadata("compiler/testData/debug/localVariables") -@TestDataPath("$PROJECT_ROOT") -public class LocalVariableTestGenerated extends AbstractLocalVariableTest { - @Test - public void testAllFilesPresentInLocalVariables() throws Exception { - KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/debug/localVariables"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM, true); - } - - @Test - @TestMetadata("assignment.kt") - public void testAssignment() throws Exception { - runTest("compiler/testData/debug/localVariables/assignment.kt"); - } - - @Test - @TestMetadata("catchClause.kt") - public void testCatchClause() throws Exception { - runTest("compiler/testData/debug/localVariables/catchClause.kt"); - } - - @Test - @TestMetadata("copyFunction.kt") - public void testCopyFunction() throws Exception { - runTest("compiler/testData/debug/localVariables/copyFunction.kt"); - } - - @Test - @TestMetadata("directInvoke.kt") - public void testDirectInvoke() throws Exception { - runTest("compiler/testData/debug/localVariables/directInvoke.kt"); - } - - @Test - @TestMetadata("doWhile.kt") - public void testDoWhile() throws Exception { - runTest("compiler/testData/debug/localVariables/doWhile.kt"); - } - - @Test - @TestMetadata("emptyFun.kt") - public void testEmptyFun() throws Exception { - runTest("compiler/testData/debug/localVariables/emptyFun.kt"); - } - - @Test - @TestMetadata("forLoopMultiline.kt") - public void testForLoopMultiline() throws Exception { - runTest("compiler/testData/debug/localVariables/forLoopMultiline.kt"); - } - - @Test - @TestMetadata("inlineFunInObject.kt") - public void testInlineFunInObject() throws Exception { - runTest("compiler/testData/debug/localVariables/inlineFunInObject.kt"); - } - - @Test - @TestMetadata("inlineProperty.kt") - public void testInlineProperty() throws Exception { - runTest("compiler/testData/debug/localVariables/inlineProperty.kt"); - } - - @Test - @TestMetadata("jvmOverloads.kt") - public void testJvmOverloads() throws Exception { - runTest("compiler/testData/debug/localVariables/jvmOverloads.kt"); - } - - @Test - @TestMetadata("lambdaInObject.kt") - public void testLambdaInObject() throws Exception { - runTest("compiler/testData/debug/localVariables/lambdaInObject.kt"); - } - - @Test - @TestMetadata("lambdaWithLambdaParameter.kt") - public void testLambdaWithLambdaParameter() throws Exception { - runTest("compiler/testData/debug/localVariables/lambdaWithLambdaParameter.kt"); - } - - @Test - @TestMetadata("localFun.kt") - public void testLocalFun() throws Exception { - runTest("compiler/testData/debug/localVariables/localFun.kt"); - } - - @Test - @TestMetadata("localFunUnused.kt") - public void testLocalFunUnused() throws Exception { - runTest("compiler/testData/debug/localVariables/localFunUnused.kt"); - } - - @Test - @TestMetadata("tryFinally.kt") - public void testTryFinally() throws Exception { - runTest("compiler/testData/debug/localVariables/tryFinally.kt"); - } - - @Test - @TestMetadata("tryFinally10.kt") - public void testTryFinally10() throws Exception { - runTest("compiler/testData/debug/localVariables/tryFinally10.kt"); - } - - @Test - @TestMetadata("tryFinally11.kt") - public void testTryFinally11() throws Exception { - runTest("compiler/testData/debug/localVariables/tryFinally11.kt"); - } - - @Test - @TestMetadata("tryFinally12.kt") - public void testTryFinally12() throws Exception { - runTest("compiler/testData/debug/localVariables/tryFinally12.kt"); - } - - @Test - @TestMetadata("tryFinally13.kt") - public void testTryFinally13() throws Exception { - runTest("compiler/testData/debug/localVariables/tryFinally13.kt"); - } - - @Test - @TestMetadata("tryFinally14.kt") - public void testTryFinally14() throws Exception { - runTest("compiler/testData/debug/localVariables/tryFinally14.kt"); - } - - @Test - @TestMetadata("tryFinally15.kt") - public void testTryFinally15() throws Exception { - runTest("compiler/testData/debug/localVariables/tryFinally15.kt"); - } - - @Test - @TestMetadata("tryFinally16.kt") - public void testTryFinally16() throws Exception { - runTest("compiler/testData/debug/localVariables/tryFinally16.kt"); - } - - @Test - @TestMetadata("tryFinally17.kt") - public void testTryFinally17() throws Exception { - runTest("compiler/testData/debug/localVariables/tryFinally17.kt"); - } - - @Test - @TestMetadata("tryFinally2.kt") - public void testTryFinally2() throws Exception { - runTest("compiler/testData/debug/localVariables/tryFinally2.kt"); - } - - @Test - @TestMetadata("tryFinally3.kt") - public void testTryFinally3() throws Exception { - runTest("compiler/testData/debug/localVariables/tryFinally3.kt"); - } - - @Test - @TestMetadata("tryFinally4.kt") - public void testTryFinally4() throws Exception { - runTest("compiler/testData/debug/localVariables/tryFinally4.kt"); - } - - @Test - @TestMetadata("tryFinally5.kt") - public void testTryFinally5() throws Exception { - runTest("compiler/testData/debug/localVariables/tryFinally5.kt"); - } - - @Test - @TestMetadata("tryFinally6_1.kt") - public void testTryFinally6_1() throws Exception { - runTest("compiler/testData/debug/localVariables/tryFinally6_1.kt"); - } - - @Test - @TestMetadata("tryFinally6_2.kt") - public void testTryFinally6_2() throws Exception { - runTest("compiler/testData/debug/localVariables/tryFinally6_2.kt"); - } - - @Test - @TestMetadata("tryFinally7.kt") - public void testTryFinally7() throws Exception { - runTest("compiler/testData/debug/localVariables/tryFinally7.kt"); - } - - @Test - @TestMetadata("tryFinally8.kt") - public void testTryFinally8() throws Exception { - runTest("compiler/testData/debug/localVariables/tryFinally8.kt"); - } - - @Test - @TestMetadata("tryFinally9.kt") - public void testTryFinally9() throws Exception { - runTest("compiler/testData/debug/localVariables/tryFinally9.kt"); - } - - @Test - @TestMetadata("underscoreNames.kt") - public void testUnderscoreNames() throws Exception { - runTest("compiler/testData/debug/localVariables/underscoreNames.kt"); - } - - @Nested - @TestMetadata("compiler/testData/debug/localVariables/constructors") - @TestDataPath("$PROJECT_ROOT") - public class Constructors { - @Test - public void testAllFilesPresentInConstructors() throws Exception { - KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/debug/localVariables/constructors"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM, true); - } - - @Test - @TestMetadata("multipleConstructors.kt") - public void testMultipleConstructors() throws Exception { - runTest("compiler/testData/debug/localVariables/constructors/multipleConstructors.kt"); - } - - @Test - @TestMetadata("property.kt") - public void testProperty() throws Exception { - runTest("compiler/testData/debug/localVariables/constructors/property.kt"); - } - } - - @Nested - @TestMetadata("compiler/testData/debug/localVariables/destructuring") - @TestDataPath("$PROJECT_ROOT") - public class Destructuring { - @Test - public void testAllFilesPresentInDestructuring() throws Exception { - KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/debug/localVariables/destructuring"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM, true); - } - - @Test - @TestMetadata("assignment.kt") - public void testAssignment() throws Exception { - runTest("compiler/testData/debug/localVariables/destructuring/assignment.kt"); - } - - @Test - @TestMetadata("assignmentCustomComponentNs.kt") - public void testAssignmentCustomComponentNs() throws Exception { - runTest("compiler/testData/debug/localVariables/destructuring/assignmentCustomComponentNs.kt"); - } - - @Test - @TestMetadata("assignmentCustomComponentNsMultiline.kt") - public void testAssignmentCustomComponentNsMultiline() throws Exception { - runTest("compiler/testData/debug/localVariables/destructuring/assignmentCustomComponentNsMultiline.kt"); - } - - @Test - @TestMetadata("assignmentMultiline.kt") - public void testAssignmentMultiline() throws Exception { - runTest("compiler/testData/debug/localVariables/destructuring/assignmentMultiline.kt"); - } - - @Test - @TestMetadata("assignmentUnderscoreNames.kt") - public void testAssignmentUnderscoreNames() throws Exception { - runTest("compiler/testData/debug/localVariables/destructuring/assignmentUnderscoreNames.kt"); - } - - @Test - @TestMetadata("assignmentUnderscoreNamesMultiline.kt") - public void testAssignmentUnderscoreNamesMultiline() throws Exception { - runTest("compiler/testData/debug/localVariables/destructuring/assignmentUnderscoreNamesMultiline.kt"); - } - - @Test - @TestMetadata("forLoop.kt") - public void testForLoop() throws Exception { - runTest("compiler/testData/debug/localVariables/destructuring/forLoop.kt"); - } - - @Test - @TestMetadata("forLoopMultiline.kt") - public void testForLoopMultiline() throws Exception { - runTest("compiler/testData/debug/localVariables/destructuring/forLoopMultiline.kt"); - } - - @Test - @TestMetadata("lambda.kt") - public void testLambda() throws Exception { - runTest("compiler/testData/debug/localVariables/destructuring/lambda.kt"); - } - - @Test - @TestMetadata("lambdaCustomComponentNs.kt") - public void testLambdaCustomComponentNs() throws Exception { - runTest("compiler/testData/debug/localVariables/destructuring/lambdaCustomComponentNs.kt"); - } - - @Test - @TestMetadata("lambdaCustomComponentNsMultiline.kt") - public void testLambdaCustomComponentNsMultiline() throws Exception { - runTest("compiler/testData/debug/localVariables/destructuring/lambdaCustomComponentNsMultiline.kt"); - } - - @Test - @TestMetadata("lambdaMultiline.kt") - public void testLambdaMultiline() throws Exception { - runTest("compiler/testData/debug/localVariables/destructuring/lambdaMultiline.kt"); - } - - @Test - @TestMetadata("lambdaMultipleDestructs.kt") - public void testLambdaMultipleDestructs() throws Exception { - runTest("compiler/testData/debug/localVariables/destructuring/lambdaMultipleDestructs.kt"); - } - } - - @Nested - @TestMetadata("compiler/testData/debug/localVariables/receiverMangling") - @TestDataPath("$PROJECT_ROOT") - public class ReceiverMangling { - @Test - public void testAllFilesPresentInReceiverMangling() throws Exception { - KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/debug/localVariables/receiverMangling"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM, true); - } - - @Test - @TestMetadata("capturedThisField.kt") - public void testCapturedThisField() throws Exception { - runTest("compiler/testData/debug/localVariables/receiverMangling/capturedThisField.kt"); - } - - @Test - @TestMetadata("labeledThisParameterLabel.kt") - public void testLabeledThisParameterLabel() throws Exception { - runTest("compiler/testData/debug/localVariables/receiverMangling/labeledThisParameterLabel.kt"); - } - - @Test - @TestMetadata("lambdaWithExtensionReceiver.kt") - public void testLambdaWithExtensionReceiver() throws Exception { - runTest("compiler/testData/debug/localVariables/receiverMangling/lambdaWithExtensionReceiver.kt"); - } - - @Test - @TestMetadata("receiverParameter.kt") - public void testReceiverParameter() throws Exception { - runTest("compiler/testData/debug/localVariables/receiverMangling/receiverParameter.kt"); - } - - @Test - @TestMetadata("simple.kt") - public void testSimple() throws Exception { - runTest("compiler/testData/debug/localVariables/receiverMangling/simple.kt"); - } - - @Test - @TestMetadata("simpleCapturedReceiver.kt") - public void testSimpleCapturedReceiver() throws Exception { - runTest("compiler/testData/debug/localVariables/receiverMangling/simpleCapturedReceiver.kt"); - } - - @Test - @TestMetadata("simpleCapturedReceiverWithLabel.kt") - public void testSimpleCapturedReceiverWithLabel() throws Exception { - runTest("compiler/testData/debug/localVariables/receiverMangling/simpleCapturedReceiverWithLabel.kt"); - } - - @Test - @TestMetadata("simpleCapturedReceiverWithParenthesis.kt") - public void testSimpleCapturedReceiverWithParenthesis() throws Exception { - runTest("compiler/testData/debug/localVariables/receiverMangling/simpleCapturedReceiverWithParenthesis.kt"); - } - } - - @Nested - @TestMetadata("compiler/testData/debug/localVariables/suspend") - @TestDataPath("$PROJECT_ROOT") - public class Suspend { - @Test - public void testAllFilesPresentInSuspend() throws Exception { - KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/debug/localVariables/suspend"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM, true); - } - - @Test - @TestMetadata("inlineLocalsStateMachineTransform.kt") - public void testInlineLocalsStateMachineTransform() throws Exception { - runTest("compiler/testData/debug/localVariables/suspend/inlineLocalsStateMachineTransform.kt"); - } - - @Test - @TestMetadata("localsStateMachineTransform.kt") - public void testLocalsStateMachineTransform() throws Exception { - runTest("compiler/testData/debug/localVariables/suspend/localsStateMachineTransform.kt"); - } - - @Test - @TestMetadata("mergeLvt.kt") - public void testMergeLvt() throws Exception { - runTest("compiler/testData/debug/localVariables/suspend/mergeLvt.kt"); - } - - @Test - @TestMetadata("nestedInsideSuspendUnintercepted.kt") - public void testNestedInsideSuspendUnintercepted() throws Exception { - runTest("compiler/testData/debug/localVariables/suspend/nestedInsideSuspendUnintercepted.kt"); - } - - @Test - @TestMetadata("nestedSuspendUnintercepted.kt") - public void testNestedSuspendUnintercepted() throws Exception { - runTest("compiler/testData/debug/localVariables/suspend/nestedSuspendUnintercepted.kt"); - } - - @Test - @TestMetadata("nestedSuspendUninterceptedWithDeepLambdaCall.kt") - public void testNestedSuspendUninterceptedWithDeepLambdaCall() throws Exception { - runTest("compiler/testData/debug/localVariables/suspend/nestedSuspendUninterceptedWithDeepLambdaCall.kt"); - } - - @Test - @TestMetadata("simple.kt") - public void testSimple() throws Exception { - runTest("compiler/testData/debug/localVariables/suspend/simple.kt"); - } - - @Test - @TestMetadata("underscoreNames.kt") - public void testUnderscoreNames() throws Exception { - runTest("compiler/testData/debug/localVariables/suspend/underscoreNames.kt"); - } - - @Nested - @TestMetadata("compiler/testData/debug/localVariables/suspend/completion") - @TestDataPath("$PROJECT_ROOT") - public class Completion { - @Test - public void testAllFilesPresentInCompletion() throws Exception { - KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/debug/localVariables/suspend/completion"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM, true); - } - - @Test - @TestMetadata("nonStaticSimple.kt") - public void testNonStaticSimple() throws Exception { - runTest("compiler/testData/debug/localVariables/suspend/completion/nonStaticSimple.kt"); - } - - @Test - @TestMetadata("nonStaticStateMachine.kt") - public void testNonStaticStateMachine() throws Exception { - runTest("compiler/testData/debug/localVariables/suspend/completion/nonStaticStateMachine.kt"); - } - - @Test - @TestMetadata("staticSimple.kt") - public void testStaticSimple() throws Exception { - runTest("compiler/testData/debug/localVariables/suspend/completion/staticSimple.kt"); - } - - @Test - @TestMetadata("staticSimpleReceiver.kt") - public void testStaticSimpleReceiver() throws Exception { - runTest("compiler/testData/debug/localVariables/suspend/completion/staticSimpleReceiver.kt"); - } - - @Test - @TestMetadata("staticStateMachine.kt") - public void testStaticStateMachine() throws Exception { - runTest("compiler/testData/debug/localVariables/suspend/completion/staticStateMachine.kt"); - } - - @Test - @TestMetadata("staticStateMachineReceiver.kt") - public void testStaticStateMachineReceiver() throws Exception { - runTest("compiler/testData/debug/localVariables/suspend/completion/staticStateMachineReceiver.kt"); - } - } - } -} diff --git a/compiler/tests-common-new/tests/org/jetbrains/kotlin/test/runners/codegen/AbstractLocalVariableTest.kt b/compiler/tests-common-new/tests/org/jetbrains/kotlin/test/runners/codegen/AbstractLocalVariableTest.kt index 3dbd8c816f9..7c99b2f3c62 100644 --- a/compiler/tests-common-new/tests/org/jetbrains/kotlin/test/runners/codegen/AbstractLocalVariableTest.kt +++ b/compiler/tests-common-new/tests/org/jetbrains/kotlin/test/runners/codegen/AbstractLocalVariableTest.kt @@ -7,35 +7,26 @@ package org.jetbrains.kotlin.test.runners.codegen import org.jetbrains.kotlin.test.Constructor import org.jetbrains.kotlin.test.FirParser -import org.jetbrains.kotlin.test.TargetBackend -import org.jetbrains.kotlin.test.backend.classic.ClassicBackendInput -import org.jetbrains.kotlin.test.backend.classic.ClassicJvmBackendFacade import org.jetbrains.kotlin.test.backend.ir.IrBackendInput -import org.jetbrains.kotlin.test.backend.ir.JvmIrBackendFacade import org.jetbrains.kotlin.test.builders.TestConfigurationBuilder import org.jetbrains.kotlin.test.directives.configureFirParser -import org.jetbrains.kotlin.test.frontend.classic.ClassicFrontend2ClassicBackendConverter import org.jetbrains.kotlin.test.frontend.classic.ClassicFrontend2IrConverter import org.jetbrains.kotlin.test.frontend.classic.ClassicFrontendFacade import org.jetbrains.kotlin.test.frontend.classic.ClassicFrontendOutputArtifact import org.jetbrains.kotlin.test.frontend.fir.Fir2IrResultsConverter import org.jetbrains.kotlin.test.frontend.fir.FirFrontendFacade import org.jetbrains.kotlin.test.frontend.fir.FirOutputArtifact -import org.jetbrains.kotlin.test.model.* +import org.jetbrains.kotlin.test.model.Frontend2BackendConverter +import org.jetbrains.kotlin.test.model.FrontendFacade +import org.jetbrains.kotlin.test.model.FrontendKinds -open class AbstractIrLocalVariableTest : AbstractLocalVariableTestBase( - FrontendKinds.ClassicFrontend, - TargetBackend.JVM_IR -) { +open class AbstractIrLocalVariableTest : AbstractLocalVariableTestBase(FrontendKinds.ClassicFrontend) { override val frontendFacade: Constructor> get() = ::ClassicFrontendFacade override val frontendToBackendConverter: Constructor> get() = ::ClassicFrontend2IrConverter - override val backendFacade: Constructor> - get() = ::JvmIrBackendFacade - override fun configure(builder: TestConfigurationBuilder) { super.configure(builder) builder.configureDumpHandlersForCodegenTest() @@ -50,39 +41,13 @@ open class AbstractIrLocalVariableIrInlinerTest : AbstractIrLocalVariableTest() } } -open class AbstractLocalVariableTest : AbstractLocalVariableTestBase( - FrontendKinds.ClassicFrontend, - TargetBackend.JVM -) { - - override val frontendFacade: Constructor> - get() = ::ClassicFrontendFacade - - override val frontendToBackendConverter: Constructor> - get() = ::ClassicFrontend2ClassicBackendConverter - - override val backendFacade: Constructor> - get() = ::ClassicJvmBackendFacade - - override fun configure(builder: TestConfigurationBuilder) { - super.configure(builder) - builder.configureDumpHandlersForCodegenTest() - } -} - -open class AbstractFirLocalVariableTestBase(val parser: FirParser) : AbstractLocalVariableTestBase( - FrontendKinds.FIR, - TargetBackend.JVM_IR -) { +open class AbstractFirLocalVariableTestBase(val parser: FirParser) : AbstractLocalVariableTestBase(FrontendKinds.FIR) { override val frontendFacade: Constructor> get() = ::FirFrontendFacade override val frontendToBackendConverter: Constructor> get() = ::Fir2IrResultsConverter - override val backendFacade: Constructor> - get() = ::JvmIrBackendFacade - override fun configure(builder: TestConfigurationBuilder) { super.configure(builder) builder.configureDumpHandlersForCodegenTest() diff --git a/compiler/tests-common-new/tests/org/jetbrains/kotlin/test/runners/codegen/AbstractLocalVariableTestBase.kt b/compiler/tests-common-new/tests/org/jetbrains/kotlin/test/runners/codegen/AbstractLocalVariableTestBase.kt index 873122d5c34..29a0d74bd28 100644 --- a/compiler/tests-common-new/tests/org/jetbrains/kotlin/test/runners/codegen/AbstractLocalVariableTestBase.kt +++ b/compiler/tests-common-new/tests/org/jetbrains/kotlin/test/runners/codegen/AbstractLocalVariableTestBase.kt @@ -9,22 +9,25 @@ import org.jetbrains.kotlin.test.Constructor import org.jetbrains.kotlin.test.TargetBackend import org.jetbrains.kotlin.test.backend.BlackBoxCodegenSuppressor import org.jetbrains.kotlin.test.backend.BlackBoxInlinerCodegenSuppressor +import org.jetbrains.kotlin.test.backend.ir.IrBackendInput +import org.jetbrains.kotlin.test.backend.ir.JvmIrBackendFacade import org.jetbrains.kotlin.test.builders.TestConfigurationBuilder import org.jetbrains.kotlin.test.directives.CodegenTestDirectives.REQUIRES_SEPARATE_PROCESS import org.jetbrains.kotlin.test.directives.DiagnosticsDirectives.REPORT_ONLY_EXPLICITLY_DEFINED_DEBUG_INFO -import org.jetbrains.kotlin.test.model.* +import org.jetbrains.kotlin.test.model.Frontend2BackendConverter +import org.jetbrains.kotlin.test.model.FrontendFacade +import org.jetbrains.kotlin.test.model.FrontendKind +import org.jetbrains.kotlin.test.model.ResultingArtifact import org.jetbrains.kotlin.test.runners.AbstractKotlinCompilerWithTargetBackendTest -abstract class AbstractLocalVariableTestBase, I : ResultingArtifact.BackendInput>( +abstract class AbstractLocalVariableTestBase>( val targetFrontend: FrontendKind, - targetBackend: TargetBackend -) : AbstractKotlinCompilerWithTargetBackendTest(targetBackend) { +) : AbstractKotlinCompilerWithTargetBackendTest(TargetBackend.JVM_IR) { abstract val frontendFacade: Constructor> - abstract val frontendToBackendConverter: Constructor> - abstract val backendFacade: Constructor> + abstract val frontendToBackendConverter: Constructor> override fun TestConfigurationBuilder.configuration() { - commonConfigurationForTest(targetFrontend, frontendFacade, frontendToBackendConverter, backendFacade) { + commonConfigurationForTest(targetFrontend, frontendFacade, frontendToBackendConverter, ::JvmIrBackendFacade) { commonServicesConfigurationForDebugTest(it) } diff --git a/compiler/tests-for-compiler-generator/tests/org/jetbrains/kotlin/test/generators/GenerateJUnit5CompilerTests.kt b/compiler/tests-for-compiler-generator/tests/org/jetbrains/kotlin/test/generators/GenerateJUnit5CompilerTests.kt index 6cdcd03e2ab..82bf0c68b99 100644 --- a/compiler/tests-for-compiler-generator/tests/org/jetbrains/kotlin/test/generators/GenerateJUnit5CompilerTests.kt +++ b/compiler/tests-for-compiler-generator/tests/org/jetbrains/kotlin/test/generators/GenerateJUnit5CompilerTests.kt @@ -92,10 +92,6 @@ fun generateJUnit5CompilerTests(args: Array, mainClassName: String?) { model("debug/stepping") } - testClass { - model("debug/localVariables") - } - testClass { model("debug/localVariables") }