From bdc3f4a198c3f047389b159e67f7e6131e053ea6 Mon Sep 17 00:00:00 2001 From: LaG1924 <12997935+LaG1924@users.noreply.github.com> Date: Wed, 3 Jan 2018 21:47:11 +0500 Subject: Fixed compilation errors --- src/Vector.hpp | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'src/Vector.hpp') diff --git a/src/Vector.hpp b/src/Vector.hpp index 0046b4a..5795db2 100644 --- a/src/Vector.hpp +++ b/src/Vector.hpp @@ -93,9 +93,17 @@ struct Vector3 { } bool operator<(const Vector3 &rhs) const { - return std::tie(x, y, z) < std::tie(rhs.x, rhs.y, rhs.z); + if (x < rhs.x) + return true; + if (rhs.x < x) + return false; + if (y < rhs.y) + return true; + if (rhs.y < y) + return false; + return z < rhs.z; } - + friend std::ostream &operator<<(std::ostream &os, const Vector3 &vector3) { os << vector3.x << ", " << vector3.y << ", " << vector3.z; -- cgit v1.2.3