comparison libinterp/corefcn/pr-output.cc @ 19508:6c9ea5be96bf

Change charMatrix to subclass charNDArray rather than be another Array<char>. * chMatrix.h: both charMatrix and charNDArray are Array<char>, the first being simply 2 dimensional. We change this so that charMatrix inherits from charNDArray instead. * chMatrix.cc: remove all constructors which are now inherited from charNDArray. * chNDArray.h, chNDArray.cc: implement all constructors here rather than calling charMatrix. Remove matrix_value() since a charMatrix constructor is now enough. * pr-output.cc, octave-value/ov-ch-mat.h, octave-value/ov-str-mat.cc: replace calls to charNDArray::matrix_value () with the charMatrix constructor.
author Carnë Draug <carandraug@octave.org>
date Fri, 24 Oct 2014 01:31:53 +0100
parents 25f535b90e52
children d0c73e23a505
comparison
equal deleted inserted replaced
19507:25f535b90e52 19508:6c9ea5be96bf
2840 { 2840 {
2841 switch (nda.ndims ()) 2841 switch (nda.ndims ())
2842 { 2842 {
2843 case 1: 2843 case 1:
2844 case 2: 2844 case 2:
2845 octave_print_internal (os, nda.matrix_value (), 2845 octave_print_internal (os, charMatrix (nda),
2846 pr_as_read_syntax, extra_indent, pr_as_string); 2846 pr_as_read_syntax, extra_indent, pr_as_string);
2847 break; 2847 break;
2848 2848
2849 default: 2849 default:
2850 print_nd_array <charNDArray, char, charMatrix> (os, nda, 2850 print_nd_array <charNDArray, char, charMatrix> (os, nda,