equals and hashcode should be overridden together