Type the @Override on a correct equals signature
Type the @Override on a correct equals signature
Answer
class Point { @Override public boolean equals(Object o) { return o instanceof Point; } }
If the signature were equals(Point), it would NOT override Object.equals and @Override would force a compile error — catching the silent-overload bug.