Mercurial > hg > octave-terminal
changeset 9410:2ad67ccd09fd
fix typo in octave_sort::lookupb
author | Jaroslav Hajek <highegg@gmail.com> |
---|---|
date | Tue, 30 Jun 2009 08:38:45 +0200 |
parents | ed392e13c117 |
children | c9636d98e5cd |
files | liboctave/ChangeLog liboctave/oct-sort.cc |
diffstat | 2 files changed, 6 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/liboctave/ChangeLog +++ b/liboctave/ChangeLog @@ -1,3 +1,7 @@ +2009-06-30 Jaroslav Hajek <highegg@gmail.com> + + * oct-sort.cc (octave_sort<T>::lookupb<Comp>): Fix typo. + 2009-06-29 Jaroslav Hajek <highegg@gmail.com> * oct-sort.cc (octave_sort<T>::lookup_merge): Delete.
--- a/liboctave/oct-sort.cc +++ b/liboctave/oct-sort.cc @@ -1919,6 +1919,7 @@ lookupm (data, nel, values, nvalues, idx, std::ptr_fun (compare)); } +#include <iostream> template <class T> template <class Comp> void octave_sort<T>::lookupb (const T *data, octave_idx_type nel, @@ -1957,7 +1958,7 @@ for (octave_idx_type j = 0; j < nvalues; j++) { octave_idx_type i = lookup_binary (data, nel, values[j], comp); - match[j] = (j != 0 && ! comp (data[i-1], values[j])); + match[j] = (i != 0 && ! comp (data[i-1], values[j])); } } }