aboutsummaryrefslogtreecommitdiff
path: root/tests/pending/pickling/named-params.scala
blob: 2697a7bb73cadeb211b16ea350f271984c80e93b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
package namedparams

class C[type Elem, type Value](val elem: Elem) {
  def toVal: Elem = ???
}

class D[type Elem, V](elem: Elem) extends C[Elem, V](elem)

object Test {
  val c = new C[String, String]("A") {
    override def toVal = elem
  }
  val x: c.Elem = c.elem

  val c2: C { type Elem = String } = c

  val c3 = new C[Elem = String, Value = Int]("B")
  val c4 = new C[Elem = String]("C")
  val x2: c2.Elem = c2.elem
}