I want !instanceof
I'm about a year late for project coin. But I still want an obvious Java language feature:!instanceof
. To illustrate: public void equals(Object other) {
if (other !instanceof Foo) {
return false;
}
return ((Foo) other).bar.equals(bar);
}
With the instanceof operator,
null instanceof T
is false for all values of T. Symmetrically, I suppose null !instanceof T
should always be true.