Mercurial > octave
changeset 23586:f6c5db0a02e7
maint: Deprecate is_numeric_type and replace with isnumeric.
* ov.h (is_numeric_type): Use OCTAVE_DEPRECATED macro around function.
* ov.h (isnumeric): New function.
* make_int.cc, besselj.cc, cellfun.cc, data.cc, dot.cc, file-io.cc,
graphics.cc, load-path.cc, lookup.cc, lu.cc, mex.cc, mgorth.cc, oct-hist.cc,
pr-output.cc, schur.cc, sparse.cc, sqrtm.cc, sub2ind.cc, typecast.cc, utils.cc,
chol.cc, qr.cc, ov-base-diag.h, ov-base-mat.h, ov-base-scalar.h,
ov-base-sparse.h, ov-base.cc, ov-base.h, ov-bool-mat.cc, ov-bool-mat.h,
ov-bool-sparse.h, ov-bool.h, ov-cell.h, ov-class.cc, ov-fcn-inline.cc,
ov-lazy-idx.h, ov-perm.h, ov-range.h, ov-str-mat.h, ov-usr-fcn.cc, bp-table.cc:
Replace instances of is_numeric_type with isnumeric.
line wrap: on
line diff
--- a/examples/code/make_int.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/examples/code/make_int.cc Tue Jun 13 10:20:55 2017 -0700 @@ -69,7 +69,7 @@ bool is_real_type (void) const { return true; } bool is_scalar_type (void) const { return true; } - bool is_numeric_type (void) const { return true; } + bool isnumeric (void) const { return true; } bool valid_as_scalar_index (void) const { return scalar == 1; }
--- a/libinterp/corefcn/besselj.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/corefcn/besselj.cc Tue Jun 13 10:20:55 2017 -0700 @@ -96,7 +96,7 @@ if (! opt_arg.is_scalar_type ()) rpt_error = true; - else if (opt_arg.is_numeric_type ()) + else if (opt_arg.isnumeric ()) { double opt_val = opt_arg.double_value (); if (opt_val != 0.0 && opt_val != 1.0)
--- a/libinterp/corefcn/cellfun.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/corefcn/cellfun.cc Tue Jun 13 10:20:55 2017 -0700 @@ -148,7 +148,7 @@ { BNDA result (f_args.dims ()); for (octave_idx_type count= 0; count < k; count++) - result(count) = f_args.elem (count).is_numeric_type (); + result(count) = f_args.elem (count).isnumeric (); retval(0) = result; } else if (name == "isreal") @@ -1786,7 +1786,7 @@ retval = do_num2cell (array.bool_array_value (), dimv); else if (array.is_char_matrix ()) retval = do_num2cell (array.char_array_value (), dimv); - else if (array.is_numeric_type ()) + else if (array.isnumeric ()) { if (array.isinteger ()) {
--- a/libinterp/corefcn/data.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/corefcn/data.cc Tue Jun 13 10:20:55 2017 -0700 @@ -220,10 +220,10 @@ octave_value retval; - if (! args(0).is_numeric_type ()) + if (! args(0).isnumeric ()) err_wrong_type_arg ("atan2", args(0)); - if (! args(1).is_numeric_type ()) + if (! args(1).isnumeric ()) err_wrong_type_arg ("atan2", args(1)); if (args(0).iscomplex () || args(1).iscomplex ()) @@ -329,9 +329,9 @@ octave_value arg0 = x; octave_value arg1 = y; - if (! arg0.is_numeric_type ()) + if (! arg0.isnumeric ()) err_wrong_type_arg ("hypot", arg0); - if (! arg1.is_numeric_type ()) + if (! arg1.isnumeric ()) err_wrong_type_arg ("hypot", arg1); if (arg0.iscomplex ()) @@ -602,10 +602,10 @@ octave_value retval; - if (! args(0).is_numeric_type ()) + if (! args(0).isnumeric ()) err_wrong_type_arg ("rem", args(0)); - if (! args(1).is_numeric_type ()) + if (! args(1).isnumeric ()) err_wrong_type_arg ("rem", args(1)); if (args(0).iscomplex () || args(1).iscomplex ()) @@ -781,10 +781,10 @@ octave_value retval; - if (! args(0).is_numeric_type ()) + if (! args(0).isnumeric ()) err_wrong_type_arg ("mod", args(0)); - if (! args(1).is_numeric_type ()) + if (! args(1).isnumeric ()) err_wrong_type_arg ("mod", args(1)); if (args(0).iscomplex () || args(1).iscomplex ()) @@ -3571,7 +3571,7 @@ if (args.length () != 1) print_usage (); - return ovl (args(0).is_numeric_type ()); + return ovl (args(0).isnumeric ()); } /* @@ -5109,7 +5109,7 @@ // numeric value, the number of points defaults to 1. octave_value arg_3 = args(2); - if (arg_3.is_numeric_type () && arg_3.isempty ()) + if (arg_3.isnumeric () && arg_3.isempty ()) npoints = 1; else if (! arg_3.is_scalar_type ()) error ("linspace: N must be a scalar"); @@ -6964,7 +6964,7 @@ if (nargin < 2 || nargin > 3) print_usage (); - if (! args(0).is_numeric_type ()) + if (! args(0).isnumeric ()) error ("__accumarray_sum__: first argument must be numeric"); octave_value retval; @@ -6994,7 +6994,7 @@ else retval = do_accumarray_sum (idx, vals.float_array_value (), n); } - else if (vals.is_numeric_type () || vals.islogical ()) + else if (vals.isnumeric () || vals.islogical ()) { if (vals.iscomplex ()) retval = do_accumarray_sum (idx, @@ -7053,7 +7053,7 @@ if (nargin < 3 || nargin > 4) print_usage (); - if (! args(0).is_numeric_type ()) + if (! args(0).isnumeric ()) error ("accumarray: first argument must be numeric"); octave_value retval; @@ -7187,7 +7187,7 @@ if (nargin < 2 || nargin > 4) print_usage (); - if (! args(0).is_numeric_type ()) + if (! args(0).isnumeric ()) error ("__accumdim_sum__: first argument must be numeric"); octave_value retval; @@ -7215,7 +7215,7 @@ retval = do_accumdim_sum (idx, vals.float_array_value (), dim, n); } - else if (vals.is_numeric_type () || vals.islogical ()) + else if (vals.isnumeric () || vals.islogical ()) { if (vals.iscomplex ()) retval = do_accumdim_sum (idx, vals.complex_array_value (), @@ -7331,7 +7331,7 @@ if (args.length () != 3) print_usage (); - if (! (args(0).islogical () || args(0).is_numeric_type ())) + if (! (args(0).islogical () || args(0).isnumeric ())) error ("merge: first argument must be logical or numeric"); octave_value retval; @@ -7567,7 +7567,7 @@ if (nargin < 1 || nargin > 3) print_usage (); - if (! (args(0).is_numeric_type () || args(0).islogical ())) + if (! (args(0).isnumeric () || args(0).islogical ())) error ("diff: X must be numeric or logical"); int dim = -1; @@ -7735,7 +7735,7 @@ if (args.length () != 1) print_usage (); - if (! args(0).is_numeric_type ()) + if (! args(0).isnumeric ()) error ("base64_encode: encoding is supported only for numeric arrays"); if (args(0).iscomplex () || args(0).issparse ())
--- a/libinterp/corefcn/dot.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/corefcn/dot.cc Tue Jun 13 10:20:55 2017 -0700 @@ -92,7 +92,7 @@ octave_value argx = args(0); octave_value argy = args(1); - if (! argx.is_numeric_type () || ! argy.is_numeric_type ()) + if (! argx.isnumeric () || ! argy.isnumeric ()) error ("dot: X and Y must be numeric"); dim_vector dimx = argx.dims (); @@ -254,7 +254,7 @@ octave_value argx = args(0); octave_value argy = args(1); - if (! argx.is_numeric_type () || ! argy.is_numeric_type ()) + if (! argx.isnumeric () || ! argy.isnumeric ()) error ("blkmm: A and B must be numeric"); const dim_vector dimx = argx.dims ();
--- a/libinterp/corefcn/file-io.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/corefcn/file-io.cc Tue Jun 13 10:20:55 2017 -0700 @@ -1217,7 +1217,7 @@ if (args.length () > 2) { - if (args(2).is_numeric_type ()) + if (args(2).isnumeric ()) { ntimes = args(2).idx_type_value ();
--- a/libinterp/corefcn/graphics.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/corefcn/graphics.cc Tue Jun 13 10:20:55 2017 -0700 @@ -1338,7 +1338,7 @@ } } } - else if (val.is_numeric_type ()) + else if (val.isnumeric ()) { Matrix m = val.matrix_value (); @@ -1422,7 +1422,7 @@ xok = false; } else - xok = v.is_numeric_type () || v.is_bool_scalar (); + xok = v.isnumeric () || v.is_bool_scalar (); if (xok) { @@ -2873,7 +2873,7 @@ if (val.is_real_scalar () && is_handle (val.double_value ())) retval = true; - else if (val.is_numeric_type () && val.isreal ()) + else if (val.isnumeric () && val.isreal ()) { const NDArray handles = val.array_value (); @@ -6614,7 +6614,7 @@ else { string_vector sv; - if (val.is_numeric_type ()) + if (val.isnumeric ()) { NDArray data = val.array_value (); std::ostringstream oss; @@ -10169,7 +10169,7 @@ if (val.is_real_scalar () && is_handle_visible (val.double_value ())) retval = true; - else if (val.is_numeric_type () && val.isreal ()) + else if (val.isnumeric () && val.isreal ()) { const NDArray handles = val.array_value ();
--- a/libinterp/corefcn/load-path.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/corefcn/load-path.cc Tue Jun 13 10:20:55 2017 -0700 @@ -2380,7 +2380,7 @@ else if (option == "-begin") nargin--; } - else if (option_arg.is_numeric_type ()) + else if (option_arg.isnumeric ()) { int val = option_arg.xint_value ("addpath: OPTION must be '-begin'/0 or '-end'/1");
--- a/libinterp/corefcn/lookup.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/corefcn/lookup.cc Tue Jun 13 10:20:55 2017 -0700 @@ -250,7 +250,7 @@ octave_value retval; - bool num_case = ((table.is_numeric_type () && y.is_numeric_type ()) + bool num_case = ((table.isnumeric () && y.isnumeric ()) || (table.is_char_matrix () && y.is_char_matrix ())); bool str_case = table.iscellstr () && (y.is_string () || y.iscellstr ()); bool left_inf = false;
--- a/libinterp/corefcn/lu.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/corefcn/lu.cc Tue Jun 13 10:20:55 2017 -0700 @@ -618,8 +618,8 @@ octave_value argx = args(2 + pivoted); octave_value argy = args(3 + pivoted); - if (! (argl.is_numeric_type () && argu.is_numeric_type () - && argx.is_numeric_type () && argy.is_numeric_type () + if (! (argl.isnumeric () && argu.isnumeric () + && argx.isnumeric () && argy.isnumeric () && (! pivoted || argp.is_perm_matrix ()))) error ("luupdate: L, U, X, and Y must be numeric");
--- a/libinterp/corefcn/mex.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/corefcn/mex.cc Tue Jun 13 10:20:55 2017 -0700 @@ -234,7 +234,7 @@ int is_logical (void) const { return val.islogical (); } - int is_numeric (void) const { return val.is_numeric_type (); } + int is_numeric (void) const { return val.isnumeric (); } int is_single (void) const { return val.is_single_type (); }
--- a/libinterp/corefcn/mgorth.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/corefcn/mgorth.cc Tue Jun 13 10:20:55 2017 -0700 @@ -78,7 +78,7 @@ error ("mgorth: V should be a matrix, and X a column vector with" " the same number of rows as V."); - if (! arg_x.is_numeric_type () && ! arg_v.is_numeric_type ()) + if (! arg_x.isnumeric () && ! arg_v.isnumeric ()) error ("mgorth: X and V must be numeric"); octave_value_list retval;
--- a/libinterp/corefcn/oct-hist.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/corefcn/oct-hist.cc Tue Jun 13 10:20:55 2017 -0700 @@ -151,7 +151,7 @@ if (arg.is_string ()) option = arg.string_value (); - else if (arg.is_numeric_type ()) + else if (arg.isnumeric ()) { limit = arg.int_value (); if (limit < 0) @@ -334,7 +334,7 @@ ok = sscanf (tmp.c_str (), "%d", &val) == 1; } - else if (arg.is_numeric_type ()) + else if (arg.isnumeric ()) val = arg.int_value (); else ok = false;
--- a/libinterp/corefcn/pr-output.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/corefcn/pr-output.cc Tue Jun 13 10:20:55 2017 -0700 @@ -3414,7 +3414,7 @@ octave_value arg = args(0); - if (! arg.is_numeric_type ()) + if (! arg.isnumeric ()) error ("rats: X must be numeric"); octave::unwind_protect frame;
--- a/libinterp/corefcn/schur.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/corefcn/schur.cc Tue Jun 13 10:20:55 2017 -0700 @@ -166,7 +166,7 @@ if (nr != nc) err_square_matrix_required ("schur", "A"); - if (! arg.is_numeric_type ()) + if (! arg.isnumeric ()) err_wrong_type_arg ("schur", arg); octave_value_list retval; @@ -289,9 +289,9 @@ if (args.length () != 2 || nargout > 2) print_usage (); - if (! args(0).is_numeric_type ()) + if (! args(0).isnumeric ()) err_wrong_type_arg ("rsf2csf", args(0)); - if (! args(1).is_numeric_type ()) + if (! args(1).isnumeric ()) err_wrong_type_arg ("rsf2csf", args(1)); if (args(0).iscomplex () || args(1).iscomplex ()) error ("rsf2csf: UR and TR must be real matrices");
--- a/libinterp/corefcn/sparse.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/corefcn/sparse.cc Tue Jun 13 10:20:55 2017 -0700 @@ -141,7 +141,7 @@ retval = arg.sparse_bool_matrix_value (); else if (arg.iscomplex ()) retval = arg.sparse_complex_matrix_value (); - else if (arg.is_numeric_type ()) + else if (arg.isnumeric ()) retval = arg.sparse_matrix_value (); else err_wrong_type_arg ("sparse", arg); @@ -203,7 +203,7 @@ else if (args(2).iscomplex ()) retval = SparseComplexMatrix (args(2).complex_array_value(), i, j, m, n, summation, nzmax); - else if (args(2).is_numeric_type ()) + else if (args(2).isnumeric ()) retval = SparseMatrix (args(2).array_value (), i, j, m, n, summation, nzmax); else
--- a/libinterp/corefcn/sqrtm.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/corefcn/sqrtm.cc Tue Jun 13 10:20:55 2017 -0700 @@ -235,7 +235,7 @@ else if (arg.is_single_type ()) retval(0) = do_sqrtm<FloatMatrix, FloatComplexMatrix, octave::math::schur<FloatComplexMatrix>> (arg); - else if (arg.is_numeric_type ()) + else if (arg.isnumeric ()) retval(0) = do_sqrtm<Matrix, ComplexMatrix, octave::math::schur<ComplexMatrix>> (arg);
--- a/libinterp/corefcn/sub2ind.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/corefcn/sub2ind.cc Tue Jun 13 10:20:55 2017 -0700 @@ -116,7 +116,7 @@ for (int j = 0; j < nargin - 1; j++) { - if (! args(j+1).is_numeric_type ()) + if (! args(j+1).isnumeric ()) error ("sub2ind: subscripts must be numeric"); try
--- a/libinterp/corefcn/typecast.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/corefcn/typecast.cc Tue Jun 13 10:20:55 2017 -0700 @@ -488,7 +488,7 @@ if (args.length () != 1) print_usage (); - if (! (args(0).is_numeric_type () || args(0).is_string ())) + if (! (args(0).isnumeric () || args(0).is_string ())) error ("bitunpack: argument must be a number or a string"); octave_value retval;
--- a/libinterp/corefcn/utils.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/corefcn/utils.cc Tue Jun 13 10:20:55 2017 -0700 @@ -1225,7 +1225,7 @@ octave_value idxi = idx_arg(i); if (idxi.is_magic_colon ()) retval *= dv(i); - else if (idxi.is_numeric_type ()) + else if (idxi.isnumeric ()) retval *= idxi.numel (); else {
--- a/libinterp/dldfcn/chol.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/dldfcn/chol.cc Tue Jun 13 10:20:55 2017 -0700 @@ -629,7 +629,7 @@ octave_value argr = args(0); octave_value argu = args(1); - if (! argr.is_numeric_type () || ! argu.is_numeric_type () + if (! argr.isnumeric () || ! argu.isnumeric () || (nargin > 2 && ! args(2).is_string ())) print_usage (); @@ -823,7 +823,7 @@ octave_value argj = args(1); octave_value argu = args(2); - if (! argr.is_numeric_type () || ! argu.is_numeric_type () + if (! argr.isnumeric () || ! argu.isnumeric () || ! argj.is_real_scalar ()) print_usage (); @@ -1061,7 +1061,7 @@ octave_value argr = args(0); octave_value argj = args(1); - if (! argr.is_numeric_type () || ! argj.is_real_scalar ()) + if (! argr.isnumeric () || ! argj.is_real_scalar ()) print_usage (); octave_idx_type n = argr.rows (); @@ -1188,7 +1188,7 @@ octave_value argi = args(1); octave_value argj = args(2); - if (! argr.is_numeric_type () || ! argi.is_real_scalar () + if (! argr.isnumeric () || ! argi.is_real_scalar () || ! argj.is_real_scalar ()) print_usage ();
--- a/libinterp/dldfcn/qr.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/dldfcn/qr.cc Tue Jun 13 10:20:55 2017 -0700 @@ -908,8 +908,8 @@ octave_value argu = args(2); octave_value argv = args(3); - if (! argq.is_numeric_type () || ! argr.is_numeric_type () - || ! argu.is_numeric_type () || ! argv.is_numeric_type ()) + if (! argq.isnumeric () || ! argr.isnumeric () + || ! argu.isnumeric () || ! argv.isnumeric ()) print_usage (); if (! check_qr_dims (argq, argr, true)) @@ -1078,8 +1078,8 @@ octave_value argj = args(2); octave_value argx = args(3); - if (! argq.is_numeric_type () || ! argr.is_numeric_type () - || ! argx.is_numeric_type () + if (! argq.isnumeric () || ! argr.isnumeric () + || ! argx.isnumeric () || (nargin > 4 && ! args(4).is_string ())) print_usage (); @@ -1273,7 +1273,7 @@ octave_value argr = args(1); octave_value argj = args(2); - if (! argq.is_numeric_type () || ! argr.is_numeric_type () + if (! argq.isnumeric () || ! argr.isnumeric () || (nargin > 3 && ! args(3).is_string ())) print_usage (); @@ -1505,7 +1505,7 @@ octave_value argi = args(2); octave_value argj = args(3); - if (! argq.is_numeric_type () || ! argr.is_numeric_type ()) + if (! argq.isnumeric () || ! argr.isnumeric ()) print_usage (); if (! check_qr_dims (argq, argr, true))
--- a/libinterp/octave-value/ov-base-diag.h Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/octave-value/ov-base-diag.h Tue Jun 13 10:20:55 2017 -0700 @@ -123,7 +123,7 @@ bool is_matrix_type (void) const { return true; } - bool is_numeric_type (void) const { return true; } + bool isnumeric (void) const { return true; } bool is_defined (void) const { return true; }
--- a/libinterp/octave-value/ov-base-mat.h Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/octave-value/ov-base-mat.h Tue Jun 13 10:20:55 2017 -0700 @@ -147,7 +147,7 @@ bool is_matrix_type (void) const { return true; } - bool is_numeric_type (void) const { return true; } + bool isnumeric (void) const { return true; } bool is_defined (void) const { return true; }
--- a/libinterp/octave-value/ov-base-scalar.h Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/octave-value/ov-base-scalar.h Tue Jun 13 10:20:55 2017 -0700 @@ -126,7 +126,7 @@ bool is_scalar_type (void) const { return true; } - bool is_numeric_type (void) const { return true; } + bool isnumeric (void) const { return true; } bool is_true (void) const;
--- a/libinterp/octave-value/ov-base-sparse.h Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/octave-value/ov-base-sparse.h Tue Jun 13 10:20:55 2017 -0700 @@ -140,7 +140,7 @@ bool is_matrix_type (void) const { return true; } - bool is_numeric_type (void) const { return true; } + bool isnumeric (void) const { return true; } bool issparse (void) const { return true; }
--- a/libinterp/octave-value/ov-base.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/octave-value/ov-base.cc Tue Jun 13 10:20:55 2017 -0700 @@ -262,7 +262,7 @@ if (is_defined ()) { - if (! is_numeric_type ()) + if (! isnumeric ()) { std::string nm = type_name (); error ("can't perform indexed assignment for %s type", nm.c_str ()); @@ -395,7 +395,7 @@ { octave_value retval = convert_to_str_internal (pad, force, type); - if (! force && is_numeric_type ()) + if (! force && isnumeric ()) warn_implicit_conversion ("Octave:num-to-str", type_name (), retval.type_name ());
--- a/libinterp/octave-value/ov-base.h Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/octave-value/ov-base.h Tue Jun 13 10:20:55 2017 -0700 @@ -423,7 +423,7 @@ virtual bool is_matrix_type (void) const { return false; } - virtual bool is_numeric_type (void) const { return false; } + virtual bool isnumeric (void) const { return false; } virtual bool issparse (void) const { return false; }
--- a/libinterp/octave-value/ov-bool-mat.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/octave-value/ov-bool-mat.cc Tue Jun 13 10:20:55 2017 -0700 @@ -602,7 +602,7 @@ if (arg.islogical ()) retval = arg; - else if (arg.is_numeric_type ()) + else if (arg.isnumeric ()) { if (arg.issparse ()) retval = arg.sparse_bool_matrix_value ();
--- a/libinterp/octave-value/ov-bool-mat.h Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/octave-value/ov-bool-mat.h Tue Jun 13 10:20:55 2017 -0700 @@ -100,7 +100,7 @@ bool isreal (void) const { return true; } - bool is_numeric_type (void) const { return false; } + bool isnumeric (void) const { return false; } int8NDArray int8_array_value (void) const { return int8NDArray (matrix); }
--- a/libinterp/octave-value/ov-bool-sparse.h Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/octave-value/ov-bool-sparse.h Tue Jun 13 10:20:55 2017 -0700 @@ -98,7 +98,7 @@ bool isreal (void) const { return true; } - bool is_numeric_type (void) const { return false; } + bool isnumeric (void) const { return false; } double double_value (bool = false) const;
--- a/libinterp/octave-value/ov-bool.h Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/octave-value/ov-bool.h Tue Jun 13 10:20:55 2017 -0700 @@ -83,7 +83,7 @@ bool isreal (void) const { return true; } - bool is_numeric_type (void) const { return false; } + bool isnumeric (void) const { return false; } bool is_true (void) const { return scalar; }
--- a/libinterp/octave-value/ov-cell.h Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/octave-value/ov-cell.h Tue Jun 13 10:20:55 2017 -0700 @@ -111,7 +111,7 @@ bool is_matrix_type (void) const { return false; } - bool is_numeric_type (void) const { return false; } + bool isnumeric (void) const { return false; } bool is_defined (void) const { return true; }
--- a/libinterp/octave-value/ov-class.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/octave-value/ov-class.cc Tue Jun 13 10:20:55 2017 -0700 @@ -1811,7 +1811,7 @@ if (obj_cls == cls || (cls == "float" && obj.isfloat ()) || (cls == "integer" && obj.isinteger ()) - || (cls == "numeric" && obj.is_numeric_type ()) + || (cls == "numeric" && obj.isnumeric ()) || obj.is_instance_of (cls)) matches(idx) = true; }
--- a/libinterp/octave-value/ov-fcn-inline.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/octave-value/ov-fcn-inline.cc Tue Jun 13 10:20:55 2017 -0700 @@ -792,7 +792,7 @@ fargs.append (std::string ("x")); } - else if (nargin == 2 && args(1).is_numeric_type ()) + else if (nargin == 2 && args(1).isnumeric ()) { if (! args(1).is_scalar_type ()) error ("inline: N must be an integer");
--- a/libinterp/octave-value/ov-lazy-idx.h Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/octave-value/ov-lazy-idx.h Tue Jun 13 10:20:55 2017 -0700 @@ -120,7 +120,7 @@ bool is_matrix_type (void) const { return true; } - bool is_numeric_type (void) const { return true; } + bool isnumeric (void) const { return true; } bool is_defined (void) const { return true; }
--- a/libinterp/octave-value/ov-perm.h Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/octave-value/ov-perm.h Tue Jun 13 10:20:55 2017 -0700 @@ -110,7 +110,7 @@ bool is_matrix_type (void) const { return true; } - bool is_numeric_type (void) const { return true; } + bool isnumeric (void) const { return true; } bool is_defined (void) const { return true; }
--- a/libinterp/octave-value/ov-range.h Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/octave-value/ov-range.h Tue Jun 13 10:20:55 2017 -0700 @@ -163,7 +163,7 @@ bool isfloat (void) const { return true; } - bool is_numeric_type (void) const { return true; } + bool isnumeric (void) const { return true; } bool is_true (void) const;
--- a/libinterp/octave-value/ov-str-mat.h Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/octave-value/ov-str-mat.h Tue Jun 13 10:20:55 2017 -0700 @@ -111,7 +111,7 @@ bool is_string (void) const { return true; } - bool is_numeric_type (void) const { return false; } + bool isnumeric (void) const { return false; } double double_value (bool = false) const;
--- a/libinterp/octave-value/ov-usr-fcn.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/octave-value/ov-usr-fcn.cc Tue Jun 13 10:20:55 2017 -0700 @@ -997,7 +997,7 @@ return ovl (isargout1 (nargout1, ignored, k)); } - else if (args(0).is_numeric_type ()) + else if (args(0).isnumeric ()) { const NDArray ka = args(0).array_value ();
--- a/libinterp/octave-value/ov.h Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/octave-value/ov.h Tue Jun 13 10:20:55 2017 -0700 @@ -666,6 +666,13 @@ bool is_uint64_type (void) const { return rep->is_uint64_type (); } + bool isinteger (void) const + { return rep->isinteger (); } + + OCTAVE_DEPRECATED ("use 'isinteger' instead") + bool is_integer_type (void) const + { return rep->isinteger (); } + // Other type stuff. bool islogical (void) const @@ -675,13 +682,6 @@ bool is_bool_type (void) const { return rep->islogical (); } - bool isinteger (void) const - { return rep->isinteger (); } - - OCTAVE_DEPRECATED ("use 'isinteger' instead") - bool is_integer_type (void) const - { return rep->isinteger (); } - bool isreal (void) const { return rep->isreal (); } @@ -702,8 +702,12 @@ bool is_matrix_type (void) const { return rep->is_matrix_type (); } + bool isnumeric (void) const + { return rep->isnumeric (); } + + OCTAVE_DEPRECATED ("use 'isnumeric' instead") bool is_numeric_type (void) const - { return rep->is_numeric_type (); } + { return rep->isnumeric (); } bool issparse (void) const { return rep->issparse (); }
--- a/libinterp/parse-tree/bp-table.cc Tue Jun 13 09:52:59 2017 -0700 +++ b/libinterp/parse-tree/bp-table.cc Tue Jun 13 10:20:55 2017 -0700 @@ -517,7 +517,7 @@ else break; // may be "if" } - else if (args(pos).is_numeric_type ()) + else if (args(pos).isnumeric ()) { const NDArray arg = args(pos).array_value ();