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
scala>objectX { defunapplySeq(x: Any):Option[String] = { Some(x.toString.toUpperCase) }}
defined objectX
scala>valX(z) ="hi"
<console>:11:error: too many patterns forobjectX offering Boolean: expected 0, found 1valX(z) ="hi"^
scala>valX() ="hi"
<console>:11:error: error during expansion of thismatch (this is a scalac bug).
The underlying error was: typemismatch;
found : Option[String]
required: BooleanvalX() ="hi"^