Skip to content
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

Match exhaustion warning on literal type #11603

dwijnand opened this issue Jul 2, 2019 · 0 comments


None yet
1 participant
Copy link

commented Jul 2, 2019

class C {
  def m(x: true) = x match {
    case true => println("the one true path")
14:53:27 $ scala exhaustive-literals.scala
exhaustive-literals.scala:2: warning: match may not be exhaustive.
It would fail on the following input: false
  def m(x: true) = x match {

Scala 2.13.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.