Files
kotlin-fork/compiler/fir/analysis-tests/testData/resolve/delegates/receiverInference.fir.txt
T
Denis.Zharkov 034671ad78 K2: Update substituted member candidate if it contains type variables
See the comment at updateSubstitutedMemberIfReceiverContainsTypeVariable

It became necessary after delegate inference is rewritten, since before
that happened, stub types were being left there and FIR2IR handled
them accidentally properly because stub types are equal to anything.

But that wasn't really correct even there because stub types are not
intended to leak out of the FIR

^KT-61060
2023-09-08 07:11:48 +00:00

38 lines
1.3 KiB
Plaintext
Vendored

FILE: receiverInference.kt
public abstract interface XEntity : R|kotlin/Any| {
}
public final class Provider<out R> : R|kotlin/Any| {
public constructor<out R>(): R|Provider<R>| {
super<R|kotlin/Any|>()
}
public final operator fun provideDelegate(thisRef: R|XEntity|, prop: R|kotlin/Any|): R|R| {
^provideDelegate Null(null)!!
}
}
public final class Prop<E, V> : R|kotlin/Any| {
public constructor<E, V>(): R|Prop<E, V>| {
super<R|kotlin/Any|>()
}
public final operator fun getValue(receiver: R|E|, prop: R|kotlin/Any|): R|V| {
^getValue Null(null)!!
}
}
public final fun <R : R|XEntity|, V> mkProp(): R|Provider<Prop<R, V>>| {
^mkProp R|/Provider.Provider|<R|Prop<R, V>|>()
}
public final class MyEnt : R|XEntity| {
public constructor(): R|MyEnt| {
super<R|kotlin/Any|>()
}
public final val d: R|kotlin/String|by R|/mkProp|<R|MyEnt|, R|kotlin/String|>().R|SubstitutionOverride</Provider.provideDelegate: R|Prop<MyEnt, kotlin/String>|>|(this@R|/MyEnt|, ::R|/MyEnt.d|)
public get(): R|kotlin/String| {
^ this@R|/MyEnt|.D|/MyEnt.d|.R|SubstitutionOverride</Prop.getValue: R|kotlin/String|>|(this@R|/MyEnt|, ::R|/MyEnt.d|)
}
}