Deprecate PropertyMetadata, use KProperty<*> for delegated properties instead

This commit is contained in:
Alexander Udalov
2015-10-12 21:42:18 +03:00
parent 3c74f48f91
commit ec1b4776fe
145 changed files with 536 additions and 379 deletions
@@ -1,15 +1,17 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
class A {
val c: Int by <!DELEGATE_SPECIAL_FUNCTION_NONE_APPLICABLE!>Delegate()<!>
}
class Delegate {
fun getValue(t: Int, p: PropertyMetadata): Int {
t.equals(p) // to avoid UNUSED_PARAMETER warning
fun getValue(t: Int, p: KProperty<*>): Int {
return 1
}
fun getValue(t: String, p: PropertyMetadata): Int {
t.equals(p) // to avoid UNUSED_PARAMETER warning
fun getValue(t: String, p: KProperty<*>): Int {
return 1
}
}