Kotlin delegate property causes a preview rendering error in Android Studio
问题 I have created a custom property dedicated to holding properties of the view that require invalidate() call for one of my projects: class InvalidatingProperty<T>(private var _value: T) { operator fun getValue(thisRef: View, property: KProperty<*>): T { return _value } operator fun setValue(thisRef: View, property: KProperty<*>, value: T) { _value = value thisRef.invalidate() } } In another project, I wanted to reuse some of my previous work, so i copied the views and their dependencies,