Skip to content

Commit b39d38e

Browse files
test: add in a regression test for #11223 (#17496)
[skip community_build] closes #11223
2 parents 5e8ee91 + bced8c8 commit b39d38e

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

tests/pos/i11223.scala

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
object T:
2+
trait M[F[_]]
3+
trait EE[A, B]
4+
trait AE[A]
5+
trait DE[A]
6+
trait CE[A]
7+
8+
type A1 = M[AE]
9+
type D1 = M[DE] | M[[a] =>> EE[Int, a]]
10+
type C1 = M[CE]
11+
12+
trait F[+R, +A]:
13+
def <+>[U, B](b: F[U, B]): F[R | U, A] = null
14+
def int: F[R | A1, Int]
15+
16+
def d1[A](f: => A): F[D1, A] = null
17+
def m[R, A](f: F[R | C1, A]): F[R | C1, A] = null
18+
19+
def x = m { // adding type annotation here helps (m[D1 | A1 | C1, Int])
20+
d1(123).int <+> null
21+
}

0 commit comments

Comments
 (0)