[FIR] Create intersection overrides for fields in intersection type scope

^KT-56820 Fixed
This commit is contained in:
Dmitriy Novozhilov
2023-03-01 13:16:00 +02:00
committed by Space Team
parent 4e56079c59
commit 8c6d4a6f4b
13 changed files with 325 additions and 70 deletions
@@ -0,0 +1,21 @@
FILE: main.kt
private final val anyProperty: R|Property<kotlin/Any>| = R|/Property.Property|<R|kotlin/Any|>()
private get(): R|Property<kotlin/Any>|
private final val boundedProperty: R|Property<kotlin/String>| = R|/Property.Property|<R|kotlin/String|>()
private get(): R|Property<kotlin/String>|
public final fun test_1(x: R|Property<kotlin/Any>|): R|kotlin/Unit| {
when () {
(R|<local>/x| is R|Reference|) -> {
R|<local>/x|.R|SubstitutionOverride</Reference.id>|
}
}
}
public final fun test_2(x: R|Property<kotlin/String>|): R|kotlin/Unit| {
when () {
(R|<local>/x| is R|Reference|) -> {
R|<local>/x|.R|/Reference.id|
}
}
}