KT-16535 'provideDelegate' convention is not supported in IR
Implement provideDelegate convention support. NB delegate type now depends on 'provideDelegate' convention resolution.
This commit is contained in:
@@ -0,0 +1,10 @@
|
||||
class Delegate(val value: String) {
|
||||
operator fun getValue(thisRef: Any?, property: Any?) = value
|
||||
}
|
||||
|
||||
class DelegateProvider(val value: String) {
|
||||
operator fun provideDelegate(thisRef: Any?, property: Any?) = Delegate(value)
|
||||
}
|
||||
|
||||
val testTopLevel by DelegateProvider("OK")
|
||||
|
||||
Reference in New Issue
Block a user