Files
kotlin-fork/compiler/testData/codegen/box/delegatedProperty/optimizedDelegatedProperties/kt40815.kt
T
2020-08-06 21:01:59 +02:00

14 lines
340 B
Kotlin
Vendored

// IGNORE_BACKEND_FIR: JVM_IR
import kotlin.reflect.KProperty
operator fun Int.provideDelegate(thiz: Any?, property: KProperty<*>): String = property.name
inline operator fun String.getValue(thiz: Any?, property: KProperty<*>): String = property.name
fun box(): String = with(42) {
val O by this
O
} + {
val K by ""
K
}()