Mercurial > hg > octave-lyh
diff liboctave/Array-C.cc @ 8752:06b9903a029b
fix & clean up complex & sparse sorting
author | Jaroslav Hajek <highegg@gmail.com> |
---|---|
date | Mon, 16 Feb 2009 10:15:43 +0100 |
parents | d5af326a3ede |
children | eb63fbe60fab |
line wrap: on
line diff
--- a/liboctave/Array-C.cc +++ b/liboctave/Array-C.cc @@ -41,22 +41,6 @@ return xisnan (x); } -template <> -bool -octave_sort<Complex>::ascending_compare (const Complex& a, const Complex& b) -{ - return ((std::abs (a) < std::abs (b)) - || ((std::abs (a) == std::abs (b)) && (arg (a) < arg (b)))); -} - -template <> -bool -octave_sort<Complex>::descending_compare (const Complex& a, const Complex& b) -{ - return ((std::abs (a) > std::abs (b)) - || ((std::abs (a) == std::abs (b)) && (arg (a) > arg (b)))); -} - static bool nan_ascending_compare (const Complex& x, const Complex& y) {