coord: express negate with scalar value multiply
we don't have universal scalar reference operations implemented, this avoids a temporary and removes compile errors
This commit is contained in:
parent
a67edcde1a
commit
e1b03e0735
@ -155,8 +155,7 @@ namespace util {
|
|||||||
template <size_t S, typename T, template<size_t,typename> class K>
|
template <size_t S, typename T, template<size_t,typename> class K>
|
||||||
K<S,T> operator- (K<S,T> k)
|
K<S,T> operator- (K<S,T> k)
|
||||||
{
|
{
|
||||||
k *= -1;
|
return k * T{-1};
|
||||||
return ;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user