Diff (Proto past) { final ModuleRequiresRepr pastRequirement = (ModuleRequiresRepr)past; return new Diff(super.difference(past)) { @Override public boolean versionChanged() { return pastRequirement.myVersion != myVersion; } @Override public boolean no() { return super.no() && !versionChanged(); } @Override public boolean becameNonTransitive() { return pastRequirement.isTransitive() && !ModuleRequiresRepr.this.isTransitive(); } }; }