Skip to content

Commit 24ac355

Browse files
apply srewrite (no procedure syntax for constructors) to tests/untried/neg
1 parent 33b0e7b commit 24ac355

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

tests/untried/neg/t5543.scala

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,19 @@
11
class C1 {
22
type T
3-
def this(x: T) { this() }
3+
def this(x: T) = { this() }
44
}
55

66
class C1a[T] {
7-
def this(x: T) { this() } // works, no error here
7+
def this(x: T) = { this() } // works, no error here
88
}
99

1010
class C2(x: Int) {
11-
def this(a: Int, b: Int = x) {
11+
def this(a: Int, b: Int = x) = {
1212
this(b)
1313
}
1414
}
1515

1616
class C3 {
1717
val x = 0
18-
def this(a: Int = x) { this() }
18+
def this(a: Int = x) = { this() }
1919
}

tests/untried/neg/t6666.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ object F {
55
}
66

77
class COkay extends C(0) {
8-
def this(a: Any) {
8+
def this(a: Any) = {
99
this()
1010
def x = "".toString
1111
F.byname(x)

tests/untried/neg/t7605-deprecation.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@ abstract class Foo {
33
def baz
44
def boo(i: Int, l: Long)
55
def boz(i: Int, l: Long): Unit = {}
6-
def this(i: Int) { this() } // Don't complain here!
6+
def this(i: Int) = { this() } // Don't complain here!
77
def foz: Unit // Don't complain here!
88
}

0 commit comments

Comments
 (0)