Skip to content

Commit 8dcb764

Browse files
committed
Alt tweak
1 parent 4da73cd commit 8dcb764

File tree

3 files changed

+9
-13
lines changed

3 files changed

+9
-13
lines changed

compiler/src/dotty/tools/dotc/reporting/Message.scala

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -132,9 +132,9 @@ object Message:
132132
def sameSuperscript(cur: Recorded, existing: Recorded) =
133133
(cur eq existing) ||
134134
(cur, existing).match
135-
case (cur: ParamRef, existing: ParamRef) =>
136-
(cur.paramName eq existing.paramName)
137-
&& cur.binder.paramNames == existing.binder.paramNames
135+
case (cur: ParamRef, existing: ParamRef) => true
136+
//(cur.paramName eq existing.paramName)
137+
//&& cur.binder.paramNames == existing.binder.paramNames
138138
case _ =>
139139
false
140140

tests/neg-custom-args/captures/filevar.check

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,10 @@
55
|The leakage occurred when trying to match the following types:
66
|
77
|Found: (l: scala.caps.Capability^) ?->'s2 File^'s3 ->'s4 Unit
8-
|Required: (l²: scala.caps.Capability^) ?-> (f: File^{l²}) => Unit
8+
|Required: (l: scala.caps.Capability^) ?-> (f: File^{l}) => Unit
99
|
10-
|where: => refers to a root capability associated with the result type of (using l²: scala.caps.Capability^): (f: File^{l²}) => Unit
10+
|where: => refers to a root capability associated with the result type of (using l: scala.caps.Capability^): (f: File^{l}) => Unit
1111
| ^ refers to the universal root capability
12-
| l is a reference to a value parameter
13-
| l² is a reference to a value parameter
1412
16 | val o = Service()
1513
17 | o.file = f
1614
18 | o.log

tests/neg-custom-args/captures/i15923.check

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,10 @@
55
|The leakage occurred when trying to match the following types:
66
|
77
|Found: (lcap: scala.caps.Capability^) ?->'s2 Cap^'s3 ->'s4 Id[Cap^'s5]^'s6
8-
|Required: (lcap²: scala.caps.Capability^) ?-> Cap^{lcap²} => Id[Cap^'s1]^'s7
8+
|Required: (lcap: scala.caps.Capability^) ?-> Cap^{lcap} => Id[Cap^'s1]^'s7
99
|
10-
|where: => refers to a root capability associated with the result type of (using lcap²: scala.caps.Capability^): Cap^{lcap²} => Id[Cap^'s1]^'s7
11-
| ^ refers to the universal root capability
12-
| cap is a root capability associated with the result type of (x$0: Cap^'s3): Id[Cap^'s5]^'s6
13-
| lcap is a reference to a value parameter
14-
| lcap² is a reference to a value parameter
10+
|where: => refers to a root capability associated with the result type of (using lcap: scala.caps.Capability^): Cap^{lcap} => Id[Cap^'s1]^'s7
11+
| ^ refers to the universal root capability
12+
| cap is a root capability associated with the result type of (x$0: Cap^'s3): Id[Cap^'s5]^'s6
1513
|
1614
| longer explanation available when compiling with `-explain`

0 commit comments

Comments
 (0)