Mercurial > octave
changeset 23468:f267a982478f
Merge stable to default.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Thu, 04 May 2017 10:29:51 -0400 |
parents | 5da300c55e89 (current diff) 0ada77ed24dd (diff) |
children | 2699c5974844 |
files | libinterp/corefcn/utils.cc libinterp/octave-value/ov-cell.cc |
diffstat | 2 files changed, 8 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/libinterp/corefcn/utils.cc Wed May 03 15:22:21 2017 -0400 +++ b/libinterp/corefcn/utils.cc Thu May 04 10:29:51 2017 -0400 @@ -1150,7 +1150,7 @@ if (! a.dims ().is_vector ()) error ("%s (A): use %s (size (A)) instead", warn_for, warn_for); - const Array<int> v = a.int_vector_value (); + const Array<octave_idx_type> v = a.octave_idx_type_vector_value (); const octave_idx_type n = v.numel (); dim.resize (n); // even if n < 2, resize sets it back to 2
--- a/libinterp/octave-value/ov-cell.cc Wed May 03 15:22:21 2017 -0400 +++ b/libinterp/octave-value/ov-cell.cc Thu May 04 10:29:51 2017 -0400 @@ -1249,7 +1249,7 @@ for (int i = 0; i < nargin; i++) dims(i) = (args(i).is_empty () - ? 0 : args(i).xnint_value ("cell: dimension must be a scalar integer")); + ? 0 : args(i).xidx_type_value ("cell: dimension must be a scalar integer")); } break; } @@ -1261,6 +1261,12 @@ return ovl (Cell (dims)); } +/* +## This might work on some system someday, but for now, who has a system +## where a 16 yottabyte array can be allocated? See bug #50934. +%!error <out of memory> cell (1e24, 1); +*/ + DEFUN (iscellstr, args, , doc: /* -*- texinfo -*- @deftypefn {} {} iscellstr (@var{cell})