Labeled this & super to nested class' outer is an error

#KT-1174 In Progress
This commit is contained in:
Alexander Udalov
2012-12-03 17:42:40 +04:00
parent 5d92453532
commit 43c37398af
17 changed files with 84 additions and 17 deletions
@@ -0,0 +1,23 @@
trait Trait {
fun bar() = 42
}
class Outer : Trait {
fun foo() {
val <!UNUSED_VARIABLE!>t<!> = this@Outer
val <!UNUSED_VARIABLE!>s<!> = super@Outer.bar()
class Local : Trait {
val t = this@Outer
val s = super@Outer.bar()
inner class Inner {
val t = this@Local
val s = super@Local.bar()
val tt = this@Outer
val ss = super@Outer.bar()
}
}
}
}