--
You received this message because you are subscribed to the Google Groups "scala-language" group.
To unsubscribe from this group and stop receiving emails from it, send an email to scala-languag...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Below 2 very similar classes, F1 and F2
You expect F1 to behave the same as F2[Int], which it does.
The output of Test results in:
A:1
B
C
A:1
B
C
My question/remark is related to the warning of the 2.10 compiler: no warning in F1 but in F2 at "t match { ... }", I got "match may not be exhaustive. It would fail on the following input: C"
Am I missing a detail or is the warning wrong here?
The warning is wrong. I've pinpointed the spot where it regressed in the lead up to 2.10.2, and lodged a bug:Thank you for reporting!-jason
On 2.11, the warning goes away if you use:
case _: C.type => println("C")