Tupe conversion is evil, don't allow it
This commit is contained in:
parent
3e52e37181
commit
343ce57468
@ -211,8 +211,9 @@ public:
|
||||
*this += r.v4();
|
||||
return *this;
|
||||
}
|
||||
inline simd4_t<T,N>& operator+=(const simd4_t<T,N>& v) {
|
||||
for (int i=0; i<N; i++) {
|
||||
template<int M>
|
||||
inline simd4_t<T,N>& operator+=(const simd4_t<T,M>& v) {
|
||||
for (int i=0; i<M; i++) {
|
||||
vec[i] += v[i];
|
||||
}
|
||||
return *this;
|
||||
|
@ -158,8 +158,7 @@ public:
|
||||
m -= *this; return m;
|
||||
}
|
||||
|
||||
template<typename S>
|
||||
inline simd4x4_t<T,N> operator*(S s) {
|
||||
inline simd4x4_t<T,N> operator*(T s) {
|
||||
simd4x4_t<T,N> r(*this);
|
||||
r *= s;
|
||||
return r;
|
||||
@ -168,8 +167,7 @@ public:
|
||||
m *= *this; return m;
|
||||
}
|
||||
|
||||
template<typename S>
|
||||
inline simd4x4_t<T,N> operator/(S s) {
|
||||
inline simd4x4_t<T,N> operator/(T s) {
|
||||
simd4x4_t<T,N> r(*this);
|
||||
r *= (1/T(s));
|
||||
return r;
|
||||
@ -219,8 +217,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
template<typename S>
|
||||
inline simd4x4_t<T,N>& operator/=(S s) {
|
||||
inline simd4x4_t<T,N>& operator/=(T s) {
|
||||
return operator*=(1/T(s));
|
||||
}
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user