Files
kotlin-fork/compiler/testData/ir/irText/declarations/fakeOverrides.kt
T
Dmitriy Novozhilov d4f55894b4 [FIR2IR] Properly calculate dispatch receiver type for fake overrides
If some function is not fake-override, then its type should be just
  default type of containing class
For fake overrides the default type calculated in the following way:
1. Find first overridden function, which is not fake override
2. Take its containing class
3. Find supertype of current containing class with type constructor of
   class from step 2

^KT-60252 Fixed
2023-08-25 21:06:15 +00:00

16 lines
227 B
Kotlin
Vendored

// FIR_IDENTICAL
interface IFooStr {
fun foo(x: String)
}
interface IBar {
val bar: Int
}
abstract class CFoo<T> {
fun foo(x: T) {}
}
class Test1 : CFoo<String>(), IFooStr, IBar {
override val bar: Int = 42
}