- Notifications
You must be signed in to change notification settings - Fork 1.1k
Open
Labels
area:pattern-matchingarea:reportingError reporting including formatting, implicit suggestions, etcError reporting including formatting, implicit suggestions, etcitype:bug
Description
Compiler version
3.7.1
Minimized code
case class Test() object Test { def unapply(int: Test): Some[Seq[Int]] = Some(Seq(1, 2)) } @main def run = { Test() match { case Test(x*) => println(x) } }Output
Compiles, runs and prints List(1, 2), but has the following warning:
match may not be exhaustive. It would fail on pattern case: Test(_) Test() match { Expectation
The compiler should not emit any error because of the exhaustive check.
Metadata
Metadata
Assignees
Labels
area:pattern-matchingarea:reportingError reporting including formatting, implicit suggestions, etcError reporting including formatting, implicit suggestions, etcitype:bug