summaryrefslogtreecommitdiff
path: root/test/files/pos/t4018.scala
blob: 2b265c5717049b3b3f33c114cf00b6c5279b5b7c (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
trait M[V[_]]

class Cls[V[_]](c: M[V])

object Cls{
  def apply[V[_]](c: M[V]): Cls[V] = new Cls[V](c)
}

object test {
  val c: M[Option] = new M[Option] {}
  new Cls(c)         // does not infer.
  new Cls[Option](c) // okay
  Cls(c)             // okay
}