Mercurial > hg > octave-nkf
diff src/ov.cc @ 7814:87865ed7405f
Second set of single precision test code and fix of resulting bugs
author | David Bateman <dbateman@free.fr> |
---|---|
date | Mon, 02 Jun 2008 16:57:45 +0200 |
parents | 5861b95e9879 |
children | f336dd8e96d0 |
line wrap: on
line diff
--- a/src/ov.cc +++ b/src/ov.cc @@ -658,7 +658,7 @@ } octave_value::octave_value (const FloatComplexDiagMatrix& d) - : rep (new octave_complex_matrix (d)) + : rep (new octave_float_complex_matrix (d)) { maybe_mutate (); } @@ -2214,12 +2214,8 @@ { octave_value retval; - // Rapid return for concatenation with an empty object. Dimension - // checking handled elsewhere. - if (v1.all_zero_dims ()) - return v2; - if (v2.all_zero_dims ()) - return v1; + // Can't rapid return for concatenation with an empty object here as + // something like cat(1,[],single([]) must return the correct type. int t1 = v1.type_id (); int t2 = v2.type_id ();