Files
kotlin-fork/compiler/testData/ir/irText/declarations/contextReceivers/class.sig.kt.txt
T
Dmitriy Dolovov 02604060ae IR text tests: Don't dump signatures for local declarations
1. Local declarations don't participate in IR-linkage, because they
can be referenced only inside the same body -> can be dropped
from IR text tests.

2. Mangled names for private declarations computed by descriptors/fir
are actually not used anywhere (they are recomputed by IR
immediately before serialization of IR). But sometimes such
mangled names diverge between K1 and K2 -> don't check them, but
always check mangled names computed by IR even for private
declarations.

3. Also: Drop DUMP_LOCAL_DECLARATION_SIGNATURES test directive.

^KT-57428 Obsolete
^KT-57430 Obsolete
^KT-57434 Obsolete
^KT-57778 Obsolete
^KT-57775 Obsolete
2023-11-30 08:32:35 +00:00

56 lines
1.7 KiB
Kotlin
Vendored

// CHECK:
// Mangled name: Inner
// Public signature: /Inner|null[0]
class Inner {
// CHECK:
// Mangled name: Inner#<init>!Outer(kotlin.Any){}
// Public signature: /Inner.<init>|7428094623108856579[0]
// Public signature debug description: <init>!Outer(kotlin.Any){}
constructor($context_receiver_0: Outer, arg: Any) /* primary */
// CHECK JVM_IR:
// Mangled name: Inner#bar(){}kotlin.Int
// Public signature: /Inner.bar|-6436649210114349217[0]
// Public signature debug description: bar(){}kotlin.Int
// CHECK JS_IR NATIVE:
// Mangled name: Inner#bar(){}
// Public signature: /Inner.bar|496682602797471549[0]
// Public signature debug description: bar(){}
fun bar(): Int
}
// CHECK:
// Mangled name: Outer
// Public signature: /Outer|null[0]
class Outer {
// CHECK:
// Mangled name: Outer{}x
// Public signature: /Outer.x|-8060530855978347579[0]
// Public signature debug description: {}x
val x: Int
// CHECK JVM_IR:
// Mangled name: Outer#<get-x>(){}kotlin.Int
// Public signature: /Outer.x.<get-x>|4966956098150895696[0]
// Public signature debug description: <get-x>(){}kotlin.Int
// CHECK JS_IR NATIVE:
// Mangled name: Outer#<get-x>(){}
// Public signature: /Outer.x.<get-x>|1482705010654679335[0]
// Public signature debug description: <get-x>(){}
get
// CHECK:
// Mangled name: Outer#<init>(){}
// Public signature: /Outer.<init>|-5645683436151566731[0]
// Public signature debug description: <init>(){}
constructor() /* primary */
}
// CHECK:
// Mangled name: #f(Outer){}
// Public signature: /f|-90367846469451219[0]
// Public signature debug description: f(Outer){}
fun f(outer: Outer): Unit