blob: 8d2b859998e941671e6e11a020d31cf78c5492d0 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
|
object C {
val a: Int = 1
val b: Int = 2
val c: Int = 2
trait X[T]
implicit def u[A, B]: X[A | B] = new X[A | B] {}
def y[T](implicit x: X[T]): T = ???
val x: a.type & b.type | b.type & c.type = y
}
|