Implementation of super methods calling (#203)

* implemented super call

* tests

* removed redundant code
This commit is contained in:
Igor Chevdar
2017-01-27 16:38:48 +05:00
committed by GitHub
parent 36c90ac47d
commit 01cb9d4cac
6 changed files with 98 additions and 7 deletions
@@ -0,0 +1,19 @@
open class C {
open fun f() = "<fun:C>"
}
class C1: C() {
override fun f() = super<C>.f() + "<fun:C1>"
}
open class C2: C() {
}
class C3: C2() {
override fun f() = super<C2>.f() + "<fun:C3>"
}
fun main(args: Array<String>) {
println(C1().f())
println(C3().f())
}