-
Notifications
You must be signed in to change notification settings - Fork 21
Extractor with default parameter causes compiler crash (assertion error) #4425
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-4425?orig=1 |
@hubertp said: object Foo {
object X { def unapply(x : Int)(y: Int) = Some((2,2)) }
42 match { case _ X _ => () }
} which is related and currently gives this error message: t4425_03.scala:3: error: error during expansion of this match (this is a scalac bug).
The underlying error was: value _1 is not a member of object Foo.X
42 match { case _ X _ => () }
^
one error found |
@lrytz said: sandbox/t4425.scala:3: error: error during expansion of this match (this is a scalac bug).
The underlying error was: value _1 is not a member of object Foo.X
42 match { case _ X _ => () }
^ |
@JamesIry said: |
@paulp said: |
@paulp said: |
File foo.scala:
Trying to compile this with
causes the compiler to crash with an assertion error:
This is the simplest such example I can find.
This certainly happens using the following:
It seems like the same problem also happens with Scala 2.8.1 final, with the following output:
The text was updated successfully, but these errors were encountered: