Skip to content

Commit 840def7

Browse files
committed
Fix #6716: Add test
1 parent bc81953 commit 840def7

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

tests/pos/i6716.scala

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
trait Monad[T]
2+
class Foo
3+
object Foo {
4+
given as Monad[Foo]
5+
}
6+
7+
opaque type Bar = Foo
8+
object Bar {
9+
given as Monad[Bar] = the[Monad[Foo]]
10+
}
11+
12+
object Test {
13+
val mf = the[Monad[Foo]]
14+
val mb = the[Monad[Bar]]
15+
}

0 commit comments

Comments
 (0)