File tree 2 files changed +13
-4
lines changed
compiler/src/dotty/tools/dotc/transform/patmat
2 files changed +13
-4
lines changed Original file line number Diff line number Diff line change @@ -354,11 +354,8 @@ class SpaceEngine(using Context) extends SpaceLogic {
354
354
case pat : Ident if isBackquoted(pat) =>
355
355
Typ (pat.tpe, decomposed = false )
356
356
357
- case Ident (nme.WILDCARD ) =>
358
- Typ (erase(pat.tpe.stripAnnots, isValue = true ), decomposed = false )
359
-
360
357
case Ident (_) | Select (_, _) =>
361
- Typ (erase(pat.tpe.stripAnnots, isValue = true ), decomposed = false )
358
+ Typ (erase(pat.tpe.stripAnnots.widenSkolem , isValue = true ), decomposed = false )
362
359
363
360
case Alternative (trees) =>
364
361
Or (trees.map(project(_)))
Original file line number Diff line number Diff line change
1
+ object Test {
2
+ sealed trait Base
3
+ class Blub extends Base
4
+ object Blub {
5
+ def unapply (blub : Blub ): Some [(Int , blub.type )] =
6
+ Some (1 -> blub)
7
+ }
8
+
9
+ (null : Base ) match {
10
+ case Blub (i, x) => println(i)
11
+ }
12
+ }
You can’t perform that action at this time.
0 commit comments