Skip to content

Commit 1af9159

Browse files
committed
Update test expectations
1 parent afee749 commit 1af9159

File tree

10 files changed

+31
-18
lines changed

10 files changed

+31
-18
lines changed

tests/init-global/warn/global-irrelevance2.check

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
-- Warning: tests/init-global/warn/global-irrelevance2.scala:5:6 -------------------------------------------------------
1+
-- Warning: tests/init-global/warn/global-irrelevance2.scala:5:2 -------------------------------------------------------
22
5 | A.x = b * 2 // warn
33
| ^^^^^^^^^^^^
44
| Mutating object A during initialization of object B.

tests/neg/assignments.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ object assignments {
1313
x = x + 1
1414
x *= 2
1515

16-
x_= = 2 // error should give missing arguments
16+
x_= = 2 // error should give missing arguments // error
1717
}
1818

1919
var c = new C

tests/neg/i11561.check

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
-- [E081] Type Error: tests/neg/i11561.scala:2:32 ----------------------------------------------------------------------
2-
2 | val updateText1 = copy(text = _) // error
2+
2 | val updateText1 = copy(text = _) // error // error
33
| ^
44
| Missing parameter type
55
|
@@ -8,9 +8,15 @@
88
| _$1 => State.this.text = _$1
99
| Expected type for the whole anonymous function:
1010
| String
11-
-- [E052] Type Error: tests/neg/i11561.scala:3:30 ----------------------------------------------------------------------
11+
-- [E052] Type Error: tests/neg/i11561.scala:2:25 ----------------------------------------------------------------------
12+
2 | val updateText1 = copy(text = _) // error // error
13+
| ^^^^
14+
| Reassignment to val text
15+
|
16+
| longer explanation available when compiling with `-explain`
17+
-- [E052] Type Error: tests/neg/i11561.scala:3:25 ----------------------------------------------------------------------
1218
3 | val updateText2 = copy(text = (_: String)) // error
13-
| ^^^^^^^^^^^^^^^^^^
19+
| ^^^^
1420
| Reassignment to val text
1521
|
1622
| longer explanation available when compiling with `-explain`

tests/neg/i11561.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
case class State(text: String):
2-
val updateText1 = copy(text = _) // error
2+
val updateText1 = copy(text = _) // error // error
33
val updateText2 = copy(text = (_: String)) // error

tests/neg/i16655.check

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,13 @@
1-
-- [E052] Type Error: tests/neg/i16655.scala:3:4 -----------------------------------------------------------------------
2-
3 | x = 5 // error
3-
| ^^^^^
1+
-- [E052] Type Error: tests/neg/i16655.scala:3:2 -----------------------------------------------------------------------
2+
3 | x = 5 // error // error
3+
| ^
44
| Reassignment to val x
55
|
66
| longer explanation available when compiling with `-explain`
7+
-- [E007] Type Mismatch Error: tests/neg/i16655.scala:3:6 --------------------------------------------------------------
8+
3 | x = 5 // error // error
9+
| ^
10+
| Found: (5 : Int)
11+
| Required: String
12+
|
13+
| longer explanation available when compiling with `-explain`

tests/neg/i16655.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
object Test:
22
val x = "MyString"
3-
x = 5 // error
3+
x = 5 // error // error

tests/neg/i20338a.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
object types:
22
opaque type Struct = Int
33
val test: Struct = 25
4-
extension (s: Struct)
4+
extension (s: Struct)
55
def field: Int = s
66
def field_=(other: Int) = ()
77

8-
@main def hello =
8+
@main def hello =
99
import types.*
1010
test.field = "hello" // error

tests/neg/i20338c.check

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
-- [E052] Type Error: tests/neg/i20338c.scala:9:6 ----------------------------------------------------------------------
1+
-- [E052] Type Error: tests/neg/i20338c.scala:9:4 ----------------------------------------------------------------------
22
9 | f.x = 42 // error
3-
| ^^^^^^^^
3+
| ^^^
44
| Reassignment to val x
55
|
66
| longer explanation available when compiling with `-explain`

tests/neg/multiple-assignment.check

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
-- [E194] Type Error: tests/neg/multiple-assignment.scala:9:11 ---------------------------------------------------------
1+
-- [E199] Type Error: tests/neg/multiple-assignment.scala:9:11 ---------------------------------------------------------
22
9 | (x, y) = 1 // error
33
| ^
44
| invalid source of multiple assignment.
55
| The right hand side must be a tuple but (1 : Int) was found.
6-
-- [E196] Type Error: tests/neg/multiple-assignment.scala:10:11 --------------------------------------------------------
6+
-- [E201] Type Error: tests/neg/multiple-assignment.scala:10:11 --------------------------------------------------------
77
10 | (x, y) = (1, 1, 1) // error
88
| ^^^^^^^^^
99
| Source and target of multiple assignment have different sizes.
@@ -16,7 +16,7 @@
1616
| Required: Boolean
1717
|
1818
| longer explanation available when compiling with `-explain`
19-
-- [E195] Type Error: tests/neg/multiple-assignment.scala:12:6 ---------------------------------------------------------
19+
-- [E200] Type Error: tests/neg/multiple-assignment.scala:12:6 ---------------------------------------------------------
2020
12 | (x, (y, z)) = (1, (true, "b")) // error
2121
| ^^^^^^
2222
| invalid target of multiple assignment.

tests/neg/parser-stability-16.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@ class x0[x0] {
22
val x1 : x0
33
}
44
trait x3 extends x0 { // error
5-
x1 = 0 object // error // error
5+
x1 = 0 object // error // error // error

0 commit comments

Comments
 (0)