We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c40760d commit 62c71c0Copy full SHA for 62c71c0
tests/neg/i13580.check
@@ -0,0 +1,4 @@
1
+-- Error: tests/neg/i13580.scala:9:7 -----------------------------------------------------------------------------------
2
+9 |given (using tracked val w: IntWidth) => IntCandidate: // error
3
+ | ^^^^^
4
+ | `using` is already implied here, should not be given explicitly
tests/pos/i13580.scala
@@ -1,12 +1,12 @@
//> using options -language:experimental.modularity -source future
trait IntWidth:
type Out
-given IntWidth with
+given IntWidth:
5
type Out = 155
6
7
trait IntCandidate:
8
9
-given (using tracked val w: IntWidth): IntCandidate with
+given (tracked val w: IntWidth) => IntCandidate:
10
type Out = w.Out
11
12
val x = summon[IntCandidate]
0 commit comments