aboutsummaryrefslogtreecommitdiff
path: root/tests/run/mixin-primitive-on-generic-3.scala
blob: f6ff0b63e4f54317183a18de1e04898984aa4892 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
object Test {
  def main(args: Array[String]): Unit = {
    println((new Foo: Baz).value)
    println((new Foo: Qux).value)
  }
}

class Foo extends Bar[Boolean](true) with Baz with Qux

class Bar[T](x: T) {
  def value: T = x
}

trait Baz {
  def value: Boolean
}

trait Qux {
  def value: Boolean
}