[IR] In irText tests, test full mangled names only computed from IR

We plan to disable computing full mangled names of declarations in all
manglers except the IR mangler (see the subsequent commits).

From now on, in irText tests we dump only the following mangled names:

- Full mangled names computed using the IR mangler
- Signature mangled names computed using the Descriptor mangler
- Signature mangled names computed using the IR mangler
- Signature mangled names computed using the FIR mangler

Here by a full mangled name we mean the mangled name of a declaration
computed using the `MangleMode.FULL` mode. Those mangled names include
the mangled names of the declaration'a parents.

By a signature mangled name we mean the mangled name of a declaration
computed using the `MangleMode.SIGNATURE` mode.
These mangled names are used to compute an `IdSignature` for
the declaration, hence the name.
This commit is contained in:
Sergej Jaskiewicz
2023-11-07 19:15:06 +01:00
committed by Space Team
parent 9ccce52915
commit 69aeddcba8
51 changed files with 372 additions and 91 deletions
+12
View File
@@ -11,26 +11,36 @@ class A {
// CHECK JVM_IR:
// Mangled name (compatible mode: false): A{}b.<no name provided>
// Mangled name (compatible mode: true): A.b.<no name provided>
// Mangled name for the signature (compatible mode: false): {}b
// Mangled name for the signature (compatible mode: true):
local class <no name provided> : DoubleExpression {
// CHECK:
// Mangled name (compatible mode: false): A{}b.<no name provided>#<init>(){}
// Mangled name (compatible mode: true): A.b.<no name provided>#<init>(){}
// Mangled name for the signature (compatible mode: false): {}b<init>(){}
// Mangled name for the signature (compatible mode: true): <init>(){}
constructor() /* primary */
// CHECK:
// Mangled name (compatible mode: false): A{}b.<no name provided>#isEqualTo(kotlin.Double){}kotlin.Any{EnhancedNullability}
// Mangled name (compatible mode: true): A.b.<no name provided>#isEqualTo(kotlin.Double){}kotlin.Any{EnhancedNullability}
// Mangled name for the signature (compatible mode: false): {}bisEqualTo(kotlin.Double){}kotlin.Any{EnhancedNullability}
// Mangled name for the signature (compatible mode: true): isEqualTo(kotlin.Double){}kotlin.Any{EnhancedNullability}
@Override
/* fake */ override fun isEqualTo(value: Double): @EnhancedNullability Any
// CHECK JVM_IR:
// Mangled name (compatible mode: false): A{}b.<no name provided>#isEqualTo(kotlin.Double{EnhancedNullability}){}kotlin.Any{EnhancedNullability}
// Mangled name (compatible mode: true): A.b.<no name provided>#isEqualTo(kotlin.Double{EnhancedNullability}){}kotlin.Any{EnhancedNullability}
// Mangled name for the signature (compatible mode: false): {}bisEqualTo(kotlin.Double{EnhancedNullability}){}kotlin.Any{EnhancedNullability}
// Mangled name for the signature (compatible mode: true): isEqualTo(kotlin.Double{EnhancedNullability}){}kotlin.Any{EnhancedNullability}
/* fake */ override fun isEqualTo(value: @EnhancedNullability Double): @EnhancedNullability Any
// CHECK JVM_IR:
// Mangled name (compatible mode: false): A{}b.<no name provided>#get(){}kotlin.Double
// Mangled name (compatible mode: true): A.b.<no name provided>#get(){}kotlin.Double
// Mangled name for the signature (compatible mode: false): {}bget(){}kotlin.Double
// Mangled name for the signature (compatible mode: true): get(){}kotlin.Double
override fun get(): Double
}
@@ -38,6 +48,8 @@ class A {
// CHECK JVM_IR:
// Mangled name (compatible mode: false): A#<get-b>(){}A{}b.<no name provided>
// Mangled name (compatible mode: true): A#<get-b>(){}A.b.<no name provided>
// Mangled name for the signature (compatible mode: false): <get-b>(){}A{}b.<no name provided>
// Mangled name for the signature (compatible mode: true): <get-b>(){}A.b.<no name provided>
// Public signature: /A.b.<get-b>|-6508357397455690228[0]
// Public signature debug description: <get-b>(){}A{}b.<no name provided>
private get
@@ -5,13 +5,16 @@
fun outer(): Unit
// CHECK:
// Mangled name: #outer(){}.LocalClass
// Mangled name for the signature: outer(){}
local class LocalClass {
// CHECK:
// Mangled name: #outer(){}.LocalClass#<init>(){}
// Mangled name for the signature: outer(){}<init>(){}
constructor() /* primary */
// CHECK:
// Mangled name: #outer(){}.LocalClass#foo(){}
// Mangled name for the signature: outer(){}foo(){}
fun foo(): Unit
}
@@ -7,13 +7,19 @@ val test1: Any
// CHECK JVM_IR:
// Mangled name (compatible mode: false): {}test1.<no name provided>
// Mangled name (compatible mode: true): test1.<no name provided>
// Mangled name for the signature (compatible mode: false): {}test1
// Mangled name for the signature (compatible mode: true):
// CHECK JS_IR NATIVE:
// Mangled name (compatible mode: false): {}test1.<no name provided>
// Mangled name (compatible mode: true): test1.<no name provided>
// Mangled name for the signature (compatible mode: false): {}test1
// Mangled name for the signature (compatible mode: true):
local class <no name provided> {
// CHECK:
// Mangled name (compatible mode: false): {}test1.<no name provided>#<init>(){}
// Mangled name (compatible mode: true): test1.<no name provided>#<init>(){}
// Mangled name for the signature (compatible mode: false): {}test1<init>(){}
// Mangled name for the signature (compatible mode: true): <init>(){}
constructor() /* primary */
}
@@ -37,18 +43,26 @@ val test2: IFoo
// CHECK JVM_IR:
// Mangled name (compatible mode: false): {}test2.<no name provided>
// Mangled name (compatible mode: true): test2.<no name provided>
// Mangled name for the signature (compatible mode: false): {}test2
// Mangled name for the signature (compatible mode: true):
// CHECK JS_IR NATIVE:
// Mangled name (compatible mode: false): {}test2.<no name provided>
// Mangled name (compatible mode: true): test2.<no name provided>
// Mangled name for the signature (compatible mode: false): {}test2
// Mangled name for the signature (compatible mode: true):
local class <no name provided> : IFoo {
// CHECK:
// Mangled name (compatible mode: false): {}test2.<no name provided>#<init>(){}
// Mangled name (compatible mode: true): test2.<no name provided>#<init>(){}
// Mangled name for the signature (compatible mode: false): {}test2<init>(){}
// Mangled name for the signature (compatible mode: true): <init>(){}
constructor() /* primary */
// CHECK:
// Mangled name (compatible mode: false): {}test2.<no name provided>#foo(){}
// Mangled name (compatible mode: true): test2.<no name provided>#foo(){}
// Mangled name for the signature (compatible mode: false): {}test2foo(){}
// Mangled name for the signature (compatible mode: true): foo(){}
override fun foo(): Unit
}
@@ -102,19 +116,25 @@ class Outer {
fun test3(): Inner
// CHECK JVM_IR:
// Mangled name: Outer#test3(){}Outer.Inner.<no name provided>
// Mangled name for the signature: test3(){}Outer.Inner
// CHECK JS_IR NATIVE:
// Mangled name: Outer#test3(){}.<no name provided>
// Mangled name for the signature: test3(){}
local class <no name provided> : Inner {
// CHECK JVM_IR:
// Mangled name: Outer#test3(){}Outer.Inner.<no name provided>#<init>(){}
// Mangled name for the signature: test3(){}Outer.Inner<init>(){}
// CHECK JS_IR NATIVE:
// Mangled name: Outer#test3(){}.<no name provided>#<init>(){}
// Mangled name for the signature: test3(){}<init>(){}
constructor() /* primary */
// CHECK JVM_IR:
// Mangled name: Outer#test3(){}Outer.Inner.<no name provided>#foo(){}
// Mangled name for the signature: test3(){}Outer.Innerfoo(){}
// CHECK JS_IR NATIVE:
// Mangled name: Outer#test3(){}.<no name provided>#foo(){}
// Mangled name for the signature: test3(){}foo(){}
override fun foo(): Unit
}
@@ -145,19 +165,25 @@ interface IFoo {
fun Outer.test4(): Inner
// CHECK JVM_IR:
// Mangled name: #test4@Outer(){}Outer.Inner.<no name provided>
// Mangled name for the signature: test4@Outer(){}Outer.Inner
// CHECK JS_IR NATIVE:
// Mangled name: #test4@Outer(){}.<no name provided>
// Mangled name for the signature: test4@Outer(){}
local class <no name provided> : Inner {
// CHECK JVM_IR:
// Mangled name: #test4@Outer(){}Outer.Inner.<no name provided>#<init>(){}
// Mangled name for the signature: test4@Outer(){}Outer.Inner<init>(){}
// CHECK JS_IR NATIVE:
// Mangled name: #test4@Outer(){}.<no name provided>#<init>(){}
// Mangled name for the signature: test4@Outer(){}<init>(){}
constructor() /* primary */
// CHECK JVM_IR:
// Mangled name: #test4@Outer(){}Outer.Inner.<no name provided>#foo(){}
// Mangled name for the signature: test4@Outer(){}Outer.Innerfoo(){}
// CHECK JS_IR NATIVE:
// Mangled name: #test4@Outer(){}.<no name provided>#foo(){}
// Mangled name for the signature: test4@Outer(){}foo(){}
override fun foo(): Unit
}
@@ -7,9 +7,13 @@ val test1: Int /* by */
// CHECK JVM_IR:
// Mangled name (compatible mode: false): {}test1#<anonymous>#static(){}kotlin.Int
// Mangled name (compatible mode: true): test1$delegate#<anonymous>#static(){}kotlin.Int
// Mangled name for the signature (compatible mode: false): {}test1<anonymous>#static(){}kotlin.Int
// Mangled name for the signature (compatible mode: true): <anonymous>#static(){}kotlin.Int
// CHECK JS_IR NATIVE:
// Mangled name (compatible mode: false): {}test1#<anonymous>#static(){}
// Mangled name (compatible mode: true): test1$delegate#<anonymous>#static(){}
// Mangled name for the signature (compatible mode: false): {}test1<anonymous>#static(){}
// Mangled name for the signature (compatible mode: true): <anonymous>#static(){}
local fun <anonymous>(): Int
// CHECK JVM_IR:
@@ -8,11 +8,13 @@ class Inner {
// Public signature debug description: <init>!Outer(kotlin.Any){}
constructor($context_receiver_0: Outer, arg: Any) /* primary */
// CHECK JVM_IR:
// Mangled name computed from Ir: Inner.contextReceiverField0
// Mangled name computed from Descriptor: Inner{}contextReceiverField0#jf
// Mangled name: Inner.contextReceiverField0
// Mangled name for the signature computed from Ir:
// Mangled name for the signature computed from Descriptor: {}contextReceiverField0#jf
// CHECK JS_IR NATIVE:
// Mangled name computed from Ir: Inner.contextReceiverField0
// Mangled name computed from Descriptor: Inner{}contextReceiverField0
// Mangled name: Inner.contextReceiverField0
// Mangled name for the signature computed from Ir:
// Mangled name for the signature computed from Descriptor: {}contextReceiverField0
private /* final field */ val contextReceiverField0: Outer
// CHECK JVM_IR:
@@ -62,7 +64,9 @@ class Outer {
fun f(outer: Outer): Unit
// CHECK JVM_IR:
// Mangled name: #f(Outer){}#<anonymous>#static@Outer(){}Inner
// Mangled name for the signature: f(Outer){}<anonymous>#static@Outer(){}Inner
// CHECK JS_IR NATIVE:
// Mangled name: #f(Outer){}#<anonymous>#static@Outer(){}
// Mangled name for the signature: f(Outer){}<anonymous>#static@Outer(){}
local fun Outer.<anonymous>(): Inner
@@ -30,11 +30,13 @@ class Test {
// Public signature debug description: <init>!Context(){}
constructor($context_receiver_0: Context) /* primary */
// CHECK JVM_IR:
// Mangled name computed from Ir: Test.contextReceiverField0
// Mangled name computed from Descriptor: Test{}contextReceiverField0#jf
// Mangled name: Test.contextReceiverField0
// Mangled name for the signature computed from Ir:
// Mangled name for the signature computed from Descriptor: {}contextReceiverField0#jf
// CHECK JS_IR NATIVE:
// Mangled name computed from Ir: Test.contextReceiverField0
// Mangled name computed from Descriptor: Test{}contextReceiverField0
// Mangled name: Test.contextReceiverField0
// Mangled name for the signature computed from Ir:
// Mangled name for the signature computed from Descriptor: {}contextReceiverField0
private /* final field */ val contextReceiverField0: Context
// CHECK:
@@ -68,11 +68,13 @@ class OK {
// Public signature debug description: <init>!O(kotlin.String){}
constructor($context_receiver_0: O, k: String) /* primary */
// CHECK JVM_IR:
// Mangled name computed from Ir: OK.contextReceiverField0
// Mangled name computed from Descriptor: OK{}contextReceiverField0#jf
// Mangled name: OK.contextReceiverField0
// Mangled name for the signature computed from Ir:
// Mangled name for the signature computed from Descriptor: {}contextReceiverField0#jf
// CHECK JS_IR NATIVE:
// Mangled name computed from Ir: OK.contextReceiverField0
// Mangled name computed from Descriptor: OK{}contextReceiverField0
// Mangled name: OK.contextReceiverField0
// Mangled name for the signature computed from Ir:
// Mangled name for the signature computed from Descriptor: {}contextReceiverField0
private /* final field */ val contextReceiverField0: O
}
@@ -88,7 +90,9 @@ class OK {
fun box(): String
// CHECK JVM_IR:
// Mangled name: #box(){}kotlin.String#<anonymous>#static@O(){}kotlin.String
// Mangled name for the signature: box(){}kotlin.String<anonymous>#static@O(){}kotlin.String
// CHECK JS_IR NATIVE:
// Mangled name: #box(){}#<anonymous>#static@O(){}
// Mangled name for the signature: box(){}<anonymous>#static@O(){}
local fun O.<anonymous>(): String
@@ -96,11 +96,13 @@ class Result {
// Public signature debug description: <init>!kotlin.Int(){}
constructor($context_receiver_0: Int) /* primary */
// CHECK JVM_IR:
// Mangled name computed from Ir: Result.contextReceiverField0
// Mangled name computed from Descriptor: Result{}contextReceiverField0#jf
// Mangled name: Result.contextReceiverField0
// Mangled name for the signature computed from Ir:
// Mangled name for the signature computed from Descriptor: {}contextReceiverField0#jf
// CHECK JS_IR NATIVE:
// Mangled name computed from Ir: Result.contextReceiverField0
// Mangled name computed from Descriptor: Result{}contextReceiverField0
// Mangled name: Result.contextReceiverField0
// Mangled name for the signature computed from Ir:
// Mangled name for the signature computed from Descriptor: {}contextReceiverField0
private /* final field */ val contextReceiverField0: Int
}
@@ -33,6 +33,7 @@ class C {
fun bar(c: C): Unit
// CHECK:
// Mangled name: #bar(C){}#<anonymous>#static@C(){}
// Mangled name for the signature: bar(C){}<anonymous>#static@C(){}
local fun C.<anonymous>(): Unit
// CHECK:
@@ -8,11 +8,13 @@ class A<T : Any?> {
// Public signature debug description: <init>!1:0(){}
constructor($context_receiver_0: T) /* primary */
// CHECK JVM_IR:
// Mangled name computed from Ir: A.contextReceiverField0
// Mangled name computed from Descriptor: A{}contextReceiverField0#jf
// Mangled name: A.contextReceiverField0
// Mangled name for the signature computed from Ir:
// Mangled name for the signature computed from Descriptor: {}contextReceiverField0#jf
// CHECK JS_IR NATIVE:
// Mangled name computed from Ir: A.contextReceiverField0
// Mangled name computed from Descriptor: A{}contextReceiverField0
// Mangled name: A.contextReceiverField0
// Mangled name for the signature computed from Ir:
// Mangled name for the signature computed from Descriptor: {}contextReceiverField0
private /* final field */ val contextReceiverField0: T
}
@@ -27,11 +29,13 @@ class B<P : Any?> {
// Public signature debug description: <init>!kotlin.collections.Collection<1:0>(){}
constructor($context_receiver_0: Collection<P>) /* primary */
// CHECK JVM_IR:
// Mangled name computed from Ir: B.contextReceiverField0
// Mangled name computed from Descriptor: B{}contextReceiverField0#jf
// Mangled name: B.contextReceiverField0
// Mangled name for the signature computed from Ir:
// Mangled name for the signature computed from Descriptor: {}contextReceiverField0#jf
// CHECK JS_IR NATIVE:
// Mangled name computed from Ir: B.contextReceiverField0
// Mangled name computed from Descriptor: B{}contextReceiverField0
// Mangled name: B.contextReceiverField0
// Mangled name for the signature computed from Ir:
// Mangled name for the signature computed from Descriptor: {}contextReceiverField0
private /* final field */ val contextReceiverField0: Collection<P>
}
@@ -180,11 +180,13 @@ class CounterIterator : Iterator<Int> {
// Public signature debug description: <init>!CounterConfig(Counter){}
constructor($context_receiver_0: CounterConfig, counter: Counter) /* primary */
// CHECK JVM_IR:
// Mangled name computed from Ir: CounterIterator.contextReceiverField0
// Mangled name computed from Descriptor: CounterIterator{}contextReceiverField0#jf
// Mangled name: CounterIterator.contextReceiverField0
// Mangled name for the signature computed from Ir:
// Mangled name for the signature computed from Descriptor: {}contextReceiverField0#jf
// CHECK JS_IR NATIVE:
// Mangled name computed from Ir: CounterIterator.contextReceiverField0
// Mangled name computed from Descriptor: CounterIterator{}contextReceiverField0
// Mangled name: CounterIterator.contextReceiverField0
// Mangled name for the signature computed from Ir:
// Mangled name for the signature computed from Descriptor: {}contextReceiverField0
private /* final field */ val contextReceiverField0: CounterConfig
// CHECK JVM_IR:
@@ -8,18 +8,22 @@ class MyClass {
// Public signature debug description: <init>!kotlin.Unit!kotlin.Int(){}
constructor($context_receiver_0: Unit, $context_receiver_1: Int) /* primary */
// CHECK JVM_IR:
// Mangled name computed from Ir: MyClass.contextReceiverField0
// Mangled name computed from Descriptor: MyClass{}contextReceiverField0#jf
// Mangled name: MyClass.contextReceiverField0
// Mangled name for the signature computed from Ir:
// Mangled name for the signature computed from Descriptor: {}contextReceiverField0#jf
// CHECK JS_IR NATIVE:
// Mangled name computed from Ir: MyClass.contextReceiverField0
// Mangled name computed from Descriptor: MyClass{}contextReceiverField0
// Mangled name: MyClass.contextReceiverField0
// Mangled name for the signature computed from Ir:
// Mangled name for the signature computed from Descriptor: {}contextReceiverField0
private /* final field */ val contextReceiverField0: Unit
// CHECK JVM_IR:
// Mangled name computed from Ir: MyClass.contextReceiverField1
// Mangled name computed from Descriptor: MyClass{}contextReceiverField1#jf
// Mangled name: MyClass.contextReceiverField1
// Mangled name for the signature computed from Ir:
// Mangled name for the signature computed from Descriptor: {}contextReceiverField1#jf
// CHECK JS_IR NATIVE:
// Mangled name computed from Ir: MyClass.contextReceiverField1
// Mangled name computed from Descriptor: MyClass{}contextReceiverField1
// Mangled name: MyClass.contextReceiverField1
// Mangled name for the signature computed from Ir:
// Mangled name for the signature computed from Descriptor: {}contextReceiverField1
private /* final field */ val contextReceiverField1: Int
}
@@ -12,37 +12,47 @@ interface Lazy<T : Any?> {
fun <T : Any?> f(lazy1: Lazy<Int>, lazy2: Lazy<CharSequence>, lazyT: Lazy<T>, lazyLazyT: Lazy<Lazy<T>>): Unit
// CHECK:
// Mangled name: #f(Lazy<kotlin.Int>;Lazy<kotlin.CharSequence>;Lazy<1:0>;Lazy<Lazy<1:0>>){0§<kotlin.Any?>}#<anonymous>#static@Lazy<kotlin.Int>(){}
// Mangled name for the signature: f(Lazy<kotlin.Int>;Lazy<kotlin.CharSequence>;Lazy<1:0>;Lazy<Lazy<1:0>>){0§<kotlin.Any?>}<anonymous>#static@Lazy<kotlin.Int>(){}
local fun Lazy<Int>.<anonymous>(): Unit
// CHECK:
// Mangled name: #f(Lazy<kotlin.Int>;Lazy<kotlin.CharSequence>;Lazy<2:0>;Lazy<Lazy<2:0>>){0§<kotlin.Any?>}#<anonymous>#static@Lazy<kotlin.Int>(){}#<anonymous>#static@Lazy<kotlin.CharSequence>(){}
// Mangled name for the signature: f(Lazy<kotlin.Int>;Lazy<kotlin.CharSequence>;Lazy<2:0>;Lazy<Lazy<2:0>>){0§<kotlin.Any?>}<anonymous>#static@Lazy<kotlin.Int>(){}<anonymous>#static@Lazy<kotlin.CharSequence>(){}
local fun Lazy<CharSequence>.<anonymous>(): Unit
// CHECK:
// Mangled name: #f(Lazy<kotlin.Int>;Lazy<kotlin.CharSequence>;Lazy<1:0>;Lazy<Lazy<1:0>>){0§<kotlin.Any?>}#<anonymous>#static@Lazy<kotlin.CharSequence>(){}
// Mangled name for the signature: f(Lazy<kotlin.Int>;Lazy<kotlin.CharSequence>;Lazy<1:0>;Lazy<Lazy<1:0>>){0§<kotlin.Any?>}<anonymous>#static@Lazy<kotlin.CharSequence>(){}
local fun Lazy<CharSequence>.<anonymous>(): Unit
// CHECK:
// Mangled name: #f(Lazy<kotlin.Int>;Lazy<kotlin.CharSequence>;Lazy<2:0>;Lazy<Lazy<2:0>>){0§<kotlin.Any?>}#<anonymous>#static@Lazy<kotlin.CharSequence>(){}#<anonymous>#static@Lazy<kotlin.Int>(){}
// Mangled name for the signature: f(Lazy<kotlin.Int>;Lazy<kotlin.CharSequence>;Lazy<2:0>;Lazy<Lazy<2:0>>){0§<kotlin.Any?>}<anonymous>#static@Lazy<kotlin.CharSequence>(){}<anonymous>#static@Lazy<kotlin.Int>(){}
local fun Lazy<Int>.<anonymous>(): Unit
// CHECK:
// Mangled name: #f(Lazy<kotlin.Int>;Lazy<kotlin.CharSequence>;Lazy<1:0>;Lazy<Lazy<1:0>>){0§<kotlin.Any?>}#<anonymous>#static@Lazy<1:0>(){}
// Mangled name for the signature: f(Lazy<kotlin.Int>;Lazy<kotlin.CharSequence>;Lazy<1:0>;Lazy<Lazy<1:0>>){0§<kotlin.Any?>}<anonymous>#static@Lazy<1:0>(){}
local fun Lazy<T>.<anonymous>(): Unit
// CHECK:
// Mangled name: #f(Lazy<kotlin.Int>;Lazy<kotlin.CharSequence>;Lazy<2:0>;Lazy<Lazy<2:0>>){0§<kotlin.Any?>}#<anonymous>#static@Lazy<2:0>(){}#<anonymous>#static@Lazy<kotlin.Int>(){}
// Mangled name for the signature: f(Lazy<kotlin.Int>;Lazy<kotlin.CharSequence>;Lazy<2:0>;Lazy<Lazy<2:0>>){0§<kotlin.Any?>}<anonymous>#static@Lazy<2:0>(){}<anonymous>#static@Lazy<kotlin.Int>(){}
local fun Lazy<Int>.<anonymous>(): Unit
// CHECK:
// Mangled name: #f(Lazy<kotlin.Int>;Lazy<kotlin.CharSequence>;Lazy<1:0>;Lazy<Lazy<1:0>>){0§<kotlin.Any?>}#<anonymous>#static@Lazy<Lazy<1:0>>(){}
// Mangled name for the signature: f(Lazy<kotlin.Int>;Lazy<kotlin.CharSequence>;Lazy<1:0>;Lazy<Lazy<1:0>>){0§<kotlin.Any?>}<anonymous>#static@Lazy<Lazy<1:0>>(){}
local fun Lazy<Lazy<T>>.<anonymous>(): Unit
// CHECK:
// Mangled name: #f(Lazy<kotlin.Int>;Lazy<kotlin.CharSequence>;Lazy<2:0>;Lazy<Lazy<2:0>>){0§<kotlin.Any?>}#<anonymous>#static@Lazy<Lazy<2:0>>(){}#<anonymous>#static@Lazy<kotlin.Int>(){}
// Mangled name for the signature: f(Lazy<kotlin.Int>;Lazy<kotlin.CharSequence>;Lazy<2:0>;Lazy<Lazy<2:0>>){0§<kotlin.Any?>}<anonymous>#static@Lazy<Lazy<2:0>>(){}<anonymous>#static@Lazy<kotlin.Int>(){}
local fun Lazy<Int>.<anonymous>(): Unit
// CHECK:
// Mangled name: #f(Lazy<kotlin.Int>;Lazy<kotlin.CharSequence>;Lazy<1:0>;Lazy<Lazy<1:0>>){0§<kotlin.Any?>}#<anonymous>#static@Lazy<kotlin.Int>(){}
// Mangled name for the signature: f(Lazy<kotlin.Int>;Lazy<kotlin.CharSequence>;Lazy<1:0>;Lazy<Lazy<1:0>>){0§<kotlin.Any?>}<anonymous>#static@Lazy<kotlin.Int>(){}
local fun Lazy<Int>.<anonymous>(): Unit
// CHECK:
// Mangled name: #f(Lazy<kotlin.Int>;Lazy<kotlin.CharSequence>;Lazy<2:0>;Lazy<Lazy<2:0>>){0§<kotlin.Any?>}#<anonymous>#static@Lazy<kotlin.Int>(){}#<anonymous>#static@Lazy<Lazy<2:0>>(){}
// Mangled name for the signature: f(Lazy<kotlin.Int>;Lazy<kotlin.CharSequence>;Lazy<2:0>;Lazy<Lazy<2:0>>){0§<kotlin.Any?>}<anonymous>#static@Lazy<kotlin.Int>(){}<anonymous>#static@Lazy<Lazy<2:0>>(){}
local fun Lazy<Lazy<T>>.<anonymous>(): Unit
// CHECK:
@@ -37,7 +37,9 @@ fun f(): Any
fun test(): Unit
// CHECK JVM_IR:
// Mangled name: #test(){}#<anonymous>#static@Context(){}kotlin.Int
// Mangled name for the signature: test(){}<anonymous>#static@Context(){}kotlin.Int
// CHECK JS_IR NATIVE:
// Mangled name: #test(){}#<anonymous>#static@Context(){}
// Mangled name for the signature: test(){}<anonymous>#static@Context(){}
local fun Context.<anonymous>(): Int
@@ -25,7 +25,9 @@ fun foo($context_receiver_0: Int, $context_receiver_1: String): Int
fun test(): Unit
// CHECK JVM_IR:
// Mangled name: #test(){}#<anonymous>#static@kotlin.Int(){}kotlin.Int
// Mangled name for the signature: test(){}<anonymous>#static@kotlin.Int(){}kotlin.Int
// CHECK JS_IR NATIVE:
// Mangled name: #test(){}#<anonymous>#static@kotlin.Int(){}
// Mangled name for the signature: test(){}<anonymous>#static@kotlin.Int(){}
local fun Int.<anonymous>(): Int
@@ -5,9 +5,11 @@
fun test(): Unit
// CHECK:
// Mangled name: #test(){}#<anonymous>#static@kotlin.Int(){}
// Mangled name for the signature: test(){}<anonymous>#static@kotlin.Int(){}
local fun Int.<anonymous>(): Unit
// CHECK:
// Mangled name: #test(){}#<anonymous>#static@kotlin.Int(){}#<anonymous>#static(kotlin.Int){}
// Mangled name for the signature: test(){}<anonymous>#static@kotlin.Int(){}<anonymous>#static(kotlin.Int){}
local fun <anonymous>(i: Int): Unit
// CHECK:
@@ -5,5 +5,6 @@
fun test1(x: Int, y: Int, z: String): Unit
// CHECK:
// Mangled name: #test1(kotlin.Int;kotlin.Int;kotlin.String){}#local#static(kotlin.Int;kotlin.Int;kotlin.String){}
// Mangled name for the signature: test1(kotlin.Int;kotlin.Int;kotlin.String){}local#static(kotlin.Int;kotlin.Int;kotlin.String){}
local fun local(xx: Int, yy: Int, zz: String): Unit
@@ -5,70 +5,90 @@
fun outer(): Unit
// CHECK:
// Mangled name: #outer(){}.ALocal
// Mangled name for the signature: outer(){}
local abstract class ALocal {
// CHECK:
// Mangled name: #outer(){}.ALocal#<init>(){}
// Mangled name for the signature: outer(){}<init>(){}
constructor() /* primary */
// CHECK:
// Mangled name: #outer(){}.ALocal#afun(){}
// Mangled name for the signature: outer(){}afun(){}
abstract fun afun(): Unit
// CHECK:
// Mangled name: #outer(){}.ALocal{}aval
// Mangled name for the signature: outer(){}{}aval
abstract val aval: Int
// CHECK JVM_IR:
// Mangled name: #outer(){}.ALocal#<get-aval>(){}kotlin.Int
// Mangled name for the signature: outer(){}<get-aval>(){}kotlin.Int
// CHECK JS_IR NATIVE:
// Mangled name: #outer(){}.ALocal#<get-aval>(){}
// Mangled name for the signature: outer(){}<get-aval>(){}
abstract get
// CHECK:
// Mangled name: #outer(){}.ALocal{}avar
// Mangled name for the signature: outer(){}{}avar
abstract var avar: Int
// CHECK JVM_IR:
// Mangled name: #outer(){}.ALocal#<get-avar>(){}kotlin.Int
// Mangled name for the signature: outer(){}<get-avar>(){}kotlin.Int
// CHECK JS_IR NATIVE:
// Mangled name: #outer(){}.ALocal#<get-avar>(){}
// Mangled name for the signature: outer(){}<get-avar>(){}
abstract get
// CHECK:
// Mangled name: #outer(){}.ALocal#<set-avar>(kotlin.Int){}
// Mangled name for the signature: outer(){}<set-avar>(kotlin.Int){}
abstract set
}
// CHECK:
// Mangled name: #outer(){}.Local
// Mangled name for the signature: outer(){}
local class Local : ALocal {
// CHECK:
// Mangled name: #outer(){}.Local{}aval
// Mangled name for the signature: outer(){}{}aval
override val aval: Int
field
// CHECK JVM_IR:
// Mangled name: #outer(){}.Local#<get-aval>(){}kotlin.Int
// Mangled name for the signature: outer(){}<get-aval>(){}kotlin.Int
// CHECK JS_IR NATIVE:
// Mangled name: #outer(){}.Local#<get-aval>(){}
// Mangled name for the signature: outer(){}<get-aval>(){}
override get
// CHECK:
// Mangled name: #outer(){}.Local{}avar
// Mangled name for the signature: outer(){}{}avar
override var avar: Int
field
// CHECK JVM_IR:
// Mangled name: #outer(){}.Local#<get-avar>(){}kotlin.Int
// Mangled name for the signature: outer(){}<get-avar>(){}kotlin.Int
// CHECK JS_IR NATIVE:
// Mangled name: #outer(){}.Local#<get-avar>(){}
// Mangled name for the signature: outer(){}<get-avar>(){}
override get
// CHECK:
// Mangled name: #outer(){}.Local#<set-avar>(kotlin.Int){}
// Mangled name for the signature: outer(){}<set-avar>(kotlin.Int){}
override set
// CHECK:
// Mangled name: #outer(){}.Local#<init>(){}
// Mangled name for the signature: outer(){}<init>(){}
constructor() /* primary */
// CHECK:
// Mangled name: #outer(){}.Local#afun(){}
// Mangled name for the signature: outer(){}afun(){}
override fun afun(): Unit
}
@@ -5,17 +5,21 @@
fun <TT : Any?> outer(): Unit
// CHECK:
// Mangled name: #outer(){0§<kotlin.Any?>}#test1#static(kotlin.Int;0:0){0§<kotlin.Any?>}
// Mangled name for the signature: outer(){0§<kotlin.Any?>}test1#static(kotlin.Int;0:0){0§<kotlin.Any?>}
local fun <T : Any?> test1(i: Int, j: T): Unit
// CHECK:
// Mangled name: #outer(){0§<kotlin.Any?>}#test2#static(kotlin.Int;kotlin.String){}
// Mangled name for the signature: outer(){0§<kotlin.Any?>}test2#static(kotlin.Int;kotlin.String){}
local fun test2(i: Int, j: String): Unit
// CHECK:
// Mangled name: #outer(){0§<kotlin.Any?>}#test3#static(kotlin.Array<out|kotlin.String>...){}
// Mangled name for the signature: outer(){0§<kotlin.Any?>}test3#static(kotlin.Array<out|kotlin.String>...){}
local fun test3(vararg args: String): Unit
// CHECK:
// Mangled name: #outer(){0§<kotlin.Any?>}#textExt1#static@kotlin.String(kotlin.Int;1:0){}
// Mangled name for the signature: outer(){0§<kotlin.Any?>}textExt1#static@kotlin.String(kotlin.Int;1:0){}
local fun String.textExt1(i: Int, j: TT): Unit
@@ -81,7 +81,9 @@ class DelegateProvider {
fun foo(): Unit
// CHECK JVM_IR:
// Mangled name: #foo(){}#<get-testMember>#static(){}kotlin.String
// Mangled name for the signature: foo(){}<get-testMember>#static(){}kotlin.String
// CHECK JS_IR NATIVE:
// Mangled name: #foo(){}#<get-testMember>#static(){}
// Mangled name for the signature: foo(){}<get-testMember>#static(){}
local fun <get-testMember>(): String
@@ -37,14 +37,18 @@ class MyClass {
fun box(): String
// CHECK JVM_IR:
// Mangled name: #box(){}kotlin.String#<get-testO>#static(){}kotlin.String
// Mangled name for the signature: box(){}kotlin.String<get-testO>#static(){}kotlin.String
// CHECK JS_IR NATIVE:
// Mangled name: #box(){}#<get-testO>#static(){}
// Mangled name for the signature: box(){}<get-testO>#static(){}
local fun <get-testO>(): String
// CHECK JVM_IR:
// Mangled name: #box(){}kotlin.String#<get-testK>#static(){}kotlin.String
// Mangled name for the signature: box(){}kotlin.String<get-testK>#static(){}kotlin.String
// CHECK JS_IR NATIVE:
// Mangled name: #box(){}#<get-testK>#static(){}
// Mangled name for the signature: box(){}<get-testK>#static(){}
local fun <get-testK>(): String
// CHECK JVM_IR:
@@ -4,8 +4,9 @@
// Public signature debug description: {}test1
val test1: ErrorType
// CHECK JVM_IR:
// Mangled name computed from Ir: #<get-test1>(){}<ERROR CLASS>
// Mangled name computed from Descriptor: #<get-test1>(){}<Error class: unknown class>
// Mangled name: #<get-test1>(){}<ERROR CLASS>
// Mangled name for the signature computed from Ir: <get-test1>(){}<ERROR CLASS>
// Mangled name for the signature computed from Descriptor: <get-test1>(){}<Error class: unknown class>
// Public signature: /test1.<get-test1>|-4817139884021780494[0]
// Public signature debug description: <get-test1>(){}<Error class: unknown class>
get
@@ -16,8 +17,9 @@ val test1: ErrorType
// Public signature debug description: {}test2
val test2: ErrorType
// CHECK JVM_IR:
// Mangled name computed from Ir: #<get-test2>(){}<ERROR CLASS>
// Mangled name computed from Descriptor: #<get-test2>(){}<Error class: unknown class>
// Mangled name: #<get-test2>(){}<ERROR CLASS>
// Mangled name for the signature computed from Ir: <get-test2>(){}<ERROR CLASS>
// Mangled name for the signature computed from Descriptor: <get-test2>(){}<Error class: unknown class>
// Public signature: /test2.<get-test2>|1859255286326922853[0]
// Public signature debug description: <get-test2>(){}<Error class: unknown class>
get
@@ -28,8 +30,9 @@ val test2: ErrorType
// Public signature debug description: {}test3
val test3: ErrorType
// CHECK JVM_IR:
// Mangled name computed from Ir: #<get-test3>(){}<ERROR CLASS>
// Mangled name computed from Descriptor: #<get-test3>(){}<Error class: unknown class>
// Mangled name: #<get-test3>(){}<ERROR CLASS>
// Mangled name for the signature computed from Ir: <get-test3>(){}<ERROR CLASS>
// Mangled name for the signature computed from Descriptor: <get-test3>(){}<Error class: unknown class>
// Public signature: /test3.<get-test3>|-2322568342617474229[0]
// Public signature debug description: <get-test3>(){}<Error class: unknown class>
get
@@ -40,8 +43,9 @@ val test3: ErrorType
// Public signature debug description: {}test4
val test4: ErrorType
// CHECK JVM_IR:
// Mangled name computed from Ir: #<get-test4>(){}<ERROR CLASS>
// Mangled name computed from Descriptor: #<get-test4>(){}<Error class: unknown class>
// Mangled name: #<get-test4>(){}<ERROR CLASS>
// Mangled name for the signature computed from Ir: <get-test4>(){}<ERROR CLASS>
// Mangled name for the signature computed from Descriptor: <get-test4>(){}<Error class: unknown class>
// Public signature: /test4.<get-test4>|-5181690683324812065[0]
// Public signature debug description: <get-test4>(){}<Error class: unknown class>
get
@@ -15,8 +15,9 @@ fun <R : Number> Number.convert(): R
fun foo(arg: Number): Unit
// CHECK JVM_IR:
// Mangled name computed from Ir: #main(kotlin.Array<kotlin.String>){}
// Mangled name computed from Descriptor: #main(kotlin.Array<kotlin.String>){}%argumentMappedWithError.kt
// Mangled name: #main(kotlin.Array<kotlin.String>){}
// Mangled name for the signature computed from Ir: main(kotlin.Array<kotlin.String>){}
// Mangled name for the signature computed from Descriptor: main(kotlin.Array<kotlin.String>){}%argumentMappedWithError.kt
// Public signature: /main|5561668743171252170[0]
// Public signature debug description: main(kotlin.Array<kotlin.String>){}%argumentMappedWithError.kt
// CHECK JS_IR NATIVE:
@@ -36,7 +36,9 @@ fun foo(f: Foo): String
fun test(): String
// CHECK JVM_IR:
// Mangled name: #test(){}kotlin.String#<anonymous>#static(){}kotlin.String
// Mangled name for the signature: test(){}kotlin.String<anonymous>#static(){}kotlin.String
// CHECK JS_IR NATIVE:
// Mangled name: #test(){}#<anonymous>#static(){}
// Mangled name for the signature: test(){}<anonymous>#static(){}
local fun <anonymous>(): String
@@ -6,6 +6,7 @@ operator fun J?.component1(): Int
// CHECK JVM_IR:
// Mangled name: #component2@J(){}kotlin.Int
// Mangled name for the signature: component2@J(){}kotlin.Int
// Public signature: [ File 'implicitNotNullInDestructuringAssignment.kt' <- /component2|-623550756830644944[0] ]
private operator fun J.component2(): Int
@@ -17,18 +17,22 @@ inline fun foo(block: Function0<Unit>): Unit
fun test1(): Unit
// CHECK:
// Mangled name: #test1(){}#<anonymous>#static(){}
// Mangled name for the signature: test1(){}<anonymous>#static(){}
local fun <anonymous>(): Unit
// CHECK:
// Mangled name: #test1(){}#<anonymous>#static(){}
// Mangled name for the signature: test1(){}<anonymous>#static(){}
local fun <anonymous>(): Unit
// CHECK:
// Mangled name: #test1(){}#<no name provided>#static(){}
// Mangled name for the signature: test1(){}<no name provided>#static(){}
local fun <no name provided>(): Unit
// CHECK:
// Mangled name: #test1(){}#<no name provided>#static(){}
// Mangled name for the signature: test1(){}<no name provided>#static(){}
local fun <no name provided>(): Unit
// CHECK:
@@ -38,33 +42,41 @@ fun test1(): Unit
fun test2(): Unit
// CHECK:
// Mangled name: #test2(){}#<anonymous>#static(){}
// Mangled name for the signature: test2(){}<anonymous>#static(){}
local fun <anonymous>(): Unit
// CHECK:
// Mangled name: #test2(){}#<anonymous>#static(){}
// Mangled name for the signature: test2(){}<anonymous>#static(){}
local fun <anonymous>(): Unit
// CHECK:
// Mangled name: #test2(){}#<anonymous>#static(){}
// Mangled name for the signature: test2(){}<anonymous>#static(){}
local fun <anonymous>(): Unit
// CHECK:
// Mangled name: #test2(){}#<anonymous>#static(){}
// Mangled name for the signature: test2(){}<anonymous>#static(){}
local fun <anonymous>(): Unit
// CHECK:
// Mangled name: #test2(){}#<no name provided>#static(){}
// Mangled name for the signature: test2(){}<no name provided>#static(){}
local fun <no name provided>(): Unit
// CHECK:
// Mangled name: #test2(){}#<no name provided>#static(){}
// Mangled name for the signature: test2(){}<no name provided>#static(){}
local fun <no name provided>(): Unit
// CHECK:
// Mangled name: #test2(){}#<no name provided>#static(){}
// Mangled name for the signature: test2(){}<no name provided>#static(){}
local fun <no name provided>(): Unit
// CHECK:
// Mangled name: #test2(){}#<no name provided>#static(){}
// Mangled name for the signature: test2(){}<no name provided>#static(){}
local fun <no name provided>(): Unit
@@ -35,36 +35,48 @@ class Host {
fun Outer.test(): Inner
// CHECK JVM_IR:
// Mangled name: Host#test@Outer(){}Outer.Inner.<no name provided>
// Mangled name for the signature: test@Outer(){}Outer.Inner
// CHECK JS_IR NATIVE:
// Mangled name: Host#test@Outer(){}.<no name provided>
// Mangled name for the signature: test@Outer(){}
local class <no name provided> : Inner {
// CHECK JVM_IR:
// Mangled name: Host#test@Outer(){}Outer.Inner.<no name provided>{}xx
// Mangled name for the signature: test@Outer(){}Outer.Inner{}xx
// CHECK JS_IR NATIVE:
// Mangled name: Host#test@Outer(){}.<no name provided>{}xx
// Mangled name for the signature: test@Outer(){}{}xx
val xx: Int
field
// CHECK JVM_IR:
// Mangled name: Host#test@Outer(){}Outer.Inner.<no name provided>#<get-xx>(){}kotlin.Int
// Mangled name for the signature: test@Outer(){}Outer.Inner<get-xx>(){}kotlin.Int
// CHECK JS_IR NATIVE:
// Mangled name: Host#test@Outer(){}.<no name provided>#<get-xx>(){}
// Mangled name for the signature: test@Outer(){}<get-xx>(){}
get
// CHECK JVM_IR:
// Mangled name: Host#test@Outer(){}Outer.Inner.<no name provided>#<init>(){}
// Mangled name for the signature: test@Outer(){}Outer.Inner<init>(){}
// CHECK JS_IR NATIVE:
// Mangled name: Host#test@Outer(){}.<no name provided>#<init>(){}
// Mangled name for the signature: test@Outer(){}<init>(){}
constructor() /* primary */
// CHECK JVM_IR:
// Mangled name: Host#test@Outer(){}Outer.Inner.<no name provided>{}x
// Mangled name for the signature: test@Outer(){}Outer.Inner{}x
// CHECK JS_IR NATIVE:
// Mangled name: Host#test@Outer(){}.<no name provided>{}x
// Mangled name for the signature: test@Outer(){}{}x
/* fake */ override val x: Int
// CHECK JVM_IR:
// Mangled name: Host#test@Outer(){}Outer.Inner.<no name provided>#<get-x>(){}kotlin.Int
// Mangled name for the signature: test@Outer(){}Outer.Inner<get-x>(){}kotlin.Int
// CHECK JS_IR NATIVE:
// Mangled name: Host#test@Outer(){}.<no name provided>#<get-x>(){}
// Mangled name for the signature: test@Outer(){}<get-x>(){}
/* fake */ override get(): Int
}
@@ -37,8 +37,10 @@ object Thing : Base {
private constructor() /* primary */
// CHECK JVM_IR:
// Mangled name: Thing#<init>(){}#<anonymous>#static(){}kotlin.Any
// Mangled name for the signature: <init>(){}<anonymous>#static(){}kotlin.Any
// CHECK JS_IR NATIVE:
// Mangled name: Thing#<init>(){}#<anonymous>#static(){}
// Mangled name for the signature: <init>(){}<anonymous>#static(){}
local fun <anonymous>(): Any
// CHECK JVM_IR:
@@ -1,6 +1,7 @@
// CHECK JVM_IR:
// Mangled name computed from Ir: #main(){}
// Mangled name computed from Descriptor: #main(){}%suspendConversionForExtensionFunction.kt
// Mangled name: #main(){}
// Mangled name for the signature computed from Ir: main(){}
// Mangled name for the signature computed from Descriptor: main(){}%suspendConversionForExtensionFunction.kt
// Public signature: /main|8952895695315889943[0]
// Public signature debug description: main(){}%suspendConversionForExtensionFunction.kt
// CHECK JS_IR NATIVE:
@@ -39,18 +39,22 @@ open class WithCompanion {
fun WithCompanion.test(): Unit
// CHECK:
// Mangled name: #test@WithCompanion(){}.<no name provided>
// Mangled name for the signature: test@WithCompanion(){}
local class <no name provided> : WithCompanion {
// CHECK:
// Mangled name: #test@WithCompanion(){}.<no name provided>#<init>(){}
// Mangled name for the signature: test@WithCompanion(){}<init>(){}
constructor() /* primary */
}
// CHECK:
// Mangled name: #test@WithCompanion(){}.<no name provided>
// Mangled name for the signature: test@WithCompanion(){}
local class <no name provided> : WithCompanion {
// CHECK:
// Mangled name: #test@WithCompanion(){}.<no name provided>#<init>(){}
// Mangled name for the signature: test@WithCompanion(){}<init>(){}
constructor() /* primary */
}
@@ -35,6 +35,7 @@ class ResolvedCall<C : Any?> {
// CHECK JVM_IR:
// Mangled name: #allCandidatesResult(kotlin.collections.Collection<MyCandidate>){0§<kotlin.Any?>}OverloadResolutionResultsImpl<0:0?>?
// Mangled name for the signature: allCandidatesResult(kotlin.collections.Collection<MyCandidate>){0§<kotlin.Any?>}OverloadResolutionResultsImpl<0:0?>?
// Public signature: [ File 'AllCandidates.kt' <- /allCandidatesResult|-4417746287859138452[0] ]
private fun <A : Any?> allCandidatesResult(allCandidates: Collection<MyCandidate>): OverloadResolutionResultsImpl<A?>?
@@ -7,26 +7,34 @@ interface NestedGroupFragment {
// CHECK JVM_IR:
// Mangled name: #addMavenOptionsGroupFragment(){}#addOptionsGroup.<no name provided><kotlin.Int>
// Mangled name for the signature: addMavenOptionsGroupFragment(){}#addOptionsGroup.<no name provided><kotlin.Int>
// Public signature: [ File 'AnonymousAsReturnOfGenericFunction.kt' <- /addMavenOptionsGroupFragment|1068646653174639665[0] ]
// CHECK JS_IR NATIVE:
// Mangled name: #addMavenOptionsGroupFragment(){}
// Mangled name for the signature: addMavenOptionsGroupFragment(){}
private fun addMavenOptionsGroupFragment(): <no name provided><Int>
// CHECK JVM_IR:
// Mangled name: #addOptionsGroup(){0§<kotlin.Any?>}#addOptionsGroup.<no name provided><0:0>
// Mangled name for the signature: addOptionsGroup(){0§<kotlin.Any?>}#addOptionsGroup.<no name provided><0:0>
// Public signature: [ File 'AnonymousAsReturnOfGenericFunction.kt' <- /addOptionsGroup|1295014906395670038[0] ]
// CHECK JS_IR NATIVE:
// Mangled name: #addOptionsGroup(){0§<kotlin.Any?>}
// Mangled name for the signature: addOptionsGroup(){0§<kotlin.Any?>}
private fun <S : Any?> addOptionsGroup(): <no name provided><S>
// CHECK JVM_IR:
// Mangled name: #addOptionsGroup(){0§<kotlin.Any?>}#addOptionsGroup.<no name provided><1:0>.<no name provided>
// Mangled name for the signature: addOptionsGroup(){0§<kotlin.Any?>}#addOptionsGroup.<no name provided><1:0>
// CHECK JS_IR NATIVE:
// Mangled name: #addOptionsGroup(){0§<kotlin.Any?>}.<no name provided>
// Mangled name for the signature: addOptionsGroup(){0§<kotlin.Any?>}
local class <no name provided> : NestedGroupFragment {
// CHECK JVM_IR:
// Mangled name: #addOptionsGroup(){0§<kotlin.Any?>}#addOptionsGroup.<no name provided><2:0>.<no name provided>#<init>(){}
// Mangled name for the signature: addOptionsGroup(){0§<kotlin.Any?>}#addOptionsGroup.<no name provided><2:0><init>(){}
// CHECK JS_IR NATIVE:
// Mangled name: #addOptionsGroup(){0§<kotlin.Any?>}.<no name provided>#<init>(){}
// Mangled name for the signature: addOptionsGroup(){0§<kotlin.Any?>}<init>(){}
constructor() /* primary */
}
@@ -90,8 +90,9 @@ object B {
fun <T : Any?> id(t: T): T
// CHECK JVM_IR:
// Mangled name computed from Ir: foo#main(){}
// Mangled name computed from Descriptor: foo#main(){}%AssignmentOperator.kt
// Mangled name: foo#main(){}
// Mangled name for the signature computed from Ir: main(){}
// Mangled name for the signature computed from Descriptor: main(){}%AssignmentOperator.kt
// Public signature: foo/main|7392120756922895329[0]
// Public signature debug description: main(){}%AssignmentOperator.kt
// CHECK JS_IR NATIVE:
@@ -1,9 +1,11 @@
// CHECK:
// Mangled name: {}registrationMap
// Mangled name for the signature: {}registrationMap
// Public signature: [ File 'ClashResolutionDescriptor.kt' <- /registrationMap|8184441143918876435[0] ]
private val registrationMap: HashMap<Type, Any>
// CHECK JVM_IR:
// Mangled name: #<get-registrationMap>(){}java.util.HashMap<java.lang.reflect.Type,kotlin.Any>
// Mangled name for the signature: <get-registrationMap>(){}java.util.HashMap<java.lang.reflect.Type,kotlin.Any>
// Public signature: [ File 'ClashResolutionDescriptor.kt' <- /registrationMap.<get-registrationMap>|3119298927482099509[0] ]
private get
@@ -1,6 +1,6 @@
// DUMP_LOCAL_DECLARATION_SIGNATURES
// MUTE_SIGNATURE_COMPARISON_K2: ANY
// MUTE_SIGNATURE_COMPARISON_K2: JVM_IR
// ^ KT-57430
class Wrapper {
@@ -11,25 +11,37 @@ class Wrapper {
// CHECK JVM_IR:
// Mangled name (compatible mode: false): Wrapper{}dummy.<no name provided>
// Mangled name (compatible mode: true): Wrapper.dummy.<no name provided>
// Mangled name for the signature (compatible mode: false): {}dummy
// Mangled name for the signature (compatible mode: true):
// CHECK JS_IR NATIVE:
// Mangled name (compatible mode: false): Wrapper{}dummy.<no name provided>
// Mangled name (compatible mode: true): Wrapper.dummy.<no name provided>
// Mangled name for the signature (compatible mode: false): {}dummy
// Mangled name for the signature (compatible mode: true):
local class <no name provided> : Bar {
// CHECK:
// Mangled name (compatible mode: false): Wrapper{}dummy.<no name provided>#<init>(){}
// Mangled name (compatible mode: true): Wrapper.dummy.<no name provided>#<init>(){}
// Mangled name for the signature (compatible mode: false): {}dummy<init>(){}
// Mangled name for the signature (compatible mode: true): <init>(){}
constructor() /* primary */
// CHECK:
// Mangled name (compatible mode: false): Wrapper{}dummy.<no name provided>{}foo
// Mangled name (compatible mode: true): Wrapper.dummy.<no name provided>{}foo
// Mangled name for the signature (compatible mode: false): {}dummy{}foo
// Mangled name for the signature (compatible mode: true): {}foo
/* fake */ override val foo: String
// CHECK JVM_IR:
// Mangled name (compatible mode: false): Wrapper{}dummy.<no name provided>#<get-foo>(){}kotlin.String
// Mangled name (compatible mode: true): Wrapper.dummy.<no name provided>#<get-foo>(){}kotlin.String
// Mangled name for the signature (compatible mode: false): {}dummy<get-foo>(){}kotlin.String
// Mangled name for the signature (compatible mode: true): <get-foo>(){}kotlin.String
// CHECK JS_IR NATIVE:
// Mangled name (compatible mode: false): Wrapper{}dummy.<no name provided>#<get-foo>(){}
// Mangled name (compatible mode: true): Wrapper.dummy.<no name provided>#<get-foo>(){}
// Mangled name for the signature (compatible mode: false): {}dummy<get-foo>(){}
// Mangled name for the signature (compatible mode: true): <get-foo>(){}
/* fake */ override get(): String
}
@@ -37,6 +49,8 @@ class Wrapper {
// CHECK JVM_IR:
// Mangled name (compatible mode: false): Wrapper#<get-dummy>(){}Wrapper{}dummy.<no name provided>
// Mangled name (compatible mode: true): Wrapper#<get-dummy>(){}Wrapper.dummy.<no name provided>
// Mangled name for the signature (compatible mode: false): <get-dummy>(){}Wrapper{}dummy.<no name provided>
// Mangled name for the signature (compatible mode: true): <get-dummy>(){}Wrapper.dummy.<no name provided>
// Public signature: /Wrapper.dummy.<get-dummy>|-1011589390871666922[0]
// Public signature debug description: <get-dummy>(){}Wrapper{}dummy.<no name provided>
// CHECK JS_IR NATIVE:
@@ -54,29 +68,43 @@ class Wrapper {
// CHECK JVM_IR:
// Mangled name (compatible mode: false): Wrapper{}bar.<no name provided>
// Mangled name (compatible mode: true): Wrapper.bar.<no name provided>
// Mangled name for the signature (compatible mode: false): {}bar
// Mangled name for the signature (compatible mode: true):
// CHECK JS_IR NATIVE:
// Mangled name (compatible mode: false): Wrapper{}bar.<no name provided>
// Mangled name (compatible mode: true): Wrapper.bar.<no name provided>
// Mangled name for the signature (compatible mode: false): {}bar
// Mangled name for the signature (compatible mode: true):
local class <no name provided> : Bar {
// CHECK:
// Mangled name (compatible mode: false): Wrapper{}bar.<no name provided>#<init>(){}
// Mangled name (compatible mode: true): Wrapper.bar.<no name provided>#<init>(){}
// Mangled name for the signature (compatible mode: false): {}bar<init>(){}
// Mangled name for the signature (compatible mode: true): <init>(){}
constructor() /* primary */
// CHECK:
// Mangled name (compatible mode: false): Wrapper{}bar.<no name provided>.$$delegate_0
// Mangled name (compatible mode: true): Wrapper.bar.<no name provided>.$$delegate_0
// Mangled name for the signature (compatible mode: false): {}bar
// Mangled name for the signature (compatible mode: true):
private /* final field */ val $$delegate_0: <no name provided>
// CHECK:
// Mangled name (compatible mode: false): Wrapper{}bar.<no name provided>{}foo
// Mangled name (compatible mode: true): Wrapper.bar.<no name provided>{}foo
// Mangled name for the signature (compatible mode: false): {}bar{}foo
// Mangled name for the signature (compatible mode: true): {}foo
override val foo: String
// CHECK JVM_IR:
// Mangled name (compatible mode: false): Wrapper{}bar.<no name provided>#<get-foo>(){}kotlin.String
// Mangled name (compatible mode: true): Wrapper.bar.<no name provided>#<get-foo>(){}kotlin.String
// Mangled name for the signature (compatible mode: false): {}bar<get-foo>(){}kotlin.String
// Mangled name for the signature (compatible mode: true): <get-foo>(){}kotlin.String
// CHECK JS_IR NATIVE:
// Mangled name (compatible mode: false): Wrapper{}bar.<no name provided>#<get-foo>(){}
// Mangled name (compatible mode: true): Wrapper.bar.<no name provided>#<get-foo>(){}
// Mangled name for the signature (compatible mode: false): {}bar<get-foo>(){}
// Mangled name for the signature (compatible mode: true): <get-foo>(){}
override get(): String
}
@@ -84,6 +112,8 @@ class Wrapper {
// CHECK JVM_IR:
// Mangled name (compatible mode: false): Wrapper#<get-bar>(){}Wrapper{}bar.<no name provided>
// Mangled name (compatible mode: true): Wrapper#<get-bar>(){}Wrapper.bar.<no name provided>
// Mangled name for the signature (compatible mode: false): <get-bar>(){}Wrapper{}bar.<no name provided>
// Mangled name for the signature (compatible mode: true): <get-bar>(){}Wrapper.bar.<no name provided>
// Public signature: /Wrapper.bar.<get-bar>|-6775654681164748186[0]
// Public signature debug description: <get-bar>(){}Wrapper{}bar.<no name provided>
// CHECK JS_IR NATIVE:
@@ -15,13 +15,16 @@ class Serializer {
private fun createMessageCollector(): <no name provided>
// CHECK:
// Mangled name: Serializer#createMessageCollector(){}Serializer#createMessageCollector.<no name provided>.<no name provided>
// Mangled name for the signature: createMessageCollector(){}Serializer#createMessageCollector.<no name provided>
local class <no name provided> : Collector {
// CHECK:
// Mangled name: Serializer#createMessageCollector(){}Serializer#createMessageCollector.<no name provided>.<no name provided>#<init>(){}
// Mangled name for the signature: createMessageCollector(){}Serializer#createMessageCollector.<no name provided><init>(){}
constructor() /* primary */
// CHECK:
// Mangled name: Serializer#createMessageCollector(){}Serializer#createMessageCollector.<no name provided>.<no name provided>#flush(){}
// Mangled name for the signature: createMessageCollector(){}Serializer#createMessageCollector.<no name provided>flush(){}
/* fake */ override fun flush(): Unit
}
@@ -6,15 +6,18 @@ fun Reader.consumeRestOfQuotedSequence(sb: StringBuilder, quote: Char): Unit
// CHECK JVM_IR:
// Mangled name: #nextChar@java.io.Reader(){}kotlin.Char?
// Mangled name for the signature: nextChar@java.io.Reader(){}kotlin.Char?
// Public signature: [ File 'coercionToUnitForNestedWhen.kt' <- /nextChar|8697099457416866690[0] ]
private fun Reader.nextChar(): Char?
// CHECK:
// Mangled name: {}BACKSLASH
// Mangled name for the signature: {}BACKSLASH
// Public signature: [ File 'coercionToUnitForNestedWhen.kt' <- /BACKSLASH|9213821134505379379[0] ]
private const val BACKSLASH: Char
// CHECK JVM_IR:
// Mangled name: #<get-BACKSLASH>(){}kotlin.Char
// Mangled name for the signature: <get-BACKSLASH>(){}kotlin.Char
// Public signature: [ File 'coercionToUnitForNestedWhen.kt' <- /BACKSLASH.<get-BACKSLASH>|7174062972088453102[0] ]
private get
+3 -2
View File
@@ -1,6 +1,7 @@
// CHECK JVM_IR:
// Mangled name computed from Ir: #main(){}
// Mangled name computed from Descriptor: #main(){}%kt55458.kt
// Mangled name: #main(){}
// Mangled name for the signature computed from Ir: main(){}
// Mangled name for the signature computed from Descriptor: main(){}%kt55458.kt
// Public signature: /main|-1793468409000137506[0]
// Public signature debug description: main(){}%kt55458.kt
// CHECK JS_IR NATIVE:
@@ -45,8 +45,9 @@ enum class ConfigurationParameter : Enum<ConfigurationParameter> {
// Public signature: /ConfigurationParameter.BASE_URL|null[0]
BASE_URL
// CHECK:
// Mangled name computed from Ir: ConfigurationParameter#<anonymous>#static(kotlin.String;Wrapper){}
// Mangled name computed from Descriptor: ConfigurationParameter.BASE_URL#<init>(){}#<anonymous>#static(kotlin.String;Wrapper){}
// Mangled name: ConfigurationParameter#<anonymous>#static(kotlin.String;Wrapper){}
// Mangled name for the signature computed from Ir: <anonymous>#static(kotlin.String;Wrapper){}
// Mangled name for the signature computed from Descriptor: <init>(){}<anonymous>#static(kotlin.String;Wrapper){}
local fun <anonymous>(value: String, nc: Wrapper): Unit
// CHECK JVM_IR:
@@ -9,50 +9,66 @@
fun box(): String
// CHECK JVM_IR:
// Mangled name: #box(){}kotlin.String.<no name provided>
// Mangled name for the signature: box(){}kotlin.String
// CHECK JS_IR NATIVE:
// Mangled name: #box(){}.<no name provided>
// Mangled name for the signature: box(){}
local class <no name provided> {
// CHECK JVM_IR:
// Mangled name: #box(){}kotlin.String.<no name provided>{}a
// Mangled name for the signature: box(){}kotlin.String{}a
// CHECK JS_IR NATIVE:
// Mangled name: #box(){}.<no name provided>{}a
// Mangled name for the signature: box(){}{}a
val a: A
field
// CHECK JVM_IR:
// Mangled name: #box(){}kotlin.String.<no name provided>#<get-a>(){}#box.<no name provided>.A
// Mangled name for the signature: box(){}kotlin.String<get-a>(){}#box.<no name provided>.A
// CHECK JS_IR NATIVE:
// Mangled name: #box(){}.<no name provided>#<get-a>(){}
// Mangled name for the signature: box(){}<get-a>(){}
get
// CHECK JVM_IR:
// Mangled name: #box(){}kotlin.String.<no name provided>.A
// Mangled name for the signature: box(){}kotlin.String
// CHECK JS_IR NATIVE:
// Mangled name: #box(){}.<no name provided>.A
// Mangled name for the signature: box(){}
local inner class A {
// CHECK JVM_IR:
// Mangled name: #box(){}kotlin.String.<no name provided>.A{}ok
// Mangled name for the signature: box(){}kotlin.String{}ok
// CHECK JS_IR NATIVE:
// Mangled name: #box(){}.<no name provided>.A{}ok
// Mangled name for the signature: box(){}{}ok
val ok: String
field
// CHECK JVM_IR:
// Mangled name: #box(){}kotlin.String.<no name provided>.A#<get-ok>(){}kotlin.String
// Mangled name for the signature: box(){}kotlin.String<get-ok>(){}kotlin.String
// CHECK JS_IR NATIVE:
// Mangled name: #box(){}.<no name provided>.A#<get-ok>(){}
// Mangled name for the signature: box(){}<get-ok>(){}
get
// CHECK JVM_IR:
// Mangled name: #box(){}kotlin.String.<no name provided>.A#<init>(kotlin.String){}
// Mangled name for the signature: box(){}kotlin.String<init>(kotlin.String){}
// CHECK JS_IR NATIVE:
// Mangled name: #box(){}.<no name provided>.A#<init>(kotlin.String){}
// Mangled name for the signature: box(){}<init>(kotlin.String){}
constructor(ok: String) /* primary */
}
// CHECK JVM_IR:
// Mangled name: #box(){}kotlin.String.<no name provided>#<init>(){}
// Mangled name for the signature: box(){}kotlin.String<init>(){}
// CHECK JS_IR NATIVE:
// Mangled name: #box(){}.<no name provided>#<init>(){}
// Mangled name for the signature: box(){}<init>(){}
constructor() /* primary */
}
@@ -1,6 +1,7 @@
// CHECK JVM_IR:
// Mangled name computed from Ir: #main(){}
// Mangled name computed from Descriptor: #main(){}%localCompanion.kt
// Mangled name: #main(){}
// Mangled name for the signature computed from Ir: main(){}
// Mangled name for the signature computed from Descriptor: main(){}%localCompanion.kt
// Public signature: /main|1798078925369608927[0]
// Public signature debug description: main(){}%localCompanion.kt
// CHECK JS_IR NATIVE:
@@ -9,38 +10,48 @@
// Public signature debug description: main(){}
fun main(): Unit
// CHECK JVM_IR:
// Mangled name computed from Ir: #main(){}.Foo
// Mangled name computed from Descriptor: #main(){}%localCompanion.kt.Foo
// Mangled name: #main(){}.Foo
// Mangled name for the signature computed from Ir: main(){}
// Mangled name for the signature computed from Descriptor: main(){}%localCompanion.kt
// CHECK JS_IR NATIVE:
// Mangled name: #main(){}.Foo
// Mangled name for the signature: main(){}
local class Foo {
// CHECK JVM_IR:
// Mangled name computed from Ir: #main(){}.Foo.Companion
// Mangled name computed from Descriptor: #main(){}%localCompanion.kt.Foo.Companion
// Mangled name: #main(){}.Foo.Companion
// Mangled name for the signature computed from Ir: main(){}
// Mangled name for the signature computed from Descriptor: main(){}%localCompanion.kt
// CHECK JS_IR NATIVE:
// Mangled name: #main(){}.Foo.Companion
// Mangled name for the signature: main(){}
local companion object Companion {
// CHECK JVM_IR:
// Mangled name computed from Ir: #main(){}.Foo.Companion#<init>(){}
// Mangled name computed from Descriptor: #main(){}%localCompanion.kt.Foo.Companion#<init>(){}
// Mangled name: #main(){}.Foo.Companion#<init>(){}
// Mangled name for the signature computed from Ir: main(){}<init>(){}
// Mangled name for the signature computed from Descriptor: main(){}%localCompanion.kt<init>(){}
// CHECK JS_IR NATIVE:
// Mangled name: #main(){}.Foo.Companion#<init>(){}
// Mangled name for the signature: main(){}<init>(){}
private constructor() /* primary */
// CHECK JVM_IR:
// Mangled name computed from Ir: #main(){}.Foo.Companion#bar(){}
// Mangled name computed from Descriptor: #main(){}%localCompanion.kt.Foo.Companion#bar(){}
// Mangled name: #main(){}.Foo.Companion#bar(){}
// Mangled name for the signature computed from Ir: main(){}bar(){}
// Mangled name for the signature computed from Descriptor: main(){}%localCompanion.ktbar(){}
// CHECK JS_IR NATIVE:
// Mangled name: #main(){}.Foo.Companion#bar(){}
// Mangled name for the signature: main(){}bar(){}
fun bar(): Unit
}
// CHECK JVM_IR:
// Mangled name computed from Ir: #main(){}.Foo#<init>(){}
// Mangled name computed from Descriptor: #main(){}%localCompanion.kt.Foo#<init>(){}
// Mangled name: #main(){}.Foo#<init>(){}
// Mangled name for the signature computed from Ir: main(){}<init>(){}
// Mangled name for the signature computed from Descriptor: main(){}%localCompanion.kt<init>(){}
// CHECK JS_IR NATIVE:
// Mangled name: #main(){}.Foo#<init>(){}
// Mangled name for the signature: main(){}<init>(){}
constructor() /* primary */
}
@@ -40,25 +40,33 @@ class IdeWizard {
private fun <V : Any, T : SettingType<V>> setting(reference: SettingReference<V, T>): <no name provided><V, T>
// CHECK JVM_IR:
// Mangled name: IdeWizard#setting(SettingReference<1:0,1:1>){0§<kotlin.Any>;1§<SettingType<1:0>>}IdeWizard#setting.<no name provided><1:0,1:1>.<no name provided>
// Mangled name for the signature: setting(SettingReference<1:0,1:1>){0§<kotlin.Any>;1§<SettingType<1:0>>}IdeWizard#setting.<no name provided><1:0,1:1>
// CHECK JS_IR NATIVE:
// Mangled name: IdeWizard#setting(SettingReference<1:0,1:1>){0§<kotlin.Any>;1§<SettingType<1:0>>}.<no name provided>
// Mangled name for the signature: setting(SettingReference<1:0,1:1>){0§<kotlin.Any>;1§<SettingType<1:0>>}
local class <no name provided> : ReadWriteProperty<Any?, V?> {
// CHECK JVM_IR:
// Mangled name: IdeWizard#setting(SettingReference<2:0,2:1>){0§<kotlin.Any>;1§<SettingType<2:0>>}IdeWizard#setting.<no name provided><2:0,2:1>.<no name provided>#<init>(){}
// Mangled name for the signature: setting(SettingReference<2:0,2:1>){0§<kotlin.Any>;1§<SettingType<2:0>>}IdeWizard#setting.<no name provided><2:0,2:1><init>(){}
// CHECK JS_IR NATIVE:
// Mangled name: IdeWizard#setting(SettingReference<2:0,2:1>){0§<kotlin.Any>;1§<SettingType<2:0>>}.<no name provided>#<init>(){}
// Mangled name for the signature: setting(SettingReference<2:0,2:1>){0§<kotlin.Any>;1§<SettingType<2:0>>}<init>(){}
constructor() /* primary */
// CHECK JVM_IR:
// Mangled name: IdeWizard#setting(SettingReference<2:0,2:1>){0§<kotlin.Any>;1§<SettingType<2:0>>}IdeWizard#setting.<no name provided><2:0,2:1>.<no name provided>#getValue(kotlin.Any?;kotlin.reflect.KProperty<*>){}2:0?
// Mangled name for the signature: setting(SettingReference<2:0,2:1>){0§<kotlin.Any>;1§<SettingType<2:0>>}IdeWizard#setting.<no name provided><2:0,2:1>getValue(kotlin.Any?;kotlin.reflect.KProperty<*>){}2:0?
// CHECK JS_IR NATIVE:
// Mangled name: IdeWizard#setting(SettingReference<2:0,2:1>){0§<kotlin.Any>;1§<SettingType<2:0>>}.<no name provided>#getValue(kotlin.Any?;kotlin.reflect.KProperty<*>){}
// Mangled name for the signature: setting(SettingReference<2:0,2:1>){0§<kotlin.Any>;1§<SettingType<2:0>>}getValue(kotlin.Any?;kotlin.reflect.KProperty<*>){}
override operator fun getValue(thisRef: Any?, property: KProperty<*>): V?
// CHECK JVM_IR:
// Mangled name: IdeWizard#setting(SettingReference<2:0,2:1>){0§<kotlin.Any>;1§<SettingType<2:0>>}IdeWizard#setting.<no name provided><2:0,2:1>.<no name provided>#setValue(kotlin.Any?;kotlin.reflect.KProperty<*>;2:0?){}
// Mangled name for the signature: setting(SettingReference<2:0,2:1>){0§<kotlin.Any>;1§<SettingType<2:0>>}IdeWizard#setting.<no name provided><2:0,2:1>setValue(kotlin.Any?;kotlin.reflect.KProperty<*>;2:0?){}
// CHECK JS_IR NATIVE:
// Mangled name: IdeWizard#setting(SettingReference<2:0,2:1>){0§<kotlin.Any>;1§<SettingType<2:0>>}.<no name provided>#setValue(kotlin.Any?;kotlin.reflect.KProperty<*>;2:0?){}
// Mangled name for the signature: setting(SettingReference<2:0,2:1>){0§<kotlin.Any>;1§<SettingType<2:0>>}setValue(kotlin.Any?;kotlin.reflect.KProperty<*>;2:0?){}
override operator fun setValue(thisRef: Any?, property: KProperty<*>, value: V?): Unit
}
@@ -72,9 +72,11 @@ class Expression {
// CHECK JVM_IR:
// Mangled name: #countIssues(kotlin.Function1<ArgumentsBuilder,kotlin.Unit>){}
// Mangled name for the signature: countIssues(kotlin.Function1<ArgumentsBuilder,kotlin.Unit>){}
// Public signature: [ File 'timesInBuilder.kt' <- /countIssues|-3006686104129982000[0] ]
// CHECK JS_IR NATIVE:
// Mangled name: #countIssues(kotlin.Function1<ArgumentsBuilder,kotlin.Unit>){}
// Mangled name for the signature: countIssues(kotlin.Function1<ArgumentsBuilder,kotlin.Unit>){}
private fun countIssues(restrictionsBuilder: @ExtensionFunctionType Function1<ArgumentsBuilder, Unit>): Unit
// CHECK JVM_IR:
@@ -119,8 +121,10 @@ fun <T : Comparable<T>> Column.select(t: T, r: T): Expression
// CHECK JVM_IR:
// Mangled name: #test(kotlin.Long){}
// Mangled name for the signature: test(kotlin.Long){}
// Public signature: [ File 'timesInBuilder.kt' <- /test|-2956403500052581138[0] ]
// CHECK JS_IR NATIVE:
// Mangled name: #test(kotlin.Long){}
// Mangled name for the signature: test(kotlin.Long){}
private fun test(x: Long): Unit
@@ -7,9 +7,13 @@ val anonymous: Function0<Unit>
// CHECK JVM_IR:
// Mangled name (compatible mode: false): {}anonymous#<no name provided>#static(){}
// Mangled name (compatible mode: true): anonymous#<no name provided>#static(){}
// Mangled name for the signature (compatible mode: false): {}anonymous<no name provided>#static(){}
// Mangled name for the signature (compatible mode: true): <no name provided>#static(){}
// CHECK JS_IR NATIVE:
// Mangled name (compatible mode: false): {}anonymous#<no name provided>#static(){}
// Mangled name (compatible mode: true): anonymous#<no name provided>#static(){}
// Mangled name for the signature (compatible mode: false): {}anonymous<no name provided>#static(){}
// Mangled name for the signature (compatible mode: true): <no name provided>#static(){}
local fun <no name provided>(): Unit
// CHECK JVM_IR:
@@ -132,16 +132,20 @@ interface SendChannel<in E : Any?> {
// CHECK JVM_IR:
// Mangled name: #asChannel@CoroutineScope(Flow<*>){}ReceiveChannel<kotlin.Any>
// Mangled name for the signature: asChannel@CoroutineScope(Flow<*>){}ReceiveChannel<kotlin.Any>
// Public signature: [ File 'castsInsideCoroutineInference.kt' <- /asChannel|-3549601571428075944[0] ]
// CHECK JS_IR NATIVE:
// Mangled name: #asChannel@CoroutineScope(Flow<*>){}
// Mangled name for the signature: asChannel@CoroutineScope(Flow<*>){}
private fun CoroutineScope.asChannel(flow: Flow<*>): ReceiveChannel<Any>
// CHECK JVM_IR:
// Mangled name: #asFairChannel@CoroutineScope(Flow<*>){}ReceiveChannel<kotlin.Any>
// Mangled name for the signature: asFairChannel@CoroutineScope(Flow<*>){}ReceiveChannel<kotlin.Any>
// Public signature: [ File 'castsInsideCoroutineInference.kt' <- /asFairChannel|-8739457176543595950[0] ]
// CHECK JS_IR NATIVE:
// Mangled name: #asFairChannel@CoroutineScope(Flow<*>){}
// Mangled name for the signature: asFairChannel@CoroutineScope(Flow<*>){}
private fun CoroutineScope.asFairChannel(flow: Flow<*>): ReceiveChannel<Any>
// CHECK:
@@ -9,8 +9,9 @@
fun <T : Any?> elvisLike(x: T, y: (T & Any)): (T & Any)
// CHECK JVM_IR:
// Mangled name computed from Ir: #main(){}
// Mangled name computed from Descriptor: #main(){}%definitelyNonNull.kt
// Mangled name: #main(){}
// Mangled name for the signature computed from Ir: main(){}
// Mangled name for the signature computed from Descriptor: main(){}%definitelyNonNull.kt
// Public signature: /main|536315142565162436[0]
// Public signature debug description: main(){}%definitelyNonNull.kt
// CHECK JS_IR NATIVE:
@@ -5,6 +5,7 @@
fun box(): Unit
// CHECK:
// Mangled name: #box(){}#<anonymous>#static(kotlin.String){}
// Mangled name for the signature: box(){}<anonymous>#static(kotlin.String){}
local fun <anonymous>(it: String): Unit
// CHECK:
@@ -41,8 +41,9 @@ class Foo<T : Any?> {
fun <K : Any?> foo(x: MutableList<K>): Foo<K>
// CHECK JVM_IR:
// Mangled name computed from Ir: #main(){}
// Mangled name computed from Descriptor: #main(){}%dontLeaveStubTypesInSetter.kt
// Mangled name: #main(){}
// Mangled name for the signature computed from Ir: main(){}
// Mangled name for the signature computed from Descriptor: main(){}%dontLeaveStubTypesInSetter.kt
// Public signature: /main|-2535684763027974809[0]
// Public signature debug description: main(){}%dontLeaveStubTypesInSetter.kt
// CHECK JS_IR NATIVE:
@@ -5,6 +5,7 @@
fun testWithNullCheck(xs: Array<String>): Unit
// CHECK JVM_IR:
// Mangled name: #testWithNullCheck(kotlin.Array<kotlin.String>){}#<anonymous>#static(){}kotlin.String
// Mangled name for the signature: testWithNullCheck(kotlin.Array<kotlin.String>){}<anonymous>#static(){}kotlin.String
local fun <anonymous>(): String
// CHECK JVM_IR:
@@ -11,13 +11,12 @@ import org.jetbrains.kotlin.backend.jvm.JvmSymbols
import org.jetbrains.kotlin.backend.jvm.ir.hasPlatformDependent
import org.jetbrains.kotlin.builtins.StandardNames
import org.jetbrains.kotlin.descriptors.DescriptorVisibilities
import org.jetbrains.kotlin.fir.backend.FirMangler
import org.jetbrains.kotlin.descriptors.PropertyDescriptor
import org.jetbrains.kotlin.fir.backend.FirMangler
import org.jetbrains.kotlin.fir.backend.FirMetadataSource
import org.jetbrains.kotlin.ir.IrBuiltIns
import org.jetbrains.kotlin.ir.IrElement
import org.jetbrains.kotlin.ir.ObsoleteDescriptorBasedAPI
import org.jetbrains.kotlin.ir.backend.js.utils.isEqualsInheritedFromAny
import org.jetbrains.kotlin.ir.declarations.*
import org.jetbrains.kotlin.ir.expressions.IrConstructorCall
import org.jetbrains.kotlin.ir.interpreter.intrinsicConstEvaluationAnnotation
@@ -71,9 +70,11 @@ private const val CHECK_MARKER = "// CHECK"
* // CHECK JVM_IR:
* // Mangled name: #test(){}kotlin.Int
* // Public signature: /test|4216975235718029399[0]
* // Public signature debug description: test(){}kotlin.Int
* // CHECK JS_IR NATIVE:
* // Mangled name: #test(){}
* // Public signature: /test|6620506149988718649[0]
* // Public signature debug description: test(){}
* fun test(): Int
* ```
*
@@ -206,13 +207,15 @@ class IrMangledNameAndSignatureDumpHandler(
val symbol = declaration.symbol
val computedMangledNames = mutableListOf<ComputedMangledName>()
val fullMangledNames = mutableListOf<ComputedMangledName>()
val signatureMangledNames = mutableListOf<ComputedMangledName>()
irMangler.addMangledNameTo(computedMangledNames, declaration)
descriptorMangler.addMangledNameTo(computedMangledNames, symbol.descriptor)
irMangler.addFullMangledNameTo(fullMangledNames, declaration)
irMangler.addSignatureMangledNameTo(signatureMangledNames, declaration)
descriptorMangler.addSignatureMangledNameTo(signatureMangledNames, symbol.descriptor)
((declaration as? IrMetadataSourceOwner)?.metadata as? FirMetadataSource)?.fir?.let {
firMangler?.addMangledNameTo(
computedMangledNames,
firMangler?.addSignatureMangledNameTo(
signatureMangledNames,
it
)
}
@@ -229,7 +232,14 @@ class IrMangledNameAndSignatureDumpHandler(
}
fun printActualMangledNamesAndSignatures() {
printMangledNames(computedMangledNames)
printMangledNames(fullMangledNames, prefix = "Mangled name")
// Signature mangled names computed from descriptors, IR and FIR must be all equal to the signature description, which
// we already print (see the IdSignature.print function above).
// If this is not the case, print them separately.
if (signatureMangledNames.any { it.value != symbol.signature?.asPublic()?.description.orEmpty() }) {
printMangledNames(signatureMangledNames, prefix = "Mangled name for the signature")
}
symbol.signature?.print("Public signature")
symbol.privateSignature?.print("Private signature")
@@ -371,13 +381,13 @@ private inline fun Iterable<ComputedMangledName>.printAligned(printer: Printer,
map { prefix(it) to it.value }.aligned().forEach(printer::println)
}
private fun Printer.printMangledNames(computedMangledNames: List<ComputedMangledName>) {
private fun Printer.printMangledNames(computedMangledNames: List<ComputedMangledName>, prefix: String) {
val distinctNames = computedMangledNames.distinctBy { it.value }
// If mangled names computed from all three representations (descriptors, IR, FIR) and modes match,
// print just one mangled name.
distinctNames.singleOrNull()?.let {
println("// Mangled name: ${it.value}")
println("// $prefix: ${it.value}")
return
}
@@ -386,17 +396,17 @@ private fun Printer.printMangledNames(computedMangledNames: List<ComputedMangled
// only mangled names from each mangler.
computedMangledNames
.distinctBy { it.manglerName }
.printAligned(this) { "// Mangled name computed from ${it.manglerName}: " }
.printAligned(this) { "// $prefix computed from ${it.manglerName}: " }
} else if (distinctNames.same { it.manglerName }) {
// If the mangled names differ only by the compatibility mode used (but not the mangler), print
// only mangled names for each compatibility mode.
computedMangledNames
.distinctBy { it.compatibleMode }
.printAligned(this) { "// Mangled name (compatible mode: ${it.compatibleMode}): " }
.printAligned(this) { "// $prefix (compatible mode: ${it.compatibleMode}): " }
} else {
// Otherwise, print the whole matrix.
computedMangledNames
.printAligned(this) { "// Mangled name computed from ${it.manglerName} (compatible mode: ${it.compatibleMode}): " }
.printAligned(this) { "// $prefix computed from ${it.manglerName} (compatible mode: ${it.compatibleMode}): " }
}
}
@@ -409,13 +419,15 @@ private fun Printer.printlnCheckMarker(backends: List<TargetBackend>) {
printlnWithNoIndent(":")
}
private fun <Declaration, Mangler : KotlinMangler<Declaration>> Mangler.addMangledNameTo(
private fun <Declaration> addMangledNameTo(
collector: MutableList<ComputedMangledName>,
declaration: Declaration
manglerName: String,
declaration: Declaration,
mangle: Declaration.(Boolean) -> String,
) {
listOf(false, true).mapTo(collector) { compatibleMode ->
val mangledName = try {
declaration.mangleString(compatibleMode)
declaration.mangle(compatibleMode)
} catch (e: Throwable) {
// Kotlin-like IR renderer suppresses exceptions thrown during rendering, which leads to missing renders that are hard to debug.
// Because this routine is executed during rendering, we print the exception description instead of a proper mangled name.
@@ -435,6 +447,20 @@ private fun <Declaration, Mangler : KotlinMangler<Declaration>> Mangler.addMangl
}
}
private fun <Declaration, Mangler : KotlinMangler<Declaration>> Mangler.addSignatureMangledNameTo(
collector: MutableList<ComputedMangledName>,
declaration: Declaration
) {
addMangledNameTo(collector, manglerName, declaration) { signatureString(it) }
}
private fun KotlinMangler.IrMangler.addFullMangledNameTo(
collector: MutableList<ComputedMangledName>,
declaration: IrDeclaration,
) {
addMangledNameTo(collector, manglerName, declaration) { mangleString(it) }
}
/**
* Represents a single `// CHECK` block.
*
@@ -492,9 +518,8 @@ private val whitespaceRegex = "\\s+".toRegex()
* // CHECK JS_IR NATIVE:
* // Mangled name: #test(){}
* // Public signature: /test|6620506149988718649[0]
* fun test(): Int {
* return 42
* }
* // Public signature debug description: test(){}
* fun test(): Int
* ```
* will be parsed into:
* ```kotlin
@@ -502,7 +527,8 @@ private val whitespaceRegex = "\\s+".toRegex()
* backends = listOf(TargetBackend.JS_IR, TargetBackend.NATIVE),
* expectations = listOf(
* "// Mangled name: #test(){}",
* "// Public signature: /test|6620506149988718649[0]"
* "// Public signature: /test|6620506149988718649[0]",
* "// Public signature debug description: test(){}",
* )
* )
* ```