Closed
Description
Following code runs in Scalac, but failed to run in Dotty. Inspecting the generated code shows that the $outer
for A.Inner
is not implemented in the top-leve class Inner
.
class A {
val a = "a"
trait Inner {
def f = println(a)
def h = 3
}
}
class Inner extends O.a.Inner
object O {
val a = new A
def main(args: Array[String]): Unit = {
(new Inner).f
}
}
A fix is in order, will push soon.