Skip to content

Commit

Permalink
fix: Improve GetHashCode method
Browse files Browse the repository at this point in the history
  • Loading branch information
davidkallesen committed Oct 7, 2024
1 parent 1744c13 commit 92c77e3
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Atc/Structs/CartesianCoordinate.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,9 @@ public readonly bool Equals(CartesianCoordinate other) =>
Latitude.AreClose(other.Latitude) &&
Longitude.AreClose(other.Longitude);

/// <inheritdoc />
public override readonly int GetHashCode()
=> base.GetHashCode();
=> HashCode.Combine(Latitude, Longitude);

/// <inheritdoc />
public override readonly string ToString()
Expand Down

0 comments on commit 92c77e3

Please sign in to comment.