Files
Ivan Kochurkin 69b9bfc3e0 [FIR] Initialize public visibility for class-like declarations at FIR building phase if no modifier is presented
Java resolving subsystem requires calculated visibility for correct disambiguation of supertypes.
But visibility remains `Unknown` for Kotlin class-like declarations during supertypes resolving because `STATUS` resolve phase is performed after `SUPER_TYPES` phase.
To fix the problem, the visibility should be initialized to public at the FIR building phase if no modifier is presented.

^KT-64127 Fixed
2024-01-04 16:17:32 +00:00

45 lines
1.6 KiB
Plaintext
Vendored

FILE: delegates.kt
public? final? val x: Intby lazy#(<L> = lazy@fun <implicit>.<anonymous>(): <implicit> <inline=Unknown> {
IntegerLiteral(1).plus#(IntegerLiteral(2))
}
)
public? get(): <implicit> {
^ D|/x|.getValue#(Null(null), ::R|/x|)
}
public? final? val delegate: <implicit> = object : ReadWriteProperty<Any?, Int> {
private [ContainingClassKey=<anonymous>] constructor(): R|<anonymous>| {
super<<implicit>>()
}
public? open? override fun getValue(thisRef: Any?, property: KProperty<*>): Int {
^getValue IntegerLiteral(1)
}
public? open? override fun setValue(thisRef: Any?, property: KProperty<*>, value: Int): R|kotlin/Unit| {
}
}
public? get(): <implicit>
public? final? val value: <implicit>by delegate#
public? get(): <implicit> {
^ D|/value|.getValue#(Null(null), ::R|/value|)
}
public? final? var variable: <implicit>by delegate#
public? get(): <implicit> {
^ D|/variable|.getValue#(Null(null), ::R|/variable|)
}
public? set(<set-?>: <implicit>): R|kotlin/Unit| {
^ D|/variable|.setValue#(Null(null), ::R|/variable|, R|<local>/variable|)
}
public final? interface Base : R|kotlin/Any| {
}
public final? [DelegateFieldsMapKey={0=FirFieldSymbol /Derived.$$delegate_0}] class Derived : Base {
public? [ContainingClassKey=Derived] constructor(b: Base): R|Derived| {
super<<implicit>>()
}
private final field $$delegate_0: Base = b#
}