Skip to content

Commit ddde3b5

Browse files
oderskyneko-kai
authored andcommitted
Reclassify test
1 parent cfb489d commit ddde3b5

File tree

2 files changed

+15
-1
lines changed

2 files changed

+15
-1
lines changed

tests/neg/6697.check

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
-- [E057] Type Mismatch Error: tests/neg/6697.scala:6:35 ---------------------------------------------------------------
2+
6 | type Copy[O <: Off] = Of[Sup[O], Sub[O]] // error
3+
| ^
4+
| Type argument Test.Sub[O] does not conform to upper bound Test.Sup[O]
5+
|
6+
| Note: a match type could not be fully reduced:
7+
|
8+
| trying to reduce Test.Sub[O]
9+
| failed since selector O
10+
| matches none of the cases
11+
|
12+
| case Test.Of[sup, sub] => sub
13+
14+
longer explanation available when compiling with `-explain`

tests/pos/6697.scala renamed to tests/neg/6697.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,5 @@ object Test {
33
case class Of[sup, sub <: sup]() extends Off
44
type Sup[O <: Off] = O match { case Of[sup, sub] => sup }
55
type Sub[O <: Off] = O match { case Of[sup, sub] => sub }
6-
type Copy[O <: Off] = Of[Sup[O], Sub[O]]
6+
type Copy[O <: Off] = Of[Sup[O], Sub[O]] // error
77
}

0 commit comments

Comments
 (0)