[FIR2IR] Generate IR declarations in classes in strict order

Order is following:
- declared declarations in declaration (in source) order
- generated declarations in sorted order
This commit is contained in:
Dmitriy Novozhilov
2023-03-13 11:57:27 +02:00
committed by Space Team
parent c961c15729
commit 839026b6fe
15 changed files with 467 additions and 22 deletions
+19
View File
@@ -0,0 +1,19 @@
// FIR_IDENTICAL
// SKIP_KLIB_TEST
// IGNORE_BACKEND_K1: JS_IR
// Ignore reason: there is a js name clash between function `a()` and property `a`
package test
class A() {
constructor(x: Int) : this()
fun b() {}
fun a() {}
val b: Int = 1
val a: Int = 2
constructor(x: String) : this()
val Int.b: String get() = "b"
fun String.b() {}
val Int.a: String get() = "a"
fun String.a() {}
constructor(x: Double) : this()
}