summaryrefslogtreecommitdiff
path: root/test-nsc/files/pos/infer2.scala
blob: 66f3d76544efc4b2f6fc51047a6b93e29727259f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
object test {

  def f[a, b <: a](x: b): a = x: a;
  def g[a >: b, b](x: b): a = x: a;

  val x: int = f(1);
  val y: String = g("")

}