K2 resolve: prefer derived class property to base class field

#KT-50082 Fixed
This commit is contained in:
Mikhail Glukhikh
2022-11-16 17:14:56 +01:00
committed by teamcity
parent 642bbd38ba
commit 59bafedd8a
15 changed files with 407 additions and 41 deletions
@@ -0,0 +1,14 @@
FILE: KotlinBase.kt
public open class KotlinBase : R|kotlin/Any| {
public constructor(): R|KotlinBase| {
super<R|kotlin/Any|>()
}
public final val abcd: R|kotlin/String| = String(abcd)
public get(): R|kotlin/String|
}
FILE: test.kt
public final fun test(d: R|JavaDerived|): R|kotlin/Unit| {
R|<local>/d|.R|/JavaDerived.abcd|
}