Mercurial > hg > octave-nkf
changeset 20638:7ac907da9fba
Use error() rather than ::error() unless explicitly required.
* resource-manager.cc (instance_ok), shortcut-manager.cc (instance_ok),
daspk.cc (DASPK_ABORT, DASPK_ABORT2), dasrt.cc (DASRT_ABORT, DASRT_ABORT2),
dassl.cc (DASSL_ABORT, DASSL_ABORT2), debug.cc (instance_ok),
display.cc (instance_ok), dynamic-ld.cc (octave_shlib_list::instance_ok,
octave_dynamic_loader::instance_ok, do_load_oct, do_load_mex), file-io.cc
(fopen_mode_to_ios_mode, do_stream_open, Ffprintf, Fsprintf, Fscanf, Ffscanf,
get_sscanf_data, Fsscanf, do_fread, do_fwrite, Fpopen, Ftempname, convert,
Fumask), graphics.in.h (graphics_toolkit::instance_ok,
gh_manager::instance_ok), load-path.cc (instance_ok),
ls-oct-ascii.cc (save_three_d), lsode.cc (LSODE_ABORT, LSODE_ABORT2),
oct-errno.in.cc (instance_ok), octave-link.cc (connect_link),
pager.cc (octave_pager_stream::instance_ok, octave_diary_stream::instance_ok),
quad.cc (QUAD_ABORT, QUAD_ABORT2),
sighandlers.cc (w32_interrupt_manager::instance_ok,
octave_child_list::instance_ok), symtab.cc (do_update_nest),
symtab.h (instance_ok), syscalls.cc (convert), toplev.h (instance_ok),
txt-eng-ft.cc (instance_ok, set_mode), urlwrite.cc (instance_ok),
__init_fltk__.cc (instance_ok), ov-builtin.cc (do_multi_index_op),
ov-classdef.cc (class_fevalStatic, make_class, octave_classdef::subsasgn,
do_multi_index_op, cdef_object_array::subsref, cdef_object_array::subsasgn,
install_meth, meta_subsref, run_constructor, make_meta_class, get_value,
set_value, check_method), ov-classdef.h (meta_subsref, instance_ok),
ov-fcn-handle.cc (octave_fcn_handle), ov-mex-fcn.cc (do_multi_index_op),
ov-range.h (octave_range), ov-typeinfo.cc (instance_ok),
ov-usr-fcn.cc (subsref, do_multi_index_op), pt-arg-list.cc (Fend,
convert_to_const_vector), pt-cell.cc (rvalue1), pt-colon.cc (append, rvalue1),
pt-eval.cc (visit_simple_for_command, visit_switch_command),
pt-exp.cc (is_logically_true, rvalue), pt-id.cc (eval_undefined_error),
pt-id.h (workspace_error), pt-mat.cc (get_concat_class):
Use error() rather than ::error().
line wrap: on
line diff
--- a/libgui/src/resource-manager.cc +++ b/libgui/src/resource-manager.cc @@ -144,7 +144,7 @@ if (! instance) { - ::error ("unable to create resource_manager object!"); + error ("unable to create resource_manager object!"); retval = false; }
--- a/libgui/src/shortcut-manager.cc +++ b/libgui/src/shortcut-manager.cc @@ -75,7 +75,7 @@ if (! instance) { - ::error ("unable to create shortcut_manager object!"); + error ("unable to create shortcut_manager object!"); retval = false; }
--- a/libinterp/corefcn/daspk.cc +++ b/libinterp/corefcn/daspk.cc @@ -157,7 +157,7 @@ #define DASPK_ABORT1(msg) \ do \ { \ - ::error ("daspk: " msg); \ + error ("daspk: " msg); \ DASPK_ABORT (); \ } \ while (0) @@ -165,7 +165,7 @@ #define DASPK_ABORT2(fmt, arg) \ do \ { \ - ::error ("daspk: " fmt, arg); \ + error ("daspk: " fmt, arg); \ DASPK_ABORT (); \ } \ while (0)
--- a/libinterp/corefcn/dasrt.cc +++ b/libinterp/corefcn/dasrt.cc @@ -193,7 +193,7 @@ #define DASRT_ABORT1(msg) \ do \ { \ - ::error ("dasrt: " msg); \ + error ("dasrt: " msg); \ DASRT_ABORT; \ } \ while (0) @@ -201,7 +201,7 @@ #define DASRT_ABORT2(fmt, arg) \ do \ { \ - ::error ("dasrt: " fmt, arg); \ + error ("dasrt: " fmt, arg); \ DASRT_ABORT; \ } \ while (0)
--- a/libinterp/corefcn/dassl.cc +++ b/libinterp/corefcn/dassl.cc @@ -157,7 +157,7 @@ #define DASSL_ABORT1(msg) \ do \ { \ - ::error ("dassl: " msg); \ + error ("dassl: " msg); \ DASSL_ABORT (); \ } \ while (0) @@ -165,7 +165,7 @@ #define DASSL_ABORT2(fmt, arg) \ do \ { \ - ::error ("dassl: " fmt, arg); \ + error ("dassl: " fmt, arg); \ DASSL_ABORT (); \ } \ while (0)
--- a/libinterp/corefcn/debug.cc +++ b/libinterp/corefcn/debug.cc @@ -292,7 +292,7 @@ if (! instance) { - ::error ("unable to create breakpoint table!"); + error ("unable to create breakpoint table!"); retval = false; }
--- a/libinterp/corefcn/display.cc +++ b/libinterp/corefcn/display.cc @@ -64,7 +64,7 @@ if (! instance) { - ::error ("unable to create display_info object!"); + error ("unable to create display_info object!"); retval = false; }
--- a/libinterp/corefcn/dynamic-ld.cc +++ b/libinterp/corefcn/dynamic-ld.cc @@ -160,7 +160,7 @@ if (! instance) { - ::error ("unable to create shared library list object!"); + error ("unable to create shared library list object!"); retval = false; } @@ -216,7 +216,7 @@ if (! instance) { - ::error ("unable to create dynamic loader object!"); + error ("unable to create dynamic loader object!"); retval = false; } @@ -295,13 +295,12 @@ retval = f (oct_file, relative); if (! retval) - ::error ("failed to install .oct file function '%s'", - fcn_name.c_str ()); + error ("failed to install .oct file function '%s'", + fcn_name.c_str ()); } } else - ::error ("%s is not a valid shared library", - file_name.c_str ()); + error ("%s is not a valid shared library", file_name.c_str ()); } return retval; @@ -363,12 +362,11 @@ retval = new octave_mex_function (function, have_fmex, mex_file, fcn_name); else - ::error ("failed to install .mex file function '%s'", - fcn_name.c_str ()); + error ("failed to install .mex file function '%s'", + fcn_name.c_str ()); } else - ::error ("%s is not a valid shared library", - file_name.c_str ()); + error ("%s is not a valid shared library", file_name.c_str ()); } return retval;
--- a/libinterp/corefcn/file-io.cc +++ b/libinterp/corefcn/file-io.cc @@ -230,7 +230,7 @@ retval = (std::ios::in | std::ios::out | std::ios::app | std::ios::binary); else - ::error ("invalid mode specified"); + error ("invalid mode specified"); } return retval; @@ -576,13 +576,13 @@ retval = do_stream_open (name, mode, arch, fid); } else - ::error ("%s: architecture type must be a string", fcn); + error ("%s: architecture type must be a string", fcn); } else - ::error ("%s: file mode must be a string", fcn); + error ("%s: file mode must be a string", fcn); } else - ::error ("%s: file name must be a string", fcn); + error ("%s: file name must be a string", fcn); return retval; } @@ -946,7 +946,7 @@ result = os.printf (args(fmt_n), tmp_args, who); } else - ::error ("%s: format TEMPLATE must be a string", who.c_str ()); + error ("%s: format TEMPLATE must be a string", who.c_str ()); } } else @@ -1001,7 +1001,7 @@ result = stdout_stream.printf (args(0), tmp_args, who); } else - ::error ("%s: format TEMPLATE must be a string", who.c_str ()); + error ("%s: format TEMPLATE must be a string", who.c_str ()); } else print_usage (); @@ -1129,10 +1129,10 @@ : octave_value (result, type)); } else - ::error ("%s: format TEMPLATE must be a string", who.c_str ()); + error ("%s: format TEMPLATE must be a string", who.c_str ()); } else - ::error ("%s: unable to create output buffer", who.c_str ()); + error ("%s: unable to create output buffer", who.c_str ()); } else print_usage (); @@ -1205,7 +1205,7 @@ if (args(1).is_string ()) retval = os.oscanf (args(1), who); else - ::error ("%s: format TEMPLATE must be a string", who.c_str ()); + error ("%s: format TEMPLATE must be a string", who.c_str ()); } } else @@ -1242,7 +1242,7 @@ } } else - ::error ("%s: format must be a string", who.c_str ()); + error ("%s: format must be a string", who.c_str ()); } } else @@ -1264,7 +1264,7 @@ retval = tmp.string_value (); } else - ::error ("sscanf: argument STRING must be a string"); + error ("sscanf: argument STRING must be a string"); return retval; } @@ -1301,14 +1301,13 @@ if (args(1).is_string ()) retval = os.oscanf (args(1), who); else - ::error ("%s: format TEMPLATE must be a string", who.c_str ()); + error ("%s: format TEMPLATE must be a string", who.c_str ()); } else - ::error ("%s: unable to create temporary input buffer", - who.c_str ()); + error ("%s: unable to create temporary input buffer", who.c_str ()); } else - ::error ("%s: argument STRING must be a string", who.c_str ()); + error ("%s: argument STRING must be a string", who.c_str ()); } else { @@ -1353,12 +1352,12 @@ } } else - ::error ("%s: format TEMPLATE must be a string", - who.c_str ()); + error ("%s: format TEMPLATE must be a string", + who.c_str ()); } else - ::error ("%s: unable to create temporary input buffer", - who.c_str ()); + error ("%s: unable to create temporary input buffer", + who.c_str ()); } } else @@ -1431,19 +1430,19 @@ output_type, skip, flt_fmt, count); } else - ::error ("fread: ARCH architecture type must be a string"); + error ("fread: ARCH architecture type must be a string"); } else - ::error ("fread: SKIP must be an integer"); + error ("fread: SKIP must be an integer"); } else - ::error ("fread: invalid PRECISION specified"); + error ("fread: invalid PRECISION specified"); } else - ::error ("fread: PRECISION must be a string"); + error ("fread: PRECISION must be a string"); } else - ::error ("fread: invalid SIZE specified"); + error ("fread: invalid SIZE specified"); return retval; } @@ -1699,16 +1698,16 @@ skip, flt_fmt); } else - ::error ("fwrite: ARCH architecture type must be a string"); + error ("fwrite: ARCH architecture type must be a string"); } else - ::error ("fwrite: SKIP must be an integer"); + error ("fwrite: SKIP must be an integer"); } else - ::error ("fwrite: invalid PRECISION specified"); + error ("fwrite: invalid PRECISION specified"); } else - ::error ("fwrite: PRECISION must be a string"); + error ("fwrite: PRECISION must be a string"); return retval; } @@ -1929,13 +1928,13 @@ retval = octave_stream_list::insert (ops); } else - ::error ("popen: invalid MODE specified"); + error ("popen: invalid MODE specified"); } else - ::error ("popen: MODE must be a string"); + error ("popen: MODE must be a string"); } else - ::error ("popen: COMMAND must be a string"); + error ("popen: COMMAND must be a string"); } else print_usage (); @@ -1996,7 +1995,7 @@ if (args(0).is_string ()) dir = args(0).string_value (); else - ::error ("DIR must be a string"); + error ("DIR must be a string"); } std::string pfx ("oct-"); @@ -2005,7 +2004,7 @@ if (args(1).is_string ()) pfx = args(1).string_value (); else - ::error ("PREFIX must be a string"); + error ("PREFIX must be a string"); } retval = octave_tempnam (dir, pfx); @@ -2214,7 +2213,7 @@ int tmp = x % obase; if (tmp > ibase - 1) - ::error ("umask: invalid digit"); + error ("umask: invalid digit"); else { retval = tmp; @@ -2224,7 +2223,7 @@ tmp = x % obase; if (tmp > ibase - 1) { - ::error ("umask: invalid digit"); + error ("umask: invalid digit"); break; } retval += mult * tmp; @@ -2266,7 +2265,7 @@ if (mask < 0) { status = -1; - ::error ("umask: MASK must be a positive integer value"); + error ("umask: MASK must be a positive integer value"); } else { @@ -2279,7 +2278,7 @@ else { status = -1; - ::error ("umask: MASK must be an integer"); + error ("umask: MASK must be an integer"); } } else
--- a/libinterp/corefcn/graphics.in.h +++ b/libinterp/corefcn/graphics.in.h @@ -2365,7 +2365,7 @@ if (! instance) { - ::error ("unable to create gh_manager!"); + error ("unable to create gh_manager!"); retval = false; } @@ -5960,7 +5960,7 @@ if (! instance) { - ::error ("unable to create gh_manager!"); + error ("unable to create gh_manager!"); retval = false; }
--- a/libinterp/corefcn/load-path.cc +++ b/libinterp/corefcn/load-path.cc @@ -333,7 +333,7 @@ if (! instance) { - ::error ("unable to create load path object!"); + error ("unable to create load path object!"); retval = false; }
--- a/libinterp/corefcn/ls-oct-ascii.cc +++ b/libinterp/corefcn/ls-oct-ascii.cc @@ -408,7 +408,7 @@ } else { - ::error ("for now, I can only save real matrices in 3-D format"); + error ("for now, I can only save real matrices in 3-D format"); fail = true; }
--- a/libinterp/corefcn/lsode.cc +++ b/libinterp/corefcn/lsode.cc @@ -143,7 +143,7 @@ #define LSODE_ABORT1(msg) \ do \ { \ - ::error ("lsode: " msg); \ + error ("lsode: " msg); \ LSODE_ABORT (); \ } \ while (0) @@ -151,7 +151,7 @@ #define LSODE_ABORT2(fmt, arg) \ do \ { \ - ::error ("lsode: " fmt, arg); \ + error ("lsode: " fmt, arg); \ LSODE_ABORT (); \ } \ while (0)
--- a/libinterp/corefcn/oct-errno.in.cc +++ b/libinterp/corefcn/oct-errno.in.cc @@ -303,7 +303,7 @@ if (! instance) { - ::error ("unable to create errno object!"); + error ("unable to create errno object!"); retval = false; }
--- a/libinterp/corefcn/octave-link.cc +++ b/libinterp/corefcn/octave-link.cc @@ -73,7 +73,7 @@ octave_link::connect_link (octave_link* obj) { if (obj && instance) - ::error ("octave_link is already linked!"); + error ("octave_link is already linked!"); else instance = obj; }
--- a/libinterp/corefcn/pager.cc +++ b/libinterp/corefcn/pager.cc @@ -381,7 +381,7 @@ if (! instance) { - ::error ("unable to create pager_stream object!"); + error ("unable to create pager_stream object!"); retval = false; } @@ -446,7 +446,7 @@ if (! instance) { - ::error ("unable to create diary_stream object!"); + error ("unable to create diary_stream object!"); retval = false; }
--- a/libinterp/corefcn/quad.cc +++ b/libinterp/corefcn/quad.cc @@ -159,7 +159,7 @@ #define QUAD_ABORT1(msg) \ do \ { \ - ::error ("quad: " msg); \ + error ("quad: " msg); \ QUAD_ABORT (); \ } \ while (0) @@ -167,7 +167,7 @@ #define QUAD_ABORT2(fmt, arg) \ do \ { \ - ::error ("quad: " fmt, arg); \ + error ("quad: " fmt, arg); \ QUAD_ABORT (); \ } \ while (0)
--- a/libinterp/corefcn/sighandlers.cc +++ b/libinterp/corefcn/sighandlers.cc @@ -199,7 +199,7 @@ if (! instance) { - ::error ("unable to create w32_interrupt_manager"); + error ("unable to create w32_interrupt_manager"); retval = false; } @@ -929,7 +929,7 @@ if (! instance) { - ::error ("unable to create child list object!"); + error ("unable to create child list object!"); retval = false; }
--- a/libinterp/corefcn/symtab.cc +++ b/libinterp/corefcn/symtab.cc @@ -1621,7 +1621,7 @@ && nest_parent->look_nonlocal (ti->first, parents)) { if (ours.is_global () || ours.is_persistent ()) - ::error ("global and persistent may only be used in the topmost level in which a nested variable is used"); + error ("global and persistent may only be used in the topmost level in which a nested variable is used"); if (! ours.is_formal ()) {
--- a/libinterp/corefcn/symtab.h +++ b/libinterp/corefcn/symtab.h @@ -94,7 +94,7 @@ if (! instance) { - ::error ("unable to create scope_id_cache object!"); + error ("unable to create scope_id_cache object!"); retval = false; }
--- a/libinterp/corefcn/syscalls.cc +++ b/libinterp/corefcn/syscalls.cc @@ -829,7 +829,7 @@ int tmp = x % obase; if (tmp > ibase - 1) - ::error ("mkfifo: invalid digit"); + error ("mkfifo: invalid digit"); else { retval = tmp; @@ -839,7 +839,7 @@ tmp = x % obase; if (tmp > ibase - 1) { - ::error ("mkfifo: invalid digit"); + error ("mkfifo: invalid digit"); break; } retval += mult * tmp;
--- a/libinterp/corefcn/toplev.h +++ b/libinterp/corefcn/toplev.h @@ -134,7 +134,7 @@ if (! instance) { - ::error ("unable to create call stack object!"); + error ("unable to create call stack object!"); retval = false; }
--- a/libinterp/corefcn/txt-eng-ft.cc +++ b/libinterp/corefcn/txt-eng-ft.cc @@ -90,7 +90,7 @@ if (! instance) { - ::error ("unable to create ft_manager!"); + error ("unable to create ft_manager!"); retval = false; } @@ -138,13 +138,13 @@ : library (), freetype_initialized (false), fontconfig_initialized (false) { if (FT_Init_FreeType (&library)) - ::error ("unable to initialize FreeType library"); + error ("unable to initialize FreeType library"); else freetype_initialized = true; #if defined (HAVE_FONTCONFIG) if (! FcInit ()) - ::error ("unable to initialize fontconfig library"); + error ("unable to initialize fontconfig library"); else fontconfig_initialized = true; #endif @@ -492,7 +492,7 @@ } break; default: - ::error ("ft_render: invalid mode '%d'", mode); + error ("ft_render: invalid mode '%d'", mode); break; } }
--- a/libinterp/corefcn/urlwrite.cc +++ b/libinterp/corefcn/urlwrite.cc @@ -81,7 +81,7 @@ if (! instance) { - ::error ("unable to create ch_manager!"); + error ("unable to create ch_manager!"); retval = false; }
--- a/libinterp/dldfcn/__init_fltk__.cc +++ b/libinterp/dldfcn/__init_fltk__.cc @@ -1777,7 +1777,7 @@ if (! instance) { - ::error ("unable to create figure_manager object!"); + error ("unable to create figure_manager object!"); retval = false; }
--- a/libinterp/octave-value/ov-builtin.cc +++ b/libinterp/octave-value/ov-builtin.cc @@ -109,7 +109,7 @@ return retval; if (args.has_magic_colon ()) - ::error ("invalid use of colon in function argument list"); + error ("invalid use of colon in function argument list"); else { unwind_protect frame;
--- a/libinterp/octave-value/ov-classdef.cc +++ b/libinterp/octave-value/ov-classdef.cc @@ -578,8 +578,7 @@ meth_name.c_str ()); } else - error ("fevalStatic: method not found: %s", - meth_name.c_str ()); + error ("fevalStatic: method not found: %s", meth_name.c_str ()); } else error ("fevalStatic: invalid method name, expected a string value"); @@ -740,8 +739,8 @@ } if (has_handle_class && ! all_handle_compatible) - ::error ("%s: cannot mix handle and non-HandleCompatible classes", - name.c_str ()); + error ("%s: cannot mix handle and non-HandleCompatible classes", + name.c_str ()); else { cls.put ("HandleCompatible", all_handle_compatible); @@ -993,7 +992,7 @@ if (retlist.length () > 0) retval = retlist(0); else - ::error ("overloaded method `subsasgn' did not return any value"); + error ("overloaded method `subsasgn' did not return any value"); } } } @@ -1256,12 +1255,12 @@ retval(0) = sym; } else - ::error ("cannot call superclass constructor with " - "variable `%s'", mname.c_str ()); + error ("cannot call superclass constructor with " + "variable `%s'", mname.c_str ()); } else - ::error ("`%s' is not a direct superclass of `%s'", - cname.c_str (), ctx.get_name ().c_str ()); + error ("`%s' is not a direct superclass of `%s'", + cname.c_str (), ctx.get_name ().c_str ()); } else { @@ -1286,21 +1285,21 @@ retval = meth.execute (idx, nargout, true, meth_name); else - ::error ("no method `%s' found in superclass `%s'", - meth_name.c_str (), cname.c_str ()); + error ("no method `%s' found in superclass `%s'", + meth_name.c_str (), cname.c_str ()); } else - ::error ("`%s' is not a superclass of `%s'", - cname.c_str (), ctx.get_name ().c_str ()); + error ("`%s' is not a superclass of `%s'", + cname.c_str (), ctx.get_name ().c_str ()); } else - ::error ("method name mismatch (`%s' != `%s')", - mname.c_str (), meth_name.c_str ()); + error ("method name mismatch (`%s' != `%s')", + mname.c_str (), meth_name.c_str ()); } } } else if (! error_state) - ::error ("superclass calls can only occur in methods or constructors"); + error ("superclass calls can only occur in methods or constructors"); return retval; } @@ -1714,8 +1713,8 @@ // fall through "default" default: - ::error ("can't perform indexing operation on array of %s objects", - class_name ().c_str ()); + error ("can't perform indexing operation on array of %s objects", + class_name ().c_str ()); break; } @@ -1784,9 +1783,9 @@ } } else - ::error ("can't assign %s object into array of %s objects.", - rhs_obj.class_name ().c_str (), - class_name ().c_str ()); + error ("can't assign %s object into array of %s objects.", + rhs_obj.class_name ().c_str (), + class_name ().c_str ()); } } else @@ -1884,8 +1883,8 @@ break; default: - ::error ("can't perform indexing operation on array of %s objects", - class_name ().c_str ()); + error ("can't perform indexing operation on array of %s objects", + class_name ().c_str ()); break; } @@ -2177,8 +2176,8 @@ } } else - ::error ("%s: invalid constructor output arguments", - meth.get_name ().c_str ()); + error ("%s: invalid constructor output arguments", + meth.get_name ().c_str ()); } } } @@ -2543,7 +2542,7 @@ "meta.class"); } else - ::error ("method `%s' is not static", nm.c_str ()); + error ("method `%s' is not static", nm.c_str ()); } else { @@ -2554,22 +2553,21 @@ if (prop.is_constant ()) retval(0) = prop.get_value (true, "meta.class"); else - ::error ("property `%s' is not constant", - nm.c_str ()); + error ("property `%s' is not constant", nm.c_str ()); } else - ::error ("no such method or property `%s'", nm.c_str ()); + error ("no such method or property `%s'", nm.c_str ()); } } else - ::error ("invalid meta.class indexing, expected a method or property name"); + error ("invalid meta.class indexing, expected a method or property name"); } else - ::error ("invalid meta.class indexing"); + error ("invalid meta.class indexing"); break; default: - ::error ("invalid meta.class indexing"); + error ("invalid meta.class indexing"); break; } @@ -2664,8 +2662,8 @@ obj = to_cdef (ctor_retval(0)); else { - ::error ("%s: invalid number of output arguments for classdef constructor", - ctor_name.c_str ()); + error ("%s: invalid number of output arguments for classdef constructor", + ctor_name.c_str ()); return; } } @@ -2839,8 +2837,8 @@ slist.push_back (sclass); else { - ::error ("`%s' cannot inherit from `%s', because it is sealed", - full_class_name.c_str (), sclass_name.c_str ()); + error ("`%s' cannot inherit from `%s', because it is sealed", + full_class_name.c_str (), sclass_name.c_str ()); return retval; } } @@ -3152,8 +3150,8 @@ if (! obj.is_partially_constructed_for (cls)) { - ::error ("cannot reference properties of class `%s' for non-constructed object", - cls.get_name ().c_str ()); + error ("cannot reference properties of class `%s' for non-constructed object", + cls.get_name ().c_str ()); return retval; } } @@ -3219,8 +3217,8 @@ if (! obj.is_partially_constructed_for (cls)) { - ::error ("cannot reference properties of class `%s' for non-constructed object", - cls.get_name ().c_str ()); + error ("cannot reference properties of class `%s' for non-constructed object", + cls.get_name ().c_str ()); return; } } @@ -3324,8 +3322,8 @@ } if (is_dummy_method (function)) - ::error ("no definition found for method `%s' of class `%s'", - get_name ().c_str (), dispatch_type.c_str ()); + error ("no definition found for method `%s' of class `%s'", + get_name ().c_str (), dispatch_type.c_str ()); } }
--- a/libinterp/octave-value/ov-classdef.h +++ b/libinterp/octave-value/ov-classdef.h @@ -546,7 +546,7 @@ const std::list<octave_value_list>& /* idx */, int /* nargout */) { - ::error ("subsref: invalid meta object"); + error ("subsref: invalid meta object"); return octave_value_list (); } @@ -1628,7 +1628,7 @@ if (! instance) { - ::error ("unable to create cdef_manager!"); + error ("unable to create cdef_manager!"); retval = false; }
--- a/libinterp/octave-value/ov-fcn-handle.cc +++ b/libinterp/octave-value/ov-fcn-handle.cc @@ -82,7 +82,7 @@ symbol_table::cache_name (uf->scope (), nm); if (uf && uf->is_nested_function ()) - ::error ("handles to nested functions are not yet supported"); + error ("handles to nested functions are not yet supported"); } octave_value_list
--- a/libinterp/octave-value/ov-mex-fcn.cc +++ b/libinterp/octave-value/ov-mex-fcn.cc @@ -136,7 +136,7 @@ return retval; if (args.has_magic_colon ()) - ::error ("invalid use of colon in function argument list"); + error ("invalid use of colon in function argument list"); else { unwind_protect frame;
--- a/libinterp/octave-value/ov-range.h +++ b/libinterp/octave-value/ov-range.h @@ -59,14 +59,14 @@ : octave_base_value (), range (base, limit, inc), idx_cache () { if (range.numel () < 0) - ::error ("invalid range"); + error ("invalid range"); } octave_range (const Range& r) : octave_base_value (), range (r), idx_cache () { if (range.numel () < 0 && range.numel () != -2) - ::error ("invalid range"); + error ("invalid range"); } octave_range (const octave_range& r)
--- a/libinterp/octave-value/ov-typeinfo.cc +++ b/libinterp/octave-value/ov-typeinfo.cc @@ -52,7 +52,7 @@ if (! instance) { - ::error ("unable to create value type info object!"); + error ("unable to create value type info object!"); retval = false; }
--- a/libinterp/octave-value/ov-usr-fcn.cc +++ b/libinterp/octave-value/ov-usr-fcn.cc @@ -117,7 +117,7 @@ { octave_value_list retval; - ::error ("invalid use of script %s in index expression", file_name.c_str ()); + error ("invalid use of script %s in index expression", file_name.c_str ()); return retval; } @@ -161,7 +161,7 @@ tree_break_command::breaking--; } else - ::error ("max_recursion_depth exceeded"); + error ("max_recursion_depth exceeded"); } } else @@ -514,7 +514,7 @@ if (call_depth >= Vmax_recursion_depth) { - ::error ("max_recursion_depth exceeded"); + error ("max_recursion_depth exceeded"); return retval; } @@ -555,8 +555,8 @@ } else { - ::error ("%s: invalid classdef constructor, no output argument defined", - dispatch_class ().c_str ()); + error ("%s: invalid classdef constructor, no output argument defined", + dispatch_class ().c_str ()); return retval; } }
--- a/libinterp/parse-tree/pt-arg-list.cc +++ b/libinterp/parse-tree/pt-arg-list.cc @@ -195,7 +195,7 @@ retval = 1; } else - ::error ("invalid use of end"); + error ("invalid use of end"); return retval; } @@ -244,7 +244,7 @@ if (error_state) { - ::error ("evaluating argument list element number %d", k+1); + error ("evaluating argument list element number %d", k+1); args.clear (); break; }
--- a/libinterp/parse-tree/pt-cell.cc +++ b/libinterp/parse-tree/pt-cell.cc @@ -71,7 +71,7 @@ continue; // blank line else { - ::error ("number of columns must match"); + error ("number of columns must match"); return retval; } }
--- a/libinterp/parse-tree/pt-colon.cc +++ b/libinterp/parse-tree/pt-colon.cc @@ -44,7 +44,7 @@ if (op_limit) { if (op_increment) - ::error ("invalid colon expression"); + error ("invalid colon expression"); else { // Stupid syntax: @@ -62,7 +62,7 @@ retval = this; } else - ::error ("invalid colon expression"); + error ("invalid colon expression"); return retval; } @@ -133,7 +133,7 @@ retval = tmp2 (0); } else - ::error ("can not find overloaded colon function"); + error ("can not find overloaded colon function"); } } else @@ -160,7 +160,7 @@ void tree_colon_expression::eval_error (const std::string& s) const { - ::error ("%s", s.c_str ()); + error ("%s", s.c_str ()); } int
--- a/libinterp/parse-tree/pt-eval.cc +++ b/libinterp/parse-tree/pt-eval.cc @@ -412,8 +412,8 @@ } else { - ::error ("invalid type in for loop expression near line %d, column %d", - cmd.line (), cmd.column ()); + error ("invalid type in for loop expression near line %d, column %d", + cmd.line (), cmd.column ()); } } } @@ -878,8 +878,8 @@ } } else - ::error ("missing value in switch command near line %d, column %d", - cmd.line (), cmd.column ()); + error ("missing value in switch command near line %d, column %d", + cmd.line (), cmd.column ()); } void
--- a/libinterp/parse-tree/pt-exp.cc +++ b/libinterp/parse-tree/pt-exp.cc @@ -47,8 +47,8 @@ if (t1.is_defined ()) return t1.is_true (); else - ::error ("%s: undefined value used in conditional expression", - warn_for); + error ("%s: undefined value used in conditional expression", + warn_for); } return expr_value; @@ -57,14 +57,14 @@ octave_value tree_expression::rvalue1 (int) { - ::error ("invalid rvalue function called in expression"); + error ("invalid rvalue function called in expression"); return octave_value (); } octave_value_list tree_expression::rvalue (int) { - ::error ("invalid rvalue function called in expression"); + error ("invalid rvalue function called in expression"); return octave_value_list (); } @@ -77,7 +77,7 @@ octave_lvalue tree_expression::lvalue (void) { - ::error ("invalid lvalue function called in expression"); + error ("invalid lvalue function called in expression"); return octave_lvalue (); }
--- a/libinterp/parse-tree/pt-id.cc +++ b/libinterp/parse-tree/pt-id.cc @@ -50,12 +50,12 @@ return; if (l == -1 && c == -1) - ::error_with_id ("Octave:undefined-function", - "'%s' undefined", name ().c_str ()); + error_with_id ("Octave:undefined-function", + "'%s' undefined", name ().c_str ()); else - ::error_with_id ("Octave:undefined-function", - "'%s' undefined near line %d column %d", - name ().c_str (), l, c); + error_with_id ("Octave:undefined-function", + "'%s' undefined near line %d column %d", + name ().c_str (), l, c); } octave_value_list
--- a/libinterp/parse-tree/pt-id.h +++ b/libinterp/parse-tree/pt-id.h @@ -118,8 +118,8 @@ void static_workspace_error (void) { - ::error ("can not add variable \"%s\" to a static workspace", - name ().c_str ()); + error ("can not add variable \"%s\" to a static workspace", + name ().c_str ()); } tree_identifier *dup (symbol_table::scope_id scope,
--- a/libinterp/parse-tree/pt-mat.cc +++ b/libinterp/parse-tree/pt-mat.cc @@ -276,7 +276,7 @@ static void eval_error (const char *msg, const dim_vector& x, const dim_vector& y) { - ::error ("%s (%s vs %s)", msg, x.str ().c_str (), y.str ().c_str ()); + error ("%s (%s vs %s)", msg, x.str ().c_str (), y.str ().c_str ()); } void