From 8d715666dbeb809ea625cd85211179283ad5d0f6 Mon Sep 17 00:00:00 2001 From: Alexander Harkness Date: Mon, 4 Nov 2024 23:12:38 +0000 Subject: Remove simple template-id from constructors for Vector3 template. This was removed from the C++ standard in C++20; annoying warnings are produced by modern C++ compilers. https://www.open-std.org/jtc1/sc22/wg21/docs/cwg_defects.html#2237 --- src/Vector3.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/Vector3.h b/src/Vector3.h index b48f35786..5df14b3ac 100644 --- a/src/Vector3.h +++ b/src/Vector3.h @@ -31,14 +31,14 @@ public: // tolua_end // Conversion constructors where U is not the same as T leaving the copy-constructor implicitly generated template ::value) && ((!std::is_integral::value) || (std::is_integral::value)), bool> = true> - constexpr Vector3(const Vector3 & a_Rhs): + constexpr Vector3(const Vector3 & a_Rhs): x(static_cast(a_Rhs.x)), y(static_cast(a_Rhs.y)), z(static_cast(a_Rhs.z)) { } template ::value) && ((std::is_integral::value) && (!std::is_integral::value)), bool> = true> - constexpr Vector3(const Vector3 & a_Rhs): + constexpr Vector3(const Vector3 & a_Rhs): x(static_cast(std::floor(a_Rhs.x))), y(static_cast(std::floor(a_Rhs.y))), z(static_cast(std::floor(a_Rhs.z))) -- cgit v1.2.3