-
Notifications
You must be signed in to change notification settings - Fork 21
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
Scala 2.13.6 Compiler Throws AssertionError #12467
Comments
That's a lot of code — have you attempted to minimize it? A proper minimization would 1) have less code in it, probably a lot less, and 2) if at all possible, not involve an external dependency. (Regardless, thanks for the report, it is already valuable.) |
Not having a clue what the error means, I didn't have any idea where to start minimizing. I will update if I find the time to trial and error into anything simpler. |
Minimized to: object PagedResponse {
type Aux[Item0] = PagedResponse { type Item = Item0 }
}
trait PagedResponse {
type Item
sealed trait NextPage
case class NoMorePages() extends NextPage
}
object Test {
def foo[A](next: PagedResponse.Aux[A]#NextPage): Unit = next match {
case _: PagedResponse.Aux[A]#NoMorePages => ???
}
}
|
Thanks for the minimisation, Tom! scala/scala#9504. That's @retronym's code, that looks to improving how we validate that the prefixes align. But here the prefixes are not stable values, they're just refined types (behind the aux type alias) so there's no outer test to emit. I'll send a patch. |
reproduction steps
Produces error:
problem
This code compiled under numerous previous version of Scala, including Scala 2.13.5.
The text was updated successfully, but these errors were encountered: