[FIR2IR] Properly create FIR f/o for lazy IR f/o
```kotlin
interface A {
fun foo() // (1)
}
interface B : A {
// f/o fun foo() // (2)
}
```
In previous commits it was forgotten to create new FIR declarations for
IR fake-overrides, which led to the situation when `IR lazy functions
of `(1)` and `(2)` both contained fir of function (1) as their base
declaration
It seems this change fixed some cases from KT-42020
This commit is contained in:
committed by
Space Team
parent
8ebb412705
commit
89b98ef784
+4
-3
@@ -1,7 +1,8 @@
|
||||
// IGNORE_BACKEND_K2: JVM_IR, JS_IR
|
||||
// KT-59609
|
||||
// IGNORE_BACKEND_K2: JS_IR
|
||||
// IGNORE_BACKEND: NATIVE
|
||||
// FIR status: Validation failed. TODO decide if we want to fix KT-42020 for FIR as well
|
||||
// IGNORE_CODEGEN_WITH_IR_FAKE_OVERRIDE_GENERATION
|
||||
// Reason: KT-42020
|
||||
|
||||
// MODULE: lib
|
||||
// FILE: a.kt
|
||||
package a
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// TARGET_BACKEND: JVM
|
||||
// IGNORE_BACKEND_K2: JVM_IR, JS_IR
|
||||
// FIR status: validation failed. TODO decide if we want to fix KT-42020 for FIR as well
|
||||
// IGNORE_CODEGEN_WITH_IR_FAKE_OVERRIDE_GENERATION
|
||||
// Reason: KT-42020
|
||||
|
||||
open class Base<T> {
|
||||
fun foo(x: T) = "x:$x"
|
||||
@@ -26,4 +26,4 @@ fun box(): String {
|
||||
throw Exception("test4: $test4")
|
||||
|
||||
return "OK"
|
||||
}
|
||||
}
|
||||
|
||||
+1
-3
@@ -7,8 +7,6 @@
|
||||
// IGNORE_BACKEND: JS
|
||||
// IGNORE_BACKEND_K2: NATIVE, JS_IR
|
||||
|
||||
// FIR status: validation failed. TODO decide if we want to fix KT-42020 for FIR as well
|
||||
// IGNORE_BACKEND_K2: JVM_IR
|
||||
// MODULE: lib
|
||||
// FILE: lib.kt
|
||||
|
||||
@@ -31,4 +29,4 @@ fun box(): String {
|
||||
if (foo24 != "p2:24") return "FAIL2: foo24=$foo24"
|
||||
|
||||
return "OK"
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user