namespace EdgeInstaller; public sealed partial class Version : IEquatable { public override bool Equals(object? obj) { if (obj is null || !this.GetType().Equals(obj.GetType())) { return false; } return this.Equals(obj); // NOTE: For the purposes of a version number same values == same version } public override int GetHashCode() { return Major + Minor + Build + Patch + Subpatch; // NOTE: For the purposes of a version number same values == same version // That is why this "hash" code will collide given two "different" versions with the same values } }