-
Notifications
You must be signed in to change notification settings - Fork 21
Pattern matching introduces unbounded existential type, losing type information #9879
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Imported From: https://issues.scala-lang.org/browse/SI-9879?orig=1 |
@SethTisue said (edited on Aug 9, 2016 5:45:17 AM UTC): Your code compiles and runs just fine in Scala 2.9. So this seems to be a regression in the new pattern matcher. In the error message, the question mark in
But it seems the existential doesn't even have a bound; at least, I would expect compiling with And the missing bound causes the error; I conclude that because e.g. this compiles if and only if the bound is included:
There are a number of existing tickets involving various combinations of pattern matching, existential, and bounds. Some of these tickets (e.g. #1786, #6169) have complicated histories. So, leaving this for Adriaan and/or Jason to decide whether this a duplicate or not. |
@SethTisue said:
Perhaps it's a clue. |
@SethTisue said: |
I'm confused by the following compile-time error:
I'm not sure if it's a bug, but it seemed suspect to me.
EDIT - I first posted this question on StackOverflow - http://stackoverflow.com/questions/38775071/no-implicit-ordering-defined-on-pattern-matched-list.
The text was updated successfully, but these errors were encountered: