//-------------------------------------------------------------- #region Overrides //-------------------------------------------------------------- /// <summary> /// Returns the hash code for this instance. /// </summary> /// <returns> /// A 32-bit signed integer that is the hash code for this instance. /// </returns> public override int GetHashCode() { // ReSharper disable NonReadonlyFieldInGetHashCode unchecked { int hashCode = Position.GetHashCode(); hashCode = (hashCode * 397) ^ Orientation.GetHashCode(); return(hashCode); } // ReSharper restore NonReadonlyFieldInGetHashCode }
public void HashCode() { Matrix33D m = new Matrix33D(columnMajor, MatrixOrder.ColumnMajor); Assert.AreNotEqual(Matrix33D.Identity.GetHashCode(), m.GetHashCode()); }