File tree Expand file tree Collapse file tree 5 files changed +18
-1
lines changed
compiler/src/dotty/tools/dotc/transform/patmat Expand file tree Collapse file tree 5 files changed +18
-1
lines changed Original file line number Diff line number Diff line change @@ -537,7 +537,7 @@ object SpaceEngine {
537537 scrutineeTp match
538538 case AppliedType (tycon, targs)
539539 if unappSym.is(Synthetic )
540- && (pt.resultType.asInstanceOf [MethodType ].paramInfos.head.typeConstructor eq tycon) =>
540+ && (pt.resultType.asInstanceOf [MethodType ].paramInfos.head.typeConstructor =:= tycon) =>
541541 // Special case synthetic unapply/unapplySeq's
542542 // Provided the shapes of the types match:
543543 // the scrutinee type being unapplied and
Original file line number Diff line number Diff line change 1+ sealed trait N [T ]
2+ case class MakeTuple [T <: Tuple ](v : T ) extends N [T ]
Original file line number Diff line number Diff line change 1+ object test {
2+ def t [T ](expr : N [T ]): Any =
3+ expr match {
4+ case MakeTuple (_) => ???
5+ }
6+ }
Original file line number Diff line number Diff line change 1+ trait TC2 [X ]
2+ sealed trait TC1 [T ]
3+ case class Iterable [T , C <: scala.Iterable [T ]](tag : TC1 [C ]) extends TC1 [C ]
Original file line number Diff line number Diff line change 1+ object test {
2+ def f [T ](c : TC1 [T ]): Unit =
3+ c match {
4+ case Iterable (_) => ???
5+ }
6+ }
You can’t perform that action at this time.
0 commit comments