From 343ce574688a14c6220103be54ff295f1c1874e3 Mon Sep 17 00:00:00 2001 From: Erik Hofman Date: Thu, 8 Dec 2016 01:02:44 +0100 Subject: [PATCH] Tupe conversion is evil, don't allow it --- simgear/math/simd.hxx | 5 +++-- simgear/math/simd4x4.hxx | 9 +++------ 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/simgear/math/simd.hxx b/simgear/math/simd.hxx index b5dc6e91..e0a20120 100644 --- a/simgear/math/simd.hxx +++ b/simgear/math/simd.hxx @@ -211,8 +211,9 @@ public: *this += r.v4(); return *this; } - inline simd4_t& operator+=(const simd4_t& v) { - for (int i=0; i + inline simd4_t& operator+=(const simd4_t& v) { + for (int i=0; i - inline simd4x4_t operator*(S s) { + inline simd4x4_t operator*(T s) { simd4x4_t r(*this); r *= s; return r; @@ -168,8 +167,7 @@ public: m *= *this; return m; } - template - inline simd4x4_t operator/(S s) { + inline simd4x4_t operator/(T s) { simd4x4_t r(*this); r *= (1/T(s)); return r; @@ -219,8 +217,7 @@ public: return *this; } - template - inline simd4x4_t& operator/=(S s) { + inline simd4x4_t& operator/=(T s) { return operator*=(1/T(s)); } };