diff options
-rw-r--r-- | tests/untried/neg/t5543.scala | 8 | ||||
-rw-r--r-- | tests/untried/neg/t6666.scala | 2 | ||||
-rw-r--r-- | tests/untried/neg/t7605-deprecation.scala | 2 |
3 files changed, 6 insertions, 6 deletions
diff --git a/tests/untried/neg/t5543.scala b/tests/untried/neg/t5543.scala index 4e03e6e11..8fa4ef36f 100644 --- a/tests/untried/neg/t5543.scala +++ b/tests/untried/neg/t5543.scala @@ -1,19 +1,19 @@ class C1 { type T - def this(x: T) { this() } + def this(x: T) = { this() } } class C1a[T] { - def this(x: T) { this() } // works, no error here + def this(x: T) = { this() } // works, no error here } class C2(x: Int) { - def this(a: Int, b: Int = x) { + def this(a: Int, b: Int = x) = { this(b) } } class C3 { val x = 0 - def this(a: Int = x) { this() } + def this(a: Int = x) = { this() } } diff --git a/tests/untried/neg/t6666.scala b/tests/untried/neg/t6666.scala index 2495c8727..01d0c0d9e 100644 --- a/tests/untried/neg/t6666.scala +++ b/tests/untried/neg/t6666.scala @@ -5,7 +5,7 @@ object F { } class COkay extends C(0) { - def this(a: Any) { + def this(a: Any) = { this() def x = "".toString F.byname(x) diff --git a/tests/untried/neg/t7605-deprecation.scala b/tests/untried/neg/t7605-deprecation.scala index 30cd21bd6..214f32437 100644 --- a/tests/untried/neg/t7605-deprecation.scala +++ b/tests/untried/neg/t7605-deprecation.scala @@ -3,6 +3,6 @@ abstract class Foo { def baz def boo(i: Int, l: Long) def boz(i: Int, l: Long): Unit = {} - def this(i: Int) { this() } // Don't complain here! + def this(i: Int) = { this() } // Don't complain here! def foz: Unit // Don't complain here! } |