coord/ops: negation operator

This commit is contained in:
Danny Robson 2015-03-07 03:18:13 +11:00
parent 869125e308
commit 3f07f6edf7

View File

@ -148,6 +148,15 @@ namespace util {
SCALAR_OP(/=)
#undef SCALAR_OP
//-------------------------------------------------------------------------
// negation
template <size_t S, typename T, template<size_t,typename> class K>
K<S,T> operator- (K<S,T> k)
{
k *= -1;
return ;
}
///////////////////////////////////////////////////////////////////////////
// logic operators