You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
cat test/files/pos/patmat-existential.scala
objectG {
defunapply(m: Any):Option[_] =Some("")
}
objectH {
defunapplySeq(m: Any):Option[Seq[_]] =None
}
objectTest {
(0:Any) match {
caseG(v) => v
caseH(v) => v
case _ =>
}
}
The two patterns above result in:
qbin/scalac test/files/pos/patmat-existential.scala
test/files/pos/patmat-existential.scala:10: error: error during expansion of this match (this is a scalac bug).
The underlying error was: type mismatch;
found : _$2(in value <local Test>) where type _$2(in value <local Test>)
required: _$2(in method unapplySeq)
(0: Any) match {
^
one error found
pr/3275 /code/scala qbin/scalac test/files/pos/patmat-existential.scala
test/files/pos/patmat-existential.scala:10: error: error during expansion of this match (this is a scalac bug).
The underlying error was: type mismatch;
found : _$1(in value <local Test>) where type _$1(in value <local Test>)
required: _$1(in method unapply)
(0: Any) match {
^
The text was updated successfully, but these errors were encountered:
The two patterns above result in:
The text was updated successfully, but these errors were encountered: