Initial implementation of platformStatic

This commit is contained in:
Michael Bogdanov
2014-09-01 15:12:31 +04:00
parent 7bbedd9685
commit e26d635633
36 changed files with 718 additions and 47 deletions
@@ -0,0 +1,28 @@
open class B {
val p = "OK"
}
class BB : B()
trait Z<T :B > {
fun T.getString() : String {
return p
}
fun test(s: T) : String {
return s.extension()
}
private fun T.extension(): String {
return getString()
}
}
object Z2 : Z<BB> {
}
fun box() : String {
return Z2.test(BB())
}