We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
val l1: List[Option[Int]] = List(Some(1))
l1.find(_ == 1) // Generates warning, as it should
case class UserId(value: Int)
case class User(id: Option[UserId], other: Int)
val l2: List[User] = List(User(Some(UserId(1)), 2))
l2.find(_.id == UserId(1)) // Does not generate warning, even though types don't match
The text was updated successfully, but these errors were encountered:
Imported From: https://issues.scala-lang.org/browse/SI-8939?orig=1 Reporter: Artur Soler
Sorry, something went wrong.
based on scala/scala#6486 it looks like this is wontfix
No branches or pull requests
val l1: List[Option[Int]] = List(Some(1))
l1.find(_ == 1) // Generates warning, as it should
case class UserId(value: Int)
case class User(id: Option[UserId], other: Int)
val l2: List[User] = List(User(Some(UserId(1)), 2))
l2.find(_.id == UserId(1)) // Does not generate warning, even though types don't match
The text was updated successfully, but these errors were encountered: