Commit afa8a133 authored by Janis Born's avatar Janis Born Committed by Jan Möbius
Browse files

take VectorT argument by reference for non-member vector scalar multiplication (fixes #12)

parent 769074a4
Pipeline #157 failed with stage
...@@ -295,7 +295,7 @@ VectorT<double,3>::operator%(const VectorT<double,3>& _rhs) const ...@@ -295,7 +295,7 @@ VectorT<double,3>::operator%(const VectorT<double,3>& _rhs) const
/// \relates OpenMesh::VectorT /// \relates OpenMesh::VectorT
/// scalar * vector /// scalar * vector
template<typename Scalar1, typename Scalar2,int N> template<typename Scalar1, typename Scalar2,int N>
inline VectorT<Scalar1,N> operator*(Scalar2 _s, const VectorT<Scalar1,N> _v) { inline VectorT<Scalar1,N> operator*(Scalar2 _s, const VectorT<Scalar1,N>& _v) {
return _v*_s; return _v*_s;
} }
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment