// - edit Vector.equality.tt to modify #nullable enable namespace Brutal.Numerics; public partial struct float2 { /// public readonly override int GetHashCode() { return HashCode.Combine(X, Y); } /// [MethodImpl(MethodImplOptions.AggressiveInlining)] public readonly bool Equals(float2 other) { return X.Equals(other.X) && Y.Equals(other.Y); } /// [MethodImpl(MethodImplOptions.AggressiveInlining)] public readonly override bool Equals([NotNullWhen(true)] object? obj) { return obj is float2 other && Equals(other); } /// IEEE lane-wise equality over every component: any NaN component makes this false (contrast , which is NaN-reflexive), and -0 equals +0. [MethodImpl(MethodImplOptions.AggressiveInlining)] public static bool operator ==(float2 a, float2 b) { return a.X == b.X && a.Y == b.Y; } /// [MethodImpl(MethodImplOptions.AggressiveInlining)] public static bool operator !=(float2 a, float2 b) { return !(a == b); } }