Evaluate overloaded toString() in watches for Kotlin classes with delegate properties (KT-14068)

(cherry picked from commit 7774d2c)

 #KT-14068 Fixed
This commit is contained in:
Nikolay Krasko
2016-10-14 18:43:36 +03:00
committed by Nikolay Krasko
parent 440bdea736
commit 944b9b5b6c
4 changed files with 90 additions and 2 deletions
@@ -0,0 +1,21 @@
package delegatedPropertyInClassWithToString
import kotlin.reflect.KProperty
fun main(args: Array<String>) {
val a = A()
//Breakpoint!
args.size
}
class A {
val prop by MyDelegate()
override fun toString(): String = "KotlinTest"
}
class MyDelegate {
operator fun getValue(t: Any?, p: KProperty<*>): Int = 1
}
// PRINT_FRAME