diff --git a/compiler/ir/ir.psi2ir/src/org/jetbrains/kotlin/psi2ir/generators/StatementGenerator.kt b/compiler/ir/ir.psi2ir/src/org/jetbrains/kotlin/psi2ir/generators/StatementGenerator.kt index 6c632a18798..998850bf52a 100644 --- a/compiler/ir/ir.psi2ir/src/org/jetbrains/kotlin/psi2ir/generators/StatementGenerator.kt +++ b/compiler/ir/ir.psi2ir/src/org/jetbrains/kotlin/psi2ir/generators/StatementGenerator.kt @@ -302,7 +302,7 @@ internal class StatementGenerator( 1 -> { val first = entries.first() if (first is IrConst<*> && first.kind == IrConstKind.String) - first + IrConstImpl.string(startOffset, endOffset, first.type, first.value as String) else IrStringConcatenationImpl(startOffset, endOffset, resultType, listOf(first)) } diff --git a/compiler/testData/debug/stepping/anonymousFunction.kt b/compiler/testData/debug/stepping/anonymousFunction.kt index d30df8d24ab..023f9a5cf86 100644 --- a/compiler/testData/debug/stepping/anonymousFunction.kt +++ b/compiler/testData/debug/stepping/anonymousFunction.kt @@ -27,7 +27,7 @@ fun box() { // test.kt:1 $box // test.kt:7 $box // test.kt:4 $eval (27, 30) -// test.kt:8 $box$lambda.invoke (9, 9, 9, 9) +// test.kt:8 $box$lambda.invoke (8, 8, 8, 8) // String.kt:141 $kotlin.stringLiteral (17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) diff --git a/compiler/testData/debug/stepping/anonymousFunctionDirect.kt b/compiler/testData/debug/stepping/anonymousFunctionDirect.kt index ea7d239d54e..6bafab12394 100644 --- a/compiler/testData/debug/stepping/anonymousFunctionDirect.kt +++ b/compiler/testData/debug/stepping/anonymousFunctionDirect.kt @@ -19,7 +19,7 @@ fun box() { // EXPECTATIONS WASM // test.kt:1 $box // test.kt:5 $box -// test.kt:6 $box$lambda.invoke (9, 9, 9, 9) +// test.kt:6 $box$lambda.invoke (8, 8, 8, 8) // String.kt:141 $kotlin.stringLiteral (17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) diff --git a/compiler/testData/debug/stepping/assertion.kt b/compiler/testData/debug/stepping/assertion.kt index 16386de9a16..75cc65ed477 100644 --- a/compiler/testData/debug/stepping/assertion.kt +++ b/compiler/testData/debug/stepping/assertion.kt @@ -1,5 +1,5 @@ // IGNORE_INLINER: IR -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt public val MASSERTIONS_ENABLED: Boolean = true @@ -56,7 +56,7 @@ fun box(): String { // EXPECTATIONS WASM // test.kt:1 $box__JsExportAdapter // test.kt:26 $box (4, 12, 4) -// test.kt:17 $box (58, 58, 58, 58) +// test.kt:17 $box (57, 57, 57, 57) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -75,7 +75,7 @@ fun box(): String { // test.kt:27 $box (4, 12, 4) // test.kt:8 $box // test.kt:9 $box (13, 12) -// test.kt:31 $box (12, 12, 12, 12, 4) +// test.kt:31 $box (11, 11, 11, 11, 4) // ExternalWrapper.kt:200 $kotlin.wasm.internal.kotlinToJsStringAdapter // ExternalWrapper.kt:201 $kotlin.wasm.internal.kotlinToJsStringAdapter // Strings.kt:161 $kotlin.wasm.internal.kotlinToJsStringAdapter diff --git a/compiler/testData/debug/stepping/constructors.kt b/compiler/testData/debug/stepping/constructors.kt index cf31674b011..0fe01b8ecbf 100644 --- a/compiler/testData/debug/stepping/constructors.kt +++ b/compiler/testData/debug/stepping/constructors.kt @@ -244,7 +244,7 @@ class O(i: T) { // test.kt:68 $N. // test.kt:16 $box (4, 6, 6, 6, 6, 4, 4) // test.kt:76 $O. (1, 1) -// test.kt:17 $box (4, 6, 10, 10, 10, 10, 4, 4) +// test.kt:17 $box (4, 6, 9, 9, 9, 9, 4, 4) // String.kt:141 $kotlin.stringLiteral (17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) diff --git a/compiler/testData/debug/stepping/continue.kt b/compiler/testData/debug/stepping/continue.kt index 280b2be6bd9..8e03743f014 100644 --- a/compiler/testData/debug/stepping/continue.kt +++ b/compiler/testData/debug/stepping/continue.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // WITH_STDLIB // FILE: test.kt @@ -66,7 +66,7 @@ fun box() { // EXPECTATIONS WASM // test.kt:5 $ -// Library.kt:2 $ (79, 79, 79, 79, 80, 80, 80, 80, 79, 79) +// Library.kt:2 $ (53, 53, 53, 53, 59, 59, 59, 59, 65, 65, 65, 65, 70, 70, 70, 70, 53, 53) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -80,13 +80,12 @@ fun box() { // Array.kt:75 $kotlin.Array.set (8, 20, 27, 16, 8, 20, 27, 16, 8, 20, 27, 16, 8, 20, 27, 16) // Array.kt:76 $kotlin.Array.set (5, 5, 5, 5) // String.kt:149 $kotlin.stringLiteral (11, 4, 11, 4, 11, 4, 11, 4) -// Library.kt:3 $ (0, 0, 0, 0, 6, 6, 6, 6, 11, 11, 11, 11) // Library.kt:39 $ (62, 82) // test.kt:1 $box // test.kt:8 $box (14, 14, 14, 14, 14, 4, 14, 4, 4, 4, 14, 9, 14, 4, 14, 4, 4, 4, 14, 9, 14, 4, 14, 4, 4, 4, 14, 9, 14, 4, 14, 4, 4, 4, 14, 9, 14, 4, 14, 4, 4, 4) // test.kt:5 $ // Array.kt:82 $kotlin.Array. (16, 24, 29) -// test.kt:9 $box (12, 18, 18, 18, 18, 12, 12, 18, 18, 18, 18, 12, 25, 31, 31, 31, 31, 25, 12, 18, 18, 18, 18, 12, 25, 31, 31, 31, 31, 25, 12, 18, 18, 18, 18, 12, 25, 31, 31, 31, 31, 25) +// test.kt:9 $box (12, 17, 17, 17, 17, 12, 12, 17, 17, 17, 17, 12, 25, 30, 30, 30, 30, 25, 12, 17, 17, 17, 17, 12, 25, 30, 30, 30, 30, 25, 12, 17, 17, 17, 17, 12, 25, 30, 30, 30, 30, 25) // String.kt:143 $kotlin.stringLiteral (15, 8, 15, 8, 15, 8, 15, 8, 15, 8, 15, 8, 15, 8, 15, 8, 15, 8) // String.kt:98 $kotlin.String.equals (12, 12, 12, 12, 12, 12, 12, 12, 12) // String.kt:99 $kotlin.String.equals (12, 35, 28, 12, 12, 35, 28, 12, 12, 12, 35, 28, 12, 12, 12) @@ -109,7 +108,7 @@ fun box() { // Standard.kt:155 $kotlin.String.equals (8, 15, 8, 15, 8, 15) // Standard.kt:126 $kotlin.String.equals (1, 1, 13, 6, 1, 13, 6) // Standard.kt:125 $kotlin.String.equals (3, 3, 3) -// test.kt:12 $box (12, 18, 18, 18, 18, 12, 12, 18, 18, 18, 18, 12) +// test.kt:12 $box (12, 17, 17, 17, 17, 12, 12, 17, 17, 17, 17, 12) // test.kt:13 $box // test.kt:15 $box (16, 8) // io.kt:28 $kotlin.io.println (16, 16, 25, 25, 25, 4) diff --git a/compiler/testData/debug/stepping/dataClass.kt b/compiler/testData/debug/stepping/dataClass.kt index eeac542d1c3..b635d497c15 100644 --- a/compiler/testData/debug/stepping/dataClass.kt +++ b/compiler/testData/debug/stepping/dataClass.kt @@ -119,7 +119,7 @@ fun box() { // test.kt:26 box // EXPECTATIONS WASM -// test.kt:14 $box (12, 14, 18, 18, 18, 18, 12) +// test.kt:14 $box (12, 14, 17, 17, 17, 17, 12) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -134,7 +134,7 @@ fun box() { // Array.kt:76 $kotlin.Array.set (5, 5, 5, 5, 5, 5, 5, 5, 5, 5) // String.kt:149 $kotlin.stringLiteral (11, 4, 11, 4, 11, 4, 11, 4, 11, 4, 11, 4, 11, 4, 11, 4, 11, 4, 11, 4) // test.kt:4 $D. (13, 25, 39, 13, 25, 39, 13, 25, 39) -// test.kt:15 $box (4, 13, 15, 19, 19, 19, 19, 13, 6, 6) +// test.kt:15 $box (4, 13, 15, 18, 18, 18, 18, 13, 6, 6) // String.kt:143 $kotlin.stringLiteral (15, 8, 15, 8, 15, 8) // String.kt:98 $kotlin.String.equals // String.kt:99 $kotlin.String.equals (12, 35, 28) @@ -305,15 +305,15 @@ fun box() { // test.kt:18 $box (17, 9, 9, 17, 12, 12) // test.kt:1 $D.component1 // test.kt:19 $box (4, 6, 6, 6, 6, 6, 6) -// test.kt:20 $box (12, 14, 18, 18, 18, 18, 12) +// test.kt:20 $box (12, 14, 17, 17, 17, 17, 12) // test.kt:6 $E. (13, 25, 13, 25, 13, 25) // test.kt:11 $E. (1, 1, 1) -// test.kt:21 $box (4, 13, 15, 19, 19, 19, 19, 13, 6, 6) +// test.kt:21 $box (4, 13, 15, 18, 18, 18, 18, 13, 6, 6) // test.kt:8 $E.equals (39, 44) // test.kt:22 $box (4, 6, 6) // test.kt:9 $E.hashCode (30, 32) // test.kt:23 $box (4, 6, 6) -// test.kt:7 $E.toString (31, 31, 31, 31, 33) +// test.kt:7 $E.toString (30, 30, 30, 30, 34) // test.kt:24 $box (19, 9, 9, 19, 13, 13) // test.kt:1 $E.component1 // test.kt:25 $box (4, 6, 6) diff --git a/compiler/testData/debug/stepping/if2.kt b/compiler/testData/debug/stepping/if2.kt index 84fa117fad7..f54fec096a7 100644 --- a/compiler/testData/debug/stepping/if2.kt +++ b/compiler/testData/debug/stepping/if2.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt fun foo(x: Int) { @@ -50,7 +50,7 @@ fun box() { // test.kt:1 $box // test.kt:21 $box (8, 4) // test.kt:5 $foo (8, 12, 8, 8, 12, 8) -// test.kt:6 $foo (9, 9, 9, 9) +// test.kt:6 $foo (8, 8, 8, 8) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -66,10 +66,10 @@ fun box() { // String.kt:149 $kotlin.stringLiteral (11, 4, 11, 4) // test.kt:9 $foo (8, 12, 8, 8, 12, 8) // test.kt:13 $foo (8, 12, 8, 8, 12, 8) -// test.kt:14 $foo (9, 9, 9, 9) +// test.kt:14 $foo (8, 8, 8, 8) // String.kt:143 $kotlin.stringLiteral (15, 8, 15, 8) // test.kt:18 $foo (1, 1) // test.kt:22 $box (8, 4) -// test.kt:10 $foo (9, 9, 9, 9) -// test.kt:16 $foo (9, 9, 9, 9) +// test.kt:10 $foo (8, 8, 8, 8) +// test.kt:16 $foo (8, 8, 8, 8) // test.kt:23 $box diff --git a/compiler/testData/debug/stepping/ifThenElse.kt b/compiler/testData/debug/stepping/ifThenElse.kt index 79012e32d8b..613a176e80e 100644 --- a/compiler/testData/debug/stepping/ifThenElse.kt +++ b/compiler/testData/debug/stepping/ifThenElse.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt fun foo() { @@ -61,7 +61,7 @@ fun box() { // test.kt:1 $box // test.kt:21 $box // test.kt:5 $foo (8, 8) -// test.kt:6 $foo (9, 9, 9, 9) +// test.kt:6 $foo (8, 8, 8, 8) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -76,11 +76,11 @@ fun box() { // Array.kt:76 $kotlin.Array.set // String.kt:149 $kotlin.stringLiteral (11, 4) // test.kt:11 $foo (16, 4, 16, 4) -// test.kt:12 $foo (9, 9, 9, 9) +// test.kt:12 $foo (8, 8, 8, 8) // String.kt:143 $kotlin.stringLiteral (15, 8, 15, 8, 15, 8) // test.kt:16 $foo (1, 1) // test.kt:22 $box (11, 4) // test.kt:23 $box -// test.kt:8 $foo (9, 9, 9, 9) -// test.kt:14 $foo (9, 9, 9, 9) +// test.kt:8 $foo (8, 8, 8, 8) +// test.kt:14 $foo (8, 8, 8, 8) // test.kt:24 $box diff --git a/compiler/testData/debug/stepping/initBlocksCompanion.kt b/compiler/testData/debug/stepping/initBlocksCompanion.kt index 87d199833ad..eeecb5c05ca 100644 --- a/compiler/testData/debug/stepping/initBlocksCompanion.kt +++ b/compiler/testData/debug/stepping/initBlocksCompanion.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt class A { @@ -67,7 +67,7 @@ fun box() { // EXPECTATIONS WASM // test.kt:1 $box -// test.kt:9 $Companion. (12, 17, 17, 17, 17, 12) +// test.kt:9 $Companion. (12, 16, 16, 16, 16, 12) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) diff --git a/compiler/testData/debug/stepping/lambdaStepInline.kt b/compiler/testData/debug/stepping/lambdaStepInline.kt index 28a72fbf3f3..28c8b4789fc 100644 --- a/compiler/testData/debug/stepping/lambdaStepInline.kt +++ b/compiler/testData/debug/stepping/lambdaStepInline.kt @@ -30,7 +30,7 @@ fun box(): String { // EXPECTATIONS WASM // test.kt:1 $box__JsExportAdapter -// test.kt:9 $box (4, 11, 11, 11, 11) +// test.kt:9 $box (4, 10, 10, 10, 10) // test.kt:5 $box (11, 11, 4, 11, 11, 4) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8) @@ -46,8 +46,8 @@ fun box(): String { // Array.kt:76 $kotlin.Array.set (5, 5) // String.kt:149 $kotlin.stringLiteral (11, 4, 11, 4) // test.kt:10 $box -// test.kt:11 $box (9, 9, 9, 9) -// test.kt:14 $box (12, 12, 12, 12, 4) +// test.kt:11 $box (8, 8, 8, 8) +// test.kt:14 $box (11, 11, 11, 11, 4) // String.kt:143 $kotlin.stringLiteral (15, 8) // ExternalWrapper.kt:200 $kotlin.wasm.internal.kotlinToJsStringAdapter // ExternalWrapper.kt:201 $kotlin.wasm.internal.kotlinToJsStringAdapter diff --git a/compiler/testData/debug/stepping/lambdaStepInlineWithDefaults.kt b/compiler/testData/debug/stepping/lambdaStepInlineWithDefaults.kt index 8c0df8e1a9a..3c9605f9dad 100644 --- a/compiler/testData/debug/stepping/lambdaStepInlineWithDefaults.kt +++ b/compiler/testData/debug/stepping/lambdaStepInlineWithDefaults.kt @@ -37,7 +37,7 @@ fun box(): String { // test.kt:1 $box__JsExportAdapter // test.kt:15 $box // test.kt:4 $box (11, 11, 4) -// test.kt:3 $box (46, 46, 46, 46) +// test.kt:3 $box (45, 45, 45, 45) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -53,9 +53,9 @@ fun box(): String { // String.kt:149 $kotlin.stringLiteral (11, 4) // test.kt:16 $box // test.kt:11 $box (11, 11, 4) -// test.kt:8 $box (5, 5, 5, 5) +// test.kt:8 $box (4, 4, 4, 4) // String.kt:143 $kotlin.stringLiteral (15, 8, 15, 8) -// test.kt:17 $box (12, 12, 12, 12, 4) +// test.kt:17 $box (11, 11, 11, 11, 4) // ExternalWrapper.kt:200 $kotlin.wasm.internal.kotlinToJsStringAdapter // ExternalWrapper.kt:201 $kotlin.wasm.internal.kotlinToJsStringAdapter // Strings.kt:161 $kotlin.wasm.internal.kotlinToJsStringAdapter diff --git a/compiler/testData/debug/stepping/lineNumberAfterInline.kt b/compiler/testData/debug/stepping/lineNumberAfterInline.kt index 08c3b8ca25d..891b60bfc54 100644 --- a/compiler/testData/debug/stepping/lineNumberAfterInline.kt +++ b/compiler/testData/debug/stepping/lineNumberAfterInline.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt fun normalFunction() { @@ -52,7 +52,7 @@ fun box() { // test.kt:1 $box // test.kt:23 $box // test.kt:13 $test1 (4, 4) -// test.kt:9 $test1 (5, 5, 5, 5) +// test.kt:9 $test1 (4, 4, 4, 4) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -66,13 +66,13 @@ fun box() { // Array.kt:75 $kotlin.Array.set (8, 20, 27, 16) // Array.kt:76 $kotlin.Array.set // String.kt:149 $kotlin.stringLiteral (11, 4) -// test.kt:14 $test1 (5, 5, 5, 5) +// test.kt:14 $test1 (4, 4, 4, 4) // String.kt:143 $kotlin.stringLiteral (15, 8, 15, 8, 15, 8) // test.kt:15 $test1 // test.kt:24 $box // test.kt:18 $test2 -// test.kt:5 $normalFunction (5, 5, 5, 5) +// test.kt:5 $normalFunction (4, 4, 4, 4) // test.kt:6 $normalFunction -// test.kt:19 $test2 (5, 5, 5, 5) +// test.kt:19 $test2 (4, 4, 4, 4) // test.kt:20 $test2 // test.kt:25 $box diff --git a/compiler/testData/debug/stepping/linenumberForOneParametersArgumentCall.kt b/compiler/testData/debug/stepping/linenumberForOneParametersArgumentCall.kt index 67bf50e4bac..a11262c761d 100644 --- a/compiler/testData/debug/stepping/linenumberForOneParametersArgumentCall.kt +++ b/compiler/testData/debug/stepping/linenumberForOneParametersArgumentCall.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt @@ -31,7 +31,7 @@ inline fun lookAtMe(f: (String) -> Unit) { // EXPECTATIONS WASM // test.kt:1 $box // test.kt:6 $box -// test.kt:12 $box (13, 13, 13, 13, 4) +// test.kt:12 $box (12, 12, 12, 12, 4) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -46,5 +46,5 @@ inline fun lookAtMe(f: (String) -> Unit) { // Array.kt:76 $kotlin.Array.set (5, 5) // String.kt:149 $kotlin.stringLiteral (11, 4, 11, 4) // test.kt:13 $box (4, 6) -// test.kt:7 $box (17, 17, 17, 17, 8) +// test.kt:7 $box (16, 16, 16, 16, 8) // test.kt:9 $box diff --git a/compiler/testData/debug/stepping/localFunction.kt b/compiler/testData/debug/stepping/localFunction.kt index addaddd0ce8..b5ea5a16baf 100644 --- a/compiler/testData/debug/stepping/localFunction.kt +++ b/compiler/testData/debug/stepping/localFunction.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt @@ -28,7 +28,7 @@ fun box() { // EXPECTATIONS WASM // test.kt:1 $box -// test.kt:6 $box (5, 5, 5, 5) +// test.kt:6 $box (4, 4, 4, 4) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -42,10 +42,10 @@ fun box() { // Array.kt:75 $kotlin.Array.set (8, 20, 27, 16) // Array.kt:76 $kotlin.Array.set // String.kt:149 $kotlin.stringLiteral (11, 4) -// test.kt:10 $box (5, 5, 5, 5) +// test.kt:10 $box (4, 4, 4, 4) // String.kt:143 $kotlin.stringLiteral (15, 8, 15, 8, 15, 8) // test.kt:11 $box -// test.kt:8 $box$bar (9, 9, 9, 9) +// test.kt:8 $box$bar (8, 8, 8, 8) // test.kt:9 $box$bar -// test.kt:12 $box (5, 5, 5, 5) +// test.kt:12 $box (4, 4, 4, 4) // test.kt:13 $box diff --git a/compiler/testData/debug/stepping/localFunctionWIthOnelineExpressionBody.kt b/compiler/testData/debug/stepping/localFunctionWIthOnelineExpressionBody.kt index 4130766af56..2551d40a485 100644 --- a/compiler/testData/debug/stepping/localFunctionWIthOnelineExpressionBody.kt +++ b/compiler/testData/debug/stepping/localFunctionWIthOnelineExpressionBody.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt @@ -26,7 +26,7 @@ fun box() { // EXPECTATIONS WASM // test.kt:1 $box -// test.kt:6 $box (5, 5, 5, 5) +// test.kt:6 $box (4, 4, 4, 4) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -40,9 +40,9 @@ fun box() { // Array.kt:75 $kotlin.Array.set (8, 20, 27, 16) // Array.kt:76 $kotlin.Array.set // String.kt:149 $kotlin.stringLiteral (11, 4) -// test.kt:8 $box (5, 5, 5, 5) +// test.kt:8 $box (4, 4, 4, 4) // String.kt:143 $kotlin.stringLiteral (15, 8, 15, 8, 15, 8) // test.kt:9 $box (4, 4) -// test.kt:7 $box$bar (17, 17, 17, 17, 19) -// test.kt:10 $box (5, 5, 5, 5) +// test.kt:7 $box$bar (16, 16, 16, 16, 20) +// test.kt:10 $box (4, 4, 4, 4) // test.kt:11 $box diff --git a/compiler/testData/debug/stepping/localProperty.kt b/compiler/testData/debug/stepping/localProperty.kt index de20051bc5b..41709984eb1 100644 --- a/compiler/testData/debug/stepping/localProperty.kt +++ b/compiler/testData/debug/stepping/localProperty.kt @@ -1,5 +1,5 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt fun box(): String { @@ -31,7 +31,7 @@ fun box(): String { // EXPECTATIONS WASM // test.kt:1 $box__JsExportAdapter -// test.kt:9 $box (9, 9, 9, 9) +// test.kt:9 $box (8, 8, 8, 8) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -46,7 +46,7 @@ fun box(): String { // Array.kt:76 $kotlin.Array.set (5, 5) // String.kt:149 $kotlin.stringLiteral (11, 4, 11, 4) // test.kt:6 $box -// test.kt:12 $box (13, 13, 13, 13, 4) +// test.kt:12 $box (12, 12, 12, 12, 4) // test.kt:14 $box (11, 15, 11, 4) // String.kt:28 $kotlin.String.plus (20, 26, 8) // Library.kt:19 $kotlin.toString (37, 37, 43, 43, 43, 37, 37, 63) diff --git a/compiler/testData/debug/stepping/multiModule.kt b/compiler/testData/debug/stepping/multiModule.kt index 1d836750e81..a590ab2e6e0 100644 --- a/compiler/testData/debug/stepping/multiModule.kt +++ b/compiler/testData/debug/stepping/multiModule.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // MODULE: lib // FILE: a.kt @@ -35,7 +35,7 @@ fun box() { // EXPECTATIONS WASM // test.kt:1 $box // test.kt:15 $box (4, 4) -// a.kt:5 $a (11, 11, 11, 11, 12) +// a.kt:5 $a (10, 10, 10, 10, 13) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -50,5 +50,5 @@ fun box() { // Array.kt:76 $kotlin.Array.set (5, 5) // String.kt:149 $kotlin.stringLiteral (11, 4, 11, 4) // test.kt:16 $box (4, 4) -// b.kt:9 $b (11, 11, 11, 11, 12) +// b.kt:9 $b (10, 10, 10, 10, 13) // test.kt:17 $box diff --git a/compiler/testData/debug/stepping/nestedInline.kt b/compiler/testData/debug/stepping/nestedInline.kt index 399cf2812c4..2323407016b 100644 --- a/compiler/testData/debug/stepping/nestedInline.kt +++ b/compiler/testData/debug/stepping/nestedInline.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // This is same as kotlin/compiler/testData/codegen/boxInline/smap/smap.kt // FILE: test.kt @@ -76,7 +76,7 @@ inline fun html(init: () -> Unit) { // EXPECTATIONS WASM // test.kt:1 $box__JsExportAdapter // test.kt:20 $box -// test.kt:8 $box (15, 15, 15, 15, 4) +// test.kt:8 $box (14, 14, 14, 14, 4, 18, 10) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -90,12 +90,11 @@ inline fun html(init: () -> Unit) { // Array.kt:75 $kotlin.Array.set (8, 20, 27, 16, 8, 20, 27, 16) // Array.kt:76 $kotlin.Array.set (5, 5) // String.kt:149 $kotlin.stringLiteral (11, 4, 11, 4) -// test.kt:10 $box (4, 4) -// test.kt:25 $box (98, 23, 46, 39, 91) -// test.kt:2 $box +// test.kt:10 $box (4, 3, 4) +// test.kt:25 $box (124, 49, 72, 65, 117) +// test.kt:5 $box // test.kt:11 $box -// test.kt:7 $box (20, 12, 27) -// test.kt:12 $box (19, 19, 19, 19, 12) +// test.kt:12 $box (18, 18, 18, 18, 12) // test.kt:16 $box (11, 4) // test.kt:22 $box (11, 4) // ExternalWrapper.kt:200 $kotlin.wasm.internal.kotlinToJsStringAdapter diff --git a/compiler/testData/debug/stepping/nullcheck.kt b/compiler/testData/debug/stepping/nullcheck.kt index d9dc4f2dc6a..28748d7af3a 100644 --- a/compiler/testData/debug/stepping/nullcheck.kt +++ b/compiler/testData/debug/stepping/nullcheck.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt @@ -59,7 +59,7 @@ fun testExpressionBody(nullable: String?) = // EXPECTATIONS WASM // test.kt:1 $box -// test.kt:7 $box (10, 10, 10, 10, 4, 4) +// test.kt:7 $box (9, 9, 9, 9, 4, 4) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -76,7 +76,7 @@ fun testExpressionBody(nullable: String?) = // test.kt:14 $test (11, 4, 11, 4) // test.kt:16 $test (12, 21, 31, 12) // test.kt:8 $box (9, 4, 4) -// test.kt:9 $box (24, 24, 24, 24, 4, 4) +// test.kt:9 $box (23, 23, 23, 23, 4, 4) // String.kt:143 $kotlin.stringLiteral (15, 8) // test.kt:20 $testExpressionBody (4, 4) // test.kt:22 $testExpressionBody (12, 21, 31, 12, 32, 32) diff --git a/compiler/testData/debug/stepping/primitiveNullChecks.kt b/compiler/testData/debug/stepping/primitiveNullChecks.kt index 8d751547642..e388f6fed18 100644 --- a/compiler/testData/debug/stepping/primitiveNullChecks.kt +++ b/compiler/testData/debug/stepping/primitiveNullChecks.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt fun box(): String { @@ -22,7 +22,7 @@ fun box(): String { // test.kt:1 $box__JsExportAdapter // test.kt:5 $box // test.kt:6 $box -// test.kt:7 $box (12, 12, 12, 12, 4) +// test.kt:7 $box (11, 11, 11, 11, 4) // String.kt:141 $kotlin.stringLiteral (17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) diff --git a/compiler/testData/debug/stepping/simpleDefaultArg.kt b/compiler/testData/debug/stepping/simpleDefaultArg.kt index 925fb533b04..d2047727c7d 100644 --- a/compiler/testData/debug/stepping/simpleDefaultArg.kt +++ b/compiler/testData/debug/stepping/simpleDefaultArg.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt fun ifoo(ok: String = "OK"): String { @@ -23,7 +23,7 @@ fun box(): String { // EXPECTATIONS WASM // test.kt:1 $box__JsExportAdapter // test.kt:9 $box (11, 11, 11, 11, 4) -// test.kt:4 $ifoo$default (0, 23, 23, 23, 23, 0) +// test.kt:4 $ifoo$default (0, 22, 22, 22, 22, 0) // String.kt:141 $kotlin.stringLiteral (17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) diff --git a/compiler/testData/debug/stepping/simpleDefaultArgWithInline.kt b/compiler/testData/debug/stepping/simpleDefaultArgWithInline.kt index 712a19af446..1d763f0913f 100644 --- a/compiler/testData/debug/stepping/simpleDefaultArgWithInline.kt +++ b/compiler/testData/debug/stepping/simpleDefaultArgWithInline.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt @@ -32,7 +32,7 @@ fun box(): String { // EXPECTATIONS WASM // test.kt:1 $box__JsExportAdapter // test.kt:14 $box -// test.kt:5 $box (30, 30, 30, 30) +// test.kt:5 $box (29, 29, 29, 29) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -48,7 +48,7 @@ fun box(): String { // String.kt:149 $kotlin.stringLiteral (11, 4) // test.kt:6 $box (11, 4) // test.kt:15 $box (11, 11, 11, 11, 4) -// test.kt:9 $ifoo2$default (0, 24, 24, 24, 24, 0) +// test.kt:9 $ifoo2$default (0, 23, 23, 23, 23, 0) // String.kt:143 $kotlin.stringLiteral (15, 8) // test.kt:10 $ifoo2 (11, 4) // ExternalWrapper.kt:200 $kotlin.wasm.internal.kotlinToJsStringAdapter diff --git a/compiler/testData/debug/stepping/simpleInlineDefaultArg.kt b/compiler/testData/debug/stepping/simpleInlineDefaultArg.kt index e39716d7491..6981bc36104 100644 --- a/compiler/testData/debug/stepping/simpleInlineDefaultArg.kt +++ b/compiler/testData/debug/stepping/simpleInlineDefaultArg.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt inline fun alsoInline() = "OK" @@ -26,7 +26,7 @@ fun box(): String { // test.kt:1 $box__JsExportAdapter // test.kt:11 $box (11, 4) // test.kt:6 $box -// test.kt:4 $box (27, 27, 27, 27, 29) +// test.kt:4 $box (26, 26, 26, 26, 30) // String.kt:141 $kotlin.stringLiteral (17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) diff --git a/compiler/testData/debug/stepping/simpleSmap.kt b/compiler/testData/debug/stepping/simpleSmap.kt index d114c8520fa..ab4e3aa0cd6 100644 --- a/compiler/testData/debug/stepping/simpleSmap.kt +++ b/compiler/testData/debug/stepping/simpleSmap.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt @@ -29,7 +29,7 @@ fun box() { // test.kt:1 $box // test.kt:11 $box // test.kt:7 $box -// test.kt:12 $box (9, 9, 9, 9) +// test.kt:12 $box (8, 8, 8, 8) // String.kt:141 $kotlin.stringLiteral (17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) diff --git a/compiler/testData/debug/stepping/smapInlineAsArgument.kt b/compiler/testData/debug/stepping/smapInlineAsArgument.kt index b3fb462acf5..109f5a41ad6 100644 --- a/compiler/testData/debug/stepping/smapInlineAsArgument.kt +++ b/compiler/testData/debug/stepping/smapInlineAsArgument.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt fun box(){ @@ -52,7 +52,7 @@ fun fail() : String { // EXPECTATIONS WASM // test.kt:1 $box // test.kt:5 $box (16, 4) -// test.kt:17 $box (12, 12, 12, 12, 4, 12, 12, 12, 12, 4) +// test.kt:17 $box (11, 11, 11, 11, 4, 11, 11, 11, 11, 4) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -67,8 +67,8 @@ fun fail() : String { // Array.kt:76 $kotlin.Array.set (5, 5, 5) // String.kt:149 $kotlin.stringLiteral (11, 4, 11, 4, 11, 4) // test.kt:6 $box -// test.kt:21 $fail (12, 12, 12, 12, 4, 12, 12, 12, 12, 4) -// test.kt:13 $checkEquals (5, 5, 5, 5, 5, 5, 5, 5) +// test.kt:21 $fail (11, 11, 11, 11, 4, 11, 11, 11, 11, 4) +// test.kt:13 $checkEquals (4, 4, 4, 4, 4, 4, 4, 4) // test.kt:14 $checkEquals (1, 1) // test.kt:8 $box (16, 4) // String.kt:143 $kotlin.stringLiteral (15, 8, 15, 8, 15, 8) diff --git a/compiler/testData/debug/stepping/smapInlineAsInfixArgument.kt b/compiler/testData/debug/stepping/smapInlineAsInfixArgument.kt index e0f60c96926..6688a3725a1 100644 --- a/compiler/testData/debug/stepping/smapInlineAsInfixArgument.kt +++ b/compiler/testData/debug/stepping/smapInlineAsInfixArgument.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt infix fun String.execute(p: String) = this + p @@ -50,7 +50,7 @@ fun fail() : String { // EXPECTATIONS WASM // test.kt:1 $box // test.kt:7 $box (4, 4, 4) -// test.kt:15 $box (12, 12, 12, 12, 4, 12, 12, 12, 12, 4) +// test.kt:15 $box (11, 11, 11, 11, 4, 11, 11, 11, 11, 4) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -65,7 +65,7 @@ fun fail() : String { // Array.kt:76 $kotlin.Array.set (5, 5) // String.kt:149 $kotlin.stringLiteral (11, 4, 11, 4) // test.kt:8 $box -// test.kt:19 $fail (12, 12, 12, 12, 4, 12, 12, 12, 12, 4) +// test.kt:19 $fail (11, 11, 11, 11, 4, 11, 11, 11, 11, 4) // test.kt:4 $execute (38, 45, 38, 46, 38, 45, 38, 46) // String.kt:28 $kotlin.String.plus (20, 26, 8, 20, 26, 8) // Library.kt:19 $kotlin.toString (37, 37, 43, 43, 43, 37, 37, 63, 37, 37, 43, 43, 43, 37, 37, 63) diff --git a/compiler/testData/debug/stepping/smapInlineAsInlineArgument.kt b/compiler/testData/debug/stepping/smapInlineAsInlineArgument.kt index de7d43ba8d4..d90c482e1db 100644 --- a/compiler/testData/debug/stepping/smapInlineAsInlineArgument.kt +++ b/compiler/testData/debug/stepping/smapInlineAsInlineArgument.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt fun box(){ @@ -47,7 +47,7 @@ fun fail() : String { // EXPECTATIONS WASM // test.kt:1 $box -// test.kt:5 $box (4, 9, 15, 15, 15, 15, 20, 20, 20, 20) +// test.kt:5 $box (4, 9, 14, 14, 14, 14, 19, 19, 19, 19) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -61,10 +61,10 @@ fun fail() : String { // Array.kt:75 $kotlin.Array.set (8, 20, 27, 16, 8, 20, 27, 16, 8, 20, 27, 16, 8, 20, 27, 16) // Array.kt:76 $kotlin.Array.set (5, 5, 5, 5) // String.kt:149 $kotlin.stringLiteral (11, 4, 11, 4, 11, 4, 11, 4) -// test.kt:17 $box (12, 12, 12, 12, 4, 12, 12, 12, 12, 4, 12, 12, 12, 12, 4, 12, 12, 12, 12, 4) +// test.kt:17 $box (11, 11, 11, 11, 4, 11, 11, 11, 11, 4, 11, 11, 11, 11, 4, 11, 11, 11, 11, 4) // test.kt:6 $box -// test.kt:21 $fail (12, 12, 12, 12, 4, 12, 12, 12, 12, 4) +// test.kt:21 $fail (11, 11, 11, 11, 4, 11, 11, 11, 11, 4) // String.kt:143 $kotlin.stringLiteral (15, 8, 15, 8, 15, 8, 15, 8, 15, 8, 15, 8) // test.kt:8 $box (4, 9, 4) -// test.kt:9 $box (16, 22, 22, 22, 22, 27, 27, 27, 27) +// test.kt:9 $box (16, 21, 21, 21, 21, 26, 26, 26, 26) // test.kt:10 $box diff --git a/compiler/testData/debug/stepping/smapInlineInIntrinsicArgument.kt b/compiler/testData/debug/stepping/smapInlineInIntrinsicArgument.kt index a378686b318..6c7e8a65ada 100644 --- a/compiler/testData/debug/stepping/smapInlineInIntrinsicArgument.kt +++ b/compiler/testData/debug/stepping/smapInlineInIntrinsicArgument.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt fun box(){ @@ -43,7 +43,7 @@ fun fail() : String { // EXPECTATIONS WASM // test.kt:1 $box // test.kt:5 $box (4, 4, 4) -// test.kt:13 $box (12, 12, 12, 12, 4, 12, 12, 12, 12, 4) +// test.kt:13 $box (11, 11, 11, 11, 4, 11, 11, 11, 11, 4) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -58,7 +58,7 @@ fun fail() : String { // Array.kt:76 $kotlin.Array.set (5, 5) // String.kt:149 $kotlin.stringLiteral (11, 4, 11, 4) // test.kt:6 $box -// test.kt:17 $fail (12, 12, 12, 12, 4, 12, 12, 12, 12, 4) +// test.kt:17 $fail (11, 11, 11, 11, 4, 11, 11, 11, 11, 4) // String.kt:28 $kotlin.String.plus (20, 26, 8, 20, 26, 8) // Library.kt:19 $kotlin.toString (37, 37, 43, 43, 43, 37, 37, 63, 37, 37, 43, 43, 43, 37, 37, 63) // String.kt:119 $kotlin.String.toString (49, 49) diff --git a/compiler/testData/debug/stepping/stringSwitches.kt b/compiler/testData/debug/stepping/stringSwitches.kt index ab353e59d11..5e6a414ce89 100644 --- a/compiler/testData/debug/stepping/stringSwitches.kt +++ b/compiler/testData/debug/stepping/stringSwitches.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt fun stringSwitch(x: String) { @@ -121,7 +121,7 @@ fun box() { // EXPECTATIONS WASM // test.kt:1 $box -// test.kt:30 $box (18, 18, 18, 18, 4) +// test.kt:30 $box (17, 17, 17, 17, 4) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -135,7 +135,7 @@ fun box() { // Array.kt:75 $kotlin.Array.set (8, 20, 27, 16, 8, 20, 27, 16, 8, 20, 27, 16, 8, 20, 27, 16) // Array.kt:76 $kotlin.Array.set (5, 5, 5, 5) // String.kt:149 $kotlin.stringLiteral (11, 4, 11, 4, 11, 4, 11, 4) -// test.kt:6 $stringSwitch (8, 14, 14, 14, 14, 8, 20, 8, 8, 8) +// test.kt:6 $stringSwitch (8, 13, 13, 13, 13, 8, 20, 8, 8, 8) // String.kt:122 $kotlin.String.hashCode (12, 25, 12, 12, 12, 25, 12, 12, 35, 28, 12, 25, 12, 12, 35, 28, 12, 25, 12, 12, 12, 25, 12, 12, 35, 28, 12, 25, 12, 12, 35, 28, 12, 25, 12, 12, 12, 25, 12, 12, 35, 28, 12, 25, 12, 12, 35, 28, 12, 25, 12, 12, 12, 25, 12, 12, 35, 28, 12, 25, 12, 12, 35, 28) // String.kt:123 $kotlin.String.hashCode (30, 30, 30, 30) // String.kt:124 $kotlin.String.hashCode (12, 26, 12, 12, 26, 12, 12, 26, 12, 12, 26, 12) @@ -159,20 +159,20 @@ fun box() { // test.kt:1 $stringSwitch (0, 0, 0, 0, 0, 0, 0, 0, 0) // test.kt:5 $stringSwitch (4, 4, 4, 4) // test.kt:12 $stringSwitch (19, 4, 19, 4, 19, 4, 19, 4) -// test.kt:13 $stringSwitch (8, 9, 9, 9, 9, 8, 15, 8, 8, 8) +// test.kt:13 $stringSwitch (8, 15, 8, 8, 8) // test.kt:20 $stringSwitch (9, 9, 9, 9) -// test.kt:22 $stringSwitch (8, 9, 9, 9, 9, 8, 15, 8, 8, 8) +// test.kt:22 $stringSwitch (8, 15, 8, 8, 8) // test.kt:19 $stringSwitch (4, 4, 4, 4) // test.kt:27 $stringSwitch (1, 1, 1, 1) -// test.kt:31 $box (18, 18, 18, 18, 4) -// test.kt:7 $stringSwitch (8, 14, 14, 14, 14, 8, 21) -// test.kt:14 $stringSwitch (8, 9, 9, 9, 9, 8, 16) -// test.kt:23 $stringSwitch (8, 9, 9, 9, 9, 8, 16) -// test.kt:32 $box (18, 18, 18, 18, 4) -// test.kt:8 $stringSwitch (8, 14, 14, 14, 14, 8, 22) -// test.kt:15 $stringSwitch (8, 9, 9, 9, 9, 8, 17) -// test.kt:24 $stringSwitch (8, 9, 9, 9, 9, 8, 17) -// test.kt:33 $box (18, 18, 18, 18, 4) +// test.kt:31 $box (17, 17, 17, 17, 4) +// test.kt:7 $stringSwitch (8, 13, 13, 13, 13, 8, 21) +// test.kt:14 $stringSwitch (8, 16) +// test.kt:23 $stringSwitch (8, 16) +// test.kt:32 $box (17, 17, 17, 17, 4) +// test.kt:8 $stringSwitch (8, 13, 13, 13, 13, 8, 22) +// test.kt:15 $stringSwitch (8, 17) +// test.kt:24 $stringSwitch (8, 17) +// test.kt:33 $box (17, 17, 17, 17, 4) // test.kt:9 $stringSwitch // test.kt:16 $stringSwitch // test.kt:25 $stringSwitch diff --git a/compiler/testData/debug/stepping/stringSwitchesSmall.kt b/compiler/testData/debug/stepping/stringSwitchesSmall.kt index eee66fe0742..64f6b5d010c 100644 --- a/compiler/testData/debug/stepping/stringSwitchesSmall.kt +++ b/compiler/testData/debug/stepping/stringSwitchesSmall.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt fun stringSwitch(x: String) { @@ -106,7 +106,7 @@ fun box() { // EXPECTATIONS WASM // test.kt:1 $box -// test.kt:27 $box (18, 18, 18, 18, 4) +// test.kt:27 $box (17, 17, 17, 17, 4) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -120,7 +120,7 @@ fun box() { // Array.kt:75 $kotlin.Array.set (8, 20, 27, 16, 8, 20, 27, 16, 8, 20, 27, 16) // Array.kt:76 $kotlin.Array.set (5, 5, 5) // String.kt:149 $kotlin.stringLiteral (11, 4, 11, 4, 11, 4) -// test.kt:6 $stringSwitch (8, 14, 14, 14, 14, 8, 20, 8, 8) +// test.kt:6 $stringSwitch (8, 13, 13, 13, 13, 8, 20, 8, 8) // String.kt:122 $kotlin.String.hashCode (12, 25, 12, 12, 12, 25, 12, 12, 35, 28, 12, 25, 12, 12, 35, 28, 12, 25, 12, 12, 12, 25, 12, 12, 35, 28, 12, 25, 12, 12, 35, 28, 12, 25, 12, 12, 12, 25, 12, 12, 35, 28, 12, 25, 12, 12, 35, 28) // String.kt:123 $kotlin.String.hashCode (30, 30, 30) // String.kt:124 $kotlin.String.hashCode (12, 26, 12, 12, 26, 12, 12, 26, 12) @@ -144,16 +144,16 @@ fun box() { // test.kt:1 $stringSwitch (0, 0, 0, 0, 0, 0) // test.kt:5 $stringSwitch (4, 4, 4) // test.kt:11 $stringSwitch (19, 4, 19, 4, 19, 4) -// test.kt:12 $stringSwitch (8, 9, 9, 9, 9, 8, 15, 8, 8) +// test.kt:12 $stringSwitch (8, 15, 8, 8) // test.kt:18 $stringSwitch (9, 9, 9) -// test.kt:20 $stringSwitch (8, 9, 9, 9, 9, 8, 15, 8, 8) +// test.kt:20 $stringSwitch (8, 15, 8, 8) // test.kt:17 $stringSwitch (4, 4, 4) // test.kt:24 $stringSwitch (1, 1, 1) -// test.kt:28 $box (18, 18, 18, 18, 4) -// test.kt:7 $stringSwitch (8, 14, 14, 14, 14, 8, 21) -// test.kt:13 $stringSwitch (8, 9, 9, 9, 9, 8, 16) -// test.kt:21 $stringSwitch (8, 9, 9, 9, 9, 8, 16) -// test.kt:29 $box (18, 18, 18, 18, 4) +// test.kt:28 $box (17, 17, 17, 17, 4) +// test.kt:7 $stringSwitch (8, 13, 13, 13, 13, 8, 21) +// test.kt:13 $stringSwitch (8, 16) +// test.kt:21 $stringSwitch (8, 16) +// test.kt:29 $box (17, 17, 17, 17, 4) // test.kt:8 $stringSwitch // test.kt:14 $stringSwitch // test.kt:22 $stringSwitch diff --git a/compiler/testData/debug/stepping/tryCatch.kt b/compiler/testData/debug/stepping/tryCatch.kt index 5b6ff8f13a4..0fa3e4e258a 100644 --- a/compiler/testData/debug/stepping/tryCatch.kt +++ b/compiler/testData/debug/stepping/tryCatch.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt fun foo(shouldThrow: Boolean) { @@ -46,7 +46,7 @@ fun box() { // test.kt:1 $box // test.kt:14 $box (8, 4) // test.kt:6 $foo (12, 12, 31, 31, 25) -// test.kt:10 $foo (5, 5, 5, 5, 5, 5, 5, 5) +// test.kt:10 $foo (4, 4, 4, 4, 4, 4, 4, 4) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -73,6 +73,6 @@ fun box() { // Exceptions.kt:20 $kotlin.Exception. // test.kt:5 $foo // test.kt:7 $foo (27, 13) -// test.kt:8 $foo (9, 9, 9, 9) +// test.kt:8 $foo (8, 8, 8, 8) // String.kt:143 $kotlin.stringLiteral (15, 8, 15, 8) // test.kt:16 $box diff --git a/compiler/testData/debug/stepping/tryCatchFinally.kt b/compiler/testData/debug/stepping/tryCatchFinally.kt index 6e5c8f6bc88..b0b538b1a64 100644 --- a/compiler/testData/debug/stepping/tryCatchFinally.kt +++ b/compiler/testData/debug/stepping/tryCatchFinally.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt fun foo() { @@ -137,7 +137,7 @@ fun box() { // test.kt:26 $mightThrow (8, 8, 8, 22, 22, 16) // test.kt:27 $mightThrow (1, 1) // test.kt:5 $foo (4, 4, 4) -// test.kt:10 $foo (9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9) +// test.kt:10 $foo (8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -155,7 +155,7 @@ fun box() { // test.kt:30 $mightThrow2 (8, 8, 22, 22, 16, 8, 22, 22, 16) // test.kt:31 $mightThrow2 // test.kt:13 $foo (12, 12, 4, 12, 12, 4, 12, 12, 4) -// test.kt:18 $foo (9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9) +// test.kt:18 $foo (8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8) // test.kt:20 $foo (1, 1, 1) // test.kt:35 $box (13, 4) // test.kt:36 $box @@ -170,9 +170,9 @@ fun box() { // Throwable.kt:49 $kotlin.Throwable. (1, 1, 1) // Exceptions.kt:20 $kotlin.Exception. (1, 1, 1) // test.kt:15 $foo (13, 13) -// test.kt:16 $foo (9, 9, 9, 9, 9, 9, 9, 9) +// test.kt:16 $foo (8, 8, 8, 8, 8, 8, 8, 8) // test.kt:37 $box (13, 4) // test.kt:38 $box // test.kt:7 $foo -// test.kt:8 $foo (9, 9, 9, 9) +// test.kt:8 $foo (8, 8, 8, 8) // test.kt:39 $box diff --git a/compiler/testData/debug/stepping/tryFinally.kt b/compiler/testData/debug/stepping/tryFinally.kt index 679ea4a45d5..a5fc61d893e 100644 --- a/compiler/testData/debug/stepping/tryFinally.kt +++ b/compiler/testData/debug/stepping/tryFinally.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt fun foo() { @@ -90,7 +90,7 @@ fun box() { // test.kt:22 $mightThrow (8, 8) // test.kt:23 $mightThrow (1, 1) // test.kt:5 $foo (4, 4) -// test.kt:8 $foo (9, 9, 9, 9, 9, 9, 9, 9) +// test.kt:8 $foo (8, 8, 8, 8, 8, 8, 8, 8) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -108,7 +108,7 @@ fun box() { // test.kt:26 $mightThrow2 (8, 8, 22, 22, 16) // test.kt:27 $mightThrow2 // test.kt:11 $foo (12, 4, 12) -// test.kt:14 $foo (9, 9, 9, 9, 9, 9, 9, 9) +// test.kt:14 $foo (8, 8, 8, 8, 8, 8, 8, 8) // test.kt:16 $foo // test.kt:31 $box (13, 4) // test.kt:32 $box diff --git a/compiler/testData/debug/stepping/voidLambdaStepInline.kt b/compiler/testData/debug/stepping/voidLambdaStepInline.kt index 25c11bb44f7..c5a050e22b3 100644 --- a/compiler/testData/debug/stepping/voidLambdaStepInline.kt +++ b/compiler/testData/debug/stepping/voidLambdaStepInline.kt @@ -43,7 +43,7 @@ fun box(): String { // test.kt:6 $box // Standard.kt:3 $box (16, 16, 16, 16) // String.kt:143 $kotlin.stringLiteral (15, 8, 15, 8) -// test.kt:9 $box (12, 12, 12, 12, 4) +// test.kt:9 $box (11, 11, 11, 11, 4) // ExternalWrapper.kt:200 $kotlin.wasm.internal.kotlinToJsStringAdapter // ExternalWrapper.kt:201 $kotlin.wasm.internal.kotlinToJsStringAdapter // Strings.kt:161 $kotlin.wasm.internal.kotlinToJsStringAdapter diff --git a/compiler/testData/debug/stepping/whenConstant.kt b/compiler/testData/debug/stepping/whenConstant.kt index d8dcd8fca75..84e3b29a9fd 100644 --- a/compiler/testData/debug/stepping/whenConstant.kt +++ b/compiler/testData/debug/stepping/whenConstant.kt @@ -27,7 +27,7 @@ fun box() { // test.kt:1 $box // test.kt:5 $box // test.kt:6 $box -// test.kt:11 $box (13, 13, 13, 13) +// test.kt:11 $box (12, 12, 12, 12) // String.kt:141 $kotlin.stringLiteral (17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) diff --git a/compiler/testData/debug/stepping/while.kt b/compiler/testData/debug/stepping/while.kt index e3c4f831d7e..3df3c3b3395 100644 --- a/compiler/testData/debug/stepping/while.kt +++ b/compiler/testData/debug/stepping/while.kt @@ -1,4 +1,4 @@ -// IGNORE_BACKEND_K2: WASM + // FILE: test.kt fun box() { @@ -43,7 +43,7 @@ fun box() { // test.kt:5 $box (12, 4) // test.kt:6 $box (13, 11, 13, 17, 11, 11, 11, 13, 11, 13, 17, 11, 11, 11) // Primitives.kt:1159 $kotlin.Int__dec-impl (15, 8, 16, 15, 8, 16, 15, 8, 16, 15, 8, 16) -// test.kt:7 $box (9, 9, 9, 9) +// test.kt:7 $box (8, 8, 8, 8) // String.kt:141 $kotlin.stringLiteral (17, 28, 17, 17, 28, 17, 17, 28, 17) // Array.kt:59 $kotlin.Array.get (19, 26, 34, 8, 19, 26, 34, 8, 19, 26, 34, 8) // ThrowHelpers.kt:29 $kotlin.wasm.internal.rangeCheck (6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19, 6, 14, 6, 19, 28, 19) @@ -58,7 +58,7 @@ fun box() { // Array.kt:76 $kotlin.Array.set // String.kt:149 $kotlin.stringLiteral (11, 4) // test.kt:10 $box (8, 4) -// test.kt:12 $box (9, 9, 9, 9, 9, 9, 9, 9) +// test.kt:12 $box (8, 8, 8, 8, 8, 8, 8, 8) // String.kt:143 $kotlin.stringLiteral (15, 8, 15, 8) // test.kt:13 $box (15, 13, 15, 19, 13, 13, 15, 13, 15, 19, 13, 13) // test.kt:14 $box diff --git a/compiler/testData/ir/sourceRanges/declarations/delegatedProperties.txt b/compiler/testData/ir/sourceRanges/declarations/delegatedProperties.txt index 282678a034a..bcd4f444ce6 100644 --- a/compiler/testData/ir/sourceRanges/declarations/delegatedProperties.txt +++ b/compiler/testData/ir/sourceRanges/declarations/delegatedProperties.txt @@ -27,7 +27,7 @@ @10:44..12:5 EXPRESSION_BODY @10:44..12:5 CALL 'public final fun observable (initialValue: T of kotlin.properties.Delegates.observable, onChange: kotlin.Function3<@[ParameterName(name = "property")] kotlin.reflect.KProperty<*>, @[ParameterName(name = "oldValue")] T of kotlin.properties.Delegates.observable, @[ParameterName(name = "newValue")] T of kotlin.properties.Delegates.observable, kotlin.Unit>): kotlin.properties.ReadWriteProperty [inline] declared in kotlin.properties.Delegates' type=kotlin.properties.ReadWriteProperty origin=null @10:34..43 GET_OBJECT 'CLASS IR_EXTERNAL_DECLARATION_STUB OBJECT name:Delegates modality:FINAL visibility:public superTypes:[kotlin.Any]' type=kotlin.properties.Delegates - @10:56..62 CONST String type=kotlin.String value="" + @10:55..63 CONST String type=kotlin.String value="" @10:65..12:5 FUN_EXPR type=kotlin.Function3<@[ParameterName(name = "property")] kotlin.reflect.KProperty<*>, @[ParameterName(name = "oldValue")] kotlin.String, @[ParameterName(name = "newValue")] kotlin.String, kotlin.Unit> origin=LAMBDA @10:65..12:5 FUN LOCAL_FUNCTION_FOR_LAMBDA name: visibility:local modality:FINAL <> (prop:kotlin.reflect.KProperty<*>, old:kotlin.String, new:kotlin.String) returnType:kotlin.Unit @10:67..71 VALUE_PARAMETER name:prop index:0 type:kotlin.reflect.KProperty<*> diff --git a/compiler/testData/ir/sourceRanges/extensionLambdaCall.fir.txt b/compiler/testData/ir/sourceRanges/extensionLambdaCall.fir.txt deleted file mode 100644 index d2f8b54df80..00000000000 --- a/compiler/testData/ir/sourceRanges/extensionLambdaCall.fir.txt +++ /dev/null @@ -1,7 +0,0 @@ -@0:0..4:0 FILE fqName: fileName:/extensionLambdaCall.kt - @0:0..3:1 FUN name:lookAtMe visibility:public modality:FINAL <> (f:@[ExtensionFunctionType] kotlin.Function1) returnType:kotlin.Unit - @0:13..33 VALUE_PARAMETER name:f index:0 type:@[ExtensionFunctionType] kotlin.Function1 - @0:35..3:1 BLOCK_BODY - @2:12..15 CALL 'public abstract fun invoke (p1: P1 of kotlin.Function1): R of kotlin.Function1 [operator] declared in kotlin.Function1' type=kotlin.Unit origin=INVOKE - @2:12..13 GET_VAR 'f: @[ExtensionFunctionType] kotlin.Function1 declared in .lookAtMe' type=@[ExtensionFunctionType] kotlin.Function1 origin=VARIABLE_AS_FUNCTION - @1:4..9 CONST String type=kotlin.String value="123" diff --git a/compiler/testData/ir/sourceRanges/extensionLambdaCall.kt b/compiler/testData/ir/sourceRanges/extensionLambdaCall.kt index d021c456739..cb5c2c43bb2 100644 --- a/compiler/testData/ir/sourceRanges/extensionLambdaCall.kt +++ b/compiler/testData/ir/sourceRanges/extensionLambdaCall.kt @@ -1,3 +1,5 @@ +// FIR_IDENTICAL + fun lookAtMe(f: String.() -> Unit) { "123". f() diff --git a/compiler/testData/ir/sourceRanges/extensionLambdaCall.txt b/compiler/testData/ir/sourceRanges/extensionLambdaCall.txt index 1fee2cc3768..cc55bc70684 100644 --- a/compiler/testData/ir/sourceRanges/extensionLambdaCall.txt +++ b/compiler/testData/ir/sourceRanges/extensionLambdaCall.txt @@ -1,7 +1,7 @@ -@0:0..4:0 FILE fqName: fileName:/extensionLambdaCall.kt - @0:0..3:1 FUN name:lookAtMe visibility:public modality:FINAL <> (f:@[ExtensionFunctionType] kotlin.Function1) returnType:kotlin.Unit - @0:13..33 VALUE_PARAMETER name:f index:0 type:@[ExtensionFunctionType] kotlin.Function1 - @0:35..3:1 BLOCK_BODY - @2:12..15 CALL 'public abstract fun invoke (p1: P1 of kotlin.Function1): R of kotlin.Function1 [operator] declared in kotlin.Function1' type=kotlin.Unit origin=INVOKE - @2:12..13 GET_VAR 'f: @[ExtensionFunctionType] kotlin.Function1 declared in .lookAtMe' type=@[ExtensionFunctionType] kotlin.Function1 origin=VARIABLE_AS_FUNCTION - @1:5..8 CONST String type=kotlin.String value="123" +@0:0..6:0 FILE fqName: fileName:/extensionLambdaCall.kt + @2:0..5:1 FUN name:lookAtMe visibility:public modality:FINAL <> (f:@[ExtensionFunctionType] kotlin.Function1) returnType:kotlin.Unit + @2:13..33 VALUE_PARAMETER name:f index:0 type:@[ExtensionFunctionType] kotlin.Function1 + @2:35..5:1 BLOCK_BODY + @4:12..15 CALL 'public abstract fun invoke (p1: P1 of kotlin.Function1): R of kotlin.Function1 [operator] declared in kotlin.Function1' type=kotlin.Unit origin=INVOKE + @4:12..13 GET_VAR 'f: @[ExtensionFunctionType] kotlin.Function1 declared in .lookAtMe' type=@[ExtensionFunctionType] kotlin.Function1 origin=VARIABLE_AS_FUNCTION + @3:4..9 CONST String type=kotlin.String value="123" diff --git a/compiler/testData/ir/sourceRanges/multiLineCall.txt b/compiler/testData/ir/sourceRanges/multiLineCall.txt index a2935977b72..7507e91c4ba 100644 --- a/compiler/testData/ir/sourceRanges/multiLineCall.txt +++ b/compiler/testData/ir/sourceRanges/multiLineCall.txt @@ -8,23 +8,23 @@ @8:7..10:1 FUN name:test visibility:public modality:FINAL <> () returnType:kotlin.String [inline] @8:26..10:1 BLOCK_BODY @9:4..16 RETURN type=kotlin.Nothing from='public final fun test (): kotlin.String [inline] declared in ' - @9:12..15 CONST String type=kotlin.String value="123" + @9:11..16 CONST String type=kotlin.String value="123" @12:7..14:1 FUN name:test visibility:public modality:FINAL <> ($receiver:kotlin.String) returnType:kotlin.String [inline] @12:11..17 VALUE_PARAMETER name: type:kotlin.String @12:33..14:1 BLOCK_BODY @13:4..16 RETURN type=kotlin.Nothing from='public final fun test (): kotlin.String [inline] declared in ' - @13:12..15 CONST String type=kotlin.String value="123" + @13:11..16 CONST String type=kotlin.String value="123" @16:0..18:1 FUN name:fail visibility:public modality:FINAL <> ($receiver:kotlin.String) returnType:kotlin.String @16:4..10 VALUE_PARAMETER name: type:kotlin.String @16:26..18:1 BLOCK_BODY @17:4..32 THROW type=kotlin.Nothing @17:10..32 CONSTRUCTOR_CALL 'public constructor (p0: @[FlexibleNullability] kotlin.Any?) declared in java.lang.AssertionError' type=java.lang.AssertionError origin=null - @17:26..30 CONST String type=kotlin.String value="fail" + @17:25..31 CONST String type=kotlin.String value="fail" @20:0..23:1 FUN name:bar visibility:public modality:FINAL <> () returnType:kotlin.Unit @20:10..23:1 BLOCK_BODY @22:4..8 TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit @22:4..8 CALL 'public final fun (): kotlin.String declared in ' type=kotlin.String origin=GET_PROPERTY - @21:5..8 CONST String type=kotlin.String value="123" + @21:4..9 CONST String type=kotlin.String value="123" @25:0..26:16 PROPERTY name:test visibility:public modality:FINAL [val] @26:4..16 FUN name: visibility:public modality:FINAL <> ($receiver:kotlin.String) returnType:kotlin.String @25:4..10 VALUE_PARAMETER name: type:kotlin.String