[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: issorted & sortrows
From: |
John W. Eaton |
Subject: |
Re: issorted & sortrows |
Date: |
Wed, 11 Feb 2009 13:29:35 -0500 |
On 11-Feb-2009, Jaroslav Hajek wrote:
| Here, this is not so easily possible. The type of
| octave_sort<T>::compare is bool (*) (T, T), not bool (*) (const T&,
| const T&), so you'd get a type mismatch. The first form is probably
| more suitable for simple built-in types, the latter for complex ones.
| Supporting both would be possible but somewhat complicated.
I don't see why it shouldn't use "const T&". Doing that shouldn't
cause trouble for built-in types, and has some advantage for aggregate
types like Complex or some other class or structure that we may use
later. I don't understand why it was ever defined to just use T.
jwe
- issorted & sortrows, Jaroslav Hajek, 2009/02/11
- issorted & sortrows, John W. Eaton, 2009/02/11
- Re: issorted & sortrows, Jaroslav Hajek, 2009/02/11
- Re: issorted & sortrows,
John W. Eaton <=
- Re: issorted & sortrows, Jaroslav Hajek, 2009/02/11
- Re: issorted & sortrows, David Bateman, 2009/02/11
- Re: issorted & sortrows, John W. Eaton, 2009/02/12
- Re: issorted & sortrows, Jaroslav Hajek, 2009/02/12
- Re: issorted & sortrows, John W. Eaton, 2009/02/12
- Re: issorted & sortrows, Jaroslav Hajek, 2009/02/12
- Re: issorted & sortrows, dbateman, 2009/02/12
- Re: issorted & sortrows, John W. Eaton, 2009/02/12
- Re: issorted & sortrows, Jaroslav Hajek, 2009/02/12
- Re: issorted & sortrows, John W. Eaton, 2009/02/11