Skip to content

Instantly share code, notes, and snippets.

@mpilquist
Created March 12, 2016 00:15
Show Gist options
  • Save mpilquist/faa3c97cfd73f3d77491 to your computer and use it in GitHub Desktop.
Save mpilquist/faa3c97cfd73f3d77491 to your computer and use it in GitHub Desktop.
Regression in 2.11.8
class A {
private case class B(x: Int)
private object B {
val z = B(0)
}
val a = B.z.x
}
/* Compiling under 2.11.7 and running (new A).a results in 0
Compiling under 2.11.8 and running (new A).a results in SOE:
at A$B$.<init>(a.scala:4)
at A.A$$B$lzycompute(a.scala:3)
at A.A$$B(a.scala:3)
at A$B$.<init>(a.scala:4)
at A.A$$B$lzycompute(a.scala:3)
at A.A$$B(a.scala:3)
at A$B$.<init>(a.scala:4)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment