We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fc65e75 commit d1cdd6eCopy full SHA for d1cdd6e
tests/pos/i12945/A_1.scala
@@ -0,0 +1,10 @@
1
+opaque type Lie[W <: Int] = Int
2
+object Lie:
3
+ trait TC[-T]:
4
+ type Out
5
+ object TC:
6
+ given [W <: Int]: TC[Lie[W]] with
7
+ type Out = W
8
+
9
+val x = summon[Lie.TC[Lie[7]]]
10
+val works = summon[x.Out =:= 7]
tests/pos/i12945/B_2.scala
@@ -0,0 +1,3 @@
+object Test:
+ val x = summon[Lie.TC[Lie[7]]]
+ val fails = summon[x.Out =:= 7]
0 commit comments