Skip to content

case objects desugaring needs to implement Product0 #915

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

Closed
DarkDimius opened this issue Nov 2, 2015 · 2 comments
Closed

case objects desugaring needs to implement Product0 #915

DarkDimius opened this issue Nov 2, 2015 · 2 comments

Comments

@DarkDimius
Copy link
Contributor

./scala-scala/src/library/scala/collection/immutable/List.scala:417: error: object creation impossible, since:
it has 2 unimplemented members.
/** As seen from module class Nil$, the missing signatures are as follows.
 *  For convenience, these are usable as stub implementations.
 */
  def productArity: => Int = ???
  def productElement: (n: Int)Any = ???

case object Nil extends List[Nothing] {
                  ^
DarkDimius added a commit to dotty-staging/dotty that referenced this issue Nov 2, 2015
DarkDimius added a commit to dotty-staging/dotty that referenced this issue Nov 2, 2015
@smarter
Copy link
Member

smarter commented Nov 2, 2015

Duplicate of #723.

@odersky
Copy link
Contributor

odersky commented Nov 5, 2015

Fixed by now.

@odersky odersky closed this as completed Nov 5, 2015
odersky added a commit to dotty-staging/dotty that referenced this issue Nov 5, 2015
As discussed in scala#780 and scala#525, the test is not needed. This makes
t1279a compile, which got moved now to pos. Fixes scala#780 and scala#915.
It also makes scala.List compile. Review by @smarter.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants