On floating point numbers == behaves in a way that violates the contract of Equals. So the behavior differs between == and Equals for such types.
One property Equals needs to have is that for every a : a.Equals(a).
NaN==NaN => false but NaN.Equals(NaN) => true
you need to mirror that property in your structs.
On floating point numbers
==behaves in a way that violates the contract ofEquals. So the behavior differs between==andEqualsfor such types.One property
Equalsneeds to have is that for everya:a.Equals(a).NaN==NaN=>falsebutNaN.Equals(NaN)=> trueyou need to mirror that property in your structs.