aboutsummaryrefslogblamecommitdiff
path: root/tests/pos/i941.scala
blob: 5a0ef512cc4bff521d43902a4f8cc345f36b05c8 (plain) (tree)
1
2
3
4
5
6
7
8
9








                                       













                              
 
object Test {

  class C[A] {

    def this(y: A) = { this(); foo(y) }

    def foo(x: A): Unit = ()

  }
  class D[A](x: A) {

    var f = x

    def this(y1: A, y2: A) = {
      this(y1)
      f = y2
      val g: A = f
      foo(y2)
    }

    def foo(x: A): Unit = ()

  }
}