blob: 88932cd2cc5ed68eccdf226f161315ca2edf4380 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
// desugars to package p { object `package` }
// previously, synthetic p.C was incorrectly added to this tree
// This only matters because synthetics are not hygienic
package object p
package p {
import scala.concurrent.Future
case class C private[p] (value: Future[Int]) // private to avoid rewriting C.apply to new C
}
package client {
trait X {
import scala.concurrent.Future
def f = p.C(Future(42)(null)) // ensure synthetics were generated, i.e., p.C.apply
}
}
|