Warning for "a" == "b"
Occaisionally I, or one of my colleagues, has (by mistake) compared strings or objects using == instead of .equals(). It would be nice (I think) if -Xlint gave a warning about this.
If you really want to compare objects in this way (and there may be some cases where you do), you could always write:
System.identityHashCode("a") == System.identityHashCode("b")
But I think this is usually not what the programmer intended.