blob: 52e167f3b8e00ee93c169197d1439358111ff555 (
plain) (
tree)
|
|
class Test {
val X: OnNext[Any] = null
def Y: OnNext[Any] = null
(null: Any) match {
case X() => () // allowed
case Y() => () // not allowed
case OnNext[Any]() => () // should *not* be allowed, but was.
}
}
class OnNext[+T] {
def unapply(x: Any) = false
}
|