Files
kotlin-fork/compiler/testData/codegen/box/delegation/genericProperty.kt
T
Alexander Udalov 5f367278c1 Psi2ir: support generic properties in class delegation
Since property accessor descriptors (unlike corresponding IR elements)
do not have type parameters, we need to take them from the corresponding
property to ensure the correct IR for delegated property accessors.
2019-12-12 15:02:32 +03:00

11 lines
168 B
Kotlin
Vendored

// IGNORE_BACKEND_FIR: JVM_IR
interface I {
val <T> T.id: T
get() = this
}
class A(i: I) : I by i
fun box(): String = with(A(object : I {})) { "OK".id }