Closed
Description
Compiler version
v3.1.0 snapshot of latest master
Minimized code
Macro.scala
import scala.quoted.*
sealed class Foo()
inline def hh(): Unit = ${ interpMacro() }
private def interpMacro()(using Quotes): Expr[Unit] =
import quotes.reflect.*
'{
val res: Either[String, (Foo, Foo)] =
Right((new Foo, new Foo))
val (a, b) = res.toOption.get
}
Main.scala
@main def main: Unit = hh()
Output
[warn] 1 |@main def main: Unit = hh()
[warn] | ^^^^
[warn] | match may not be exhaustive.
[warn] |
[warn] | It would fail on pattern case: (_, _)
Expectation
No warning.