diff options
Diffstat (limited to 'src/Coord.hpp')
-rw-r--r-- | src/Coord.hpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/Coord.hpp b/src/Coord.hpp index f77bc40..2d6a85a 100644 --- a/src/Coord.hpp +++ b/src/Coord.hpp @@ -24,6 +24,18 @@ struct Coord { double y{0.0}; }; +inline bool +operator==(const Coord& lhs, const Coord& rhs) +{ + return lhs.x == rhs.x && lhs.y == rhs.y; +} + +inline bool +operator!=(const Coord& lhs, const Coord& rhs) +{ + return !(lhs == rhs); +} + } // namespace patchage #endif // PATCHAGE_COORD_HPP |