Proper equals and hashcode in Goal