Mercurial > hg > octave-nkf
changeset 5086:55f5b61d74b7
[project @ 2004-11-19 21:50:50 by jwe]
author | jwe |
---|---|
date | Fri, 19 Nov 2004 21:50:50 +0000 |
parents | 6861a84b1d47 |
children | 7497a16d90f9 |
files | src/ChangeLog src/ov-str-mat.cc src/pr-output.cc |
diffstat | 3 files changed, 23 insertions(+), 11 deletions(-) [+] |
line wrap: on
line diff
--- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,12 @@ +2004-11-19 John W. Eaton <jwe@octave.org> + + * ov-str-mat.cc (octave_char_matrix_str::do_index_op): + Skip indexing operation if indices are invalid. + + * pr-output.cc (set_range_format, set_complex_matrix_format, + set_complex_format, set_real_matrix_format, set_real_format): + Also specify std::ios::fixed for bank format. + 2004-11-17 John W. Eaton <jwe@octave.org> * version.h (OCTAVE_VERSION): Now 2.1.62.
--- a/src/ov-str-mat.cc +++ b/src/ov-str-mat.cc @@ -96,8 +96,9 @@ idx_vector i = idx (0).index_vector (); idx_vector j = idx (1).index_vector (); - retval = octave_value (charNDArray (matrix.index (i, j, resize_ok)), - true); + if (! error_state) + retval = octave_value (charNDArray (matrix.index (i, j, resize_ok)), + true); } break; @@ -105,8 +106,9 @@ { idx_vector i = idx (0).index_vector (); - retval = octave_value (charNDArray (matrix.index (i, resize_ok)), - true); + if (! error_state) + retval = octave_value (charNDArray (matrix.index (i, resize_ok)), + true); } break; @@ -117,8 +119,9 @@ for (int i = 0; i < len; i++) idx_vec(i) = idx(i).index_vector (); - retval = octave_value (charNDArray (matrix.index (idx_vec, resize_ok)), - true); + if (! error_state) + retval = octave_value (charNDArray (matrix.index (idx_vec, resize_ok)), + true); } break; }
--- a/src/pr-output.cc +++ b/src/pr-output.cc @@ -350,7 +350,7 @@ if (print_big_e) fmt.uppercase (); } - else if (inf_or_nan || int_only) + else if (! bank_format && (inf_or_nan || int_only)) fmt = float_format (fw, rd); else fmt = float_format (fw, rd, std::ios::fixed); @@ -497,7 +497,7 @@ if (print_big_e) fmt.uppercase (); } - else if (int_or_inf_or_nan) + else if (! bank_format && int_or_inf_or_nan) fmt = float_format (fw, rd); else fmt = float_format (fw, rd, std::ios::fixed); @@ -654,7 +654,7 @@ i_fmt.uppercase (); } } - else if (inf_or_nan || int_only) + else if (! bank_format && (inf_or_nan || int_only)) { r_fmt = float_format (r_fw, rd); i_fmt = float_format (i_fw, rd); @@ -841,7 +841,7 @@ i_fmt.uppercase (); } } - else if (int_or_inf_or_nan) + else if (! bank_format && int_or_inf_or_nan) { r_fmt = float_format (r_fw, rd); i_fmt = float_format (i_fw, rd); @@ -1005,7 +1005,7 @@ if (print_big_e) fmt.uppercase (); } - else if (all_ints) + else if (! bank_format && all_ints) fmt = float_format (fw, rd); else fmt = float_format (fw, rd, std::ios::fixed);