File tree Expand file tree Collapse file tree 3 files changed +9
-1
lines changed
compiler/src/dotty/tools/dotc/transform/patmat Expand file tree Collapse file tree 3 files changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -380,7 +380,7 @@ class SpaceEngine(implicit ctx: Context) extends SpaceLogic {
380
380
* cause false unreachable warnings. See tests/patmat/t2425.scala
381
381
*
382
382
* We cannot use type erasure here, as it would lose the constraints
383
- * invovling GADTs. For example, in the following code, type
383
+ * involving GADTs. For example, in the following code, type
384
384
* erasure would loose the constraint that `x` and `y` must be
385
385
* the same type, resulting in false inexhaustive warnings:
386
386
*
Original file line number Diff line number Diff line change
1
+ 5: Pattern Match Exhaustivity: _: Array[String]
Original file line number Diff line number Diff line change
1
+ def foo (x : Array [String ]) = x match {
2
+ case _ : Array [_] =>
3
+ }
4
+
5
+ def bar (x : Array [String ]) = x match {
6
+ case _ : Array [_ <: Int ] =>
7
+ }
You can’t perform that action at this time.
0 commit comments