changeset 17874:28e9562d708b

Fix display of '{}' for empty cells in GUI Variable window. * libinterp/octave-value/ov-cell.cc(short_disp): Use parentheses around tertiary operator expression so that C++ stream operator '<<' doesn't grab result of test, rather than output of test.
author Rik <rik@octave.org>
date Thu, 07 Nov 2013 09:54:38 -0800
parents 58b39152b0f6
children 8fde5edabedd
files libinterp/octave-value/ov-cell.cc
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/libinterp/octave-value/ov-cell.cc	Thu Nov 07 09:39:49 2013 -0800
+++ b/libinterp/octave-value/ov-cell.cc	Thu Nov 07 09:54:38 2013 -0800
@@ -753,7 +753,7 @@
 void
 octave_cell::short_disp (std::ostream& os) const
 {
-  os << matrix.is_empty () ? "{}" : "...";
+  os << (matrix.is_empty () ? "{}" : "...");
 }
 
 #define CELL_ELT_TAG "<cell-element>"