blob: 3cc96afa5b8255944c051d39bd6b21d24bf217a1 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
// A test for the case where the outer field of class B#J should be eliminated.
// You can verify this by running a javap on B.J
abstract class A {
abstract class I {
}
val foo = "foo"
}
class B extends A {
class J extends I {
val bar = foo
}
}
object Test extends App {
val b = new B
assert((new b.J).bar == b.foo)
}
|