public override int GetHashCode() { unchecked // Overflow is fine, just wrap { int hash = 17; // Suitable nullity checks etc, of course :) hash = hash * 23 + VariableA.GetHashCode(); hash = hash * 23 + VariableB.GetHashCode(); hash = hash * 23 + Sancts.GetHashCode(); return(hash); } }