You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: tests/neg-custom-args/captures/filevar.check
+5-4Lines changed: 5 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -1,12 +1,13 @@
1
1
-- [E007] Type Mismatch Error: tests/neg-custom-args/captures/filevar.scala:15:12 --------------------------------------
2
2
15 | withFile: f => // error with level checking, was OK under both schemes before
3
3
| ^
4
-
|Found: (f: File^'s1) ->'s2 Unit
5
-
|Required: (f: File^{l}) => Unit
4
+
|Found: (l: scala.caps.Capability^) ?->'s1 File^'s2 ->'s3 Unit
5
+
|Required: (l: scala.caps.Capability^) ?-> (f: File^{l}) => Unit
6
6
|
7
-
|Note that capability l cannot be included in outer capture set 's1 of parameter f.
7
+
|Note that capability l cannot be included in outer capture set 's4 of parameter f.
8
8
|
9
-
|where: => refers to a fresh root capability created in anonymous function of type (using l: scala.caps.Capability): File^{l} -> Unit when instantiating expected result type (f: File^{l}) ->{cap} Unit of function literal
9
+
|where: => refers to a root capability associated with the result type of (using l: scala.caps.Capability^): (f: File^{l}) => Unit
|Note that capability lcap cannot be included in outer capture set 's1 of parameter cap.
8
-
|
9
-
|where: => refers to a fresh root capability created in anonymous function of type (using lcap: scala.caps.Capability): test2.Cap^{lcap} -> [T] => (op: test2.Cap^{lcap} => T) -> T when instantiating expected result type test2.Cap^{lcap} ->{cap²} [T] => (op: test2.Cap^'s6 ->'s7 T) ->'s8 T of function literal
10
-
|
11
-
| longer explanation available when compiling with `-explain`
12
1
-- [E007] Type Mismatch Error: tests/neg-custom-args/captures/i15923.scala:12:21 ---------------------------------------
13
2
12 | val leak = withCap(cap => mkId(cap)) // error
|Note that capability lcap cannot be included in outer capture set 's9 of parameter cap.
7
+
|Note that capability cap cannot be included in outer capture set 's6.
19
8
|
20
-
|where: => refers to a fresh root capability created in anonymous function of type (using lcap: scala.caps.Capability): Cap^{lcap} -> Id[Cap] when instantiating expected result type Cap^{lcap} ->{cap²} Id[Cap^'s13]^'s14 of function literal
9
+
|where: => refers to a root capability associated with the result type of (using lcap: scala.caps.Capability^): Cap^{lcap} => Id[Cap^'s6]^'s7
10
+
| ^ refers to the universal root capability
11
+
| cap is a root capability associated with the result type of (x$0: Cap^'s2): Id[Cap^'s4]^'s5
21
12
|
22
13
| longer explanation available when compiling with `-explain`
0 commit comments