# HG changeset patch # User Rik # Date 1674609584 28800 # Node ID 21f9b34eb893e27c29b4478f8e973baf9a4758ea # Parent 1d1eff97670ef1c14e69872e3b37d39b39f7b655 maint: Eliminate "(void)" in C++ function prototypes/declarations. * mk-opts.pl, external.txi, embedded.cc, make_int.cc, standalone.cc, standalonebuiltin.cc, BaseControl.cc, BaseControl.h, ButtonControl.cc, ButtonControl.h, ButtonGroup.cc, ButtonGroup.h, Canvas.cc, Canvas.h, CheckBoxControl.cc, CheckBoxControl.h, Container.cc, Container.h, ContextMenu.cc, ContextMenu.h, EditControl.cc, EditControl.h, Figure.cc, Figure.h, FigureWindow.cc, FigureWindow.h, GLCanvas.cc, GLCanvas.h, GenericEventNotify.h, KeyMap.cc, ListBoxControl.cc, ListBoxControl.h, Logger.cc, Logger.h, Menu.cc, Menu.h, MenuContainer.h, Object.cc, Object.h, ObjectProxy.cc, ObjectProxy.h, Panel.cc, Panel.h, PopupMenuControl.cc, PopupMenuControl.h, PushButtonControl.cc, PushButtonControl.h, PushTool.cc, PushTool.h, RadioButtonControl.cc, RadioButtonControl.h, SliderControl.cc, SliderControl.h, Table.cc, Table.h, TextControl.cc, TextControl.h, TextEdit.h, ToggleButtonControl.cc, ToggleButtonControl.h, ToggleTool.cc, ToggleTool.h, ToolBar.cc, ToolBar.h, ToolBarButton.cc, ToolBarButton.h, gl-select.cc, gl-select.h, qopengl-functions.h, qt-graphics-toolkit.h, qdialog.cpp, qfontdialog.cpp, qprintdialog_win.cpp, liboctgui-build-info.h, liboctgui-build-info.in.cc, color-picker.cc, color-picker.h, command-widget.cc, command-widget.h, community-news.cc, community-news.h, dialog.cc, dialog.h, documentation-bookmarks.cc, documentation-bookmarks.h, documentation-dock-widget.cc, documentation-dock-widget.h, documentation.cc, documentation.h, dw-main-window.cc, dw-main-window.h, external-editor-interface.cc, external-editor-interface.h, files-dock-widget.cc, files-dock-widget.h, find-files-dialog.cc, find-files-dialog.h, find-files-model.cc, find-files-model.h, gui-preferences.cc, gui-preferences.h, gui-settings.cc, gui-settings.h, history-dock-widget.cc, history-dock-widget.h, interpreter-qobject.cc, interpreter-qobject.h, file-editor-interface.h, file-editor-tab.cc, file-editor-tab.h, file-editor.cc, file-editor.h, find-dialog.cc, find-dialog.h, marker.cc, marker.h, octave-qscintilla.cc, octave-qscintilla.h, octave-txt-lexer.cc, octave-txt-lexer.h, main-window.cc, main-window.h, news-reader.cc, news-reader.h, octave-dock-widget.cc, octave-dock-widget.h, octave-qobject.cc, octave-qobject.h, qt-application.cc, qt-application.h, qt-interpreter-events.cc, qt-interpreter-events.h, release-notes.cc, release-notes.h, set-path-dialog.cc, set-path-dialog.h, set-path-model.cc, set-path-model.h, settings-dialog.cc, settings-dialog.h, shortcuts-tree-widget.cc, shortcuts-tree-widget.h, tab-bar.cc, tab-bar.h, terminal-dock-widget.cc, terminal-dock-widget.h, variable-editor-model.cc, variable-editor-model.h, variable-editor.cc, variable-editor.h, welcome-wizard.cc, welcome-wizard.h, workspace-model.cc, workspace-model.h, workspace-view.cc, workspace-view.h, build-env.h, Cell.cc, Cell.h, __contourc__.cc, __magick_read__.cc, auto-shlib.cc, auto-shlib.h, base-text-renderer.h, bsxfun.cc, c-file-ptr-stream.cc, c-file-ptr-stream.h, call-stack.cc, call-stack.h, debug.cc, defaults.cc, defaults.h, defun.cc, display.cc, display.h, dynamic-ld.cc, dynamic-ld.h, environment.cc, environment.h, error.cc, error.h, errwarn.cc, errwarn.h, event-manager.cc, event-manager.h, event-queue.cc, event-queue.h, fcn-info.cc, fcn-info.h, ft-text-renderer.cc, ft-text-renderer.h, genprops.awk, gh-manager.cc, gh-manager.h, gl-render.cc, gl-render.h, gl2ps-print.cc, graphics-toolkit.h, graphics.cc, graphics.in.h, gtk-manager.cc, gtk-manager.h, help.cc, help.h, hook-fcn.h, input.cc, input.h, interpreter-private.cc, interpreter-private.h, interpreter.cc, interpreter.h, jsondecode.cc, latex-text-renderer.cc, latex-text-renderer.h, load-path.cc, load-path.h, load-save.cc, load-save.h, ls-hdf5.cc, ls-hdf5.h, mxarray.h, oct-errno.h, oct-errno.in.cc, oct-fstrm.cc, oct-fstrm.h, oct-handle.h, oct-hist.cc, oct-hist.h, oct-iostrm.cc, oct-iostrm.h, oct-map.cc, oct-map.h, oct-opengl.h, oct-prcstrm.cc, oct-prcstrm.h, oct-procbuf.cc, oct-procbuf.h, oct-process.h, oct-stdstrm.h, oct-stream.cc, oct-stream.h, oct-strstrm.cc, oct-strstrm.h, oct-tex-lexer.in.ll, pager.cc, pager.h, pr-flt-fmt.cc, pr-flt-fmt.h, pr-output.cc, pr-output.h, procstream.cc, procstream.h, settings.cc, settings.h, sighandlers.cc, sighandlers.h, stack-frame.cc, stack-frame.h, svd.cc, syminfo.cc, syminfo.h, symrec.cc, symrec.h, symscope.cc, symscope.h, symtab.cc, symtab.h, sysdep.cc, sysdep.h, text-engine.cc, text-engine.h, text-renderer.cc, text-renderer.h, toplev.cc, url-handle-manager.cc, url-handle-manager.h, variables.cc, xpow.cc, __init_fltk__.cc, __init_gnuplot__.cc, __ode15__.cc, audiodevinfo.cc, gzip.cc, liboctinterp-build-info.h, liboctinterp-build-info.in.cc, mk-build-env-features.sh, mk-builtins.pl, cdef-class.cc, cdef-class.h, cdef-manager.h, cdef-method.cc, cdef-method.h, cdef-object.cc, cdef-object.h, cdef-package.cc, cdef-package.h, cdef-property.cc, cdef-property.h, cdef-utils.cc, cdef-utils.h, ov-base-diag.cc, ov-base-diag.h, ov-base-int.cc, ov-base-int.h, ov-base-mat.cc, ov-base-mat.h, ov-base-scalar.cc, ov-base-scalar.h, ov-base-sparse.cc, ov-base-sparse.h, ov-base.cc, ov-base.h, ov-bool-mat.cc, ov-bool-mat.h, ov-bool-sparse.cc, ov-bool-sparse.h, ov-bool.cc, ov-bool.h, ov-builtin.cc, ov-builtin.h, ov-cell.cc, ov-cell.h, ov-ch-mat.cc, ov-ch-mat.h, ov-class.cc, ov-class.h, ov-classdef.cc, ov-classdef.h, ov-colon.h, ov-complex.cc, ov-complex.h, ov-cs-list.h, ov-cx-diag.cc, ov-cx-diag.h, ov-cx-mat.cc, ov-cx-mat.h, ov-cx-sparse.cc, ov-cx-sparse.h, ov-dld-fcn.cc, ov-dld-fcn.h, ov-fcn-handle.cc, ov-fcn-handle.h, ov-fcn.cc, ov-fcn.h, ov-float.cc, ov-float.h, ov-flt-complex.cc, ov-flt-complex.h, ov-flt-cx-diag.cc, ov-flt-cx-diag.h, ov-flt-cx-mat.cc, ov-flt-cx-mat.h, ov-flt-re-diag.cc, ov-flt-re-diag.h, ov-flt-re-mat.cc, ov-flt-re-mat.h, ov-intx.h, ov-java.cc, ov-java.h, ov-lazy-idx.cc, ov-lazy-idx.h, ov-legacy-range.cc, ov-legacy-range.h, ov-magic-int.cc, ov-magic-int.h, ov-mex-fcn.cc, ov-mex-fcn.h, ov-null-mat.cc, ov-null-mat.h, ov-oncleanup.cc, ov-oncleanup.h, ov-perm.cc, ov-perm.h, ov-range.cc, ov-range.h, ov-re-diag.cc, ov-re-diag.h, ov-re-mat.cc, ov-re-mat.h, ov-re-sparse.cc, ov-re-sparse.h, ov-scalar.cc, ov-scalar.h, ov-str-mat.cc, ov-str-mat.h, ov-struct.cc, ov-struct.h, ov-typeinfo.cc, ov-typeinfo.h, ov-usr-fcn.cc, ov-usr-fcn.h, ov.cc, ov.h, ovl.cc, ovl.h, octave.cc, octave.h, anon-fcn-validator.h, bp-table.cc, bp-table.h, comment-list.cc, comment-list.h, filepos.h, lex.h, lex.ll, oct-lvalue.cc, oct-lvalue.h, oct-parse.yy, parse.h, profiler.cc, profiler.h, pt-anon-scopes.h, pt-arg-list.cc, pt-arg-list.h, pt-args-block.cc, pt-args-block.h, pt-array-list.cc, pt-array-list.h, pt-assign.cc, pt-assign.h, pt-binop.cc, pt-binop.h, pt-bp.h, pt-cbinop.h, pt-cell.h, pt-check.h, pt-classdef.cc, pt-classdef.h, pt-cmd.h, pt-colon.h, pt-const.h, pt-decl.cc, pt-decl.h, pt-eval.cc, pt-eval.h, pt-except.cc, pt-except.h, pt-exp.cc, pt-exp.h, pt-fcn-handle.cc, pt-fcn-handle.h, pt-id.cc, pt-id.h, pt-idx.cc, pt-idx.h, pt-jump.h, pt-loop.cc, pt-loop.h, pt-mat.h, pt-misc.cc, pt-misc.h, pt-pr-code.cc, pt-pr-code.h, pt-select.cc, pt-select.h, pt-spmd.cc, pt-spmd.h, pt-stmt.cc, pt-stmt.h, pt-tm-const.cc, pt-tm-const.h, pt-unop.cc, pt-unop.h, pt-walk.h, pt.cc, pt.h, token.cc, token.h, usage.h, Array-base.cc, Array.h, CColVector.cc, CColVector.h, CDiagMatrix.cc, CDiagMatrix.h, CMatrix.cc, CMatrix.h, CNDArray.cc, CNDArray.h, CRowVector.cc, CRowVector.h, CSparse.cc, CSparse.h, DiagArray2.cc, DiagArray2.h, MArray.cc, MArray.h, MDiagArray2.h, MSparse.h, MatrixType.cc, MatrixType.h, PermMatrix.cc, PermMatrix.h, Range.cc, Range.h, Sparse-b.cc, Sparse.cc, Sparse.h, boolMatrix.cc, boolMatrix.h, boolNDArray.cc, boolNDArray.h, boolSparse.cc, boolSparse.h, chMatrix.h, chNDArray.h, dColVector.cc, dColVector.h, dDiagMatrix.cc, dDiagMatrix.h, dMatrix.cc, dMatrix.h, dNDArray.cc, dNDArray.h, dRowVector.cc, dRowVector.h, dSparse.cc, dSparse.h, dim-vector.cc, dim-vector.h, fCColVector.cc, fCColVector.h, fCDiagMatrix.cc, fCDiagMatrix.h, fCMatrix.cc, fCMatrix.h, fCNDArray.cc, fCNDArray.h, fCRowVector.cc, fCRowVector.h, fColVector.cc, fColVector.h, fDiagMatrix.cc, fDiagMatrix.h, fMatrix.cc, fMatrix.h, fNDArray.cc, fNDArray.h, fRowVector.cc, fRowVector.h, idx-vector.cc, idx-vector.h, intNDArray.cc, intNDArray.h, liboctave-build-info.h, liboctave-build-info.in.cc, CollocWt.cc, CollocWt.h, DAE.h, DAEFunc.h, DAERT.h, DAERTFunc.h, DASPK.cc, DASPK.h, DASRT.cc, DASRT.h, DASSL.cc, DASSL.h, DET.h, EIG.h, LSODE.cc, LSODE.h, ODE.h, ODEFunc.h, ODES.h, ODESFunc.h, Quad.h, aepbalance.cc, aepbalance.h, base-dae.h, base-de.h, chol.cc, chol.h, eigs-base.cc, fEIG.h, gepbalance.h, gsvd.cc, gsvd.h, hess.h, lu.cc, lu.h, oct-fftw.cc, oct-fftw.h, oct-rand.cc, oct-rand.h, oct-spparms.cc, oct-spparms.h, qr.cc, qr.h, qrp.cc, qrp.h, randmtzig.cc, randmtzig.h, schur.h, sparse-chol.cc, sparse-chol.h, sparse-lu.cc, sparse-lu.h, sparse-qr.cc, sparse-qr.h, svd.cc, svd.h, child-list.cc, child-list.h, dir-ops.cc, dir-ops.h, file-ops.cc, file-ops.h, file-stat.cc, file-stat.h, lo-sysdep.cc, lo-sysdep.h, lo-sysinfo.cc, lo-sysinfo.h, mach-info.cc, mach-info.h, oct-env.cc, oct-env.h, oct-group.cc, oct-group.h, oct-password.cc, oct-password.h, oct-syscalls.cc, oct-syscalls.h, oct-time.cc, oct-time.h, oct-uname.cc, oct-uname.h, action-container.h, base-list.h, caseless-str.h, cmd-edit.cc, cmd-edit.h, cmd-hist.cc, cmd-hist.h, data-conv.cc, file-info.h, glob-match.cc, glob-match.h, kpse.cc, kpse.h, lo-array-errwarn.cc, lo-array-errwarn.h, lo-hash.cc, lo-hash.h, lo-ieee.cc, lo-ieee.h, lo-regexp.cc, lo-regexp.h, oct-inttypes.cc, oct-inttypes.h, oct-mutex.cc, oct-mutex.h, oct-refcount.h, oct-shlib.cc, oct-shlib.h, oct-sort.cc, oct-sort.h, oct-sparse.cc, octave-preserve-stream-state.h, pathsearch.cc, pathsearch.h, quit.cc, singleton-cleanup.cc, singleton-cleanup.h, str-vec.cc, str-vec.h, unwind-prot.cc, unwind-prot.h, url-transfer.cc, url-transfer.h, version.cc, version.in.h, cxx-signal-helpers.cc, acinclude.m4, main-cli.cc, main-gui.cc, main.in.cc, mkoctfile.in.cc, octave-build-info.h, octave-build-info.in.cc, octave-config.in.cc, octave-svgconvert.cc, shared-fcns.h: maint: Eliminate "(void)" in C++ function prototypes/declarations. diff -r 1d1eff97670e -r 21f9b34eb893 build-aux/mk-opts.pl --- a/build-aux/mk-opts.pl Tue Jan 24 16:17:31 2023 -0500 +++ b/build-aux/mk-opts.pl Tue Jan 24 17:19:44 2023 -0800 @@ -392,7 +392,7 @@ { public: - $CLASS_NAME (void) + $CLASS_NAME () _END_EMIT_OPT_CLASS_HEADER_ print ' : '; @@ -421,9 +421,9 @@ return *this; } - ~$CLASS_NAME (void) { }\n"; + ~$CLASS_NAME () { }\n"; - print "\n void init (void)\n {\n"; + print "\n void init ()\n {\n"; for ($i = 0; $i < $OPT_NUM; $i++) { @@ -452,7 +452,7 @@ emit_copy_body (' ', 'opt'); - print " }\n\n void set_default_options (void) { init (); }\n"; + print " }\n\n void set_default_options () { init (); }\n"; for ($i = 0; $i < $OPT_NUM; $i++) { @@ -484,7 +484,7 @@ for ($i = 0; $i < $OPT_NUM; $i++) { - print " $TYPE[$i] $OPT[$i] (void) const\n { return $OPTVAR[$i]; }\n\n"; + print " $TYPE[$i] $OPT[$i] () const\n { return $OPTVAR[$i]; }\n\n"; } print "private:\n\n"; diff -r 1d1eff97670e -r 21f9b34eb893 doc/interpreter/external.txi --- a/doc/interpreter/external.txi Tue Jan 24 16:17:31 2023 -0500 +++ b/doc/interpreter/external.txi Tue Jan 24 17:19:44 2023 -0800 @@ -312,19 +312,19 @@ circumstances the user might prefer to access the data of the array or matrix directly through the @code{fortran_vec} method discussed below. -@deftypefn {Method} {octave_idx_type} numel (void) const +@deftypefn {Method} {octave_idx_type} numel () const The total number of elements in the matrix or array. @end deftypefn -@deftypefn {Method} {size_t} byte_size (void) const +@deftypefn {Method} {size_t} byte_size () const The number of bytes used to store the matrix or array. @end deftypefn -@deftypefn {Method} {dim_vector} dims (void) const +@deftypefn {Method} {dim_vector} dims () const The dimensions of the matrix or array in value of type @code{dim_vector}. @end deftypefn -@deftypefn {Method} {int} ndims (void) const +@deftypefn {Method} {int} ndims () const The number of dimensions of the matrix or array. Matrices are always 2-D, but arrays can be N-dimensional. @end deftypefn @@ -336,7 +336,7 @@ of rows and columns in the matrix. @end deftypefn -@deftypefn {Method} {T*} fortran_vec (void) +@deftypefn {Method} {T*} fortran_vec () This method returns a pointer to the underlying data of the matrix or array so that it can be manipulated directly, either within Octave or by an external library. diff -r 1d1eff97670e -r 21f9b34eb893 examples/code/embedded.cc --- a/examples/code/embedded.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/examples/code/embedded.cc Tue Jan 24 17:19:44 2023 -0800 @@ -5,7 +5,7 @@ #include int -main (void) +main () { // Create interpreter. diff -r 1d1eff97670e -r 21f9b34eb893 examples/code/make_int.cc --- a/examples/code/make_int.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/examples/code/make_int.cc Tue Jan 24 17:19:44 2023 -0800 @@ -37,7 +37,7 @@ { public: - octave_integer (void) + octave_integer () : octave_base_dld_value (), scalar (0) { } octave_integer (int i) @@ -46,9 +46,9 @@ octave_integer (const octave_integer& s) : octave_base_dld_value (), scalar (s.scalar) { } - ~octave_integer (void) = default; + ~octave_integer () = default; - octave_base_value * clone (void) { return new octave_integer (*this); } + octave_base_value * clone () { return new octave_integer (*this); } #if 0 void *operator new (std::size_t size); @@ -58,28 +58,28 @@ octave::idx_vector index_vector (bool) const { return octave::idx_vector ((double) scalar); } - int rows (void) const { return 1; } - int columns (void) const { return 1; } + int rows () const { return 1; } + int columns () const { return 1; } - bool is_constant (void) const { return true; } + bool is_constant () const { return true; } - bool is_defined (void) const { return true; } - bool is_real_scalar (void) const { return true; } + bool is_defined () const { return true; } + bool is_real_scalar () const { return true; } - octave_value all (void) const { return (double) (scalar != 0); } - octave_value any (void) const { return (double) (scalar != 0); } + octave_value all () const { return (double) (scalar != 0); } + octave_value any () const { return (double) (scalar != 0); } - bool is_real_type (void) const { return true; } - bool is_scalar_type (void) const { return true; } - bool isnumeric (void) const { return true; } + bool is_real_type () const { return true; } + bool is_scalar_type () const { return true; } + bool isnumeric () const { return true; } - bool valid_as_scalar_index (void) const + bool valid_as_scalar_index () const { return scalar == 1; } - bool valid_as_zero_index (void) const + bool valid_as_zero_index () const { return scalar == 0; } - bool is_true (void) const { return (scalar != 0); } + bool is_true () const { return (scalar != 0); } double double_value (bool = false) const { return (double) scalar; } @@ -92,17 +92,17 @@ ComplexMatrix complex_matrix_value (bool = false) const { return ComplexMatrix (1, 1, Complex (scalar)); } - octave_value gnot (void) const { return octave_value ((double) ! scalar); } + octave_value gnot () const { return octave_value ((double) ! scalar); } - octave_value uminus (void) const { return new octave_integer (- scalar); } + octave_value uminus () const { return new octave_integer (- scalar); } - octave_value transpose (void) const { return new octave_integer (scalar); } + octave_value transpose () const { return new octave_integer (scalar); } - octave_value hermitian (void) const { return new octave_integer (scalar); } + octave_value hermitian () const { return new octave_integer (scalar); } - void increment (void) { ++scalar; } + void increment () { ++scalar; } - void decrement (void) { --scalar; } + void decrement () { --scalar; } void print (std::ostream& os, bool pr_as_read_syntax = false); diff -r 1d1eff97670e -r 21f9b34eb893 examples/code/standalone.cc --- a/examples/code/standalone.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/examples/code/standalone.cc Tue Jan 24 17:19:44 2023 -0800 @@ -2,7 +2,7 @@ #include int -main (void) +main () { std::cout << "Hello Octave world!\n"; diff -r 1d1eff97670e -r 21f9b34eb893 examples/code/standalonebuiltin.cc --- a/examples/code/standalonebuiltin.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/examples/code/standalonebuiltin.cc Tue Jan 24 17:19:44 2023 -0800 @@ -3,7 +3,7 @@ #include int -main (void) +main () { int n = 2; Matrix a_matrix = Matrix (n, n); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/BaseControl.cc --- a/libgui/graphics/BaseControl.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/BaseControl.cc Tue Jan 24 17:19:44 2023 -0800 @@ -150,11 +150,11 @@ m_normalizedFont = up.fontunits_is ("normalized"); } - BaseControl::~BaseControl (void) + BaseControl::~BaseControl () { } void - BaseControl::redraw (void) + BaseControl::redraw () { update (uicontrol::properties::ID_POSITION); } diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/BaseControl.h --- a/libgui/graphics/BaseControl.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/BaseControl.h Tue Jan 24 17:19:44 2023 -0800 @@ -40,15 +40,15 @@ public: BaseControl (octave::interpreter& interp, const graphics_object& go, QWidget *w); - ~BaseControl (void); + ~BaseControl (); - Container * innerContainer (void) { return nullptr; } + Container * innerContainer () { return nullptr; } bool eventFilter (QObject *watched, QEvent *e); protected: void init (QWidget *w, bool callBase = false); - void redraw (void); + void redraw (); void update (int pId); private: diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/ButtonControl.cc --- a/libgui/graphics/ButtonControl.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/ButtonControl.cc Tue Jan 24 17:19:44 2023 -0800 @@ -63,7 +63,7 @@ connect (btn, &QAbstractButton::toggled, this, &ButtonControl::toggled); } - ButtonControl::~ButtonControl (void) + ButtonControl::~ButtonControl () { } void @@ -143,7 +143,7 @@ } void - ButtonControl::clicked (void) + ButtonControl::clicked () { QAbstractButton *btn = qWidget (); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/ButtonControl.h --- a/libgui/graphics/ButtonControl.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/ButtonControl.h Tue Jan 24 17:19:44 2023 -0800 @@ -41,13 +41,13 @@ public: ButtonControl (octave::interpreter& interp, const graphics_object& go, QAbstractButton *btn); - ~ButtonControl (void); + ~ButtonControl (); protected: void update (int pId); private slots: - void clicked (void); + void clicked (); void toggled (bool checked); private: diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/ButtonGroup.cc --- a/libgui/graphics/ButtonGroup.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/ButtonGroup.cc Tue Jan 24 17:19:44 2023 -0800 @@ -173,7 +173,7 @@ QTimer::singleShot (0, frame, &QFrame::show); // FIXME: What is the intent here? QButtonGroup::show is not a // member of QButtonGroup. - QTimer::singleShot (0, buttongroup, SLOT (show (void))); + QTimer::singleShot (0, buttongroup, SLOT (show ())); } else frame->hide (); @@ -183,7 +183,7 @@ this, &ButtonGroup::buttonClicked); } - ButtonGroup::~ButtonGroup (void) + ButtonGroup::~ButtonGroup () { } bool @@ -399,7 +399,7 @@ } void - ButtonGroup::redraw (void) + ButtonGroup::redraw () { update (uibuttongroup::properties::ID_POSITION); @@ -411,7 +411,7 @@ } void - ButtonGroup::updateLayout (void) + ButtonGroup::updateLayout () { uibuttongroup::properties& pp = properties (); QFrame *frame = qWidget (); @@ -452,7 +452,7 @@ } void - ButtonGroup::selectNothing (void) + ButtonGroup::selectNothing () { m_hiddenbutton->setChecked (true); } diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/ButtonGroup.h --- a/libgui/graphics/ButtonGroup.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/ButtonGroup.h Tue Jan 24 17:19:44 2023 -0800 @@ -48,9 +48,9 @@ ButtonGroup (octave::interpreter& interp, const graphics_object& go, QButtonGroup *buttongroup, QFrame *frame); - ~ButtonGroup (void); + ~ButtonGroup (); - Container * innerContainer (void) { return m_container; } + Container * innerContainer () { return m_container; } bool eventFilter (QObject *watched, QEvent *event); @@ -60,18 +60,18 @@ void addButton (QAbstractButton *btn); - void selectNothing (void); + void selectNothing (); protected: void update (int pId); - void redraw (void); + void redraw (); private slots: void buttonToggled (bool toggled); void buttonClicked (QAbstractButton *btn); private: - void updateLayout (void); + void updateLayout (); private: QButtonGroup *m_buttongroup; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/Canvas.cc --- a/libgui/graphics/Canvas.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/Canvas.cc Tue Jan 24 17:19:44 2023 -0800 @@ -272,7 +272,7 @@ } void - Canvas::canvasPaintEvent (void) + Canvas::canvasPaintEvent () { if (! m_redrawBlocked) { diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/Canvas.h --- a/libgui/graphics/Canvas.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/Canvas.h Tue Jan 24 17:19:44 2023 -0800 @@ -57,7 +57,7 @@ }; public: - virtual ~Canvas (void) = default; + virtual ~Canvas () = default; void redraw (bool sync = false); void blockRedraw (bool block = true); @@ -74,13 +74,13 @@ void setCursor (MouseMode mode, std::string fallback, QImage cdata, Matrix hotspot); - virtual QWidget * qWidget (void) = 0; + virtual QWidget * qWidget () = 0; static Canvas * create (octave::interpreter& interp, const graphics_handle& handle, QWidget *parent, const std::string& name); - virtual uint8NDArray getPixels (void) { return do_getPixels (m_handle); }; + virtual uint8NDArray getPixels () { return do_getPixels (m_handle); }; signals: @@ -123,7 +123,7 @@ void canvasToggleAxes (const graphics_handle& handle); void canvasToggleGrid (const graphics_handle& handle); void canvasAutoAxes (const graphics_handle& handle); - void canvasPaintEvent (void); + void canvasPaintEvent (); void canvasMouseDoubleClickEvent (QMouseEvent *event); void canvasMouseMoveEvent (QMouseEvent *event); void canvasMousePressEvent (QMouseEvent *event); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/CheckBoxControl.cc --- a/libgui/graphics/CheckBoxControl.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/CheckBoxControl.cc Tue Jan 24 17:19:44 2023 -0800 @@ -63,7 +63,7 @@ box->setCheckable (false); } - CheckBoxControl::~CheckBoxControl (void) + CheckBoxControl::~CheckBoxControl () { } void diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/CheckBoxControl.h --- a/libgui/graphics/CheckBoxControl.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/CheckBoxControl.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,7 +39,7 @@ public: CheckBoxControl (octave::interpreter& interp, const graphics_object& go, QCheckBox *box); - ~CheckBoxControl (void); + ~CheckBoxControl (); static CheckBoxControl * create (octave::interpreter& interp, diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/Container.cc --- a/libgui/graphics/Container.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/Container.cc Tue Jan 24 17:19:44 2023 -0800 @@ -46,7 +46,7 @@ setFocusPolicy (Qt::ClickFocus); } - Container::~Container (void) + Container::~Container () { } Canvas * diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/Container.h --- a/libgui/graphics/Container.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/Container.h Tue Jan 24 17:19:44 2023 -0800 @@ -45,7 +45,7 @@ public: Container (QWidget *parent, octave::interpreter& interp); - ~Container (void); + ~Container (); Canvas * canvas (const graphics_handle& handle, bool create = true); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/ContextMenu.cc --- a/libgui/graphics/ContextMenu.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/ContextMenu.cc Tue Jan 24 17:19:44 2023 -0800 @@ -62,7 +62,7 @@ connect (xmenu, &QMenu::aboutToHide, this, &ContextMenu::aboutToHide); } - ContextMenu::~ContextMenu (void) + ContextMenu::~ContextMenu () { } void @@ -96,20 +96,20 @@ } void - ContextMenu::aboutToShow (void) + ContextMenu::aboutToShow () { emit gh_callback_event (m_handle, "callback"); emit gh_set_event (m_handle, "visible", "on", false); } void - ContextMenu::aboutToHide (void) + ContextMenu::aboutToHide () { emit gh_set_event (m_handle, "visible", "off", false); } QWidget * - ContextMenu::menu (void) + ContextMenu::menu () { return qWidget (); } diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/ContextMenu.h --- a/libgui/graphics/ContextMenu.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/ContextMenu.h Tue Jan 24 17:19:44 2023 -0800 @@ -44,7 +44,7 @@ public: ContextMenu (octave::interpreter& interp, const graphics_object& go, QMenu *menu); - ~ContextMenu (void); + ~ContextMenu (); static ContextMenu * create (octave::interpreter& interp, @@ -53,16 +53,16 @@ static void executeAt (octave::interpreter& interp, const base_properties& props, const QPoint& pt); - Container * innerContainer (void) { return nullptr; } + Container * innerContainer () { return nullptr; } - QWidget * menu (void); + QWidget * menu (); protected: void update (int pId); private slots: - void aboutToShow (void); - void aboutToHide (void); + void aboutToShow (); + void aboutToHide (); }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/EditControl.cc --- a/libgui/graphics/EditControl.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/EditControl.cc Tue Jan 24 17:19:44 2023 -0800 @@ -133,7 +133,7 @@ this, &EditControl::returnPressed); } - EditControl::~EditControl (void) + EditControl::~EditControl () { } void @@ -257,13 +257,13 @@ } void - EditControl::textChanged (void) + EditControl::textChanged () { m_textChanged = true; } void - EditControl::returnPressed (void) + EditControl::returnPressed () { QString txt = (m_multiLine ? qWidget ()->toPlainText () @@ -286,7 +286,7 @@ } void - EditControl::editingFinished (void) + EditControl::editingFinished () { if (m_textChanged) { diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/EditControl.h --- a/libgui/graphics/EditControl.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/EditControl.h Tue Jan 24 17:19:44 2023 -0800 @@ -48,7 +48,7 @@ EditControl (octave::interpreter& interp, const graphics_object& go, TextEdit *edit); - ~EditControl (void); + ~EditControl (); static EditControl * create (octave::interpreter& interp, @@ -65,9 +65,9 @@ bool updateMultiLine (int pId); private slots: - void textChanged (void); - void editingFinished (void); - void returnPressed (void); + void textChanged (); + void editingFinished (); + void returnPressed (); private: bool m_multiLine; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/Figure.cc --- a/libgui/graphics/Figure.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/Figure.cc Tue Jan 24 17:19:44 2023 -0800 @@ -189,11 +189,11 @@ m_container->addReceiver (this); } - Figure::~Figure (void) + Figure::~Figure () { } QString - Figure::fileName (void) + Figure::fileName () { gh_manager& gh_mgr = m_interpreter.get_gh_manager (); @@ -219,7 +219,7 @@ } MouseMode - Figure::mouseMode (void) + Figure::mouseMode () { gh_manager& gh_mgr = m_interpreter.get_gh_manager (); @@ -278,13 +278,13 @@ } Container * - Figure::innerContainer (void) + Figure::innerContainer () { return m_container; } void - Figure::redraw (void) + Figure::redraw () { Canvas *canvas = m_container->canvas (m_handle); @@ -307,7 +307,7 @@ } void - Figure::show (void) + Figure::show () { QWidget *win = qWidget (); @@ -325,7 +325,7 @@ } uint8NDArray - Figure::slotGetPixels (void) + Figure::slotGetPixels () { uint8NDArray retval; Canvas *canvas = m_container->canvas (m_handle); @@ -343,7 +343,7 @@ } void - Figure::beingDeleted (void) + Figure::beingDeleted () { Canvas *canvas = m_container->canvas (m_handle.value (), false); @@ -615,7 +615,7 @@ } QWidget * - Figure::menu (void) + Figure::menu () { return qWidget ()->menuBar (); } @@ -864,7 +864,7 @@ } void - Figure::updateContainer (void) + Figure::updateContainer () { redraw (); } @@ -906,7 +906,7 @@ } void - Figure::enableMouseTracking (void) + Figure::enableMouseTracking () { // Enable mouse tracking on every widgets m_container->setMouseTracking (true); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/Figure.h --- a/libgui/graphics/Figure.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/Figure.h Tue Jan 24 17:19:44 2023 -0800 @@ -69,19 +69,19 @@ public: Figure (octave::interpreter& interp, const graphics_object& go, FigureWindow *win); - ~Figure (void); + ~Figure (); static Figure * create (octave::interpreter& interp, const graphics_object& go); - QString fileName (void); + QString fileName (); void setFileName (const QString& name); - MouseMode mouseMode (void); + MouseMode mouseMode (); - Container * innerContainer (void); - QWidget * menu (void); + Container * innerContainer (); + QWidget * menu (); void updateStatusBar (ColumnVector pt); void do_connections (const QObject *receiver, @@ -99,12 +99,12 @@ }; protected: - void redraw (void); - void show (void); + void redraw (); + void show (); void print (const QString& file_cmd, const QString& term); void update (int pId); void updateBoundingBox (bool internal = false, int flags = 0); - void beingDeleted (void); + void beingDeleted (); private: void showFigureStatusBar (bool visible); @@ -112,19 +112,19 @@ void showCustomToolBar (QToolBar *bar, bool visible); void set_geometry (QRect r); - void enableMouseTracking (void); + void enableMouseTracking (); private slots: void updateFigureHeight (int delta_h); - void updateContainer (void); + void updateContainer (); void figureWindowShown (); void screenChanged (QScreen *); public slots: - uint8NDArray slotGetPixels (void); + uint8NDArray slotGetPixels (); signals: - void asyncUpdate (void); + void asyncUpdate (); void interpreter_event (const octave::fcn_callback& fcn); void interpreter_event (const octave::meth_callback& meth); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/FigureWindow.cc --- a/libgui/graphics/FigureWindow.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/FigureWindow.cc Tue Jan 24 17:19:44 2023 -0800 @@ -41,11 +41,11 @@ setWindowIcon (QIcon (global_icon_paths.at (ICON_THEME_OCTAVE))); } -FigureWindow::~FigureWindow (void) +FigureWindow::~FigureWindow () { } QMenu * -FigureWindow::createPopupMenu (void) +FigureWindow::createPopupMenu () { // For the time being, disable menubar/toolbar popup menu return nullptr; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/FigureWindow.h --- a/libgui/graphics/FigureWindow.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/FigureWindow.h Tue Jan 24 17:19:44 2023 -0800 @@ -40,9 +40,9 @@ public: explicit FigureWindow (QWidget *parent = nullptr); - ~FigureWindow (void); + ~FigureWindow (); - QMenu * createPopupMenu (void); + QMenu * createPopupMenu (); protected: void showEvent(QShowEvent *ev); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/GLCanvas.cc --- a/libgui/graphics/GLCanvas.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/GLCanvas.cc Tue Jan 24 17:19:44 2023 -0800 @@ -45,10 +45,10 @@ setFocus (); } - GLWidget::~GLWidget (void) { } + GLWidget::~GLWidget () { } void - GLWidget::initializeGL (void) + GLWidget::initializeGL () { // The qopengl_functions object (part of Octave, not Qt) is just // wrapper around QOpenGLFunctions_1_1. Does initialization really @@ -208,7 +208,7 @@ } void - GLWidget::paintGL (void) + GLWidget::paintGL () { m_parent_canvas.canvasPaintEvent (); } @@ -258,7 +258,7 @@ } bool - GLWidget::begin_rendering (void) + GLWidget::begin_rendering () { bool retval = true; @@ -290,7 +290,7 @@ } void - GLWidget::end_rendering (void) + GLWidget::end_rendering () { doneCurrent (); } @@ -300,7 +300,7 @@ : Canvas (interp, gh), m_glwidget (new GLWidget (*this, parent)) { } - GLCanvas::~GLCanvas (void) + GLCanvas::~GLCanvas () { delete m_glwidget; } @@ -346,7 +346,7 @@ catch (octave::execution_exception& ee) { emit interpreter_event - ([=] (void) + ([=] () { // INTERPRETER THREAD throw ee; @@ -367,13 +367,13 @@ } bool - GLCanvas::begin_rendering (void) + GLCanvas::begin_rendering () { return m_glwidget->begin_rendering (); } void - GLCanvas::end_rendering (void) + GLCanvas::end_rendering () { m_glwidget->end_rendering (); } diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/GLCanvas.h --- a/libgui/graphics/GLCanvas.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/GLCanvas.h Tue Jan 24 17:19:44 2023 -0800 @@ -46,9 +46,9 @@ GLWidget (Canvas& parent_canvas, QWidget *parent); - ~GLWidget (void); + ~GLWidget (); - void initializeGL (void); + void initializeGL (); void draw (graphics_object go); uint8NDArray do_getPixels (graphics_object go); @@ -60,12 +60,12 @@ graphics_object selectFromAxes (const graphics_object& ax, const QPoint& pt); - bool begin_rendering (void); - void end_rendering (void); + bool begin_rendering (); + void end_rendering (); protected: - void paintGL (void); + void paintGL (); void mouseDoubleClickEvent (QMouseEvent *event); void mouseMoveEvent (QMouseEvent *event); void mousePressEvent (QMouseEvent *event); @@ -92,7 +92,7 @@ GLCanvas (octave::interpreter& interp, const graphics_handle& handle, QWidget *parent); - ~GLCanvas (void); + ~GLCanvas (); void draw (const graphics_handle& handle); uint8NDArray do_getPixels (const graphics_handle& handle); @@ -104,14 +104,14 @@ graphics_object selectFromAxes (const graphics_object& ax, const QPoint& pt); - QWidget * qWidget (void) { return m_glwidget; } + QWidget * qWidget () { return m_glwidget; } private: GLWidget *m_glwidget; - bool begin_rendering (void); - void end_rendering (void); + bool begin_rendering (); + void end_rendering (); }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/GenericEventNotify.h --- a/libgui/graphics/GenericEventNotify.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/GenericEventNotify.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,8 +39,8 @@ class GenericEventNotifySender { public: - GenericEventNotifySender (void) : m_receivers () { } - virtual ~GenericEventNotifySender (void) = default; + GenericEventNotifySender () : m_receivers () { } + virtual ~GenericEventNotifySender () = default; void addReceiver (GenericEventNotifyReceiver *r) { m_receivers.insert (r); } @@ -59,8 +59,8 @@ class GenericEventNotifyReceiver { public: - GenericEventNotifyReceiver (void) { } - virtual ~GenericEventNotifyReceiver (void) = default; + GenericEventNotifyReceiver () { } + virtual ~GenericEventNotifyReceiver () = default; virtual bool eventNotifyBefore (QObject *obj, QEvent *evt) = 0; virtual void eventNotifyAfter (QObject *obj, QEvent *evt) = 0; @@ -92,7 +92,7 @@ { \ public: \ T (QWidget *xparent) : B (xparent), GenericEventNotifySender () { } \ - ~ T (void) = default; \ + ~ T () = default; \ \ bool event (QEvent *evt) \ { \ diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/KeyMap.cc --- a/libgui/graphics/KeyMap.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/KeyMap.cc Tue Jan 24 17:19:44 2023 -0800 @@ -36,7 +36,7 @@ namespace KeyMap { - QMap makeKeyMapper (void) + QMap makeKeyMapper () { QMap keyMapper; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/ListBoxControl.cc --- a/libgui/graphics/ListBoxControl.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/ListBoxControl.cc Tue Jan 24 17:19:44 2023 -0800 @@ -127,7 +127,7 @@ this, &ListBoxControl::itemPressed); } - ListBoxControl::~ListBoxControl (void) + ListBoxControl::~ListBoxControl () { } void @@ -197,7 +197,7 @@ } void - ListBoxControl::itemSelectionChanged (void) + ListBoxControl::itemSelectionChanged () { if (! m_blockCallback) m_selectionChanged = true; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/ListBoxControl.h --- a/libgui/graphics/ListBoxControl.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/ListBoxControl.h Tue Jan 24 17:19:44 2023 -0800 @@ -43,7 +43,7 @@ public: ListBoxControl (octave::interpreter& interp, const graphics_object& go, QListWidget *list); - ~ListBoxControl (void); + ~ListBoxControl (); static ListBoxControl * create (octave::interpreter& interp, @@ -55,7 +55,7 @@ void sendSelectionChange (); private slots: - void itemSelectionChanged (void); + void itemSelectionChanged (); void itemActivated (const QModelIndex&); void itemPressed (QListWidgetItem *); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/Logger.cc --- a/libgui/graphics/Logger.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/Logger.cc Tue Jan 24 17:19:44 2023 -0800 @@ -40,7 +40,7 @@ Logger *Logger::s_instance = nullptr; QMutex *Logger::s_mutex = nullptr; -Logger::Logger (void) +Logger::Logger () : m_debugEnabled (false) { QProcessEnvironment pe (QProcessEnvironment::systemEnvironment ()); @@ -49,11 +49,11 @@ m_debugEnabled = true; } -Logger::~Logger (void) +Logger::~Logger () { } Logger * -Logger::instance (void) +Logger::instance () { if (! s_instance) { diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/Logger.h --- a/libgui/graphics/Logger.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/Logger.h Tue Jan 24 17:19:44 2023 -0800 @@ -44,10 +44,10 @@ static QMutex *s_mutex; private: - Logger (void); - ~Logger (void); + Logger (); + ~Logger (); - static Logger * instance (void); + static Logger * instance (); void debugV (const char *fmt, va_list arg); }; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/Menu.cc --- a/libgui/graphics/Menu.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/Menu.cc Tue Jan 24 17:19:44 2023 -0800 @@ -161,7 +161,7 @@ connect (action, &QAction::triggered, this, &Menu::actionTriggered); } - Menu::~Menu (void) + Menu::~Menu () { } void @@ -268,7 +268,7 @@ } QWidget * - Menu::menu (void) + Menu::menu () { QAction *action = qWidget (); QMenu *action_menu = action->menu (); @@ -285,7 +285,7 @@ } void - Menu::actionTriggered (void) + Menu::actionTriggered () { QAction *action = qWidget (); @@ -295,13 +295,13 @@ } void - Menu::actionHovered (void) + Menu::actionHovered () { emit gh_callback_event (m_handle, "menuselectedfcn"); } void - Menu::updateSiblingPositions (void) + Menu::updateSiblingPositions () { if (m_parent) { diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/Menu.h --- a/libgui/graphics/Menu.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/Menu.h Tue Jan 24 17:19:44 2023 -0800 @@ -44,25 +44,25 @@ public: Menu (octave::interpreter& interp, const graphics_object& go, QAction *action, Object *parent); - ~Menu (void); + ~Menu (); static Menu * create (octave::interpreter& interp, const graphics_object& go); - Container * innerContainer (void) { return nullptr; } + Container * innerContainer () { return nullptr; } - QWidget * menu (void); + QWidget * menu (); protected: void update (int pId); private slots: - void actionTriggered (void); - void actionHovered (void); + void actionTriggered (); + void actionHovered (); private: - void updateSiblingPositions (void); + void updateSiblingPositions (); private: QWidget *m_parent; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/MenuContainer.h --- a/libgui/graphics/MenuContainer.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/MenuContainer.h Tue Jan 24 17:19:44 2023 -0800 @@ -33,7 +33,7 @@ class MenuContainer { public: - virtual QWidget * menu (void) = 0; + virtual QWidget * menu () = 0; }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/Object.cc --- a/libgui/graphics/Object.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/Object.cc Tue Jan 24 17:19:44 2023 -0800 @@ -74,11 +74,11 @@ } } - Object::~Object (void) + Object::~Object () { } graphics_object - Object::object (void) const + Object::object () const { gh_manager& gh_mgr = m_interpreter.get_gh_manager (); @@ -116,7 +116,7 @@ } void - Object::slotFinalize (void) + Object::slotFinalize () { gh_manager& gh_mgr = m_interpreter.get_gh_manager (); @@ -126,7 +126,7 @@ } void - Object::slotRedraw (void) + Object::slotRedraw () { gh_manager& gh_mgr = m_interpreter.get_gh_manager (); @@ -137,7 +137,7 @@ } void - Object::slotShow (void) + Object::slotShow () { gh_manager& gh_mgr = m_interpreter.get_gh_manager (); @@ -163,7 +163,7 @@ { } void - Object::finalize (void) + Object::finalize () { if (m_qobject) { @@ -174,11 +174,11 @@ } void - Object::redraw (void) + Object::redraw () { } void - Object::show (void) + Object::show () { } void @@ -186,7 +186,7 @@ { } void - Object::beingDeleted (void) + Object::beingDeleted () { } void Object::objectDestroyed (QObject *obj) diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/Object.h --- a/libgui/graphics/Object.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/Object.h Tue Jan 24 17:19:44 2023 -0800 @@ -50,36 +50,36 @@ Object (octave::interpreter& interp, const graphics_object& go, QObject *obj = nullptr); - virtual ~Object (void); + virtual ~Object (); - base_properties& properties (void) + base_properties& properties () { return object ().get_properties (); } - const base_properties& properties (void) const + const base_properties& properties () const { return object ().get_properties (); } template - typename T::properties& properties (void) + typename T::properties& properties () { return dynamic_cast (object ().get_properties ()); } template - const typename T::properties& properties (void) const + const typename T::properties& properties () const { return dynamic_cast (object ().get_properties ()); } - graphics_object object (void) const; + graphics_object object () const; - virtual QObject * qObject (void) { return m_qobject; } + virtual QObject * qObject () { return m_qobject; } template - T * qWidget (void) { return qobject_cast(qObject ()); } + T * qWidget () { return qobject_cast(qObject ()); } - virtual Container * innerContainer (void) = 0; + virtual Container * innerContainer () = 0; static Object * fromQObject (QObject *obj); @@ -108,9 +108,9 @@ public slots: void slotUpdate (int pId); - void slotFinalize (void); - void slotRedraw (void); - void slotShow (void); + void slotFinalize (); + void slotRedraw (); + void slotShow (); void slotPrint (const QString& file_cmd, const QString& term); void objectDestroyed (QObject *obj = nullptr); @@ -122,12 +122,12 @@ void init (QObject *obj, bool callBase = false); virtual void update (int pId); - virtual void finalize (void); - virtual void redraw (void); - virtual void show (void); + virtual void finalize (); + virtual void redraw (); + virtual void show (); virtual void print (const QString& file_cmd, const QString& term); - virtual void beingDeleted (void); + virtual void beingDeleted (); protected: diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/ObjectProxy.cc --- a/libgui/graphics/ObjectProxy.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/ObjectProxy.cc Tue Jan 24 17:19:44 2023 -0800 @@ -91,7 +91,7 @@ } void -ObjectProxy::finalize (void) +ObjectProxy::finalize () { if (! m_object) error ("ObjectProxy::finalize: invalid GUI Object"); @@ -106,13 +106,13 @@ } void -ObjectProxy::redraw (void) +ObjectProxy::redraw () { emit sendRedraw (); } void -ObjectProxy::show (void) +ObjectProxy::show () { emit sendShow (); } @@ -135,7 +135,7 @@ } uint8NDArray -ObjectProxy::get_pixels (void) +ObjectProxy::get_pixels () { if (! m_object) error ("ObjectProxy::finalize: invalid GUI Object"); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/ObjectProxy.h --- a/libgui/graphics/ObjectProxy.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/ObjectProxy.h Tue Jan 24 17:19:44 2023 -0800 @@ -44,19 +44,19 @@ ObjectProxy (Object *obj = nullptr); void update (int pId); - void finalize (void); - void redraw (void); - void show (void); + void finalize (); + void redraw (); + void show (); void print (const QString& file_cmd, const QString& term); - uint8NDArray get_pixels (void); + uint8NDArray get_pixels (); - Object * object (void) { return m_object; } + Object * object () { return m_object; } void setObject (Object *obj); signals: void sendUpdate (int pId); - void sendRedraw (void); - void sendShow (void); + void sendRedraw (); + void sendShow (); private: void init (Object *obj); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/Panel.cc --- a/libgui/graphics/Panel.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/Panel.cc Tue Jan 24 17:19:44 2023 -0800 @@ -166,7 +166,7 @@ frame->hide (); } - Panel::~Panel (void) + Panel::~Panel () { } bool @@ -366,7 +366,7 @@ } void - Panel::redraw (void) + Panel::redraw () { update (uipanel::properties::ID_POSITION); @@ -377,7 +377,7 @@ } void - Panel::updateLayout (void) + Panel::updateLayout () { uipanel::properties& pp = properties (); QFrame *frame = qWidget (); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/Panel.h --- a/libgui/graphics/Panel.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/Panel.h Tue Jan 24 17:19:44 2023 -0800 @@ -42,9 +42,9 @@ public: Panel (octave::interpreter& interp, const graphics_object& go, QFrame *frame); - ~Panel (void); + ~Panel (); - Container * innerContainer (void) { return m_container; } + Container * innerContainer () { return m_container; } bool eventFilter (QObject *watched, QEvent *event); @@ -57,10 +57,10 @@ protected: void update (int pId); - void redraw (void); + void redraw (); private: - void updateLayout (void); + void updateLayout (); private: Container *m_container; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/PopupMenuControl.cc --- a/libgui/graphics/PopupMenuControl.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/PopupMenuControl.cc Tue Jan 24 17:19:44 2023 -0800 @@ -68,7 +68,7 @@ this, &PopupMenuControl::currentIndexChanged); } - PopupMenuControl::~PopupMenuControl (void) + PopupMenuControl::~PopupMenuControl () { } void PopupMenuControl::update (int pId) diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/PopupMenuControl.h --- a/libgui/graphics/PopupMenuControl.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/PopupMenuControl.h Tue Jan 24 17:19:44 2023 -0800 @@ -41,7 +41,7 @@ public: PopupMenuControl (octave::interpreter& interp, const graphics_object& go, QComboBox *box); - ~PopupMenuControl (void); + ~PopupMenuControl (); static PopupMenuControl * create (octave::interpreter& interp, diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/PushButtonControl.cc --- a/libgui/graphics/PushButtonControl.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/PushButtonControl.cc Tue Jan 24 17:19:44 2023 -0800 @@ -69,7 +69,7 @@ btn->setIconSize (QSize (cdat.columns (), cdat.rows ())); } - PushButtonControl::~PushButtonControl (void) + PushButtonControl::~PushButtonControl () { } void diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/PushButtonControl.h --- a/libgui/graphics/PushButtonControl.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/PushButtonControl.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,7 +39,7 @@ public: PushButtonControl (octave::interpreter& interp, const graphics_object& go, QPushButton *btn); - ~PushButtonControl (void); + ~PushButtonControl (); static PushButtonControl * create (octave::interpreter& interp, diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/PushTool.cc --- a/libgui/graphics/PushTool.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/PushTool.cc Tue Jan 24 17:19:44 2023 -0800 @@ -57,7 +57,7 @@ connect (action, &QAction::triggered, this, &PushTool::clicked); } - PushTool::~PushTool (void) + PushTool::~PushTool () { } void @@ -72,7 +72,7 @@ } void - PushTool::clicked (void) + PushTool::clicked () { emit gh_callback_event (m_handle, "clickedcallback"); } diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/PushTool.h --- a/libgui/graphics/PushTool.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/PushTool.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,7 +39,7 @@ public: PushTool (octave::interpreter& interp, const graphics_object& go, QAction *action); - ~PushTool (void); + ~PushTool (); static PushTool * create (octave::interpreter& interp, @@ -49,7 +49,7 @@ void update (int pId); private slots: - void clicked (void); + void clicked (); }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/RadioButtonControl.cc --- a/libgui/graphics/RadioButtonControl.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/RadioButtonControl.cc Tue Jan 24 17:19:44 2023 -0800 @@ -72,7 +72,7 @@ radio->setCheckable (false); } - RadioButtonControl::~RadioButtonControl (void) + RadioButtonControl::~RadioButtonControl () { } void diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/RadioButtonControl.h --- a/libgui/graphics/RadioButtonControl.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/RadioButtonControl.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,7 +39,7 @@ public: RadioButtonControl (octave::interpreter& interp, const graphics_object& go, QRadioButton *box); - ~RadioButtonControl (void); + ~RadioButtonControl (); static RadioButtonControl * create (octave::interpreter& interp, const graphics_object& go); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/SliderControl.cc --- a/libgui/graphics/SliderControl.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/SliderControl.cc Tue Jan 24 17:19:44 2023 -0800 @@ -89,7 +89,7 @@ this, &SliderControl::valueChanged); } - SliderControl::~SliderControl (void) + SliderControl::~SliderControl () { } void diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/SliderControl.h --- a/libgui/graphics/SliderControl.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/SliderControl.h Tue Jan 24 17:19:44 2023 -0800 @@ -41,7 +41,7 @@ public: SliderControl (octave::interpreter& interp, const graphics_object& go, QAbstractSlider *slider); - ~SliderControl (void); + ~SliderControl (); static SliderControl * create (octave::interpreter& interp, diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/Table.cc --- a/libgui/graphics/Table.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/Table.cc Tue Jan 24 17:19:44 2023 -0800 @@ -488,7 +488,7 @@ this, &Table::itemSelectionChanged); } - Table::~Table (void) { } + Table::~Table () { } void Table::itemSelectionChanged () @@ -880,7 +880,7 @@ } void - Table::redraw (void) + Table::redraw () { update (uitable::properties::ID_POSITION); } @@ -983,7 +983,7 @@ } void - Table::updateColumnname (void) + Table::updateColumnname () { uitable::properties& tp = properties (); @@ -1079,7 +1079,7 @@ } void - Table::updateColumnwidth (void) + Table::updateColumnwidth () { uitable::properties& tp = properties (); @@ -1307,7 +1307,7 @@ } void - Table::updateEnable (void) + Table::updateEnable () { uitable::properties& tp = properties (); bool enabled = tp.is_enable (); @@ -1365,7 +1365,7 @@ } void - Table::updateExtent (void) + Table::updateExtent () { QSize s = realQSizeForTable (m_tableWidget); Matrix extent = Matrix (1, 4); @@ -1378,7 +1378,7 @@ } void - Table::updatePalette (void) + Table::updatePalette () { uitable::properties& tp = properties (); @@ -1395,7 +1395,7 @@ } void - Table::updateRowname (void) + Table::updateRowname () { uitable::properties& tp = properties (); @@ -1493,7 +1493,7 @@ } void - Table::updateRearrangeableColumns (void) + Table::updateRearrangeableColumns () { uitable::properties& tp = properties (); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/Table.h --- a/libgui/graphics/Table.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/Table.h Tue Jan 24 17:19:44 2023 -0800 @@ -45,9 +45,9 @@ public: Table (octave::interpreter& interp, const graphics_object& go, QTableWidget *tableWidget); - ~Table (void); + ~Table (); - Container * innerContainer (void) { return m_container; } + Container * innerContainer () { return m_container; } bool eventFilter (QObject *watched, QEvent *event); @@ -57,21 +57,21 @@ protected: void update (int pId); - void redraw (void); - void updateColumnname (void); - void updateColumnwidth (void); - void updateData (void); - void updateEnable (void); - void updateExtent (void); - void updatePalette (void); - void updateRearrangeableColumns (void); - void updateRowname (void); + void redraw (); + void updateColumnname (); + void updateColumnwidth (); + void updateData (); + void updateEnable (); + void updateExtent (); + void updatePalette (); + void updateRearrangeableColumns (); + void updateRowname (); private slots: void itemChanged (QTableWidgetItem *item); void comboBoxCurrentIndexChanged (const QString& value); void cellClicked (int row, int col); - void itemSelectionChanged (void); + void itemSelectionChanged (); private: Container *m_container; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/TextControl.cc --- a/libgui/graphics/TextControl.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/TextControl.cc Tue Jan 24 17:19:44 2023 -0800 @@ -65,7 +65,7 @@ label->setText (Utils::fromStringVector (up.get_string_vector ()).join ("\n")); } - TextControl::~TextControl (void) + TextControl::~TextControl () { } void diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/TextControl.h --- a/libgui/graphics/TextControl.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/TextControl.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,7 +39,7 @@ public: TextControl (octave::interpreter& interp, const graphics_object& go, QLabel *label); - ~TextControl (void); + ~TextControl (); static TextControl * create (octave::interpreter& interp, diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/TextEdit.h --- a/libgui/graphics/TextEdit.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/TextEdit.h Tue Jan 24 17:19:44 2023 -0800 @@ -36,11 +36,11 @@ public: TextEdit (QWidget *xparent) : QTextEdit (xparent) { } - ~TextEdit (void) = default; + ~TextEdit () = default; signals: - void editingFinished (void); - void returnPressed (void); + void editingFinished (); + void returnPressed (); protected: void focusOutEvent (QFocusEvent *event); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/ToggleButtonControl.cc --- a/libgui/graphics/ToggleButtonControl.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/ToggleButtonControl.cc Tue Jan 24 17:19:44 2023 -0800 @@ -75,7 +75,7 @@ btn->setIconSize (QSize (cdat.columns (), cdat.rows ())); } - ToggleButtonControl::~ToggleButtonControl (void) + ToggleButtonControl::~ToggleButtonControl () { } void diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/ToggleButtonControl.h --- a/libgui/graphics/ToggleButtonControl.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/ToggleButtonControl.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,7 +39,7 @@ public: ToggleButtonControl (octave::interpreter& interp, const graphics_object& go, QPushButton *box); - ~ToggleButtonControl (void); + ~ToggleButtonControl (); static ToggleButtonControl * create (octave::interpreter& interp, diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/ToggleTool.cc --- a/libgui/graphics/ToggleTool.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/ToggleTool.cc Tue Jan 24 17:19:44 2023 -0800 @@ -62,7 +62,7 @@ connect (action, &QAction::toggled, this, &ToggleTool::triggered); } - ToggleTool::~ToggleTool (void) + ToggleTool::~ToggleTool () { } void diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/ToggleTool.h --- a/libgui/graphics/ToggleTool.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/ToggleTool.h Tue Jan 24 17:19:44 2023 -0800 @@ -40,7 +40,7 @@ ToggleTool (octave::interpreter& interp, const graphics_object& go, QAction *action); - ~ToggleTool (void); + ~ToggleTool (); static ToggleTool * create (octave::interpreter& interp, diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/ToolBar.cc --- a/libgui/graphics/ToolBar.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/ToolBar.cc Tue Jan 24 17:19:44 2023 -0800 @@ -45,7 +45,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) - static QIcon makeEmptyIcon (void) + static QIcon makeEmptyIcon () { QPixmap pix (16, 16); @@ -108,7 +108,7 @@ bar->installEventFilter (this); } - ToolBar::~ToolBar (void) + ToolBar::~ToolBar () { } void @@ -168,13 +168,13 @@ } void - ToolBar::hideEmpty (void) + ToolBar::hideEmpty () { m_empty->setVisible (false); } void - ToolBar::beingDeleted (void) + ToolBar::beingDeleted () { if (m_figure) { diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/ToolBar.h --- a/libgui/graphics/ToolBar.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/ToolBar.h Tue Jan 24 17:19:44 2023 -0800 @@ -44,22 +44,22 @@ public: ToolBar (octave::interpreter& interp, const graphics_object& go, QToolBar *bar); - ~ToolBar (void); + ~ToolBar (); static ToolBar * create (octave::interpreter& interp, const graphics_object& go); - Container * innerContainer (void) { return nullptr; } + Container * innerContainer () { return nullptr; } bool eventFilter (QObject *watched, QEvent *event); protected: void update (int pId); - void beingDeleted (void); + void beingDeleted (); private slots: - void hideEmpty (void); + void hideEmpty (); private: QAction *m_empty; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/ToolBarButton.cc --- a/libgui/graphics/ToolBarButton.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/ToolBarButton.cc Tue Jan 24 17:19:44 2023 -0800 @@ -79,7 +79,7 @@ } template - ToolBarButton::~ToolBarButton (void) + ToolBarButton::~ToolBarButton () { } template diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/ToolBarButton.h --- a/libgui/graphics/ToolBarButton.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/ToolBarButton.h Tue Jan 24 17:19:44 2023 -0800 @@ -43,9 +43,9 @@ public: ToolBarButton (octave::interpreter& interp, const graphics_object& go, QAction *action); - ~ToolBarButton (void); + ~ToolBarButton (); - Container * innerContainer (void) { return nullptr; } + Container * innerContainer () { return nullptr; } protected: void update (int pId); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/gl-select.cc --- a/libgui/graphics/gl-select.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/gl-select.cc Tue Jan 24 17:19:44 2023 -0800 @@ -32,7 +32,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) void -opengl_selector::apply_pick_matrix (void) +opengl_selector::apply_pick_matrix () { GLdouble p_matrix[16]; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/gl-select.h --- a/libgui/graphics/gl-select.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/gl-select.h Tue Jan 24 17:19:44 2023 -0800 @@ -47,7 +47,7 @@ : opengl_renderer (glfcns), size (5) { } - virtual ~opengl_selector (void) = default; + virtual ~opengl_selector () = default; graphics_object select (const graphics_object& ax, int x, int y, int flags = 0); @@ -68,7 +68,7 @@ int halign, int valign, double rotation = 0.0); private: - void apply_pick_matrix (void); + void apply_pick_matrix (); void fake_text (double x, double y, double z, const Matrix& bbox, bool use_scale = true); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/qopengl-functions.h --- a/libgui/graphics/qopengl-functions.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/qopengl-functions.h Tue Jan 24 17:19:44 2023 -0800 @@ -42,7 +42,7 @@ { public: - qopengl_functions (void) + qopengl_functions () #if defined (HAVE_QOPENGLFUNCTIONS_1_1) : m_glfcns () #endif @@ -52,9 +52,9 @@ qopengl_functions& operator = (const qopengl_functions&) = default; - ~qopengl_functions (void) = default; + ~qopengl_functions () = default; - void init (void) + void init () { #if defined (HAVE_QOPENGLFUNCTIONS_1_1) m_glfcns.initializeOpenGLFunctions (); @@ -176,17 +176,17 @@ m_glfcns.glEnable (cap); } - void glEndList (void) + void glEndList () { m_glfcns.glEndList (); } - void glEnd (void) + void glEnd () { m_glfcns.glEnd (); } - void glFinish (void) + void glFinish () { m_glfcns.glFinish (); } @@ -211,7 +211,7 @@ m_glfcns.glGetDoublev (pname, data); } - GLenum glGetError (void) + GLenum glGetError () { return m_glfcns.glGetError (); } @@ -236,7 +236,7 @@ m_glfcns.glHint (target, mode); } - void glInitNames (void) + void glInitNames () { m_glfcns.glInitNames (); } @@ -261,7 +261,7 @@ m_glfcns.glLineWidth (width); } - void glLoadIdentity (void) + void glLoadIdentity () { m_glfcns.glLoadIdentity (); } @@ -327,17 +327,17 @@ m_glfcns.glPolygonOffset (factor, units); } - void glPopAttrib (void) + void glPopAttrib () { m_glfcns.glPopAttrib (); } - void glPopMatrix (void) + void glPopMatrix () { m_glfcns.glPopMatrix (); } - void glPopName (void) + void glPopName () { m_glfcns.glPopName (); } @@ -347,7 +347,7 @@ m_glfcns.glPushAttrib (mask); } - void glPushMatrix (void) + void glPushMatrix () { m_glfcns.glPushMatrix (); } diff -r 1d1eff97670e -r 21f9b34eb893 libgui/graphics/qt-graphics-toolkit.h --- a/libgui/graphics/qt-graphics-toolkit.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/graphics/qt-graphics-toolkit.h Tue Jan 24 17:19:44 2023 -0800 @@ -47,7 +47,7 @@ qt_graphics_toolkit (octave::interpreter& interp); - ~qt_graphics_toolkit (void) = default; + ~qt_graphics_toolkit () = default; // The interpreter may call graphics toolkit functions that we // implement here. The Qt GUI that manages these actions runs in a @@ -64,7 +64,7 @@ // we should ensure that they are correctly handling the connection // between the interpreter and GUI threads. - bool is_valid (void) const { return true; } + bool is_valid () const { return true; } void redraw_figure (const graphics_object& h) const; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/languages/build_ts/octave-qt/qdialog.cpp --- a/libgui/languages/build_ts/octave-qt/qdialog.cpp Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/languages/build_ts/octave-qt/qdialog.cpp Tue Jan 24 17:19:44 2023 -0800 @@ -559,7 +559,7 @@ QEventLoop eventLoop; d->eventLoop = &eventLoop; QPointer guard = this; - (void) eventLoop.exec(QEventLoop::DialogExec); + () eventLoop.exec(QEventLoop::DialogExec); if (guard.isNull()) return QDialog::Rejected; d->eventLoop = 0; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/languages/build_ts/octave-qt/qfontdialog.cpp --- a/libgui/languages/build_ts/octave-qt/qfontdialog.cpp Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/languages/build_ts/octave-qt/qfontdialog.cpp Tue Jan 24 17:19:44 2023 -0800 @@ -463,7 +463,7 @@ k->key() == Qt::Key_PageDown)) { int ci = d->sizeList->currentItem(); - (void)QApplication::sendEvent(d->sizeList, k); + ()QApplication::sendEvent(d->sizeList, k); if (ci != d->sizeList->currentItem() && style()->styleHint(QStyle::SH_FontDialog_SelectAssociatedText, 0, this)) diff -r 1d1eff97670e -r 21f9b34eb893 libgui/languages/build_ts/octave-qt/qprintdialog_win.cpp --- a/libgui/languages/build_ts/octave-qt/qprintdialog_win.cpp Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/languages/build_ts/octave-qt/qprintdialog_win.cpp Tue Jan 24 17:19:44 2023 -0800 @@ -307,7 +307,7 @@ if (!warnIfNotNative(d->printer)) return; - (void)d->openWindowsPrintDialogModally(); + ()d->openWindowsPrintDialogModally(); return; } diff -r 1d1eff97670e -r 21f9b34eb893 libgui/liboctgui-build-info.h --- a/libgui/liboctgui-build-info.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/liboctgui-build-info.h Tue Jan 24 17:19:44 2023 -0800 @@ -30,6 +30,6 @@ #include -extern OCTGUI_API std::string liboctgui_hg_id (void); +extern OCTGUI_API std::string liboctgui_hg_id (); #endif diff -r 1d1eff97670e -r 21f9b34eb893 libgui/liboctgui-build-info.in.cc --- a/libgui/liboctgui-build-info.in.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/liboctgui-build-info.in.cc Tue Jan 24 17:19:44 2023 -0800 @@ -32,7 +32,7 @@ #include "liboctgui-build-info.h" std::string -liboctgui_hg_id (void) +liboctgui_hg_id () { return "%OCTAVE_HG_ID%"; } diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/color-picker.cc --- a/libgui/src/color-picker.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/color-picker.cc Tue Jan 24 17:19:44 2023 -0800 @@ -46,7 +46,7 @@ } // Slot for button clicked: select a new color using QColorDialog -void color_picker::select_color (void) +void color_picker::select_color () { QColor new_color = QColorDialog::getColor (m_color); @@ -65,7 +65,7 @@ } // Draw the button with the actual color (using a stylesheet) -void color_picker::update_button (void) +void color_picker::update_button () { // Is this the right place to look for a "foreground" color that would // provide a reasonable border for the color swatches? diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/color-picker.h --- a/libgui/src/color-picker.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/color-picker.h Tue Jan 24 17:19:44 2023 -0800 @@ -42,17 +42,17 @@ color_picker (QColor color = QColor (0, 0, 0), QWidget *parent = nullptr); - QColor color (void) const { return m_color; } + QColor color () const { return m_color; } void set_color (QColor new_color); private slots: - void select_color (void); + void select_color (); private: - virtual void update_button (void); + virtual void update_button (); QColor m_color; }; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/command-widget.cc --- a/libgui/src/command-widget.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/command-widget.cc Tue Jan 24 17:19:44 2023 -0800 @@ -180,7 +180,7 @@ } - void command_widget::notice_settings (void) + void command_widget::notice_settings () { gui_settings settings; @@ -223,11 +223,11 @@ connect (this, SIGNAL (cursorPositionChanged (int, int)), this, SLOT (cursor_position_changed (int, int))); - connect (this, SIGNAL (textChanged (void)), - this, SLOT (text_changed (void))); + connect (this, SIGNAL (textChanged ()), + this, SLOT (text_changed ())); - connect (this, SIGNAL (modificationAttempted (void)), - this, SLOT (move_cursor_to_end (void))); + connect (this, SIGNAL (modificationAttempted ()), + this, SLOT (move_cursor_to_end ())); } // Prepare a new command line with the current prompt @@ -308,7 +308,7 @@ // User attempted to type on read only mode: move cursor at end and allow // editing - void console::move_cursor_to_end (void) + void console::move_cursor_to_end () { if ((! m_last_key_string.isEmpty ()) && (m_last_key_string.at (0).isPrint ())) { @@ -319,7 +319,7 @@ // Text has changed: is cursor still in "writable" area? // This signal seems to be emitted before cursor position changed. - void console::text_changed (void) + void console::text_changed () { m_text_changed = true; } diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/command-widget.h --- a/libgui/src/command-widget.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/command-widget.h Tue Jan 24 17:19:44 2023 -0800 @@ -59,9 +59,9 @@ void cursor_position_changed (int line, int col); - void text_changed (void); + void text_changed (); - void move_cursor_to_end (void); + void move_cursor_to_end (); void new_command_line (const QString& command = QString ()); @@ -75,7 +75,7 @@ void append_string (const QString& string); - void accept_command_line (void); + void accept_command_line (); int m_command_position; int m_cursor_position; @@ -97,15 +97,15 @@ void init_command_prompt (); - QString prompt (void); + QString prompt (); signals: - void clear_line_edit (void); + void clear_line_edit (); - void interpreter_pause (void); - void interpreter_resume (void); - void interpreter_stop (void); + void interpreter_pause (); + void interpreter_resume (); + void interpreter_stop (); void update_prompt_signal (const QString& prompt); void new_command_line_signal (const QString& command = QString ()); @@ -121,7 +121,7 @@ void insert_interpreter_output (const QString& msg); - void notice_settings (void); + void notice_settings (); private: diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/community-news.cc --- a/libgui/src/community-news.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/community-news.cc Tue Jan 24 17:19:44 2023 -0800 @@ -119,7 +119,7 @@ m_browser->setHtml (news); } - void community_news::display (void) + void community_news::display () { if (! isVisible ()) show (); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/community-news.h --- a/libgui/src/community-news.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/community-news.h Tue Jan 24 17:19:44 2023 -0800 @@ -46,13 +46,13 @@ const QString& page = "community-news.html", int serial = -1); - ~community_news (void) = default; + ~community_news () = default; public slots: void set_news (const QString& news); - void display (void); + void display (); private: diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/dialog.cc --- a/libgui/src/dialog.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/dialog.cc Tue Jan 24 17:19:44 2023 -0800 @@ -484,7 +484,7 @@ this, &ListDialog::item_double_clicked); } - void ListDialog::buttonOk_clicked (void) + void ListDialog::buttonOk_clicked () { // Store information about what button was pressed so that builtin // functions can retrieve. @@ -500,7 +500,7 @@ done (QDialog::Accepted); } - void ListDialog::buttonCancel_clicked (void) + void ListDialog::buttonCancel_clicked () { // Store information about what button was pressed so that builtin // functions can retrieve. @@ -512,7 +512,7 @@ done (QDialog::Rejected); } - void ListDialog::reject (void) + void ListDialog::reject () { buttonCancel_clicked (); } @@ -589,7 +589,7 @@ this, &InputDialog::buttonCancel_clicked); } - void InputDialog::buttonOk_clicked (void) + void InputDialog::buttonOk_clicked () { // Store information about what button was pressed so that builtin // functions can retrieve. @@ -601,7 +601,7 @@ done (QDialog::Accepted); } - void InputDialog::buttonCancel_clicked (void) + void InputDialog::buttonCancel_clicked () { // Store information about what button was pressed so that builtin // functions can retrieve. @@ -611,7 +611,7 @@ done (QDialog::Rejected); } - void InputDialog::reject (void) + void InputDialog::reject () { buttonCancel_clicked (); } @@ -667,13 +667,13 @@ connect (this, &FileDialog::rejected, this, &FileDialog::rejectSelection); } - void FileDialog::rejectSelection (void) + void FileDialog::rejectSelection () { QStringList empty; emit finish_input (empty, "", 0); } - void FileDialog::acceptSelection (void) + void FileDialog::acceptSelection () { QStringList string_result; QString path; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/dialog.h --- a/libgui/src/dialog.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/dialog.h Tue Jan 24 17:19:44 2023 -0800 @@ -50,9 +50,9 @@ public: - QUIWidgetCreator (void); + QUIWidgetCreator (); - ~QUIWidgetCreator (void) = default; + ~QUIWidgetCreator () = default; public: @@ -62,9 +62,9 @@ const QString& icon, const QStringList& button, const QString& defbutton, const QStringList& role); - int get_dialog_result (void) { return m_dialog_result; } + int get_dialog_result () { return m_dialog_result; } - QString get_dialog_button (void) { return m_dialog_button; } + QString get_dialog_button () { return m_dialog_button; } QPair list_dialog (const QStringList& list, const QString& mode, @@ -75,24 +75,24 @@ const QString& ok_string, const QString& cancel_string); - QIntList get_list_index (void) const { return m_list_index; } + QIntList get_list_index () const { return m_list_index; } QStringList input_dialog (const QStringList& prompt, const QString& title, const QFloatList& nr, const QFloatList& nc, const QStringList& defaults); - QStringList get_string_list (void) const { return m_string_list; } + QStringList get_string_list () const { return m_string_list; } QStringList file_dialog (const QStringList& filters, const QString& title, const QString& filename, const QString& dirname, const QString& multimode); - QString get_dialog_path (void) const { return m_path_name; } + QString get_dialog_path () const { return m_path_name; } - void lock (void) { m_mutex.lock (); } - void wait (void) { m_waitcondition.wait (&m_mutex); } - void unlock (void) { m_mutex.unlock (); } - void wake_all (void) { m_waitcondition.wakeAll (); } + void lock () { m_mutex.lock (); } + void wait () { m_waitcondition.wait (&m_mutex); } + void unlock () { m_mutex.unlock (); } + void wake_all () { m_waitcondition.wakeAll (); } signals: @@ -177,7 +177,7 @@ const QStringList& button, const QString& defbutton, const QStringList& role); - ~MessageDialog (void) = default; + ~MessageDialog () = default; private: @@ -203,7 +203,7 @@ const QStringList& prompt, const QString& ok_string, const QString& cancel_string); - ~ListDialog (void) = default; + ~ListDialog () = default; signals: @@ -211,11 +211,11 @@ public slots: - void buttonOk_clicked (void); + void buttonOk_clicked (); - void buttonCancel_clicked (void); + void buttonCancel_clicked (); - void reject (void); + void reject (); void item_double_clicked (const QModelIndex&); @@ -236,7 +236,7 @@ const QString& title, const QFloatList& nr, const QFloatList& nc, const QStringList& defaults); - ~InputDialog (void) = default; + ~InputDialog () = default; signals: @@ -244,11 +244,11 @@ public slots: - void buttonOk_clicked (void); + void buttonOk_clicked (); - void buttonCancel_clicked (void); + void buttonCancel_clicked (); - void reject (void); + void reject (); }; class FileDialog : public QFileDialog @@ -261,7 +261,7 @@ const QString& title, const QString& filename, const QString& dirname, const QString& multimode); - ~FileDialog (void) = default; + ~FileDialog () = default; signals: @@ -269,9 +269,9 @@ private slots: - void acceptSelection (void); + void acceptSelection (); - void rejectSelection (void); + void rejectSelection (); }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/documentation-bookmarks.cc --- a/libgui/src/documentation-bookmarks.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/documentation-bookmarks.cc Tue Jan 24 17:19:44 2023 -0800 @@ -154,7 +154,7 @@ } // Slot for adding the current page as a bookmark - void documentation_bookmarks::add_bookmark (void) + void documentation_bookmarks::add_bookmark () { QUrl url = m_browser->historyUrl (0); @@ -282,7 +282,7 @@ filter_bookmarks (pattern); } - void documentation_bookmarks::update_filter_history (void) + void documentation_bookmarks::update_filter_history () { QString text = m_filter->currentText (); // get current text int index = m_filter->findText (text); // and its actual index @@ -378,7 +378,7 @@ m_filter_widget->setVisible (m_filter_shown); } - void documentation_bookmarks::save_settings (void) + void documentation_bookmarks::save_settings () { // Write the bookmarks to the xbel-file write_bookmarks (); @@ -397,7 +397,7 @@ settings.sync (); } - void documentation_bookmarks::write_bookmarks (void) + void documentation_bookmarks::write_bookmarks () { if (! m_xbel_file.open (QFile::WriteOnly | QFile::Text)) { @@ -450,7 +450,7 @@ } } - QString documentation_bookmarks::read_bookmarks (void) + QString documentation_bookmarks::read_bookmarks () { QString error_message; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/documentation-bookmarks.h --- a/libgui/src/documentation-bookmarks.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/documentation-bookmarks.h Tue Jan 24 17:19:44 2023 -0800 @@ -48,19 +48,19 @@ documentation_browser *browser, QWidget *p = nullptr); - ~documentation_bookmarks (void) = default; + ~documentation_bookmarks () = default; public slots: - void add_bookmark (void); + void add_bookmark (); void add_folder (bool); - void save_settings (void); + void save_settings (); private slots: void filter_bookmarks (const QString& pattern); void filter_activate (bool state); - void update_filter_history (void); + void update_filter_history (); void handle_double_click (QTreeWidgetItem *item, int col = 0); void ctx_menu (const QPoint& xpos); void open (bool); @@ -92,10 +92,10 @@ proposed in the qt example [QXmlStream Bookmarks Example](https://doc.qt.io/qt-5/qtxml-streambookmarks-example.html) */ - void write_bookmarks (void); + void write_bookmarks (); void write_tree_item (QXmlStreamWriter *xml_writer, const QTreeWidgetItem *item); - QString read_bookmarks (void); + QString read_bookmarks (); void read_next_item (QXmlStreamReader *xml_writer, item_tag tag, QTreeWidgetItem *item = nullptr); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/documentation-dock-widget.cc --- a/libgui/src/documentation-dock-widget.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/documentation-dock-widget.cc Tue Jan 24 17:19:44 2023 -0800 @@ -46,28 +46,28 @@ make_window (); } - void documentation_dock_widget::notice_settings (void) + void documentation_dock_widget::notice_settings () { m_docs->notice_settings (); } - void documentation_dock_widget::save_settings (void) + void documentation_dock_widget::save_settings () { m_docs->save_settings (); octave_dock_widget::save_settings (); } - void documentation_dock_widget::copyClipboard (void) + void documentation_dock_widget::copyClipboard () { m_docs->copyClipboard (); } - void documentation_dock_widget::pasteClipboard (void) + void documentation_dock_widget::pasteClipboard () { m_docs->pasteClipboard (); } - void documentation_dock_widget::selectAll (void) + void documentation_dock_widget::selectAll () { m_docs->selectAll (); } diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/documentation-dock-widget.h --- a/libgui/src/documentation-dock-widget.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/documentation-dock-widget.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,16 +39,16 @@ documentation_dock_widget (QWidget *parent); - ~documentation_dock_widget (void) = default; + ~documentation_dock_widget () = default; public slots: - void notice_settings (void); - void save_settings (void); + void notice_settings (); + void save_settings (); - void copyClipboard (void); - void pasteClipboard (void); - void selectAll (void); + void copyClipboard (); + void pasteClipboard (); + void selectAll (); void showDoc (const QString& name); void registerDoc (const QString& name); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/documentation.cc --- a/libgui/src/documentation.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/documentation.cc Tue Jan 24 17:19:44 2023 -0800 @@ -302,7 +302,7 @@ } } - documentation::~documentation (void) + documentation::~documentation () { // Cleanup temporary file and directory QFile file (m_collection); @@ -347,18 +347,18 @@ return a; } - void documentation::construct_tool_bar (void) + void documentation::construct_tool_bar () { // Home, Previous, Next gui_settings settings; m_action_go_home - = add_action (settings.icon ("go-home"), tr ("Go home"), SLOT (home (void)), + = add_action (settings.icon ("go-home"), tr ("Go home"), SLOT (home ()), m_doc_browser, m_tool_bar); m_action_go_prev = add_action (settings.icon ("go-previous"), tr ("Go back"), - SLOT (backward (void)), m_doc_browser, m_tool_bar); + SLOT (backward ()), m_doc_browser, m_tool_bar); m_action_go_prev->setEnabled (false); // popdown menu with prev pages files @@ -373,7 +373,7 @@ m_action_go_next = add_action (settings.icon ("go-next"), tr ("Go forward"), - SLOT (forward (void)), m_doc_browser, m_tool_bar); + SLOT (forward ()), m_doc_browser, m_tool_bar); m_action_go_next->setEnabled (false); // popdown menu with prev pages files @@ -416,19 +416,19 @@ m_tool_bar->addSeparator (); m_action_find = add_action (settings.icon ("edit-find"), tr ("Find"), - SLOT (activate_find (void)), this, m_tool_bar); + SLOT (activate_find ()), this, m_tool_bar); // Zoom m_tool_bar->addSeparator (); m_action_zoom_in = add_action (settings.icon ("view-zoom-in"), tr ("Zoom in"), - SLOT (zoom_in (void)), m_doc_browser, m_tool_bar); + SLOT (zoom_in ()), m_doc_browser, m_tool_bar); m_action_zoom_out = add_action (settings.icon ("view-zoom-out"), tr ("Zoom out"), - SLOT (zoom_out (void)), m_doc_browser, m_tool_bar); + SLOT (zoom_out ()), m_doc_browser, m_tool_bar); m_action_zoom_original = add_action (settings.icon ("view-zoom-original"), tr ("Zoom original"), - SLOT (zoom_original (void)), m_doc_browser, m_tool_bar); + SLOT (zoom_original ()), m_doc_browser, m_tool_bar); // Bookmarks (connect slots later) m_tool_bar->addSeparator (); @@ -437,7 +437,7 @@ tr ("Bookmark current page"), nullptr, nullptr, m_tool_bar); } - void documentation::global_search (void) + void documentation::global_search () { if (! m_help_engine) return; @@ -474,7 +474,7 @@ m_help_engine->searchEngine ()->search (queries); } - void documentation::global_search_started (void) + void documentation::global_search_started () { qApp->setOverrideCursor(QCursor(Qt::WaitCursor)); } @@ -606,7 +606,7 @@ m_doc_browser->moveCursor (QTextCursor::Start); } - void documentation::notice_settings (void) + void documentation::notice_settings () { gui_settings settings; @@ -639,7 +639,7 @@ m_doc_browser->notice_settings (); } - void documentation::save_settings (void) + void documentation::save_settings () { gui_settings settings; @@ -647,7 +647,7 @@ m_bookmarks->save_settings (); } - void documentation::copyClipboard (void) + void documentation::copyClipboard () { if (m_doc_browser->hasFocus ()) { @@ -655,11 +655,11 @@ } } - void documentation::pasteClipboard (void) { } + void documentation::pasteClipboard () { } - void documentation::selectAll (void) { } + void documentation::selectAll () { } - void documentation::load_index (void) + void documentation::load_index () { m_indexed = true; @@ -739,7 +739,7 @@ } } - void documentation::activate_find (void) + void documentation::activate_find () { if (m_find_line_edit->parentWidget ()->isVisible ()) { @@ -766,7 +766,7 @@ m_help_engine->indexWidget ()->filterIndices(expression, wildcard); } - void documentation::filter_update_history (void) + void documentation::filter_update_history () { QString text = m_filter->currentText (); // get current text int index = m_filter->findText (text); // and its actual index @@ -778,7 +778,7 @@ m_filter->setCurrentIndex (0); } - void documentation::find_backward (void) + void documentation::find_backward () { find (true); } @@ -826,7 +826,7 @@ } } - void documentation::record_anchor_position (void) + void documentation::record_anchor_position () { if (! m_help_engine) return; @@ -834,7 +834,7 @@ m_search_anchor_position = m_doc_browser->textCursor ().position (); } - void documentation::handle_cursor_position_change (void) + void documentation::handle_cursor_position_change () { if (! m_help_engine) return; @@ -887,7 +887,7 @@ } } - void documentation::update_history_menus (void) + void documentation::update_history_menus () { if (m_prev_pages_count != m_doc_browser->backwardHistoryCount ()) { @@ -1041,7 +1041,7 @@ QDesktopServices::openUrl (url); } - void documentation_browser::notice_settings (void) + void documentation_browser::notice_settings () { gui_settings settings; @@ -1061,7 +1061,7 @@ return QTextBrowser::loadResource(type, url); } - void documentation_browser::save_settings (void) + void documentation_browser::save_settings () { gui_settings settings; @@ -1070,7 +1070,7 @@ settings.sync (); } - void documentation_browser::zoom_in (void) + void documentation_browser::zoom_in () { if (m_zoom_level < max_zoom_level) { @@ -1079,7 +1079,7 @@ } } - void documentation_browser::zoom_out (void) + void documentation_browser::zoom_out () { if (m_zoom_level > min_zoom_level) { @@ -1088,7 +1088,7 @@ } } - void documentation_browser::zoom_original (void) + void documentation_browser::zoom_original () { zoomIn (- m_zoom_level); m_zoom_level = 0; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/documentation.h --- a/libgui/src/documentation.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/documentation.h Tue Jan 24 17:19:44 2023 -0800 @@ -51,7 +51,7 @@ public: documentation_browser (QHelpEngine *help_engine, QWidget *parent = nullptr); - ~documentation_browser (void) = default; + ~documentation_browser () = default; virtual QVariant loadResource (int type, const QUrl& url); @@ -59,14 +59,14 @@ void handle_index_clicked (const QUrl& url, const QString& keyword = QString ()); - void notice_settings (void); - void save_settings (void); + void notice_settings (); + void save_settings (); //! Zooming in and out while taking care of the zoom level //!@{ - void zoom_in (void); - void zoom_out (void); - void zoom_original (void); + void zoom_in (); + void zoom_out (); + void zoom_original (); //!@} protected: @@ -99,7 +99,7 @@ public: documentation (QWidget *parent); - ~documentation (void); + ~documentation (); /*! Generate a string with page name @p title and current anchor @@ -118,39 +118,39 @@ public slots: - void notice_settings (void); - void save_settings (void); + void notice_settings (); + void save_settings (); - void copyClipboard (void); - void pasteClipboard (void); - void selectAll (void); + void copyClipboard (); + void pasteClipboard (); + void selectAll (); - void load_index (void); + void load_index (); void load_ref (const QString& name = QString ()); void registerDoc (const QString& name); void unregisterDoc (const QString& name); private slots: - void activate_find (void); - void global_search (void); - void global_search_started (void); + void activate_find (); + void global_search (); + void global_search_started (); void global_search_finished (int hits); void filter_update (const QString& expression); - void filter_update_history (void); + void filter_update_history (); void find (bool backward = false); - void find_backward (void); + void find_backward (); void find_forward_from_anchor (const QString& text); - void record_anchor_position (void); - void handle_cursor_position_change (void); + void record_anchor_position (); + void handle_cursor_position_change (); void handle_search_result_clicked (const QUrl& url); - void update_history_menus (void); + void update_history_menus (); void open_hist_url (QAction *a); private: - void construct_tool_bar (void); + void construct_tool_bar (); QAction * add_action (const QIcon& icon, const QString& text, const char *member, QWidget *receiver = nullptr, QToolBar *tool_bar = nullptr); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/dw-main-window.cc --- a/libgui/src/dw-main-window.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/dw-main-window.cc Tue Jan 24 17:19:44 2023 -0800 @@ -127,7 +127,7 @@ } // Update the settings - void dw_main_window::notice_settings (void) + void dw_main_window::notice_settings () { gui_settings settings; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/dw-main-window.h --- a/libgui/src/dw-main-window.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/dw-main-window.h Tue Jan 24 17:19:44 2023 -0800 @@ -38,7 +38,7 @@ dw_main_window (QWidget *parent = nullptr); - ~dw_main_window (void) = default; + ~dw_main_window () = default; // No copying! @@ -48,7 +48,7 @@ public slots: - void notice_settings (void); + void notice_settings (); protected slots: diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/external-editor-interface.cc --- a/libgui/src/external-editor-interface.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/external-editor-interface.cc Tue Jan 24 17:19:44 2023 -0800 @@ -98,7 +98,7 @@ } // Get and verify the settings of the external editor program - QString external_editor_interface::external_editor (void) + QString external_editor_interface::external_editor () { gui_settings settings; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/external-editor-interface.h --- a/libgui/src/external-editor-interface.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/external-editor-interface.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,7 +39,7 @@ external_editor_interface (QWidget *main_win); - ~external_editor_interface (void) = default; + ~external_editor_interface () = default; signals: @@ -61,7 +61,7 @@ private: - QString external_editor (void); + QString external_editor (); }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/files-dock-widget.cc --- a/libgui/src/files-dock-widget.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/files-dock-widget.cc Tue Jan 24 17:19:44 2023 -0800 @@ -62,7 +62,7 @@ FileTreeViewer (QWidget *p) : QTreeView (p) { } - ~FileTreeViewer (void) = default; + ~FileTreeViewer () = default; void mousePressEvent (QMouseEvent *e) { @@ -425,7 +425,7 @@ make_window (); } - void files_dock_widget::save_settings (void) + void files_dock_widget::save_settings () { gui_settings settings; @@ -463,12 +463,12 @@ display_directory (dir); } - void files_dock_widget::accept_directory_line_edit (void) + void files_dock_widget::accept_directory_line_edit () { display_directory (m_current_directory->currentText ()); } - void files_dock_widget::change_directory_up (void) + void files_dock_widget::change_directory_up () { QDir dir = QDir (m_file_system_model->filePath (m_file_tree_view->rootIndex ())); @@ -477,7 +477,7 @@ display_directory (dir.absolutePath ()); } - void files_dock_widget::do_sync_octave_directory (void) + void files_dock_widget::do_sync_octave_directory () { QDir dir = QDir (m_file_system_model->filePath (m_file_tree_view->rootIndex ())); @@ -485,7 +485,7 @@ emit displayed_directory_changed (dir.absolutePath ()); } - void files_dock_widget::do_sync_browser_directory (void) + void files_dock_widget::do_sync_browser_directory () { display_directory (m_octave_dir, false); // false: no sync of octave dir } @@ -999,7 +999,7 @@ } } - void files_dock_widget::notice_settings (void) + void files_dock_widget::notice_settings () { gui_settings settings; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/files-dock-widget.h --- a/libgui/src/files-dock-widget.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/files-dock-widget.h Tue Jan 24 17:19:44 2023 -0800 @@ -56,7 +56,7 @@ files_dock_widget (QWidget *parent); - ~files_dock_widget (void) = default; + ~files_dock_widget () = default; signals: @@ -105,15 +105,15 @@ //! Slot for handling the up-directory button in the toolbar. - void change_directory_up (void); + void change_directory_up (); //! Slot for handling the sync octave directory button in the toolbar. - void do_sync_octave_directory (void); + void do_sync_octave_directory (); //! Slot for handling the sync browser directory button in the toolbar. - void do_sync_browser_directory (void); + void do_sync_browser_directory (); //! Sets the current directory being displayed. @@ -121,7 +121,7 @@ //! Accepts user input a the line edit for the current directory. - void accept_directory_line_edit (void); + void accept_directory_line_edit (); //! Set the internal variable that holds the actual octave variable. @@ -129,9 +129,9 @@ //! Tells the widget to react on changed settings. - void notice_settings (void); + void notice_settings (); - void save_settings (void); + void save_settings (); private slots: diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/find-files-dialog.cc --- a/libgui/src/find-files-dialog.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/find-files-dialog.cc Tue Jan 24 17:19:44 2023 -0800 @@ -200,12 +200,12 @@ this, &find_files_dialog::handle_done); } - find_files_dialog::~find_files_dialog (void) + find_files_dialog::~find_files_dialog () { delete m_dir_iterator; } - void find_files_dialog::save_settings (void) + void find_files_dialog::save_settings () { gui_settings settings; @@ -237,7 +237,7 @@ m_start_dir_edit->setText (dir); } - void find_files_dialog::start_find (void) + void find_files_dialog::start_find () { stop_find (); @@ -279,7 +279,7 @@ m_timer->start (0); } - void find_files_dialog::stop_find (void) + void find_files_dialog::stop_find () { m_timer->stop (); @@ -302,7 +302,7 @@ m_status_bar->showMessage (res_str); } - void find_files_dialog::browse_folders (void) + void find_files_dialog::browse_folders () { int opts = 0; // No options by default. @@ -343,7 +343,7 @@ } } - void find_files_dialog::look_for_files (void) + void find_files_dialog::look_for_files () { if (m_dir_iterator && m_dir_iterator->hasNext ()) { diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/find-files-dialog.h --- a/libgui/src/find-files-dialog.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/find-files-dialog.h Tue Jan 24 17:19:44 2023 -0800 @@ -47,9 +47,9 @@ find_files_dialog (QWidget *parent); - virtual ~find_files_dialog (void); + virtual ~find_files_dialog (); - void save_settings (void); + void save_settings (); signals: @@ -62,10 +62,10 @@ private slots: - void start_find (void); - void stop_find (void); - void browse_folders (void); - void look_for_files (void); + void start_find (); + void stop_find (); + void browse_folders (); + void look_for_files (); void item_double_clicked (const QModelIndex&); void handle_done (int); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/find-files-model.cc --- a/libgui/src/find-files-model.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/find-files-model.cc Tue Jan 24 17:19:44 2023 -0800 @@ -95,7 +95,7 @@ m_sortorder = 0; } -void find_files_model::clear (void) +void find_files_model::clear () { beginResetModel (); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/find-files-model.h --- a/libgui/src/find-files-model.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/find-files-model.h Tue Jan 24 17:19:44 2023 -0800 @@ -41,9 +41,9 @@ find_files_model (QObject *p = nullptr); - ~find_files_model (void) = default; + ~find_files_model () = default; - void clear (void); + void clear (); void addFile (const QFileInfo& info); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/gui-preferences.cc --- a/libgui/src/gui-preferences.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/gui-preferences.cc Tue Jan 24 17:19:44 2023 -0800 @@ -54,7 +54,7 @@ return s_instance->do_value (settings_key); } -QStringList all_gui_preferences::keys (void) +QStringList all_gui_preferences::keys () { ensure_instance (); @@ -73,12 +73,12 @@ return m_hash.value (settings_key); } -QStringList all_gui_preferences::do_keys (void) const +QStringList all_gui_preferences::do_keys () const { return m_hash.keys (); } -void all_gui_preferences::ensure_instance (void) +void all_gui_preferences::ensure_instance () { if (! s_instance) s_instance = new all_gui_preferences (); @@ -108,7 +108,7 @@ all_shortcut_preferences::insert (settings_key, *this); } -QKeySequence sc_pref::def_value (void) const +QKeySequence sc_pref::def_value () const { QKeySequence key_seq = QKeySequence (); @@ -120,7 +120,7 @@ return key_seq; } -QString sc_pref::def_text (void) const +QString sc_pref::def_text () const { return def_value ().toString (); } @@ -142,7 +142,7 @@ return s_instance->do_value (settings_key); } -QStringList all_shortcut_preferences::keys (void) +QStringList all_shortcut_preferences::keys () { ensure_instance (); @@ -161,12 +161,12 @@ return m_hash.value (settings_key); } -QStringList all_shortcut_preferences::do_keys (void) const +QStringList all_shortcut_preferences::do_keys () const { return m_hash.keys (); } -void all_shortcut_preferences::ensure_instance (void) +void all_shortcut_preferences::ensure_instance () { if (! s_instance) s_instance = new all_shortcut_preferences (); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/gui-preferences.h --- a/libgui/src/gui-preferences.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/gui-preferences.h Tue Jan 24 17:19:44 2023 -0800 @@ -47,7 +47,7 @@ // to create QHash objects that contain gui_pref objects. No invalid // gui_pref objects should acutally be used. - gui_pref (void) = default; + gui_pref () = default; gui_pref (const QString& settings_key, const QVariant& def, bool ignore = false); @@ -56,11 +56,11 @@ gui_pref& operator = (const gui_pref&) = default; - ~gui_pref (void) = default; + ~gui_pref () = default; - QString settings_key (void) const { return m_settings_key; } - QVariant def (void) const { return m_def; } - bool ignore (void) const { return m_ignore; } + QString settings_key () const { return m_settings_key; } + QVariant def () const { return m_def; } + bool ignore () const { return m_ignore; } private: @@ -84,7 +84,7 @@ { public: - all_gui_preferences (void) = default; + all_gui_preferences () = default; // No copying! @@ -93,13 +93,13 @@ all_gui_preferences& operator = (const all_gui_preferences&) = delete; - ~all_gui_preferences (void) = default; + ~all_gui_preferences () = default; static void insert (const QString& settings_key, const gui_pref& pref); static const gui_pref value (const QString& settings_key); - static QStringList keys (void); + static QStringList keys (); private: @@ -110,9 +110,9 @@ const gui_pref do_value (const QString& settings_key) const; - QStringList do_keys (void) const; + QStringList do_keys () const; - static void ensure_instance (void); + static void ensure_instance (); // Map from shortcut identifier (settings key) to sc_pref object. static all_gui_preferences *s_instance; @@ -130,7 +130,7 @@ // to create QHash objects that contain sc_pref objects. No invalid // sc_pref objects should acutally be used. - sc_pref (void) = default; + sc_pref () = default; sc_pref (const QString& description, const QString& settings_key, Qt::Key def); @@ -145,19 +145,19 @@ sc_pref& operator = (const sc_pref&) = default; - ~sc_pref (void) = default; + ~sc_pref () = default; - QString description (void) const { return m_description; } + QString description () const { return m_description; } - QString settings_key (void) const { return m_settings_key; } + QString settings_key () const { return m_settings_key; } - unsigned int def (void) const { return m_def; } + unsigned int def () const { return m_def; } - QKeySequence::StandardKey def_std (void) const { return m_def_std; } + QKeySequence::StandardKey def_std () const { return m_def_std; } - QKeySequence def_value (void) const; + QKeySequence def_value () const; - QString def_text (void) const; + QString def_text () const; private: @@ -184,7 +184,7 @@ { public: - all_shortcut_preferences (void) = default; + all_shortcut_preferences () = default; // No copying! @@ -193,13 +193,13 @@ all_shortcut_preferences& operator = (const all_shortcut_preferences&) = delete; - ~all_shortcut_preferences (void) = default; + ~all_shortcut_preferences () = default; static void insert (const QString& settings_key, const sc_pref& scpref); static const sc_pref value (const QString& settings_key); - static QStringList keys (void); + static QStringList keys (); private: @@ -210,9 +210,9 @@ const sc_pref do_value (const QString& settings_key) const; - QStringList do_keys (void) const; + QStringList do_keys () const; - static void ensure_instance (void); + static void ensure_instance (); // Map from shortcut identifier (settings key) to sc_pref object. static all_shortcut_preferences *s_instance; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/gui-settings.cc --- a/libgui/src/gui-settings.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/gui-settings.cc Tue Jan 24 17:19:44 2023 -0800 @@ -66,12 +66,12 @@ OCTAVE_BEGIN_NAMESPACE(octave) - QString gui_settings::file_name (void) const + QString gui_settings::file_name () const { return fileName (); } - QString gui_settings::directory_name (void) const + QString gui_settings::directory_name () const { QFileInfo sfile (fileName ()); @@ -214,7 +214,7 @@ << " not found in settings"; } - void gui_settings::config_icon_theme (void) + void gui_settings::config_icon_theme () { int theme_index; @@ -284,7 +284,7 @@ return QIcon (); } - QString gui_settings::get_default_font_family (void) + QString gui_settings::get_default_font_family () { // Get all available fixed width fonts from the Qt font database. @@ -332,7 +332,7 @@ return default_family; } - QStringList gui_settings::get_default_font (void) + QStringList gui_settings::get_default_font () { QString default_family = get_default_font_family (); @@ -362,7 +362,7 @@ return result; } - QString gui_settings::get_gui_translation_dir (void) + QString gui_settings::get_gui_translation_dir () { // get environment variable for the locale dir (e.g. from run-octave) std::string dldir = sys::env::getenv ("OCTAVE_LOCALE_DIR"); @@ -532,7 +532,7 @@ return false; } - void gui_settings::update_network_settings (void) + void gui_settings::update_network_settings () { QNetworkProxy proxy; @@ -711,7 +711,7 @@ combo->setMaxVisibleItems (12); } - void gui_settings::reload (void) + void gui_settings::reload () { // Declare some empty options, which may be set at first startup for // writing them into the newly created settings file @@ -752,7 +752,7 @@ setValue (global_mono_font.settings_key (), get_default_font_family ()); } - void gui_settings::check (void) + void gui_settings::check () { if (status () == QSettings::NoError) { diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/gui-settings.h --- a/libgui/src/gui-settings.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/gui-settings.h Tue Jan 24 17:19:44 2023 -0800 @@ -75,11 +75,11 @@ gui_settings& operator = (const gui_settings&) = delete; - ~gui_settings (void) = default; + ~gui_settings () = default; - QString file_name (void) const; + QString file_name () const; - QString directory_name (void) const; + QString directory_name () const; using QSettings::value; @@ -182,16 +182,16 @@ // QSettings object is supposed to be fast, so that may not matter. // Hmm. - void config_icon_theme (void); + void config_icon_theme (); QIcon icon (const QString& icon_name, bool octave_only = false, const QString& icon_alt_name = QString ()); - QString get_default_font_family (void); + QString get_default_font_family (); - QStringList get_default_font (void); + QStringList get_default_font (); - QString get_gui_translation_dir (void); + QString get_gui_translation_dir (); void config_translators (QTranslator *qt_tr, QTranslator *qsci_tr, QTranslator *gui_tr); @@ -203,17 +203,17 @@ bool update_settings_key (const QString& new_key, const QString& old_key); - void update_network_settings (void); + void update_network_settings (); void get_codecs (QStringList *codecs); void combo_encoding (QComboBox *combo, const QString& current = QString ()); - void reload (void); + void reload (); private: - void check (void); + void check (); }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/history-dock-widget.cc --- a/libgui/src/history-dock-widget.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/history-dock-widget.cc Tue Jan 24 17:19:44 2023 -0800 @@ -80,12 +80,12 @@ m_history_list_view->scrollToBottom (); } - void history_dock_widget::clear_history (void) + void history_dock_widget::clear_history () { m_history_model->setStringList (QStringList ()); } - void history_dock_widget::save_settings (void) + void history_dock_widget::save_settings () { gui_settings settings; @@ -102,7 +102,7 @@ octave_dock_widget::save_settings (); } - void history_dock_widget::update_filter_history (void) + void history_dock_widget::update_filter_history () { QString text = m_filter->currentText (); // get current text int index = m_filter->findText (text); // and its actual index @@ -225,7 +225,7 @@ emit command_create_script (text); } - void history_dock_widget::handle_contextmenu_filter (void) + void history_dock_widget::handle_contextmenu_filter () { m_filter_shown = ! m_filter_shown; m_filter_widget->setVisible (m_filter_shown); @@ -233,7 +233,7 @@ set_filter_focus (m_filter_shown && m_filter_checkbox->isChecked ()) ; } - void history_dock_widget::copyClipboard (void) + void history_dock_widget::copyClipboard () { if (m_history_list_view->hasFocus ()) handle_contextmenu_copy (true); @@ -245,7 +245,7 @@ } } - void history_dock_widget::pasteClipboard (void) + void history_dock_widget::pasteClipboard () { if (m_filter->lineEdit ()->hasFocus ()) { @@ -256,7 +256,7 @@ } } - void history_dock_widget::selectAll (void) + void history_dock_widget::selectAll () { if (m_filter->lineEdit ()->hasFocus ()) m_filter->lineEdit ()->selectAll (); @@ -276,7 +276,7 @@ } } - void history_dock_widget::construct (void) + void history_dock_widget::construct () { m_history_model = new QStringListModel (); m_sort_filter_proxy_model.setSourceModel (m_history_model); @@ -353,7 +353,7 @@ m_history_list_view->setTextElideMode (Qt::ElideRight); } - void history_dock_widget::notice_settings (void) + void history_dock_widget::notice_settings () { gui_settings settings; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/history-dock-widget.h --- a/libgui/src/history-dock-widget.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/history-dock-widget.h Tue Jan 24 17:19:44 2023 -0800 @@ -45,7 +45,7 @@ history_dock_widget (QWidget *parent); - ~history_dock_widget (void) = default; + ~history_dock_widget () = default; signals: @@ -63,13 +63,13 @@ void set_history (const QStringList& hist); void append_history (const QString& hist_entry); - void clear_history (void); - void save_settings (void); - void notice_settings (void); + void clear_history (); + void save_settings (); + void notice_settings (); private slots: - void update_filter_history (void); + void update_filter_history (); void filter_activate (bool enable); void ctxMenu (const QPoint& pos); @@ -77,17 +77,17 @@ void handle_contextmenu_copy (bool flag); void handle_contextmenu_evaluate (bool flag); void handle_contextmenu_create_script (bool flag); - void handle_contextmenu_filter (void); + void handle_contextmenu_filter (); - void copyClipboard (void); - void pasteClipboard (void); - void selectAll (void); + void copyClipboard (); + void pasteClipboard (); + void selectAll (); virtual void handle_visibility (bool visible); private: - void construct (void); + void construct (); void set_filter_focus (bool focus); QListView *m_history_list_view; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/interpreter-qobject.cc --- a/libgui/src/interpreter-qobject.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/interpreter-qobject.cc Tue Jan 24 17:19:44 2023 -0800 @@ -42,7 +42,7 @@ : QObject (), m_octave_qobj (oct_qobj), m_interpreter (nullptr) { } - void interpreter_qobject::execute (void) + void interpreter_qobject::execute () { // The Octave application context owns the interpreter. @@ -128,7 +128,7 @@ evmgr.post_event (meth); } - void interpreter_qobject::interrupt (void) + void interpreter_qobject::interrupt () { if (! m_interpreter) return; @@ -139,7 +139,7 @@ m_interpreter->interrupt (); } - void interpreter_qobject::pause (void) + void interpreter_qobject::pause () { // FIXME: Should we make this action work with the old terminal // widget? @@ -156,7 +156,7 @@ } } - void interpreter_qobject::stop (void) + void interpreter_qobject::stop () { // FIXME: Should we make this action work with the old terminal // widget? @@ -173,7 +173,7 @@ } } - void interpreter_qobject::resume (void) + void interpreter_qobject::resume () { // FIXME: Should we make this action work with the old terminal // widget? @@ -193,7 +193,7 @@ } } - qt_interpreter_events *interpreter_qobject::qt_link (void) + qt_interpreter_events *interpreter_qobject::qt_link () { return m_octave_qobj.qt_link (); } diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/interpreter-qobject.h --- a/libgui/src/interpreter-qobject.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/interpreter-qobject.h Tue Jan 24 17:19:44 2023 -0800 @@ -44,25 +44,25 @@ interpreter_qobject (base_qobject& oct_qobj); - ~interpreter_qobject (void) = default; + ~interpreter_qobject () = default; - qt_interpreter_events * qt_link (void); + qt_interpreter_events * qt_link (); void interpreter_event (const fcn_callback& fcn); void interpreter_event (const meth_callback& meth); - void interrupt (void); + void interrupt (); // Note: PAUSE, STOP, and RESUME are currently only used by the new // experimental terminal widget. - void pause (void); - void stop (void); - void resume (void); + void pause (); + void stop (); + void resume (); signals: - void ready (void); + void ready (); void shutdown_finished (int); @@ -88,7 +88,7 @@ //! Initialize and execute the octave interpreter. - void execute (void); + void execute (); private: diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/m-editor/file-editor-interface.h --- a/libgui/src/m-editor/file-editor-interface.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/m-editor/file-editor-interface.h Tue Jan 24 17:19:44 2023 -0800 @@ -44,16 +44,16 @@ : octave_dock_widget ("FileEditor", p) { } - virtual ~file_editor_interface (void) = default; + virtual ~file_editor_interface () = default; - virtual QMenu * get_mru_menu (void) = 0; - virtual QMenu * debug_menu (void) = 0; - virtual QToolBar * toolbar (void) = 0; - virtual QMenuBar * menubar (void) = 0; + virtual QMenu * get_mru_menu () = 0; + virtual QMenu * debug_menu () = 0; + virtual QToolBar * toolbar () = 0; + virtual QMenuBar * menubar () = 0; virtual void insert_global_actions (QList) = 0; - virtual void handle_enter_debug_mode (void) = 0; - virtual void handle_exit_debug_mode (void) = 0; + virtual void handle_enter_debug_mode () = 0; + virtual void handle_exit_debug_mode () = 0; virtual void handle_insert_debugger_pointer_request (const QString& file, int line) = 0; @@ -67,11 +67,11 @@ virtual void handle_edit_file_request (const QString& file) = 0; - virtual bool check_closing (void) = 0; + virtual bool check_closing () = 0; virtual void empty_script (bool, bool) = 0; - virtual void restore_session (void) = 0; + virtual void restore_session () = 0; virtual void enable_menu_shortcuts (bool enable) = 0; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/m-editor/file-editor-tab.cc --- a/libgui/src/m-editor/file-editor-tab.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/m-editor/file-editor-tab.cc Tue Jan 24 17:19:44 2023 -0800 @@ -274,7 +274,7 @@ m_new_encoding = m_encoding; } - file_editor_tab::~file_editor_tab (void) + file_editor_tab::~file_editor_tab () { // Tell all connected markers to self-destruct. emit remove_all_breakpoints_signal (); @@ -558,7 +558,7 @@ // not match what Octave core is interpreting in the // file on disk. This function gives the user the option // to save before creating the breakpoint. - bool file_editor_tab::unchanged_or_saved (void) + bool file_editor_tab::unchanged_or_saved () { bool retval = true; if (m_edit_area->isModified () || ! valid_file_name ()) @@ -607,7 +607,7 @@ } } - void file_editor_tab::update_lexer (void) + void file_editor_tab::update_lexer () { // Create a new lexer QsciLexer *lexer = nullptr; @@ -973,7 +973,7 @@ emit api_entries_added (); } - void file_editor_tab::handle_api_entries_added (void) + void file_editor_tab::handle_api_entries_added () { // disconnect slot for saving prepared info if already connected disconnect (m_lexer_apis, &QsciAPIs::apiPreparationFinished, @@ -990,7 +990,7 @@ m_lexer_apis->prepare (); // prepare apis info } - void file_editor_tab::save_apis_info (void) + void file_editor_tab::save_apis_info () { m_lexer_apis->savePrepared (m_prep_apis_file); } @@ -1529,7 +1529,7 @@ m_edit_area->endUndoAction (); } - void file_editor_tab::do_smart_indent_line_or_selected_text (void) + void file_editor_tab::do_smart_indent_line_or_selected_text () { m_edit_area->beginUndoAction (); @@ -1797,7 +1797,7 @@ m_edit_area->setModified (modified); } - void file_editor_tab::recover_from_exit (void) + void file_editor_tab::recover_from_exit () { // reset the possibly still existing read only state m_edit_area->setReadOnly (false); @@ -1809,7 +1809,7 @@ check_restore_breakpoints (); } - void file_editor_tab::check_restore_breakpoints (void) + void file_editor_tab::check_restore_breakpoints () { if (! m_bp_lines.isEmpty ()) { @@ -1987,7 +1987,7 @@ m_new_encoding = enc; } - QsciScintilla::EolMode file_editor_tab::detect_eol_mode (void) + QsciScintilla::EolMode file_editor_tab::detect_eol_mode () { QByteArray text = m_edit_area->text ().toLatin1 (); @@ -2025,7 +2025,7 @@ return eol_mode; } - void file_editor_tab::update_eol_indicator (void) + void file_editor_tab::update_eol_indicator () { switch (m_edit_area->eolMode ()) { @@ -2661,7 +2661,7 @@ emit editor_check_conflict_save (saveFileName, true); } - void file_editor_tab::handle_save_file_as_answer_cancel (void) + void file_editor_tab::handle_save_file_as_answer_cancel () { // User canceled, allow editing again. m_edit_area->setReadOnly (false); @@ -2931,7 +2931,7 @@ } - void file_editor_tab::auto_margin_width (void) + void file_editor_tab::auto_margin_width () { m_edit_area->setMarginWidth (2, "1" + QString::number (m_edit_area->lines ())); } @@ -2941,7 +2941,7 @@ // the tab really was closed (for canceling exiting octave). // When emitting a signal, only the return value from the last slot // goes back to the sender - bool file_editor_tab::conditional_close (void) + bool file_editor_tab::conditional_close () { return close (); } @@ -3154,7 +3154,7 @@ } } - void file_editor_tab::handle_lines_changed (void) + void file_editor_tab::handle_lines_changed () { // the related signal is emitted before cursor-move-signal! m_lines_changed = true; @@ -3341,7 +3341,7 @@ } } - QString file_editor_tab::get_function_name (void) + QString file_editor_tab::get_function_name () { QRegExp rxfun1 ("^[\t ]*function[^=]+=([^\\(]+)\\([^\\)]*\\)[\t ]*$"); QRegExp rxfun2 ("^[\t ]*function[\t ]+([^\\(]+)\\([^\\)]*\\)[\t ]*$"); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/m-editor/file-editor-tab.h --- a/libgui/src/m-editor/file-editor-tab.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/m-editor/file-editor-tab.h Tue Jan 24 17:19:44 2023 -0800 @@ -54,23 +54,23 @@ file_editor_tab (const QString& directory = ""); - ~file_editor_tab (void); + ~file_editor_tab (); - octave_qscintilla * qsci_edit_area (void) { return m_edit_area; } + octave_qscintilla * qsci_edit_area () { return m_edit_area; } // Will initiate close if associated with the identifier tag. - bool conditional_close (void); + bool conditional_close (); void update_breakpoints (); void set_file_name (const QString& fileName); void enable_file_watcher (bool do_enable); - QString file_name (void) const { return m_file_name; } - QString encoding (void) const { return m_encoding; } + QString file_name () const { return m_file_name; } + QString encoding () const { return m_encoding; } signals: - void tab_ready_to_close (void); + void tab_ready_to_close (); void file_name_changed (const QString& fileName, const QString& toolTip, bool modified); @@ -78,7 +78,7 @@ bool is_modified); void set_focus_editor_signal (QWidget *); void edit_area_changed (octave_qscintilla *edit_area); - void tab_remove_request (void); + void tab_remove_request (); void mru_add_file (const QString& file_name, const QString& encoding); void editor_check_conflict_save (const QString& saveFileName, bool remove_on_success); @@ -87,22 +87,22 @@ void edit_mfile_request (const QString&, const QString&, const QString&, int); - void autoc_closed (void); + void autoc_closed (); void update_breakpoints_signal (const octave_value_list& args); void remove_breakpoint_via_debugger_linenr (int debugger_linenr); void request_remove_breakpoint_via_editor_linenr (int editor_linenr); - void remove_all_breakpoints_signal (void); + void remove_all_breakpoints_signal (); void find_translated_line_number (int original_linenr, int& translated_linenr, marker*&); void find_linenr_just_before (int linenr, int& original_linenr, int& editor_linenr); void report_marker_linenr (QIntList& lines, QStringList& conditions); void remove_position_via_debugger_linenr (int debugger_linenr); - void remove_all_positions (void); + void remove_all_positions (); - void debug_quit_signal (void); + void debug_quit_signal (); void interpreter_event (const fcn_callback& fcn); void interpreter_event (const meth_callback& meth); @@ -112,7 +112,7 @@ void dbstop_if (const QString& prompt, int line, const QString& cond); void request_add_breakpoint (int line, const QString& cond); void request_add_octave_apis (const QStringList&); - void api_entries_added (void); + void api_entries_added (); void do_save_file_signal (const QString& file_to_save, bool remove_on_success, bool restore_breakpoints); @@ -186,7 +186,7 @@ void do_breakpoint_marker (bool insert, const QWidget *ID, int line = -1, const QString& cond = ""); - void recover_from_exit (void); + void recover_from_exit (); void set_modified (bool modified = true); void set_encoding (const QString& new_encoding); @@ -221,28 +221,28 @@ // When user closes QFileDialog box. void handle_save_file_as_answer (const QString& fileName); void handle_save_file_as_answer_close (const QString& fileName); - void handle_save_file_as_answer_cancel (void); + void handle_save_file_as_answer_cancel (); void handle_save_as_filter_selected (const QString& filter); // When user changes encoding after decoding errors were found void handle_current_enc_changed (const QString& enc); // When apis preparation has finished and is ready to save - void save_apis_info (void); + void save_apis_info (); // When the numer of lines changes -> adapt width of margin - void auto_margin_width (void); + void auto_margin_width (); void handle_cursor_moved (int line, int col); void handle_char_added (int character); void handle_double_click (int p, int l, int modifier); - void handle_lines_changed (void); + void handle_lines_changed (); void handle_remove_next (int remove_line); void handle_dbstop_if (const QString& prompt, int line, const QString& cond); void handle_add_octave_apis (const QStringList& api_entries); - void handle_api_entries_added (void); + void handle_api_entries_added (); void do_save_file (const QString& file_to_save, bool remove_on_success, bool restore_breakpoints); @@ -265,31 +265,31 @@ bool restore_breakpoints = true); void save_file_as (bool remove_on_success = false); bool check_valid_identifier (QString file_name); - QTextCodec * check_valid_codec (void); + QTextCodec * check_valid_codec (); - bool unchanged_or_saved (void); + bool unchanged_or_saved (); - void update_lexer (void); + void update_lexer (); void show_dialog (QDialog *dlg, bool modal); public: int check_file_modified (bool remove = false); - QString get_all_bookmarks (void); + QString get_all_bookmarks (); private: void do_comment_selected_text (bool comment, bool input_str = false); void do_indent_selected_text (bool indent); - void do_smart_indent_line_or_selected_text (void); + void do_smart_indent_line_or_selected_text (); - void check_restore_breakpoints (void); + void check_restore_breakpoints (); void center_current_line (bool always=true); - QString get_function_name (void); + QString get_function_name (); - QsciScintilla::EolMode detect_eol_mode (void); - void update_eol_indicator (void); + QsciScintilla::EolMode detect_eol_mode (); + void update_eol_indicator (); octave_qscintilla *m_edit_area; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/m-editor/file-editor.cc --- a/libgui/src/m-editor/file-editor.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/m-editor/file-editor.cc Tue Jan 24 17:19:44 2023 -0800 @@ -80,13 +80,13 @@ setMovable (true); } - tab_bar *file_editor_tab_widget::get_tab_bar (void) const + tab_bar *file_editor_tab_widget::get_tab_bar () const { return qobject_cast (tabBar ()); } std::list - file_editor_tab_widget::tab_list (void) const + file_editor_tab_widget::tab_list () const { std::list retval; for (int i = 0; i < count (); i++) @@ -176,7 +176,7 @@ m_edit_menu->insertAction (m_find_action, m_find_files_action); } - void file_editor::handle_enter_debug_mode (void) + void file_editor::handle_enter_debug_mode () { gui_settings settings; @@ -191,7 +191,7 @@ emit enter_debug_mode_signal (); } - void file_editor::handle_exit_debug_mode (void) + void file_editor::handle_exit_debug_mode () { gui_settings settings; settings.set_shortcut (m_run_action, sc_edit_run_run_file); @@ -200,7 +200,7 @@ emit exit_debug_mode_signal (); } - void file_editor::check_actions (void) + void file_editor::check_actions () { // Do not include shared actions not only related to the editor bool have_tabs = m_tab_widget->count () > 0; @@ -315,7 +315,7 @@ request_new_file (""); } - void file_editor::restore_session (void) + void file_editor::restore_session () { gui_settings settings; @@ -376,7 +376,7 @@ s_data.at (n).bookmarks); } - void file_editor::activate (void) + void file_editor::activate () { if (m_no_focus) return; // No focus for the editor if external open/close request @@ -437,7 +437,7 @@ // Save open files for restoring in next session // (even if last session will not be restored next time) // together with encoding and the tab index - void file_editor::save_session (void) + void file_editor::save_session () { gui_settings settings; @@ -480,7 +480,7 @@ settings.sync (); } - bool file_editor::check_closing (void) + bool file_editor::check_closing () { // When the application or the editor is closing and the user wants to // close all files, in the latter case all editor tabs are checked whether @@ -530,7 +530,7 @@ return true; } - void file_editor::handle_tab_ready_to_close (void) + void file_editor::handle_tab_ready_to_close () { if (m_closing_canceled) return; @@ -1016,7 +1016,7 @@ } void - file_editor::handle_tab_remove_request (void) + file_editor::handle_tab_remove_request () { QObject *fileEditorTab = sender (); if (fileEditorTab) @@ -1285,7 +1285,7 @@ m_tmp_closed_files.clear (); } - void file_editor::notice_settings (void) + void file_editor::notice_settings () { gui_settings settings; @@ -1392,7 +1392,7 @@ emit fetab_settings_changed (); } - void file_editor::set_shortcuts (void) + void file_editor::set_shortcuts () { // Shortcuts also available in the main window, as well as the related // shortcuts, are defined in main_window and added to the editor @@ -1524,28 +1524,28 @@ emit fetab_set_directory (m_ced); // for save dialog } - void file_editor::copyClipboard (void) + void file_editor::copyClipboard () { if (editor_tab_has_focus ()) emit fetab_scintilla_command (m_tab_widget->currentWidget (), QsciScintillaBase::SCI_COPY); } - void file_editor::pasteClipboard (void) + void file_editor::pasteClipboard () { if (editor_tab_has_focus ()) emit fetab_scintilla_command (m_tab_widget->currentWidget (), QsciScintillaBase::SCI_PASTE); } - void file_editor::selectAll (void) + void file_editor::selectAll () { if (editor_tab_has_focus ()) emit fetab_scintilla_command (m_tab_widget->currentWidget (), QsciScintillaBase::SCI_SELECTALL); } - void file_editor::do_undo (void) + void file_editor::do_undo () { if (editor_tab_has_focus ()) emit fetab_scintilla_command (m_tab_widget->currentWidget (), @@ -1903,7 +1903,7 @@ } } - bool file_editor::is_editor_console_tabbed (void) + bool file_editor::is_editor_console_tabbed () { // FIXME: is there a way to do this job that doesn't require casting // the parent to a main_window object? @@ -1926,7 +1926,7 @@ return false; } - void file_editor::construct (void) + void file_editor::construct () { QWidget *editor_widget = new QWidget (this); @@ -2130,7 +2130,7 @@ m_smart_indent_line_or_selection_action = add_action (m_edit_fmt_menu, tr ("Indent Code"), - SLOT (request_smart_indent_line_or_selected_text (void))); + SLOT (request_smart_indent_line_or_selected_text ())); m_edit_fmt_menu->addSeparator (); @@ -2260,7 +2260,7 @@ m_sort_tabs_action = add_action (view_menu, tr ("&Sort Tabs Alphabetically"), - SLOT (sort_tabs_alph (void)), + SLOT (sort_tabs_alph ()), m_tab_widget->get_tab_bar ()); m_menu_bar->addMenu (view_menu); @@ -2326,19 +2326,19 @@ // tab navigation (no menu, only actions; slots in tab_bar) m_switch_left_tab_action - = add_action (nullptr, "", SLOT (switch_left_tab (void)), + = add_action (nullptr, "", SLOT (switch_left_tab ()), m_tab_widget->get_tab_bar ()); m_switch_right_tab_action - = add_action (nullptr, "", SLOT (switch_right_tab (void)), + = add_action (nullptr, "", SLOT (switch_right_tab ()), m_tab_widget->get_tab_bar ()); m_move_tab_left_action - = add_action (nullptr, "", SLOT (move_tab_left (void)), + = add_action (nullptr, "", SLOT (move_tab_left ()), m_tab_widget->get_tab_bar ()); m_move_tab_right_action - = add_action (nullptr, "", SLOT (move_tab_right (void)), + = add_action (nullptr, "", SLOT (move_tab_right ()), m_tab_widget->get_tab_bar ()); // toolbar @@ -2416,7 +2416,7 @@ } // Slot when autocompletion list was cancelled - void file_editor::handle_autoc_cancelled (void) + void file_editor::handle_autoc_cancelled () { // List was cancelled but somehow still active and blocking the // edit area from accepting shortcuts. Only after another keypress @@ -2440,7 +2440,7 @@ qsci->undo (); } - file_editor_tab *file_editor::reset_focus (void) + file_editor_tab *file_editor::reset_focus () { // Reset the focus of the tab and the related edit area file_editor_tab *f @@ -2466,10 +2466,10 @@ connect (f->qsci_edit_area (), SIGNAL (SCN_AUTOCCOMPLETED (const char *, int, int, int)), - this, SLOT (reset_focus (void))); - - connect (f->qsci_edit_area (), SIGNAL (SCN_AUTOCCANCELLED (void)), - this, SLOT (handle_autoc_cancelled (void))); + this, SLOT (reset_focus ())); + + connect (f->qsci_edit_area (), SIGNAL (SCN_AUTOCCANCELLED ()), + this, SLOT (handle_autoc_cancelled ())); // signals from the qscintilla edit area connect (this, &file_editor::enter_debug_mode_signal, @@ -2662,7 +2662,7 @@ check_actions (); } - void file_editor::mru_menu_update (void) + void file_editor::mru_menu_update () { int num_files = qMin (m_mru_files.size (), int (MaxMRUFiles)); @@ -2801,7 +2801,7 @@ } } - bool file_editor::editor_tab_has_focus (void) + bool file_editor::editor_tab_has_focus () { QWidget *foc_w = focusWidget (); if (foc_w && foc_w->inherits ("octave::octave_qscintilla")) diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/m-editor/file-editor.h --- a/libgui/src/m-editor/file-editor.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/m-editor/file-editor.h Tue Jan 24 17:19:44 2023 -0800 @@ -59,11 +59,11 @@ file_editor_tab_widget (QWidget *p, file_editor *fe); - ~file_editor_tab_widget (void) = default; + ~file_editor_tab_widget () = default; - tab_bar * get_tab_bar (void) const; + tab_bar * get_tab_bar () const; - std::list tab_list (void) const; + std::list tab_list () const; }; // the class for the file editor @@ -98,15 +98,15 @@ file_editor (QWidget *p); - ~file_editor (void) = default; + ~file_editor () = default; - QMenu * get_mru_menu (void) { return m_mru_file_menu; } + QMenu * get_mru_menu () { return m_mru_file_menu; } - QMenu * debug_menu (void) { return m_debug_menu; } + QMenu * debug_menu () { return m_debug_menu; } - QToolBar * toolbar (void) { return m_tool_bar; } + QToolBar * toolbar () { return m_tool_bar; } - QMenuBar * menubar (void) { return m_menu_bar; } + QMenuBar * menubar () { return m_menu_bar; } void insert_global_actions (QList); @@ -122,13 +122,13 @@ SELECTALL_ACTION }; - void check_actions (void); + void check_actions (); void empty_script (bool startup, bool visible); - void restore_session (void); + void restore_session (); signals: - void fetab_settings_changed (void); + void fetab_settings_changed (); void fetab_change_request (const QWidget *ID); // Save is a ping-pong type of communication void fetab_save_file (const QWidget *ID, const QString& fileName, @@ -171,40 +171,40 @@ void fetab_zoom_normal (const QWidget *ID); void fetab_set_directory (const QString& dir); - void fetab_recover_from_exit (void); + void fetab_recover_from_exit (); void edit_area_changed (octave_qscintilla *edit_area); void request_settings_dialog (const QString&); void request_open_file_external (const QString& file_name, int line); - void file_loaded_signal (void); + void file_loaded_signal (); void editor_tabs_changed_signal (bool, bool); - void request_dbcont_signal (void); + void request_dbcont_signal (); - void enter_debug_mode_signal (void); - void exit_debug_mode_signal (void); + void enter_debug_mode_signal (); + void exit_debug_mode_signal (); void update_gui_lexer_signal (bool); void execute_command_in_terminal_signal (const QString&); - void focus_console_after_command_signal (void); + void focus_console_after_command_signal (); void run_file_signal (const QFileInfo&); void edit_mfile_request (const QString&, const QString&, const QString&, int); - void debug_quit_signal (void); + void debug_quit_signal (); void show_symbol_tooltip_signal (const QPoint&, const QString&); public slots: - void activate (void); + void activate (); void set_focus (QWidget *fet); void enable_menu_shortcuts (bool); - void save_session (void); - bool check_closing (void); - void handle_tab_ready_to_close (void); + void save_session (); + bool check_closing (); + void handle_tab_ready_to_close (); - void handle_enter_debug_mode (void); - void handle_exit_debug_mode (void); + void handle_enter_debug_mode (); + void handle_exit_debug_mode (); void request_new_file (const QString& commands); void request_close_file (bool); @@ -254,7 +254,7 @@ void request_lower_case (bool); void request_indent_selected_text (bool); void request_unindent_selected_text (bool); - void request_smart_indent_line_or_selected_text (void); + void request_smart_indent_line_or_selected_text (); void request_conv_eol_windows (bool); void request_conv_eol_unix (bool); void request_conv_eol_mac (bool); @@ -270,7 +270,7 @@ const QString& toolTip, bool modified); void handle_tab_close_request (int index); - void handle_tab_remove_request (void); + void handle_tab_remove_request (); void active_tab_changed (int index); void handle_editor_state_changed (bool enableCopy, bool is_octave_file, bool is_modified); @@ -289,9 +289,9 @@ void handle_file_renamed (bool load_new = true); // Tells the editor to react on changed settings. - void notice_settings (void); + void notice_settings (); - void set_shortcuts (void); + void set_shortcuts (); void handle_visibility (bool visible); @@ -299,16 +299,16 @@ void toplevel_change (bool toplevel); - void handle_autoc_cancelled (void); + void handle_autoc_cancelled (); - file_editor_tab * reset_focus (void); + file_editor_tab * reset_focus (); protected slots: - void copyClipboard (void); - void pasteClipboard (void); - void selectAll (void); - void do_undo (void); + void copyClipboard (); + void pasteClipboard (); + void selectAll (); + void do_undo (); private slots: @@ -347,20 +347,20 @@ file_editor_tab * make_file_editor_tab (const QString& directory = ""); - bool is_editor_console_tabbed (void); - void construct (void); + bool is_editor_console_tabbed (); + void construct (); void add_file_editor_tab (file_editor_tab *f, const QString& fn, int index = -1); - void mru_menu_update (void); + void mru_menu_update (); bool call_custom_editor (const QString& file_name = QString (), int line = -1); void toggle_preference (const gui_pref& preference); void handle_dir_remove (const QString& old_name, const QString& new_name); - bool editor_tab_has_focus (void); + bool editor_tab_has_focus (); - void find_create (void); + void find_create (); file_editor_tab * find_tab_widget (const QString& openFileName); QAction * add_action (QMenu *menu, const QString& text, diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/m-editor/find-dialog.cc --- a/libgui/src/m-editor/find-dialog.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/m-editor/find-dialog.cc Tue Jan 24 17:19:44 2023 -0800 @@ -314,7 +314,7 @@ } // search text has changed: reset the search - void find_dialog::handle_search_text_changed (void) + void find_dialog::handle_search_text_changed () { // Return if nothing has changed if (m_search_line_edit->currentText () == m_search_line_edit->itemText (0)) @@ -327,7 +327,7 @@ } // replaced text has changed: reset the search - void find_dialog::handle_replace_text_changed (void) + void find_dialog::handle_replace_text_changed () { // Return if nothing has changed if (m_replace_line_edit->currentText () == m_replace_line_edit->itemText (0)) @@ -379,7 +379,7 @@ } // initialize search text with selected text if this is in one single line - void find_dialog::init_search_text (void) + void find_dialog::init_search_text () { if (m_edit_area && m_edit_area->hasSelectedText ()) { @@ -398,12 +398,12 @@ m_find_next_button->setDefault (true); } - void find_dialog::find_next (void) + void find_dialog::find_next () { find (! m_backward_check_box->isChecked ()); } - void find_dialog::find_prev (void) + void find_dialog::find_prev () { find (m_backward_check_box->isChecked ()); } @@ -561,7 +561,7 @@ } - void find_dialog::do_replace (void) + void find_dialog::do_replace () { if (m_edit_area) { @@ -580,7 +580,7 @@ } } - void find_dialog::replace (void) + void find_dialog::replace () { if (m_edit_area) { @@ -594,7 +594,7 @@ } } - void find_dialog::replace_all (void) + void find_dialog::replace_all () { int line, col; @@ -629,7 +629,7 @@ } } - void find_dialog::no_matches_message (void) + void find_dialog::no_matches_message () { QMessageBox msg_box (QMessageBox::Information, tr ("Find Result"), tr ("No more matches found"), QMessageBox::Ok, this); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/m-editor/find-dialog.h --- a/libgui/src/m-editor/find-dialog.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/m-editor/find-dialog.h Tue Jan 24 17:19:44 2023 -0800 @@ -93,7 +93,7 @@ void set_visible (bool visible); //! Init the search text with the selected text in the editor tab - void init_search_text (void); + void init_search_text (); //! Restore position and the search options from the given settings //! where def_pos is the default position suitable for the current @@ -102,8 +102,8 @@ public slots: - void find_next (void); - void find_prev (void); + void find_next (); + void find_prev (); //! Slot for updating the edit area when the active tab has changed void update_edit_area (octave_qscintilla *); @@ -116,8 +116,8 @@ void handle_backward_search_changed (int); void find (bool forward = true); - void replace (void); - void replace_all (void); + void replace (); + void replace_all (); private: @@ -133,11 +133,11 @@ //! Update mru lists with new entry void mru_update (QComboBox *mru); - void no_matches_message (void); - void do_replace (void); + void no_matches_message (); + void do_replace (); - void handle_search_text_changed (void); - void handle_replace_text_changed (void); + void handle_search_text_changed (); + void handle_replace_text_changed (); octave_dock_widget *m_editor; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/m-editor/marker.cc --- a/libgui/src/m-editor/marker.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/m-editor/marker.cc Tue Jan 24 17:19:44 2023 -0800 @@ -81,7 +81,7 @@ } } -void marker::handle_remove (void) +void marker::handle_remove () { m_edit_area->markerDeleteHandle (m_mhandle); delete this; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/m-editor/marker.h --- a/libgui/src/m-editor/marker.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/m-editor/marker.h Tue Jan 24 17:19:44 2023 -0800 @@ -68,9 +68,9 @@ editor_markers marker_type, int editor_linenr, const QString& condition = ""); - ~marker (void) = default; + ~marker () = default; - const QString& get_cond (void) const { return m_condition; } + const QString& get_cond () const { return m_condition; } void set_cond (const QString& cond) { m_condition = cond; } @@ -82,14 +82,14 @@ void handle_remove_via_original_linenr (int original_linenr); void handle_request_remove_via_editor_linenr (int editor_linenr); - void handle_remove (void); + void handle_remove (); void handle_find_translation (int original_linenr, int& editor_linenr, marker*& bp); void handle_find_just_before (int linenr, int& original_linenr, int& editor_linenr); void handle_find_just_after (int linenr, int& original_linenr, int& editor_linenr); - /* void handle_lines_changed (void);*/ + /* void handle_lines_changed ();*/ void handle_marker_line_deleted (int mhandle); void handle_marker_line_undeleted (int mhandle); void handle_report_editor_linenr (QIntList& lines, QStringList& conditions); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/m-editor/octave-qscintilla.cc --- a/libgui/src/m-editor/octave-qscintilla.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/m-editor/octave-qscintilla.cc Tue Jan 24 17:19:44 2023 -0800 @@ -116,8 +116,8 @@ m_selection (), m_selection_replacement (), m_selection_line (-1), m_selection_col (-1), m_indicator_id (1) { - connect (this, SIGNAL (textChanged (void)), - this, SLOT (text_changed (void))); + connect (this, SIGNAL (textChanged ()), + this, SLOT (text_changed ())); connect (this, SIGNAL (cursorPositionChanged (int, int)), this, SLOT (cursor_position_changed (int, int))); @@ -351,14 +351,14 @@ } // call edit the function related to the current word - void octave_qscintilla::context_edit (void) + void octave_qscintilla::context_edit () { if (get_actual_word ()) contextmenu_edit (true); } // call edit the function related to the current word - void octave_qscintilla::context_run (void) + void octave_qscintilla::context_run () { if (hasSelectedText ()) { @@ -381,7 +381,7 @@ } // determine the actual word and whether we are in an octave or matlab script - bool octave_qscintilla::get_actual_word (void) + bool octave_qscintilla::get_actual_word () { QPoint global_pos, local_pos; get_global_textcursor_pos (&global_pos, &local_pos); @@ -392,7 +392,7 @@ } // helper function for clearing all indicators of a specific style - void octave_qscintilla::clear_selection_markers (void) + void octave_qscintilla::clear_selection_markers () { int end_pos = text ().length (); int end_line, end_col; @@ -402,7 +402,7 @@ markerDeleteAll (marker::selection); } - QString octave_qscintilla::eol_string (void) + QString octave_qscintilla::eol_string () { switch (eolMode ()) { @@ -824,7 +824,7 @@ emit context_menu_edit_signal (m_word_at_cursor); } - void octave_qscintilla::contextmenu_run_temp_error (void) + void octave_qscintilla::contextmenu_run_temp_error () { QMessageBox::critical (this, tr ("Octave Editor"), tr ("Creating temporary files failed.\n" @@ -1100,7 +1100,7 @@ #endif } - void octave_qscintilla::text_changed (void) + void octave_qscintilla::text_changed () { emit status_update (isUndoAvailable (), isRedoAvailable ()); } @@ -1125,7 +1125,7 @@ QsciScintilla::focusInEvent (focusEvent); } - void octave_qscintilla::show_replace_action_tooltip (void) + void octave_qscintilla::show_replace_action_tooltip () { int pos; get_current_position (&pos, &m_selection_line, &m_selection_col); @@ -1369,12 +1369,12 @@ } } - void octave_qscintilla::handle_enter_debug_mode (void) + void octave_qscintilla::handle_enter_debug_mode () { m_debug_mode = true; } - void octave_qscintilla::handle_exit_debug_mode (void) + void octave_qscintilla::handle_exit_debug_mode () { m_debug_mode = false; } diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/m-editor/octave-qscintilla.h --- a/libgui/src/m-editor/octave-qscintilla.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/m-editor/octave-qscintilla.h Tue Jan 24 17:19:44 2023 -0800 @@ -47,7 +47,7 @@ octave_qscintilla (QWidget *p); - ~octave_qscintilla (void) = default; + ~octave_qscintilla () = default; enum { @@ -60,12 +60,12 @@ virtual void setCursorPosition (int line, int col); void context_help_doc (bool); - void context_edit (void); - void context_run (void); + void context_edit (); + void context_run (); void get_global_textcursor_pos (QPoint *global_pos, QPoint *local_pos); - bool get_actual_word (void); - void clear_selection_markers (void); - QString eol_string (void); + bool get_actual_word (); + void clear_selection_markers (); + QString eol_string (); void get_current_position (int *pos, int *line, int *col); QStringList comment_string (bool comment = true); int get_style (int pos = -1); @@ -98,15 +98,15 @@ void context_menu_break_once (int); void ctx_menu_run_finished_signal (bool, int, QPointer, QPointer, bool, bool); - void focus_console_after_command_signal (void); + void focus_console_after_command_signal (); void interpreter_event (const fcn_callback& fcn); void interpreter_event (const meth_callback& meth); public slots: - void handle_enter_debug_mode (void); - void handle_exit_debug_mode (void); + void handle_enter_debug_mode (); + void handle_exit_debug_mode (); private slots: @@ -118,19 +118,19 @@ void contextmenu_help_doc (bool); void contextmenu_edit (bool); void contextmenu_run (bool); - void contextmenu_run_temp_error (void); + void contextmenu_run_temp_error (); void contextmenu_break_condition (bool); void contextmenu_break_once (const QPoint&); - void text_changed (void); + void text_changed (); void cursor_position_changed (int, int); protected: void focusInEvent (QFocusEvent *focusEvent); - void show_replace_action_tooltip (void); + void show_replace_action_tooltip (); bool event (QEvent *e); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/m-editor/octave-txt-lexer.cc --- a/libgui/src/m-editor/octave-txt-lexer.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/m-editor/octave-txt-lexer.cc Tue Jan 24 17:19:44 2023 -0800 @@ -43,12 +43,12 @@ return QString (); }; -const char * octave_txt_lexer::language (void) const +const char * octave_txt_lexer::language () const { return "Text"; } -const char * octave_txt_lexer::lexer (void) const +const char * octave_txt_lexer::lexer () const { return "text"; } diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/m-editor/octave-txt-lexer.h --- a/libgui/src/m-editor/octave-txt-lexer.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/m-editor/octave-txt-lexer.h Tue Jan 24 17:19:44 2023 -0800 @@ -37,9 +37,9 @@ public: - virtual const char * language (void) const; + virtual const char * language () const; - virtual const char * lexer (void) const; + virtual const char * lexer () const; virtual QString description (int style) const; }; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/main-window.cc --- a/libgui/src/main-window.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/main-window.cc Tue Jan 24 17:19:44 2023 -0800 @@ -198,9 +198,9 @@ focus_command_window (); } - main_window::~main_window (void) { } - - void main_window::adopt_dock_widgets (void) + main_window::~main_window () { } + + void main_window::adopt_dock_widgets () { adopt_terminal_widget (); adopt_documentation_widget (); @@ -213,7 +213,7 @@ m_previous_dock = m_command_window; } - void main_window::adopt_terminal_widget (void) + void main_window::adopt_terminal_widget () { m_command_window = m_octave_qobj.terminal_widget (this); @@ -271,14 +271,14 @@ } } - void main_window::adopt_documentation_widget (void) + void main_window::adopt_documentation_widget () { m_doc_browser_window = m_octave_qobj.documentation_widget (this); make_dock_widget_connections (m_doc_browser_window); } - void main_window::adopt_file_browser_widget (void) + void main_window::adopt_file_browser_widget () { m_file_browser_window = m_octave_qobj.file_browser_widget (this); @@ -306,7 +306,7 @@ this, &main_window::find_files); } - void main_window::adopt_history_widget (void) + void main_window::adopt_history_widget () { m_history_window = m_octave_qobj.history_widget (this); @@ -319,7 +319,7 @@ this, &main_window::execute_command_in_terminal); } - void main_window::adopt_workspace_widget (void) + void main_window::adopt_workspace_widget () { m_workspace_window = m_octave_qobj.workspace_widget (this); @@ -329,7 +329,7 @@ this, &main_window::execute_command_in_terminal); } - void main_window::adopt_editor_widget (void) + void main_window::adopt_editor_widget () { interpreter_qobject *interp_qobj = m_octave_qobj.interpreter_qobj (); @@ -437,7 +437,7 @@ m_active_editor, SLOT (handle_edit_file_request (const QString&))); } - void main_window::adopt_variable_editor_widget (void) + void main_window::adopt_variable_editor_widget () { m_variable_editor_window = m_octave_qobj.variable_editor_widget (this); @@ -468,12 +468,12 @@ dw, &octave_dock_widget::save_settings); } - bool main_window::command_window_has_focus (void) const + bool main_window::command_window_has_focus () const { return m_command_window->has_focus (); } - void main_window::focus_command_window (void) + void main_window::focus_command_window () { m_command_window->activate (); } @@ -490,7 +490,7 @@ m_file_browser_window->activate (); } - bool main_window::confirm_shutdown (void) + bool main_window::confirm_shutdown () { bool closenow = true; @@ -631,7 +631,7 @@ } } - void main_window::request_reload_settings (void) + void main_window::request_reload_settings () { emit settings_changed (); } @@ -641,7 +641,7 @@ m_status_bar->showMessage (statusMessage, 1000); } - void main_window::handle_save_workspace_request (void) + void main_window::handle_save_workspace_request () { // FIXME: Remove, if for all common KDE versions (bug #54607) is resolved. int opts = 0; // No options by default. @@ -725,7 +725,7 @@ } } - void main_window::handle_clear_workspace_request (void) + void main_window::handle_clear_workspace_request () { emit interpreter_event ([] (interpreter& interp) @@ -736,10 +736,10 @@ }); } - void main_window::handle_clear_command_window_request (void) + void main_window::handle_clear_command_window_request () { emit interpreter_event - ([] (void) + ([] () { // INTERPRETER THREAD @@ -748,7 +748,7 @@ }); } - void main_window::handle_clear_history_request (void) + void main_window::handle_clear_history_request () { emit interpreter_event ([] (interpreter& interp) @@ -761,12 +761,12 @@ }); } - void main_window::handle_undo_request (void) + void main_window::handle_undo_request () { if (command_window_has_focus ()) { emit interpreter_event - ([] (void) + ([] () { // INTERPRETER THREAD @@ -832,28 +832,28 @@ qt_link->wake_all (); } - void main_window::open_online_documentation_page (void) + void main_window::open_online_documentation_page () { QDesktopServices::openUrl (QUrl ("https://octave.org/doc/interpreter/index.html")); } - void main_window::open_bug_tracker_page (void) + void main_window::open_bug_tracker_page () { QDesktopServices::openUrl (QUrl ("https://octave.org/bugs.html")); } - void main_window::open_octave_packages_page (void) + void main_window::open_octave_packages_page () { QDesktopServices::openUrl (QUrl ("https://packages.octave.org/index.html")); } - void main_window::open_contribute_page (void) + void main_window::open_contribute_page () { QDesktopServices::openUrl (QUrl ("https://octave.org/contribute.html")); } - void main_window::open_donate_page (void) + void main_window::open_donate_page () { QDesktopServices::openUrl (QUrl ("https://octave.org/donate.html")); } @@ -878,7 +878,7 @@ m_settings_dlg->show (); } - void main_window::show_about_octave (void) + void main_window::show_about_octave () { std::string message = octave_name_version_copyright_copying_warranty_and_bugs (true); @@ -1022,7 +1022,7 @@ return darkPalette; } - void main_window::prepare_to_exit (void) + void main_window::prepare_to_exit () { // Find files dialog is constructed dynamically, not at time of main_window // construction. Connecting it to qApp aboutToQuit signal would have @@ -1040,7 +1040,7 @@ m_active_dock = nullptr; } - void main_window::go_to_previous_widget (void) + void main_window::go_to_previous_widget () { m_previous_dock->activate (); } @@ -1060,7 +1060,7 @@ m_current_directory_combo_box->setCurrentIndex (0); } - void main_window::browse_for_directory (void) + void main_window::browse_for_directory () { // FIXME: Remove, if for all common KDE versions (bug #54607) is resolved. int opts = QFileDialog::ShowDirsOnly; @@ -1102,7 +1102,7 @@ } } - void main_window::change_directory_up (void) + void main_window::change_directory_up () { set_current_working_directory (".."); } @@ -1111,7 +1111,7 @@ // combobox to change to a new directory or a directory that is already // in the drop down list. - void main_window::accept_directory_line_edit (void) + void main_window::accept_directory_line_edit () { // Get new directory name, and change to it if it is new. Otherwise, // the combo box will trigger the "activated" signal to change to the @@ -1134,7 +1134,7 @@ else { emit interpreter_event - ([=] (void) + ([=] () { // INTERPRETER THREAD @@ -1195,7 +1195,7 @@ focus_console_after_command (); } - void main_window::handle_new_figure_request (void) + void main_window::handle_new_figure_request () { emit interpreter_event ([] (interpreter& interp) @@ -1207,7 +1207,7 @@ }); } - void main_window::handle_enter_debugger (void) + void main_window::handle_enter_debugger () { setWindowTitle ("Octave (Debugging)"); @@ -1218,7 +1218,7 @@ m_debug_quit->setEnabled (true); } - void main_window::handle_exit_debugger (void) + void main_window::handle_exit_debugger () { setWindowTitle ("Octave"); @@ -1229,7 +1229,7 @@ m_debug_quit->setEnabled (false); } - void main_window::debug_continue (void) + void main_window::debug_continue () { emit interpreter_event ([=] (interpreter& interp) @@ -1243,7 +1243,7 @@ }); } - void main_window::debug_step_into (void) + void main_window::debug_step_into () { emit interpreter_event ([=] (interpreter& interp) @@ -1257,7 +1257,7 @@ }); } - void main_window::debug_step_over (void) + void main_window::debug_step_over () { if (m_debug_quit->isEnabled ()) { @@ -1282,7 +1282,7 @@ } } - void main_window::debug_step_out (void) + void main_window::debug_step_out () { emit interpreter_event ([=] (interpreter& interp) @@ -1296,7 +1296,7 @@ }); } - void main_window::debug_quit (void) + void main_window::debug_quit () { emit interpreter_event ([] (interpreter& interp) @@ -1315,7 +1315,7 @@ // These are moved from editor to here for also using them when octave // is built without qscintilla // - void main_window::request_open_file (void) + void main_window::request_open_file () { // Open file isn't a file_editor_tab or editor function since the file // might be opened in an external editor. Hence, functionality is here. @@ -1383,8 +1383,8 @@ { // no, so enable this settings and wait for end of new file loading settings.setValue (ed_create_new_file.settings_key (), true); - connect (m_editor_window, SIGNAL (file_loaded_signal (void)), - this, SLOT (restore_create_file_setting (void))); + connect (m_editor_window, SIGNAL (file_loaded_signal ()), + this, SLOT (restore_create_file_setting ())); } // start the edit command execute_command_in_terminal ("edit " + new_name); @@ -1537,7 +1537,7 @@ focus_command_window (); } - void main_window::read_settings (void) + void main_window::read_settings () { gui_settings settings; @@ -1553,12 +1553,12 @@ emit settings_changed (); } - void main_window::init_terminal_size (void) + void main_window::init_terminal_size () { emit init_terminal_size_signal (); } - void main_window::set_window_layout (void) + void main_window::set_window_layout () { gui_settings settings; @@ -1655,7 +1655,7 @@ show (); } - void main_window::write_settings (void) + void main_window::write_settings () { gui_settings settings; @@ -1671,7 +1671,7 @@ settings.sync (); } - void main_window::copyClipboard (void) + void main_window::copyClipboard () { if (m_current_directory_combo_box->hasFocus ()) { @@ -1686,7 +1686,7 @@ emit copyClipboard_signal (); } - void main_window::pasteClipboard (void) + void main_window::pasteClipboard () { if (m_current_directory_combo_box->hasFocus ()) { @@ -1702,7 +1702,7 @@ emit pasteClipboard_signal (); } - void main_window::selectAll (void) + void main_window::selectAll () { if (m_current_directory_combo_box->hasFocus ()) { @@ -1731,7 +1731,7 @@ } } - void main_window::handle_octave_ready (void) + void main_window::handle_octave_ready () { // actions after the startup files are executed @@ -1811,7 +1811,7 @@ focus_command_window (); // make sure that the command window has focus } - void main_window::handle_set_path_dialog_request (void) + void main_window::handle_set_path_dialog_request () { if (m_set_path_dlg) // m_set_path_dlg is a guarded pointer! return; @@ -1880,7 +1880,7 @@ void main_window::set_screen_size (int ht, int wd) { emit interpreter_event - ([=] (void) + ([=] () { // INTERPRETER THREAD @@ -1888,7 +1888,7 @@ }); } - void main_window::clipboard_has_changed (void) + void main_window::clipboard_has_changed () { if (m_clipboard->text ().isEmpty ()) { @@ -1902,7 +1902,7 @@ } } - void main_window::clear_clipboard (void) + void main_window::clear_clipboard () { m_clipboard->clear (QClipboard::Clipboard); } @@ -1918,15 +1918,15 @@ } } - void main_window::restore_create_file_setting (void) + void main_window::restore_create_file_setting () { // restore the new files creation setting gui_settings settings; settings.setValue (ed_create_new_file.settings_key (), false); - disconnect (m_editor_window, SIGNAL (file_loaded_signal (void)), - this, SLOT (restore_create_file_setting (void))); + disconnect (m_editor_window, SIGNAL (file_loaded_signal ()), + this, SLOT (restore_create_file_setting ())); } void main_window::set_file_encoding (const QString& new_encoding) @@ -1943,7 +1943,7 @@ emit open_file_signal (open_file_names.at (i), m_file_encoding, -1); } - void main_window::profiler_session (void) + void main_window::profiler_session () { emit interpreter_event ([=] (interpreter& interp) @@ -1954,7 +1954,7 @@ }); } - void main_window::profiler_session_resume (void) + void main_window::profiler_session_resume () { emit interpreter_event ([=] (interpreter& interp) @@ -1965,7 +1965,7 @@ }); } - void main_window::profiler_stop (void) + void main_window::profiler_stop () { emit interpreter_event ([=] (interpreter& interp) @@ -1988,7 +1988,7 @@ m_profiler_status_indicator->set_state (state); } - void main_window::profiler_show (void) + void main_window::profiler_show () { // Do not use a separate interpreter event as in the other // profiler slots since the output of the command "profshow" @@ -2030,7 +2030,7 @@ e->ignore (); } - void main_window::construct_central_widget (void) + void main_window::construct_central_widget () { // Create and set the central widget. QMainWindow takes ownership of // the widget (pointer) so there is no need to delete the object upon @@ -2046,7 +2046,7 @@ // Main subroutine of the constructor - void main_window::construct (void) + void main_window::construct () { setWindowIcon (QIcon (dw_icon_set_names["NONE"])); @@ -2093,7 +2093,7 @@ configure_shortcuts (); } - void main_window::construct_octave_qt_link (void) + void main_window::construct_octave_qt_link () { interpreter_qobject *interp_qobj = m_octave_qobj.interpreter_qobj (); @@ -2170,7 +2170,7 @@ return menu; } - void main_window::construct_menu_bar (void) + void main_window::construct_menu_bar () { QMenuBar *menu_bar = menuBar (); @@ -2215,7 +2215,7 @@ m_open_action = add_action (file_menu, settings.icon ("document-open"), tr ("Open..."), - SLOT (request_open_file (void)), this); + SLOT (request_open_file ()), this); m_open_action->setToolTip (tr ("Open an existing file in editor")); #if defined (HAVE_QSCINTILLA) @@ -2226,17 +2226,17 @@ m_load_workspace_action = add_action (file_menu, QIcon (), tr ("Load Workspace..."), - SLOT (handle_load_workspace_request (void)), this); + SLOT (handle_load_workspace_request ()), this); m_save_workspace_action = add_action (file_menu, QIcon (), tr ("Save Workspace As..."), - SLOT (handle_save_workspace_request (void)), this); + SLOT (handle_save_workspace_request ()), this); file_menu->addSeparator (); m_exit_action = add_action (file_menu, QIcon (), tr ("Exit"), - SLOT (close (void)), this); + SLOT (close ()), this); m_exit_action->setMenuRole (QAction::QuitRole); // Connect signal related to opening or creating editor files @@ -2260,15 +2260,15 @@ m_new_script_action = add_action (new_menu, settings.icon ("document-new"), tr ("New Script"), - SLOT (request_new_script (void)), this); + SLOT (request_new_script ()), this); m_new_function_action = add_action (new_menu, QIcon (), tr ("New Function..."), - SLOT (request_new_function (void)), this); + SLOT (request_new_function ()), this); m_new_figure_action = add_action (new_menu, QIcon (), tr ("New Figure"), - SLOT (handle_new_figure_request (void)), this); + SLOT (handle_new_figure_request ()), this); } void main_window::construct_edit_menu (QMenuBar *p) @@ -2386,19 +2386,19 @@ m_debug_step_over = construct_debug_menu_item ("db-step", tr ("Step"), - SLOT (debug_step_over (void))); + SLOT (debug_step_over ())); m_debug_step_into = construct_debug_menu_item ("db-step-in", tr ("Step In"), - SLOT (debug_step_into (void))); + SLOT (debug_step_into ())); m_debug_step_out = construct_debug_menu_item ("db-step-out", tr ("Step Out"), - SLOT (debug_step_out (void))); + SLOT (debug_step_out ())); m_debug_continue = construct_debug_menu_item ("db-cont", tr ("Continue"), - SLOT (debug_continue (void))); + SLOT (debug_continue ())); m_debug_menu->addSeparator (); #if defined (HAVE_QSCINTILLA) @@ -2407,7 +2407,7 @@ m_debug_quit = construct_debug_menu_item ("db-stop", tr ("Quit Debug Mode"), - SLOT (debug_quit (void))); + SLOT (debug_quit ())); } void main_window::construct_tools_menu (QMenuBar *p) @@ -2461,8 +2461,8 @@ else { // action for focus of dock widget - connect (action, SIGNAL (triggered (void)), - widget, SLOT (activate (void))); + connect (action, SIGNAL (triggered ()), + widget, SLOT (activate ())); } } else @@ -2524,12 +2524,12 @@ window_menu->addSeparator (); m_previous_dock_action = add_action (window_menu, QIcon (), - tr ("Previous Widget"), SLOT (go_to_previous_widget (void))); + tr ("Previous Widget"), SLOT (go_to_previous_widget ())); window_menu->addSeparator (); m_reset_windows_action = add_action (window_menu, QIcon (), - tr ("Reset Default Window Layout"), SLOT (reset_windows (void))); + tr ("Reset Default Window Layout"), SLOT (reset_windows ())); } void main_window::construct_help_menu (QMenuBar *p) @@ -2590,7 +2590,7 @@ m_current_news_action->setShortcutContext (Qt::ApplicationShortcut); } - void main_window::construct_tool_bar (void) + void main_window::construct_tool_bar () { m_main_tool_bar = addToolBar (tr ("Toolbar")); m_main_tool_bar->setStyleSheet (m_main_tool_bar->styleSheet () @@ -2650,7 +2650,7 @@ this, &main_window::handle_undo_request); } - void main_window::focus_console_after_command (void) + void main_window::focus_console_after_command () { gui_settings settings; @@ -2658,7 +2658,7 @@ focus_command_window (); } - void main_window::configure_shortcuts (void) + void main_window::configure_shortcuts () { gui_settings settings; @@ -2733,7 +2733,7 @@ settings.set_shortcut (m_current_news_action, sc_main_news_community_news, enable); } - QList main_window::dock_widget_list (void) + QList main_window::dock_widget_list () { QList list = QList (); list.append (static_cast (m_command_window)); @@ -2783,7 +2783,7 @@ resize (2*win_x/3, 7*win_y/8); } - void main_window::reset_windows (void) + void main_window::reset_windows () { // Slot for resetting the window layout to the default one hide (); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/main-window.h --- a/libgui/src/main-window.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/main-window.h Tue Jan 24 17:19:44 2023 -0800 @@ -80,35 +80,35 @@ main_window (base_qobject& oct_qobj); - ~main_window (void); + ~main_window (); void make_dock_widget_connections (octave_dock_widget *dw); - bool command_window_has_focus (void) const; + bool command_window_has_focus () const; - void focus_command_window (void); + void focus_command_window (); - bool confirm_shutdown (void); + bool confirm_shutdown (); signals: // Note: CLOSE_GUI_SIGNAL is currently only used by the new // experimental terminal widget. - void close_gui_signal (void); + void close_gui_signal (); void active_dock_changed (octave_dock_widget *, octave_dock_widget *); void editor_focus_changed (bool); - void settings_changed (void); - void init_terminal_size_signal (void); - void init_window_menu (void); + void settings_changed (); + void init_terminal_size_signal (); + void init_window_menu (); void new_file_signal (const QString&); void open_file_signal (const QString&); void open_file_signal (const QString& file, const QString& enc, int line); - void step_into_file_signal (void); + void step_into_file_signal (); void show_community_news_signal (int serial); - void show_release_notes_signal (void); + void show_release_notes_signal (); void update_gui_lexer_signal (bool); @@ -117,10 +117,10 @@ void update_breakpoint_marker_signal (bool insert, const QString& file, int line, const QString& cond); - void copyClipboard_signal (void); - void pasteClipboard_signal (void); - void selectAll_signal (void); - void undo_signal (void); + void copyClipboard_signal (); + void pasteClipboard_signal (); + void selectAll_signal (); + void undo_signal (); void add_actions_signal (QList action_list); @@ -137,56 +137,56 @@ void focus_changed (QWidget *w_old, QWidget *w_new); void focus_window (const QString& win_name); - void request_reload_settings (void); + void request_reload_settings (); void report_status_message (const QString& statusMessage); - void handle_save_workspace_request (void); + void handle_save_workspace_request (); void handle_load_workspace_request (const QString& file = QString ()); void handle_open_any_request (const QString& file = QString ()); - void handle_clear_workspace_request (void); - void handle_clear_command_window_request (void); - void handle_clear_history_request (void); - void handle_undo_request (void); + void handle_clear_workspace_request (); + void handle_clear_command_window_request (); + void handle_clear_history_request (); + void handle_undo_request (); void modify_path (const QStringList& dir_list, bool rm, bool subdirs); void edit_mfile (const QString&, int); void file_remove_proxy (const QString& o, const QString& n); - void open_online_documentation_page (void); - void open_bug_tracker_page (void); - void open_octave_packages_page (void); - void open_contribute_page (void); - void open_donate_page (void); + void open_online_documentation_page (); + void open_bug_tracker_page (); + void open_octave_packages_page (); + void open_contribute_page (); + void open_donate_page (); void process_settings_dialog_request (const QString& desired_tab = QString ()); - void show_about_octave (void); + void show_about_octave (); void notice_settings (bool update_by_worker = false); QPalette getFusionDarkPalette(); - void prepare_to_exit (void); - void go_to_previous_widget (void); - void reset_windows (void); + void prepare_to_exit (); + void go_to_previous_widget (); + void reset_windows (); void do_reset_windows (bool show = true, bool save = true, bool force_all = false); void update_octave_directory (const QString& dir); - void browse_for_directory (void); + void browse_for_directory (); void set_current_working_directory (const QString& dir); - void change_directory_up (void); - void accept_directory_line_edit (void); + void change_directory_up (); + void accept_directory_line_edit (); void execute_command_in_terminal (const QString& dir); void run_file_in_terminal (const QFileInfo& info); - void handle_new_figure_request (void); + void handle_new_figure_request (); - void handle_enter_debugger (void); - void handle_exit_debugger (void); - void debug_continue (void); - void debug_step_into (void); - void debug_step_over (void); - void debug_step_out (void); - void debug_quit (void); + void handle_enter_debugger (); + void handle_exit_debugger (); + void debug_continue (); + void debug_step_into (); + void debug_step_over (); + void debug_step_out (); + void debug_quit (); void editor_tabs_changed (bool, bool); - void request_open_file (void); + void request_open_file (); void request_new_script (const QString& commands = QString ()); void request_new_function (bool triggered = true); void handle_edit_mfile_request (const QString& name, const QString& file, @@ -198,28 +198,28 @@ const QString& file, int line, const QString& cond); - void read_settings (void); - void init_terminal_size (void); - void set_window_layout (void); - void write_settings (void); + void read_settings (); + void init_terminal_size (); + void set_window_layout (); + void write_settings (); - void copyClipboard (void); - void pasteClipboard (void); - void selectAll (void); + void copyClipboard (); + void pasteClipboard (); + void selectAll (); void handle_gui_status_update (const QString& feature, const QString& status); - void focus_console_after_command (void); + void focus_console_after_command (); - void profiler_session (void); - void profiler_session_resume (void); - void profiler_stop (void); + void profiler_session (); + void profiler_session_resume (); + void profiler_stop (); void handle_profiler_status_update (bool); - void profiler_show (void); + void profiler_show (); void handle_octave_ready (); - void handle_set_path_dialog_request (void); + void handle_set_path_dialog_request (); //! Find files dialog. //!@{ @@ -231,13 +231,13 @@ //! Handling the clipboard. //!@{ - void clipboard_has_changed (void); + void clipboard_has_changed (); void clear_clipboard (); //!@} //! Returns a list of dock widgets. - QList get_dock_widget_list (void) + QList get_dock_widget_list () { return dock_widget_list (); } @@ -245,7 +245,7 @@ private slots: void disable_menu_shortcuts (bool disable); - void restore_create_file_setting (void); + void restore_create_file_setting (); void set_file_encoding (const QString& new_encoding); void request_open_files (const QStringList& open_file_names); @@ -257,28 +257,28 @@ private: - void adopt_dock_widgets (void); + void adopt_dock_widgets (); - void adopt_terminal_widget (void); - void adopt_documentation_widget (void); - void adopt_file_browser_widget (void); - void adopt_history_widget (void); - void adopt_workspace_widget (void); - void adopt_editor_widget (void); - void adopt_variable_editor_widget (void); + void adopt_terminal_widget (); + void adopt_documentation_widget (); + void adopt_file_browser_widget (); + void adopt_history_widget (); + void adopt_workspace_widget (); + void adopt_editor_widget (); + void adopt_variable_editor_widget (); - void construct_central_widget (void); + void construct_central_widget (); - void construct (void); + void construct (); - void construct_octave_qt_link (void); + void construct_octave_qt_link (); QAction * add_action (QMenu *menu, const QIcon& icon, const QString& text, const char *member, const QWidget *receiver = nullptr); QMenu * m_add_menu (QMenuBar *p, QString text); - void construct_menu_bar (void); + void construct_menu_bar (); void construct_file_menu (QMenuBar *p); void construct_new_menu (QMenu *p); void construct_edit_menu (QMenuBar *p); @@ -294,15 +294,15 @@ void construct_news_menu (QMenuBar *p); - void construct_tool_bar (void); + void construct_tool_bar (); - void configure_shortcuts (void); + void configure_shortcuts (); - QList dock_widget_list (void); + QList dock_widget_list (); void update_default_encoding (const QString& default_encoding); - void set_default_geometry (void); + void set_default_geometry (); void resize_dock (QDockWidget *dw, int width, int height); base_qobject& m_octave_qobj; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/news-reader.cc --- a/libgui/src/news-reader.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/news-reader.cc Tue Jan 24 17:19:44 2023 -0800 @@ -41,7 +41,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) - void news_reader::process (void) + void news_reader::process () { QString html_text; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/news-reader.h --- a/libgui/src/news-reader.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/news-reader.h Tue Jan 24 17:19:44 2023 -0800 @@ -47,11 +47,11 @@ void display_news_signal (const QString& news); - void finished (void); + void finished (); public slots: - void process (void); + void process (); private: diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/octave-dock-widget.cc --- a/libgui/src/octave-dock-widget.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/octave-dock-widget.cc Tue Jan 24 17:19:44 2023 -0800 @@ -257,7 +257,7 @@ } void - octave_dock_widget::init_window_menu_entry (void) + octave_dock_widget::init_window_menu_entry () { emit active_changed (isVisible ()); // emit once for init of window menu } @@ -438,7 +438,7 @@ // get focus widget QWidget * - octave_dock_widget::focusWidget (void) + octave_dock_widget::focusWidget () { QWidget *w = QApplication::focusWidget (); if (w && w->focusProxy ()) w = w->focusProxy (); @@ -467,7 +467,7 @@ } void - octave_dock_widget::handle_settings (void) + octave_dock_widget::handle_settings () { gui_settings settings; @@ -575,7 +575,7 @@ } void - octave_dock_widget::save_settings (void) + octave_dock_widget::save_settings () { gui_settings settings; @@ -616,7 +616,7 @@ } void - octave_dock_widget::store_geometry (void) + octave_dock_widget::store_geometry () { if (isFloating ()) { @@ -653,7 +653,7 @@ emit active_changed (false); } - void octave_dock_widget::activate (void) + void octave_dock_widget::activate () { if (! isVisible ()) setVisible (true); @@ -815,7 +815,7 @@ // set focus to previously active widget in tabbed widget stack void - octave_dock_widget::set_focus_predecessor (void) + octave_dock_widget::set_focus_predecessor () { // only != 0 if widget was tabbed if (m_predecessor_widget && m_predecessor_widget->isVisible ()) diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/octave-dock-widget.h --- a/libgui/src/octave-dock-widget.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/octave-dock-widget.h Tue Jan 24 17:19:44 2023 -0800 @@ -47,7 +47,7 @@ label_dock_widget (QWidget *p); - ~label_dock_widget (void) = default; + ~label_dock_widget () = default; // set_title() uses the custom title bar while setWindowTitle() uses // the default title bar (with style sheets) @@ -57,14 +57,14 @@ //! Slots to handle copy & paste. //!@{ - virtual void copyClipboard (void) { } - virtual void pasteClipboard (void) { } - virtual void selectAll (void) { } + virtual void copyClipboard () { } + virtual void pasteClipboard () { } + virtual void selectAll () { } //!@} //! Slot to handle undo. - virtual void do_undo (void) { } + virtual void do_undo () { } protected: @@ -87,14 +87,14 @@ octave_dock_widget (const QString& obj_name, QWidget *p); - ~octave_dock_widget (void) = default; + ~octave_dock_widget () = default; void set_predecessor_widget (octave_dock_widget *prev_widget); void set_main_window (main_window *mw); void set_adopted (bool adopted = true) { m_adopted = adopted; } - bool adopted (void) const { return m_adopted; } + bool adopted () const { return m_adopted; } signals: @@ -105,29 +105,29 @@ void queue_make_window (bool widget_was_dragged); - void queue_make_widget (void); + void queue_make_widget (); protected: virtual void closeEvent (QCloseEvent *e); - QWidget * focusWidget (void); + QWidget * focusWidget (); bool event (QEvent *event); public slots: - virtual void activate (void); + virtual void activate (); virtual void handle_visibility (bool visible); - virtual void notice_settings (void) { } + virtual void notice_settings () { } - virtual void save_settings (void); + virtual void save_settings (); - void init_window_menu_entry (void); + void init_window_menu_entry (); - void handle_settings (void); + void handle_settings (); void handle_active_dock_changed (octave_dock_widget *, octave_dock_widget *); @@ -156,8 +156,8 @@ private: void set_style (bool active); - void set_focus_predecessor (void); - void store_geometry (void); + void set_focus_predecessor (); + void store_geometry (); private: diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/octave-qobject.cc --- a/libgui/src/octave-qobject.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/octave-qobject.cc Tue Jan 24 17:19:44 2023 -0800 @@ -73,7 +73,7 @@ // Bug #55940 (Disable App Nap on Mac) #if defined (Q_OS_MAC) -static void disable_app_nap (void) +static void disable_app_nap () { Class process_info_class; SEL process_info_selector; @@ -148,7 +148,7 @@ catch (execution_exception& ee) { emit interpreter_event - ([=] (void) + ([=] () { // INTERPRETER THREAD throw ee; @@ -320,7 +320,7 @@ start_main_thread (); } - base_qobject::~base_qobject (void) + base_qobject::~base_qobject () { // Note that we don't delete m_main_thread here. That is handled by // deleteLater slot that is called when the m_main_thread issues a @@ -383,7 +383,7 @@ string_vector::delete_c_str_vec (m_argv); } - void base_qobject::config_translators (void) + void base_qobject::config_translators () { if (m_translators_installed) return; @@ -399,7 +399,7 @@ m_translators_installed = true; } - void base_qobject::start_main_thread (void) + void base_qobject::start_main_thread () { // Note: if using the new experimental terminal widget, we defer // initializing and executing the interpreter until the main event @@ -409,14 +409,14 @@ // the interpreter until after the main window and QApplication are // running to prevent race conditions. - QTimer::singleShot (0, m_interpreter_qobj, SLOT (execute (void))); + QTimer::singleShot (0, m_interpreter_qobj, SLOT (execute ())); m_interpreter_qobj->moveToThread (m_main_thread); m_main_thread->start (); } - int base_qobject::exec (void) + int base_qobject::exec () { int status = m_qapplication->exec (); @@ -433,12 +433,12 @@ // Provided for convenience. Will be removed once we eliminate the // old terminal widget. - bool base_qobject::experimental_terminal_widget (void) const + bool base_qobject::experimental_terminal_widget () const { return m_app_context.experimental_terminal_widget (); } - bool base_qobject::gui_running (void) const + bool base_qobject::gui_running () const { return m_app_context.gui_running (); } @@ -738,7 +738,7 @@ return m_community_news; } - QPointer base_qobject::release_notes_widget (void) + QPointer base_qobject::release_notes_widget () { if (! m_release_notes) m_release_notes = QPointer (new release_notes ()); @@ -746,7 +746,7 @@ return m_release_notes; } - bool base_qobject::confirm_shutdown (void) + bool base_qobject::confirm_shutdown () { // Currently, we forward to main_window::confirm_shutdown instead of // just displaying a dialog box here because the main_window also @@ -799,7 +799,7 @@ } } - void base_qobject::show_terminal_window (void) + void base_qobject::show_terminal_window () { terminal_dock_widget *widget = (m_terminal_widget @@ -827,7 +827,7 @@ } } - void base_qobject::show_file_browser_window (void) + void base_qobject::show_file_browser_window () { files_dock_widget *widget = m_file_browser_widget ? m_file_browser_widget : file_browser_widget (); @@ -839,7 +839,7 @@ } } - void base_qobject::show_command_history_window (void) + void base_qobject::show_command_history_window () { history_dock_widget *widget = m_history_widget ? m_history_widget : history_widget (); @@ -851,7 +851,7 @@ } } - void base_qobject::show_workspace_window (void) + void base_qobject::show_workspace_window () { workspace_view *widget = m_workspace_widget ? m_workspace_widget : workspace_widget (); @@ -880,7 +880,7 @@ widget->edit_variable (name, value); } - void base_qobject::handle_variable_editor_update (void) + void base_qobject::handle_variable_editor_update () { // Called when the variable editor emits the updated signal. The size // of a variable may have changed, so we refresh the workspace in the @@ -908,7 +908,7 @@ m_community_news->display (); } - void base_qobject::show_release_notes (void) + void base_qobject::show_release_notes () { // Ensure widget exists. release_notes_widget (); @@ -934,7 +934,7 @@ }); } - void base_qobject::close_gui (void) + void base_qobject::close_gui () { if (m_app_context.experimental_terminal_widget ()) { @@ -968,7 +968,7 @@ } } - void base_qobject::interpreter_ready (void) + void base_qobject::interpreter_ready () { m_interpreter_ready = true; } @@ -997,7 +997,7 @@ m_interpreter_qobj->interpreter_event (meth); } - void base_qobject::interpreter_interrupt (void) + void base_qobject::interpreter_interrupt () { m_interpreter_qobj->interrupt (); } @@ -1005,19 +1005,19 @@ // FIXME: Should we try to make the pause, stop, and resume actions // work for both the old and new terminal widget? - void base_qobject::interpreter_pause (void) + void base_qobject::interpreter_pause () { if (m_app_context.experimental_terminal_widget ()) m_interpreter_qobj->pause (); } - void base_qobject::interpreter_stop (void) + void base_qobject::interpreter_stop () { if (m_app_context.experimental_terminal_widget ()) m_interpreter_qobj->stop (); } - void base_qobject::interpreter_resume (void) + void base_qobject::interpreter_resume () { if (m_app_context.experimental_terminal_widget ()) m_interpreter_qobj->resume (); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/octave-qobject.h --- a/libgui/src/octave-qobject.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/octave-qobject.h Tue Jan 24 17:19:44 2023 -0800 @@ -64,7 +64,7 @@ virtual bool notify (QObject *receiver, QEvent *e) override; - ~octave_qapplication (void) { }; + ~octave_qapplication () { }; signals: @@ -104,53 +104,53 @@ // experimental terminal widget. base_qobject (qt_application& app_context, bool gui_app = false); - ~base_qobject (void); + ~base_qobject (); - void config_translators (void); + void config_translators (); - void start_main_thread (void); + void start_main_thread (); - int exec (void); + int exec (); // The Octave application context. - qt_application& app_context (void) { return m_app_context; } + qt_application& app_context () { return m_app_context; } // The Qt QApplication. - QApplication * qapplication (void) { return m_qapplication; }; + QApplication * qapplication () { return m_qapplication; }; // Provided for convenience. Will be removed once we eliminate the // old terminal widget. - bool experimental_terminal_widget (void) const; + bool experimental_terminal_widget () const; // Provided for convenience. - bool gui_running (void) const; + bool gui_running () const; - bool have_terminal_window (void) const + bool have_terminal_window () const { return ! m_terminal_widget.isNull (); } - main_window * get_main_window (void) + main_window * get_main_window () { return m_main_window; } - std::shared_ptr get_qt_interpreter_events (void) + std::shared_ptr get_qt_interpreter_events () { return m_qt_interpreter_events; } - qt_interpreter_events * qt_link (void) + qt_interpreter_events * qt_link () { return m_qt_interpreter_events.get (); } - interpreter_qobject * interpreter_qobj (void) + interpreter_qobject * interpreter_qobj () { return m_interpreter_qobj; } - workspace_model * get_workspace_model (void) + workspace_model * get_workspace_model () { return m_workspace_model; } @@ -181,16 +181,16 @@ QPointer community_news_widget (int serial = -1); - QPointer release_notes_widget (void); + QPointer release_notes_widget (); - QThread * main_thread (void) { return m_main_thread; } + QThread * main_thread () { return m_main_thread; } // Declared virtual so that a derived class may redefine this // method. - virtual bool confirm_shutdown (void); + virtual bool confirm_shutdown (); - bool is_gui_app (void) const { return m_gui_app; } + bool is_gui_app () const { return m_gui_app; } template void connect_interpreter_events (T *widget) { @@ -208,40 +208,40 @@ // Note: START_GUI and CLOSE_GUI don't currently perform any work // with the old terminal widget. void start_gui (bool gui_app); - void close_gui (void); + void close_gui (); - void show_terminal_window (void); + void show_terminal_window (); void show_documentation_window (const QString& file); - void show_file_browser_window (void); + void show_file_browser_window (); - void show_command_history_window (void); + void show_command_history_window (); - void show_workspace_window (void); + void show_workspace_window (); void show_variable_editor_window (const QString& name, const octave_value& value); - void handle_variable_editor_update (void); + void handle_variable_editor_update (); void show_community_news (int serial); - void show_release_notes (void); + void show_release_notes (); - void interpreter_ready (void); + void interpreter_ready (); void interpreter_event (const fcn_callback& fcn); void interpreter_event (const meth_callback& meth); - void interpreter_interrupt (void); + void interpreter_interrupt (); // Note: these currently only work with the new experimental // terminal widget. - void interpreter_pause (void); - void interpreter_stop (void); - void interpreter_resume (void); + void interpreter_pause (); + void interpreter_stop (); + void interpreter_resume (); void copy_image_to_clipboard (const QString& file, bool remove_file); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/qt-application.cc --- a/libgui/src/qt-application.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/qt-application.cc Tue Jan 24 17:19:44 2023 -0800 @@ -78,7 +78,7 @@ sysdep_init (); } - bool qt_application::start_gui_p (void) const + bool qt_application::start_gui_p () const { // Note: this function is not needed if using the experimental // terminal widget, so return a dummy value of false in that case. @@ -86,7 +86,7 @@ return experimental_terminal_widget () ? false : m_options.gui (); } - int qt_application::execute (void) + int qt_application::execute () { octave_block_interrupt_signal (); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/qt-application.h --- a/libgui/src/qt-application.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/qt-application.h Tue Jan 24 17:19:44 2023 -0800 @@ -60,14 +60,14 @@ qt_application& operator = (const qt_application&) = delete; - ~qt_application (void) = default; + ~qt_application () = default; // Should we start the GUI or fall back to the CLI? - bool start_gui_p (void) const; + bool start_gui_p () const; - int execute (void); + int execute (); - bool gui_running (void) const { return m_gui_running; } + bool gui_running () const { return m_gui_running; } void gui_running (bool arg) { m_gui_running = arg; } private: diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/qt-interpreter-events.cc --- a/libgui/src/qt-interpreter-events.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/qt-interpreter-events.cc Tue Jan 24 17:19:44 2023 -0800 @@ -138,7 +138,7 @@ emit start_gui_signal (gui_app); } - void qt_interpreter_events::close_gui (void) + void qt_interpreter_events::close_gui () { if (m_octave_qobj.experimental_terminal_widget ()) emit close_gui_signal (); @@ -245,22 +245,22 @@ return answer.toStdString (); } - void qt_interpreter_events::update_path_dialog (void) + void qt_interpreter_events::update_path_dialog () { emit update_path_dialog_signal (); } - void qt_interpreter_events::show_preferences (void) + void qt_interpreter_events::show_preferences () { emit show_preferences_signal (); } - void qt_interpreter_events::apply_preferences (void) + void qt_interpreter_events::apply_preferences () { emit apply_new_settings (); } - void qt_interpreter_events::show_terminal_window (void) + void qt_interpreter_events::show_terminal_window () { emit show_terminal_window_signal (); } @@ -272,17 +272,17 @@ return true; } - void qt_interpreter_events::show_file_browser (void) + void qt_interpreter_events::show_file_browser () { emit show_file_browser_signal (); } - void qt_interpreter_events::show_command_history (void) + void qt_interpreter_events::show_command_history () { emit show_command_history_signal (); } - void qt_interpreter_events::show_workspace (void) + void qt_interpreter_events::show_workspace () { emit show_workspace_signal (); } @@ -292,7 +292,7 @@ emit show_community_news_signal (serial); } - void qt_interpreter_events::show_release_notes (void) + void qt_interpreter_events::show_release_notes () { emit show_release_notes_signal (); } @@ -310,7 +310,7 @@ emit edit_variable_signal (QString::fromStdString (expr), val); } - bool qt_interpreter_events::confirm_shutdown (void) + bool qt_interpreter_events::confirm_shutdown () { QMutexLocker autolock (&m_mutex); @@ -534,7 +534,7 @@ QString::fromStdString (status)); } - void qt_interpreter_events::update_gui_lexer (void) + void qt_interpreter_events::update_gui_lexer () { emit update_gui_lexer_signal (true); } @@ -575,7 +575,7 @@ emit refresh_variable_editor_signal (); } - void qt_interpreter_events::clear_workspace (void) + void qt_interpreter_events::clear_workspace () { emit clear_workspace_signal (); } @@ -600,15 +600,15 @@ emit append_history_signal (QString::fromStdString (hist_entry)); } - void qt_interpreter_events::clear_history (void) + void qt_interpreter_events::clear_history () { emit clear_history_signal (); } - void qt_interpreter_events::pre_input_event (void) + void qt_interpreter_events::pre_input_event () { } - void qt_interpreter_events::post_input_event (void) + void qt_interpreter_events::post_input_event () { } void qt_interpreter_events::enter_debugger_event (const std::string& /*fcn_name*/, @@ -630,7 +630,7 @@ delete_debugger_pointer (file, line); } - void qt_interpreter_events::exit_debugger_event (void) + void qt_interpreter_events::exit_debugger_event () { emit exit_debugger_signal (); } @@ -661,7 +661,7 @@ } void - qt_interpreter_events::confirm_shutdown_octave (void) + qt_interpreter_events::confirm_shutdown_octave () { QMutexLocker autolock (&m_mutex); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/qt-interpreter-events.h --- a/libgui/src/qt-interpreter-events.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/qt-interpreter-events.h Tue Jan 24 17:19:44 2023 -0800 @@ -78,14 +78,14 @@ qt_interpreter_events& operator = (const qt_interpreter_events&) = delete; - ~qt_interpreter_events (void) = default; + ~qt_interpreter_events () = default; // Note: these functions currently do nothing with the old terminal // widget. void start_gui (bool gui_app = false); - void close_gui (void); + void close_gui (); - bool have_dialogs (void) const { return true; } + bool have_dialogs () const { return true; } std::list file_dialog (const filter_list& filter, const std::string& title, @@ -112,30 +112,30 @@ const std::string& btn1, const std::string& btn2, const std::string& btn3, const std::string& btndef); - void update_path_dialog (void); + void update_path_dialog (); - void show_preferences (void); + void show_preferences (); - void apply_preferences (void); + void apply_preferences (); - void show_terminal_window (void); + void show_terminal_window (); bool show_documentation (const std::string& file); - void show_file_browser (void); + void show_file_browser (); - void show_command_history (void); + void show_command_history (); - void show_workspace (void); + void show_workspace (); void show_community_news (int serial); - void show_release_notes (void); + void show_release_notes (); bool edit_file (const std::string& file); void edit_variable (const std::string& name, const octave_value& val); - bool confirm_shutdown (void); + bool confirm_shutdown (); bool prompt_new_edit_file (const std::string& file); @@ -166,7 +166,7 @@ void gui_status_update (const std::string& feature, const std::string& status); - void update_gui_lexer (void); + void update_gui_lexer (); void directory_changed (const std::string& dir); @@ -179,7 +179,7 @@ const symbol_info_list& syminfo, bool update_variable_editor); - void clear_workspace (void); + void clear_workspace (); void update_prompt (const std::string& prompt); @@ -187,33 +187,33 @@ void append_history (const std::string& hist_entry); - void clear_history (void); + void clear_history (); - void pre_input_event (void); + void pre_input_event (); - void post_input_event (void); + void post_input_event (); void enter_debugger_event (const std::string& fcn_name, const std::string& fcn_file_name, int line); void execute_in_debugger_event (const std::string& file, int line); - void exit_debugger_event (void); + void exit_debugger_event (); void update_breakpoint (bool insert, const std::string& file, int line, const std::string& cond); - void lock (void) { m_mutex.lock (); } + void lock () { m_mutex.lock (); } - void wait (void) { m_waitcondition.wait (&m_mutex); } + void wait () { m_waitcondition.wait (&m_mutex); } - void unlock (void) { m_mutex.unlock (); } + void unlock () { m_mutex.unlock (); } - void wake_all (void) { m_waitcondition.wakeAll (); } + void wake_all () { m_waitcondition.wakeAll (); } public slots: - void confirm_shutdown_octave (void); + void confirm_shutdown_octave (); void get_named_icon_slot (const QString& name); @@ -223,7 +223,7 @@ // Note: these signals are not currently used by the old terminal widget. void start_gui_signal (bool gui_app); - void close_gui_signal (void); + void close_gui_signal (); void copy_image_to_clipboard_signal (const QString& file, bool remove_file); @@ -233,7 +233,7 @@ void directory_changed_signal (const QString& dir); - void update_path_dialog_signal (void); + void update_path_dialog_signal (); void file_remove_signal (const QString& old_name, const QString& new_name); @@ -244,7 +244,7 @@ void set_workspace_signal (bool top_level, bool debug, const symbol_info_list& syminfo); - void clear_workspace_signal (void); + void clear_workspace_signal (); void update_prompt_signal (const QString& prompt); @@ -252,11 +252,11 @@ void append_history_signal (const QString& hist_entry); - void clear_history_signal (void); + void clear_history_signal (); - void enter_debugger_signal (void); + void enter_debugger_signal (); - void exit_debugger_signal (void); + void exit_debugger_signal (); void update_breakpoint_marker_signal (bool insert, const QString& file, int line, const QString& cond); @@ -265,11 +265,11 @@ void delete_debugger_pointer_signal (const QString&, int); - void show_preferences_signal (void); + void show_preferences_signal (); void gui_preference_signal (const QString& key, const QString& value); - void show_terminal_window_signal (void); + void show_terminal_window_signal (); void show_documentation_signal (const QString& file); @@ -277,14 +277,14 @@ void unregister_documentation_signal (const QString& file); - void show_file_browser_signal (void); + void show_file_browser_signal (); - void show_command_history_signal (void); + void show_command_history_signal (); - void show_workspace_signal (void); + void show_workspace_signal (); void show_community_news_signal (int serial); - void show_release_notes_signal (void); + void show_release_notes_signal (); // Note: the next two signals are currently not used by the old terminal widget. void interpreter_output_signal (const QString& msg); @@ -296,15 +296,15 @@ void edit_variable_signal (const QString& name, const octave_value& val); - void refresh_variable_editor_signal (void); + void refresh_variable_editor_signal (); - void confirm_shutdown_signal (void); + void confirm_shutdown_signal (); void get_named_icon_signal (const QString& name); void settings_changed (bool); - void apply_new_settings (void); + void apply_new_settings (); private: diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/release-notes.cc --- a/libgui/src/release-notes.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/release-notes.cc Tue Jan 24 17:19:44 2023 -0800 @@ -47,7 +47,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) - release_notes::release_notes (void) + release_notes::release_notes () : QWidget (nullptr), m_browser (nullptr) { @@ -106,7 +106,7 @@ move (20, 20); // move to the top left corner } - void release_notes::display (void) + void release_notes::display () { if (! isVisible ()) show (); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/release-notes.h --- a/libgui/src/release-notes.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/release-notes.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,13 +39,13 @@ public: - release_notes (void); + release_notes (); - ~release_notes (void) = default; + ~release_notes () = default; public slots: - void display (void); + void display (); private: diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/set-path-dialog.cc --- a/libgui/src/set-path-dialog.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/set-path-dialog.cc Tue Jan 24 17:19:44 2023 -0800 @@ -172,7 +172,7 @@ restoreGeometry (settings.value(pd_geometry.settings_key ()).toByteArray()); } - void set_path_dialog::update_model (void) + void set_path_dialog::update_model () { set_path_model *m = static_cast (m_path_list->model ()); m->path_to_model (); @@ -203,17 +203,17 @@ } } - void set_path_dialog::add_dir(void) + void set_path_dialog::add_dir() { add_dir_common (false); } - void set_path_dialog::add_dir_subdirs (void) + void set_path_dialog::add_dir_subdirs () { add_dir_common (true); } - void set_path_dialog::rm_dir (void) + void set_path_dialog::rm_dir () { set_path_model *m = static_cast (m_path_list->model ()); QItemSelectionModel *selmodel = m_path_list->selectionModel (); @@ -223,7 +223,7 @@ selmodel->clearSelection (); } - void set_path_dialog::move_dir_up (void) + void set_path_dialog::move_dir_up () { set_path_model *m = static_cast (m_path_list->model ()); QItemSelectionModel *selmodel = m_path_list->selectionModel (); @@ -243,7 +243,7 @@ m_path_list->scrollTo (m->index (min_row)); } - void set_path_dialog::move_dir_down (void) + void set_path_dialog::move_dir_down () { set_path_model *m = static_cast (m_path_list->model ()); QItemSelectionModel *selmodel = m_path_list->selectionModel (); @@ -263,7 +263,7 @@ m_path_list->scrollTo (m->index (max_row)); } - void set_path_dialog::move_dir_top (void) + void set_path_dialog::move_dir_top () { set_path_model *m = static_cast (m_path_list->model ()); QItemSelectionModel *selmodel = m_path_list->selectionModel (); @@ -278,7 +278,7 @@ m_path_list->scrollTo (m->index (0)); } - void set_path_dialog::move_dir_bottom (void) + void set_path_dialog::move_dir_bottom () { set_path_model *m = static_cast (m_path_list->model ()); QItemSelectionModel *selmodel = m_path_list->selectionModel (); @@ -295,7 +295,7 @@ m_path_list->scrollTo (m->index (row_count - 1)); } - void set_path_dialog::save_settings (void) + void set_path_dialog::save_settings () { gui_settings settings; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/set-path-dialog.h --- a/libgui/src/set-path-dialog.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/set-path-dialog.h Tue Jan 24 17:19:44 2023 -0800 @@ -53,9 +53,9 @@ set_path_dialog (QWidget *parent); - virtual ~set_path_dialog (void) = default; + virtual ~set_path_dialog () = default; - void save_settings (void); + void save_settings (); signals: @@ -69,7 +69,7 @@ public slots: - void update_model (void); + void update_model (); protected: @@ -77,18 +77,18 @@ private slots: - void add_dir (void); - void add_dir_subdirs (void); + void add_dir (); + void add_dir_subdirs (); - void rm_dir (void); + void rm_dir (); - void move_dir_up (void); + void move_dir_up (); - void move_dir_down (void); + void move_dir_down (); - void move_dir_top (void); + void move_dir_top (); - void move_dir_bottom (void); + void move_dir_bottom (); private: diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/set-path-model.cc --- a/libgui/src/set-path-model.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/set-path-model.cc Tue Jan 24 17:19:44 2023 -0800 @@ -54,7 +54,7 @@ m_revertible = false; } -std::string set_path_model::to_string (void) +std::string set_path_model::to_string () { std::string path_sep = directory_path::path_sep_str (); @@ -73,7 +73,7 @@ return path_str; } -void set_path_model::model_to_path (void) +void set_path_model::model_to_path () { std::string path_str = to_string (); @@ -88,7 +88,7 @@ }); } -void set_path_model::clear (void) +void set_path_model::clear () { beginResetModel (); @@ -97,7 +97,7 @@ endResetModel (); } -void set_path_model::save (void) +void set_path_model::save () { model_to_path (); @@ -110,7 +110,7 @@ }); } -void set_path_model::revert (void) +void set_path_model::revert () { clear (); @@ -121,7 +121,7 @@ model_to_path (); } -void set_path_model::revert_last (void) +void set_path_model::revert_last () { clear (); @@ -281,7 +281,7 @@ return retval; } -void set_path_model::path_to_model (void) +void set_path_model::path_to_model () { // The interpreter_event callback function below emits a signal. // Because we don't control when that happens, use a guarded pointer diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/set-path-model.h --- a/libgui/src/set-path-model.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/set-path-model.h Tue Jan 24 17:19:44 2023 -0800 @@ -44,9 +44,9 @@ set_path_model (QObject *p = nullptr); - ~set_path_model (void) = default; + ~set_path_model () = default; - void clear (void); + void clear (); void add_dir (const QString& p); @@ -60,11 +60,11 @@ void move_dir_bottom (const QModelIndexList& indices); - std::string to_string (void); + std::string to_string (); // Overloaded Qt methods - void model_to_path (void); + void model_to_path (); int rowCount (const QModelIndex& p = QModelIndex ()) const; @@ -79,13 +79,13 @@ public slots: - void path_to_model (void); + void path_to_model (); - void save (void); + void save (); - void revert (void); + void revert (); - void revert_last (void); + void revert_last (); private slots: diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/settings-dialog.cc --- a/libgui/src/settings-dialog.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/settings-dialog.cc Tue Jan 24 17:19:44 2023 -0800 @@ -502,12 +502,12 @@ } } - void settings_dialog::get_octave_dir (void) + void settings_dialog::get_octave_dir () { get_dir (le_octave_dir, tr ("Set Octave Startup Directory")); } - void settings_dialog::get_file_browser_dir (void) + void settings_dialog::get_file_browser_dir () { get_dir (le_file_browser_dir, tr ("Set File Browser Startup Directory")); } @@ -571,7 +571,7 @@ } // slot for updating enabled state of proxy settings - void settings_dialog::proxy_items_update (void) + void settings_dialog::proxy_items_update () { bool use_proxy = use_proxy_server->isChecked (); @@ -603,7 +603,7 @@ // gui_settings_object so that the user may choose to apply or cancel // the action. - void settings_dialog::import_shortcut_set (void) + void settings_dialog::import_shortcut_set () { if (! overwrite_all_shortcuts ()) return; @@ -627,7 +627,7 @@ // choice to save current application settings or the modified values // in the dialog? - void settings_dialog::export_shortcut_set (void) + void settings_dialog::export_shortcut_set () { QString file = get_shortcuts_file_name (OSC_EXPORT); @@ -644,7 +644,7 @@ // gui_settings object so that the user may choose to apply or cancel // the action. - void settings_dialog::default_shortcut_set (void) + void settings_dialog::default_shortcut_set () { if (! overwrite_all_shortcuts ()) return; @@ -1032,7 +1032,7 @@ #endif - void settings_dialog::write_changed_settings (void) + void settings_dialog::write_changed_settings () { gui_settings settings; @@ -1261,7 +1261,7 @@ settings.sync (); } - void settings_dialog::read_workspace_colors (void) + void settings_dialog::read_workspace_colors () { gui_settings settings; @@ -1377,7 +1377,7 @@ } } - void settings_dialog::write_workspace_colors (void) + void settings_dialog::write_workspace_colors () { gui_settings settings; @@ -1405,7 +1405,7 @@ settings.sync (); } - void settings_dialog::read_terminal_colors (void) + void settings_dialog::read_terminal_colors () { gui_settings settings; @@ -1489,7 +1489,7 @@ } } - void settings_dialog::write_terminal_colors (void) + void settings_dialog::write_terminal_colors () { QCheckBox *cb_color_mode = terminal_colors_box->findChild (cs_color_mode.settings_key ()); @@ -1514,7 +1514,7 @@ settings.sync (); } - void settings_dialog::read_varedit_colors (void) + void settings_dialog::read_varedit_colors () { gui_settings settings; @@ -1599,7 +1599,7 @@ } } - void settings_dialog::write_varedit_colors (void) + void settings_dialog::write_varedit_colors () { QCheckBox *cb_color_mode = varedit_colors_box->findChild (ve_color_mode.settings_key ()); @@ -1671,7 +1671,7 @@ // (XX) - already possible (cancel operation, cancel settings // dialog, re-open settings dialog and export changes). - bool settings_dialog::overwrite_all_shortcuts (void) + bool settings_dialog::overwrite_all_shortcuts () { QMessageBox msg_box; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/settings-dialog.h --- a/libgui/src/settings-dialog.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/settings-dialog.h Tue Jan 24 17:19:44 2023 -0800 @@ -50,21 +50,21 @@ explicit settings_dialog (QWidget *parent, const QString& desired_tab = QString ()); - ~settings_dialog (void) = default; + ~settings_dialog () = default; void show_tab (const QString&); signals: - void apply_new_settings (void); + void apply_new_settings (); private slots: - void get_octave_dir (void); - void get_file_browser_dir (void); + void get_octave_dir (); + void get_file_browser_dir (); void get_dir (QLineEdit *, const QString&); void set_disabled_pref_file_browser_dir (bool disable); - void proxy_items_update (void); + void proxy_items_update (); // slots updating colors depending on theme void update_terminal_colors (int def = 0); @@ -76,9 +76,9 @@ void button_clicked (QAbstractButton *button); // slots for import/export-buttons of shortcut sets - void import_shortcut_set (void); - void export_shortcut_set (void); - void default_shortcut_set (void); + void import_shortcut_set (); + void export_shortcut_set (); + void default_shortcut_set (); private: @@ -94,20 +94,20 @@ void write_lexer_settings (QsciLexer *lexer); #endif - void write_changed_settings (void); + void write_changed_settings (); - void read_workspace_colors (void); - void write_workspace_colors (void); + void read_workspace_colors (); + void write_workspace_colors (); - void read_terminal_colors (void); - void write_terminal_colors (void); + void read_terminal_colors (); + void write_terminal_colors (); - void read_varedit_colors (void); - void write_varedit_colors (void); + void read_varedit_colors (); + void write_varedit_colors (); QString get_shortcuts_file_name (import_export_action action); - bool overwrite_all_shortcuts (void); + bool overwrite_all_shortcuts (); color_picker *m_widget_title_bg_color; color_picker *m_widget_title_bg_color_active; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/shortcuts-tree-widget.cc --- a/libgui/src/shortcuts-tree-widget.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/shortcuts-tree-widget.cc Tue Jan 24 17:19:44 2023 -0800 @@ -117,12 +117,12 @@ set_actual_text (actual_text); } -QString tree_widget_shortcut_item::settings_key (void) const +QString tree_widget_shortcut_item::settings_key () const { return m_settings_key; } -QString tree_widget_shortcut_item::description (void) const +QString tree_widget_shortcut_item::description () const { return text (DESCRIPTION_COLUMN); } @@ -132,7 +132,7 @@ setText (DESCRIPTION_COLUMN, text); } -QString tree_widget_shortcut_item::default_text (void) const +QString tree_widget_shortcut_item::default_text () const { return text (DEFAULT_COLUMN); } @@ -142,7 +142,7 @@ setText (DEFAULT_COLUMN, text); } -QString tree_widget_shortcut_item::actual_text (void) const +QString tree_widget_shortcut_item::actual_text () const { return text (ACTUAL_COLUMN); } @@ -334,7 +334,7 @@ m_shortcut_item->set_actual_text (actual_text); } -void shortcut_edit_dialog::set_default_shortcut (void) +void shortcut_edit_dialog::set_default_shortcut () { // Just remove user-set value so that the default will be used. m_edit_actual->setText (""); @@ -653,7 +653,7 @@ // Clear all user-defined settings from the tree widget and the // application settings. -void shortcuts_tree_widget::set_default_shortcuts (void) +void shortcuts_tree_widget::set_default_shortcuts () { gui_settings settings; @@ -699,7 +699,7 @@ // For each key found in application settings object, transfer // corresponding setting to the application settings object. -void shortcuts_tree_widget::write_settings (void) +void shortcuts_tree_widget::write_settings () { gui_settings settings; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/shortcuts-tree-widget.h --- a/libgui/src/shortcuts-tree-widget.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/shortcuts-tree-widget.h Tue Jan 24 17:19:44 2023 -0800 @@ -47,7 +47,7 @@ enter_shortcut (QWidget *p = nullptr); - ~enter_shortcut (void) = default; + ~enter_shortcut () = default; virtual void keyPressEvent (QKeyEvent *e); @@ -76,15 +76,15 @@ tree_widget_shortcut_item (QTreeWidgetItem *parent, const sc_pref& scpref, const QString& actual_text); - QString settings_key (void) const; + QString settings_key () const; - QString description (void) const; + QString description () const; void set_description (const QString& text); - QString default_text (void) const; + QString default_text () const; void set_default_text (const QString& text); - QString actual_text (void) const; + QString actual_text () const; void set_actual_text (const QString& text); private: @@ -105,7 +105,7 @@ void finished (int result); - void set_default_shortcut (void); + void set_default_shortcut (); signals: @@ -134,9 +134,9 @@ void export_shortcuts (gui_settings& settings); - void set_default_shortcuts (void); + void set_default_shortcuts (); - void write_settings (void); + void write_settings (); public slots: diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/tab-bar.cc --- a/libgui/src/tab-bar.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/tab-bar.cc Tue Jan 24 17:19:44 2023 -0800 @@ -48,22 +48,22 @@ } // slots for tab navigation -void tab_bar::switch_left_tab (void) +void tab_bar::switch_left_tab () { switch_tab (-1); } -void tab_bar::switch_right_tab (void) +void tab_bar::switch_right_tab () { switch_tab (1); } -void tab_bar::move_tab_left (void) +void tab_bar::move_tab_left () { switch_tab (-1, true); } -void tab_bar::move_tab_right (void) +void tab_bar::move_tab_right () { switch_tab (1, true); } @@ -91,7 +91,7 @@ setCurrentIndex (new_pos); } -void tab_bar::sort_tabs_alph (void) +void tab_bar::sort_tabs_alph () { QString current_title = tabText (currentIndex ()); int tab_with_focus = 0; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/tab-bar.h --- a/libgui/src/tab-bar.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/tab-bar.h Tue Jan 24 17:19:44 2023 -0800 @@ -49,10 +49,10 @@ tab_bar (QWidget *p); - ~tab_bar (void) = default; + ~tab_bar () = default; void set_rotated (int rotated); - QMenu * get_context_menu (void) { return m_context_menu; }; + QMenu * get_context_menu () { return m_context_menu; }; QSize tabSizeHint (int idx) const; signals: @@ -61,11 +61,11 @@ public slots: - void switch_left_tab (void); - void switch_right_tab (void); - void move_tab_left (void); - void move_tab_right (void); - void sort_tabs_alph (void); + void switch_left_tab (); + void switch_right_tab (); + void move_tab_left (); + void move_tab_right (); + void sort_tabs_alph (); private slots: diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/terminal-dock-widget.cc --- a/libgui/src/terminal-dock-widget.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/terminal-dock-widget.cc Tue Jan 24 17:19:44 2023 -0800 @@ -141,27 +141,27 @@ make_window (); } - bool terminal_dock_widget::has_focus (void) const + bool terminal_dock_widget::has_focus () const { QWidget *w = widget (); return w->hasFocus (); } - QTerminal * terminal_dock_widget::get_qterminal (void) + QTerminal * terminal_dock_widget::get_qterminal () { return (m_experimental_terminal_widget ? nullptr : dynamic_cast (m_terminal)); } #if defined (HAVE_QSCINTILLA) - command_widget * terminal_dock_widget::get_command_widget (void) + command_widget * terminal_dock_widget::get_command_widget () { return (m_experimental_terminal_widget ? dynamic_cast (m_terminal) : nullptr); } #endif - void terminal_dock_widget::notice_settings (void) + void terminal_dock_widget::notice_settings () { emit settings_changed (); } @@ -178,7 +178,7 @@ } } - void terminal_dock_widget::init_control_d_shortcut_behavior (void) + void terminal_dock_widget::init_control_d_shortcut_behavior () { gui_settings settings; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/terminal-dock-widget.h --- a/libgui/src/terminal-dock-widget.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/terminal-dock-widget.h Tue Jan 24 17:19:44 2023 -0800 @@ -45,9 +45,9 @@ terminal_dock_widget (QWidget *parent, bool experimental_terminal_widget = false); - ~terminal_dock_widget (void) = default; + ~terminal_dock_widget () = default; - bool has_focus (void) const; + bool has_focus () const; void init_command_prompt (); @@ -58,16 +58,16 @@ // widgets. // Only valid if using the old terminal widget. - QTerminal * get_qterminal (void); + QTerminal * get_qterminal (); #if defined (HAVE_QSCINTILLA) // Only valid if using the new terminal widget. - command_widget * get_command_widget (void); + command_widget * get_command_widget (); #endif signals: - void settings_changed (void); + void settings_changed (); // Note: the following four signals are // currently only used by the new experimental terminal widget. @@ -85,7 +85,7 @@ public slots: - void notice_settings (void); + void notice_settings (); private: diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/variable-editor-model.cc --- a/libgui/src/variable-editor-model.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/variable-editor-model.cc Tue Jan 24 17:19:44 2023 -0800 @@ -104,7 +104,7 @@ { } std::string -base_ve_model::name (void) const +base_ve_model::name () const { return m_name; } @@ -125,7 +125,7 @@ } int -base_ve_model::column_width (void) const +base_ve_model::column_width () const { int width = 0; @@ -257,7 +257,7 @@ } void -base_ve_model::clear_update_pending (void) +base_ve_model::clear_update_pending () { return m_update_pending.clear (); } @@ -285,7 +285,7 @@ } QString -base_ve_model::make_description_text (void) const +base_ve_model::make_description_text () const { QString lbl_txt = QString::fromStdString (m_name); @@ -330,7 +330,7 @@ maybe_resize_columns (m_data_cols + 16); } - ~numeric_model (void) = default; + ~numeric_model () = default; // No copying! @@ -394,7 +394,7 @@ m_display_cols = 1; } - ~string_model (void) = default; + ~string_model () = default; // No copying! @@ -431,7 +431,7 @@ maybe_resize_columns (m_data_cols + 16); } - ~cell_model (void) = default; + ~cell_model () = default; // No copying! @@ -532,7 +532,7 @@ m_display_cols = 1; } - ~scalar_struct_model (void) = default; + ~scalar_struct_model () = default; // No copying! @@ -655,7 +655,7 @@ m_display_cols = m_data_cols; } - ~display_only_model (void) = default; + ~display_only_model () = default; // No copying! @@ -663,7 +663,7 @@ display_only_model& operator = (const display_only_model&) = delete; - bool is_editable (void) const { return false; } + bool is_editable () const { return false; } QVariant edit_display (const QModelIndex&, int) const { @@ -679,7 +679,7 @@ return QString::fromStdString (buf.str ()); } - QString make_description_text (void) const + QString make_description_text () const { return (QString ("unable to edit %1") .arg (base_ve_model::make_description_text ())); @@ -706,7 +706,7 @@ m_display_cols = m_data_cols; } - ~vector_struct_model (void) = default; + ~vector_struct_model () = default; // No copying! @@ -839,7 +839,7 @@ maybe_resize_columns (m_data_cols + 16); } - ~struct_model (void) = default; + ~struct_model () = default; // No copying! @@ -1255,7 +1255,7 @@ } void -variable_editor_model::update_data_cache (void) +variable_editor_model::update_data_cache () { emit interpreter_event ([=] (interpreter& interp) @@ -1383,7 +1383,7 @@ } void -variable_editor_model::invalidate (void) +variable_editor_model::invalidate () { beginResetModel (); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/variable-editor-model.h --- a/libgui/src/variable-editor-model.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/variable-editor-model.h Tue Jan 24 17:19:44 2023 -0800 @@ -45,7 +45,7 @@ base_ve_model (const QString& expr, const octave_value& val); - virtual ~base_ve_model (void) = default; + virtual ~base_ve_model () = default; // No copying! @@ -57,15 +57,15 @@ virtual void maybe_resize_columns (int) { } - std::string name (void) const; + std::string name () const; bool index_ok (const QModelIndex& idx, int& row, int& col) const; - virtual bool is_editable (void) const { return true; } + virtual bool is_editable () const { return true; } virtual octave_value value_at (const QModelIndex& idx) const; - int column_width (void) const; + int column_width () const; int rowCount (const QModelIndex& = QModelIndex ()) const; @@ -85,7 +85,7 @@ QString update_pending_data (const QModelIndex& idx) const; - void clear_update_pending (void); + void clear_update_pending (); virtual char quote_char (const QModelIndex& idx) const; @@ -98,17 +98,17 @@ virtual QString subscript_expression (const QModelIndex& idx) const; - bool is_valid (void) const { return m_valid; } + bool is_valid () const { return m_valid; } - octave_idx_type data_rows (void) const { return m_data_rows; } + octave_idx_type data_rows () const { return m_data_rows; } - octave_idx_type data_columns (void) const { return m_data_cols; } + octave_idx_type data_columns () const { return m_data_cols; } - int display_rows (void) const { return m_display_rows; } + int display_rows () const { return m_display_rows; } - int display_columns (void) const { return m_display_cols; } + int display_columns () const { return m_display_cols; } - virtual QString make_description_text (void) const; + virtual QString make_description_text () const; void reset (const octave_value& val); @@ -145,7 +145,7 @@ variable_editor_model (const QString& expr, const octave_value& val, QObject *parent = nullptr); - ~variable_editor_model (void) + ~variable_editor_model () { delete rep; } @@ -156,12 +156,12 @@ variable_editor_model& operator = (const variable_editor_model&) = delete; - std::string name (void) const + std::string name () const { return rep->name (); } - bool is_editable (void) const + bool is_editable () const { return rep->is_editable (); } @@ -171,7 +171,7 @@ return rep->value_at (idx); } - int column_width (void) const + int column_width () const { return rep->column_width (); } @@ -233,7 +233,7 @@ return rep->update_pending_data (idx); } - void clear_update_pending (void) + void clear_update_pending () { rep->clear_update_pending (); } @@ -258,22 +258,22 @@ return rep->subscript_expression (idx); } - int display_rows (void) const + int display_rows () const { return rep->display_rows (); } - octave_idx_type data_rows (void) const + octave_idx_type data_rows () const { return rep->data_rows (); } - int display_columns (void) const + int display_columns () const { return rep->display_columns (); } - octave_idx_type data_columns (void) const + octave_idx_type data_columns () const { return rep->data_columns (); } @@ -303,7 +303,7 @@ void update_data (const octave_value& val); - void update_data_cache (void); + void update_data_cache (); void double_click (const QModelIndex& idx); @@ -323,7 +323,7 @@ octave_value retrieve_variable (interpreter&, const std::string& name); - bool is_valid (void) const + bool is_valid () const { return rep->is_valid (); } @@ -331,14 +331,14 @@ void change_display_size (int old_rows, int old_cols, int new_rows, int new_cols); - QString make_description_text (void) const + QString make_description_text () const { return rep->make_description_text (); } void reset (const octave_value& val); - void invalidate (void); + void invalidate (); void update_description (const QString& description = QString ()); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/variable-editor.cc --- a/libgui/src/variable-editor.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/variable-editor.cc Tue Jan 24 17:19:44 2023 -0800 @@ -204,7 +204,7 @@ } void - variable_dock_widget::change_fullscreen (void) + variable_dock_widget::change_fullscreen () { gui_settings settings; @@ -328,7 +328,7 @@ } void - variable_dock_widget::unfloat_float (void) + variable_dock_widget::unfloat_float () { hide (); setFloating (false); @@ -339,7 +339,7 @@ } void - variable_dock_widget::refloat (void) + variable_dock_widget::refloat () { setFloating (true); m_waiting_for_mouse_move = false; @@ -352,11 +352,11 @@ #else void - variable_dock_widget::unfloat_float (void) + variable_dock_widget::unfloat_float () { } void - variable_dock_widget::refloat (void) + variable_dock_widget::refloat () { } #endif @@ -423,7 +423,7 @@ } void - variable_editor_stack::levelUp (void) + variable_editor_stack::levelUp () { if (! hasFocus ()) return; @@ -573,7 +573,7 @@ } QList - variable_editor_view::range_selected (void) + variable_editor_view::range_selected () { QItemSelectionModel *sel = selectionModel (); @@ -813,7 +813,7 @@ } void - variable_editor_view::createVariable (void) + variable_editor_view::createVariable () { // FIXME: Create unnamed1..n if exist ('unnamed', 'var') is true. @@ -821,7 +821,7 @@ } void - variable_editor_view::transposeContent (void) + variable_editor_view::transposeContent () { if (! hasFocus ()) return; @@ -830,7 +830,7 @@ } void - variable_editor_view::delete_selected (void) + variable_editor_view::delete_selected () { if (! hasFocus ()) return; @@ -860,7 +860,7 @@ } void - variable_editor_view::clearContent (void) + variable_editor_view::clearContent () { if (! hasFocus ()) return; @@ -878,7 +878,7 @@ } void - variable_editor_view::cutClipboard (void) + variable_editor_view::cutClipboard () { copyClipboard (); @@ -886,7 +886,7 @@ } void - variable_editor_view::copyClipboard (void) + variable_editor_view::copyClipboard () { if (! hasFocus ()) return; @@ -917,7 +917,7 @@ } void - variable_editor_view::pasteClipboard (void) + variable_editor_view::pasteClipboard () { if (! hasFocus ()) return; @@ -1193,7 +1193,7 @@ } } - variable_editor::~variable_editor (void) + variable_editor::~variable_editor () { // FIXME: Maybe toolbar actions could be handled with signals and // slots so that deleting the toolbar here would disconnect all @@ -1378,7 +1378,7 @@ } void - variable_editor::tab_to_front (void) + variable_editor::tab_to_front () { QWidget *parent = parentWidget (); @@ -1403,7 +1403,7 @@ } void - variable_editor::refresh (void) + variable_editor::refresh () { emit refresh_signal (); } @@ -1415,7 +1415,7 @@ } void - variable_editor::notice_settings (void) + variable_editor::notice_settings () { gui_settings settings; @@ -1534,13 +1534,13 @@ } void - variable_editor::record_hovered_focus_variable (void) + variable_editor::record_hovered_focus_variable () { m_hovered_focus_vname = m_current_focus_vname; } void - variable_editor::restore_hovered_focus_variable (void) + variable_editor::restore_hovered_focus_variable () { variable_dock_widget *tofocus = findChild (m_hovered_focus_vname); if (tofocus != nullptr) @@ -1557,13 +1557,13 @@ } void - variable_editor::save (void) + variable_editor::save () { emit save_signal (); } void - variable_editor::cutClipboard (void) + variable_editor::cutClipboard () { copyClipboard (); @@ -1571,13 +1571,13 @@ } void - variable_editor::copyClipboard (void) + variable_editor::copyClipboard () { emit copy_clipboard_signal (); } void - variable_editor::pasteClipboard (void) + variable_editor::pasteClipboard () { emit paste_clipboard_signal (); @@ -1585,14 +1585,14 @@ } void - variable_editor::levelUp (void) + variable_editor::levelUp () { emit level_up_signal (); } // Also updates the font. - void variable_editor::update_colors (void) + void variable_editor::update_colors () { m_stylesheet = ""; @@ -1655,7 +1655,7 @@ } void - variable_editor::construct_tool_bar (void) + variable_editor::construct_tool_bar () { m_tool_bar->setAllowedAreas (Qt::TopToolBarArea); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/variable-editor.h --- a/libgui/src/variable-editor.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/variable-editor.h Tue Jan 24 17:19:44 2023 -0800 @@ -57,7 +57,7 @@ variable_dock_widget (QWidget *p); - ~variable_dock_widget (void) = default; + ~variable_dock_widget () = default; signals: @@ -81,7 +81,7 @@ void toplevel_change (bool); - void change_fullscreen (void); + void change_fullscreen (); protected: @@ -99,15 +99,15 @@ #define QTBUG_44813_FIX_VERSION 0x999999 signals: - void queue_unfloat_float (void); + void queue_unfloat_float (); - void queue_float (void); + void queue_float (); protected slots: - void unfloat_float (void); + void unfloat_float (); - void refloat (void); + void refloat (); #if (QT_VERSION >= 0x050302) && (QT_VERSION <= QTBUG_44813_FIX_VERSION) protected: @@ -130,11 +130,11 @@ variable_editor_stack (QWidget *p); - ~variable_editor_stack (void) = default; + ~variable_editor_stack () = default; - variable_editor_view * edit_view (void) {return m_edit_view;}; + variable_editor_view * edit_view () {return m_edit_view;}; - QTextEdit * disp_view (void) {return m_disp_view;}; + QTextEdit * disp_view () {return m_disp_view;}; signals: @@ -149,7 +149,7 @@ void set_editable (bool editable); - void levelUp (void); + void levelUp (); void save (const QString& format = QString ()); @@ -172,7 +172,7 @@ variable_editor_view (QWidget *p); - ~variable_editor_view (void) = default; + ~variable_editor_view () = default; void setModel (QAbstractItemModel *model); @@ -184,21 +184,21 @@ public slots: - void createVariable (void); + void createVariable (); - void transposeContent (void); + void transposeContent (); - QList range_selected (void); + QList range_selected (); - void delete_selected (void); + void delete_selected (); - void clearContent (void); + void clearContent (); - void cutClipboard (void); + void cutClipboard (); - void copyClipboard (void); + void copyClipboard (); - void pasteClipboard (void); + void pasteClipboard (); void handle_horizontal_scroll_action (int action); @@ -230,13 +230,13 @@ HoverToolButton (QWidget *parent = nullptr); - ~HoverToolButton (void) = default; + ~HoverToolButton () = default; signals: - void hovered_signal (void); + void hovered_signal (); - void popup_shown_signal (void); + void popup_shown_signal (); protected: @@ -251,11 +251,11 @@ ReturnFocusToolButton (QWidget *parent = nullptr); - ~ReturnFocusToolButton (void) = default; + ~ReturnFocusToolButton () = default; signals: - void about_to_activate (void); + void about_to_activate (); protected: @@ -270,11 +270,11 @@ ReturnFocusMenu (QWidget *parent = nullptr); - ~ReturnFocusMenu (void) = default; + ~ReturnFocusMenu () = default; signals: - void about_to_activate (void); + void about_to_activate (); protected: @@ -291,7 +291,7 @@ variable_editor (QWidget *parent); - ~variable_editor (void); + ~variable_editor (); // No copying! @@ -299,31 +299,31 @@ variable_editor& operator = (const variable_editor&) = delete; - void refresh (void); + void refresh (); - void tab_to_front (void); + void tab_to_front (); signals: - void updated (void); + void updated (); - void finished (void); + void finished (); void command_signal (const QString& cmd); - void refresh_signal (void); + void refresh_signal (); - void clear_content_signal (void); + void clear_content_signal (); - void copy_clipboard_signal (void); + void copy_clipboard_signal (); - void paste_clipboard_signal (void); + void paste_clipboard_signal (); - void level_up_signal (void); + void level_up_signal (); - void save_signal (void); + void save_signal (); - void delete_selected_signal (void); + void delete_selected_signal (); void interpreter_event (const fcn_callback& fcn); void interpreter_event (const meth_callback& meth); @@ -332,7 +332,7 @@ void callUpdate (const QModelIndex&, const QModelIndex&); - void notice_settings (void); + void notice_settings (); void edit_variable (const QString& name, const octave_value& val); @@ -340,23 +340,23 @@ void variable_focused (const QString& name); - void record_hovered_focus_variable (void); + void record_hovered_focus_variable (); - void restore_hovered_focus_variable (void); + void restore_hovered_focus_variable (); protected slots: void closeEvent (QCloseEvent *); - void save (void); + void save (); - void cutClipboard (void); + void cutClipboard (); - void copyClipboard (void); + void copyClipboard (); - void pasteClipboard (void); + void pasteClipboard (); - void levelUp (void); + void levelUp (); protected: @@ -389,12 +389,12 @@ QList m_table_colors; - void update_colors (void); + void update_colors (); QAction * add_tool_bar_button (const QIcon& icon, const QString& text, const QObject *receiver, const char *member); - void construct_tool_bar (void); + void construct_tool_bar (); QString m_current_focus_vname; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/welcome-wizard.cc --- a/libgui/src/welcome-wizard.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/welcome-wizard.cc Tue Jan 24 17:19:44 2023 -0800 @@ -91,7 +91,7 @@ #endif } - void welcome_wizard::adjust_size (void) + void welcome_wizard::adjust_size () { // Get adjusted size for the current page adjustSize (); @@ -111,7 +111,7 @@ m_allow_web_connect_state = state == Qt::Checked; } - void welcome_wizard::show_page (void) + void welcome_wizard::show_page () { delete m_current_page; delete layout (); @@ -124,21 +124,21 @@ new_layout->addWidget (m_current_page); } - void welcome_wizard::previous_page (void) + void welcome_wizard::previous_page () { --m_page_list_iterator; show_page (); } - void welcome_wizard::next_page (void) + void welcome_wizard::next_page () { ++m_page_list_iterator; show_page (); } - void welcome_wizard::accept (void) + void welcome_wizard::accept () { // Create default settings file. diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/welcome-wizard.h --- a/libgui/src/welcome-wizard.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/welcome-wizard.h Tue Jan 24 17:19:44 2023 -0800 @@ -42,9 +42,9 @@ welcome_wizard (QWidget *parent = nullptr); - ~welcome_wizard (void) = default; + ~welcome_wizard () = default; - void adjust_size (void); + void adjust_size (); private: @@ -59,11 +59,11 @@ void handle_web_connect_option (int state); - void show_page (void); - void previous_page (void); - void next_page (void); + void show_page (); + void previous_page (); + void next_page (); - void accept (void); + void accept (); }; class initial_page : public QWidget @@ -74,7 +74,7 @@ initial_page (welcome_wizard *wizard); - ~initial_page (void) = default; + ~initial_page () = default; static QWidget * create (welcome_wizard *wizard) @@ -99,7 +99,7 @@ setup_community_news (welcome_wizard *wizard); - ~setup_community_news (void) = default; + ~setup_community_news () = default; static QWidget * create (welcome_wizard *wizard) @@ -127,7 +127,7 @@ final_page (welcome_wizard *wizard); - ~final_page (void) = default; + ~final_page () = default; static QWidget * create (welcome_wizard *wizard) diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/workspace-model.cc --- a/libgui/src/workspace-model.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/workspace-model.cc Tue Jan 24 17:19:44 2023 -0800 @@ -191,14 +191,14 @@ } void - workspace_model::clear_workspace (void) + workspace_model::clear_workspace () { clear_data (); update_table (); } void - workspace_model::notice_settings (void) + workspace_model::notice_settings () { gui_settings settings; @@ -232,7 +232,7 @@ } void - workspace_model::clear_data (void) + workspace_model::clear_data () { m_top_level = false; m_syminfo_list = symbol_info_list (); @@ -245,7 +245,7 @@ } void - workspace_model::update_table (void) + workspace_model::update_table () { beginResetModel (); diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/workspace-model.h --- a/libgui/src/workspace-model.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/workspace-model.h Tue Jan 24 17:19:44 2023 -0800 @@ -49,7 +49,7 @@ workspace_model (QObject *parent = nullptr); - ~workspace_model (void) = default; + ~workspace_model () = default; int rowCount (const QModelIndex& parent = QModelIndex ()) const; @@ -62,38 +62,38 @@ QVariant data (const QModelIndex& index, int role) const; - bool is_top_level (void) const { return m_top_level; } + bool is_top_level () const { return m_top_level; } QColor storage_class_color (int s_class) { return m_storage_class_colors.at (s_class); } - symbol_info_list get_symbol_info (void) const { return m_syminfo_list; } + symbol_info_list get_symbol_info () const { return m_syminfo_list; } - QStringList get_symbol_names (void) const { return m_symbols; } - QStringList get_symbol_values (void) const { return m_values; } + QStringList get_symbol_names () const { return m_symbols; } + QStringList get_symbol_values () const { return m_values; } signals: - void model_changed (void); - void prompt_variable_editor(void); + void model_changed (); + void prompt_variable_editor(); public slots: void set_workspace (bool top_level, bool debug, const symbol_info_list& syminfo); - void clear_workspace (void); + void clear_workspace (); - void notice_settings (void); + void notice_settings (); void show_symbol_tooltip (const QPoint& pos, const QString& symbol); private: - void clear_data (void); - void update_table (void); + void clear_data (); + void update_table (); bool m_top_level; symbol_info_list m_syminfo_list; diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/workspace-view.cc --- a/libgui/src/workspace-view.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/workspace-view.cc Tue Jan 24 17:19:44 2023 -0800 @@ -174,7 +174,7 @@ } void - workspace_view::notice_settings (void) + workspace_view::notice_settings () { gui_settings settings; @@ -206,7 +206,7 @@ } void - workspace_view::save_settings (void) + workspace_view::save_settings () { gui_settings settings; @@ -267,7 +267,7 @@ } void - workspace_view::update_filter_history (void) + workspace_view::update_filter_history () { QString text = m_filter->currentText (); // get current text int index = m_filter->findText (text); // and its actual index @@ -395,7 +395,7 @@ } void - workspace_view::handle_contextmenu_copy (void) + workspace_view::handle_contextmenu_copy () { QModelIndex index = m_view->currentIndex (); @@ -410,7 +410,7 @@ } void - workspace_view::handle_contextmenu_copy_value (void) + workspace_view::handle_contextmenu_copy_value () { QModelIndex index = m_view->currentIndex (); @@ -419,7 +419,7 @@ } void - workspace_view::handle_contextmenu_rename (void) + workspace_view::handle_contextmenu_rename () { QModelIndex index = m_view->currentIndex (); @@ -443,7 +443,7 @@ } void - workspace_view::handle_contextmenu_edit (void) + workspace_view::handle_contextmenu_edit () { QModelIndex index = m_view->currentIndex (); @@ -452,31 +452,31 @@ } void - workspace_view::handle_contextmenu_clear (void) + workspace_view::handle_contextmenu_clear () { relay_contextmenu_command ("clear", true); } void - workspace_view::handle_contextmenu_disp (void) + workspace_view::handle_contextmenu_disp () { relay_contextmenu_command ("disp"); } void - workspace_view::handle_contextmenu_plot (void) + workspace_view::handle_contextmenu_plot () { relay_contextmenu_command ("figure (); plot"); } void - workspace_view::handle_contextmenu_stem (void) + workspace_view::handle_contextmenu_stem () { relay_contextmenu_command ("figure (); stem"); } void - workspace_view::handle_contextmenu_filter (void) + workspace_view::handle_contextmenu_filter () { m_filter_shown = ! m_filter_shown; m_filter_widget->setVisible (m_filter_shown); @@ -485,7 +485,7 @@ } void - workspace_view::handle_model_changed (void) + workspace_view::handle_model_changed () { // m_view->resizeRowsToContents (); // Just modify those rows that have been added rather than go through diff -r 1d1eff97670e -r 21f9b34eb893 libgui/src/workspace-view.h --- a/libgui/src/workspace-view.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libgui/src/workspace-view.h Tue Jan 24 17:19:44 2023 -0800 @@ -47,7 +47,7 @@ workspace_view (QWidget *parent); - ~workspace_view (void) = default; + ~workspace_view () = default; signals: @@ -72,15 +72,15 @@ void setModel (workspace_model *model); - void notice_settings (void); + void notice_settings (); - void save_settings (void); + void save_settings (); protected slots: void filter_update (const QString& expression); void filter_activate (bool enable); - void update_filter_history (void); + void update_filter_history (); void header_contextmenu_requested (const QPoint& mpos); @@ -88,22 +88,22 @@ void contextmenu_requested (const QPoint& pos); - void handle_contextmenu_copy (void); - void handle_contextmenu_copy_value (void); - void handle_contextmenu_rename (void); - void handle_contextmenu_edit (void); - void handle_contextmenu_clear (void); - void handle_contextmenu_disp (void); - void handle_contextmenu_plot (void); - void handle_contextmenu_stem (void); - void handle_contextmenu_filter (void); + void handle_contextmenu_copy (); + void handle_contextmenu_copy_value (); + void handle_contextmenu_rename (); + void handle_contextmenu_edit (); + void handle_contextmenu_clear (); + void handle_contextmenu_disp (); + void handle_contextmenu_plot (); + void handle_contextmenu_stem (); + void handle_contextmenu_filter (); public slots: - void handle_model_changed (void); + void handle_model_changed (); - void copyClipboard (void); - void selectAll (void); + void copyClipboard (); + void selectAll (); private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/build-env.h --- a/libinterp/build-env.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/build-env.h Tue Jan 24 17:19:44 2023 -0800 @@ -34,7 +34,7 @@ OCTAVE_BEGIN_NAMESPACE(build_env) -extern OCTINTERP_API octave_scalar_map features (void); +extern OCTINTERP_API octave_scalar_map features (); extern OCTINTERP_API const char *AMD_CPPFLAGS; extern OCTINTERP_API const char *AMD_LDFLAGS; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/Cell.cc --- a/libinterp/corefcn/Cell.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/Cell.cc Tue Jan 24 17:19:44 2023 -0800 @@ -123,7 +123,7 @@ } bool -Cell::iscellstr (void) const +Cell::iscellstr () const { bool retval = true; @@ -142,7 +142,7 @@ } Array -Cell::cellstr_value (void) const +Cell::cellstr_value () const { Array retval (dims ()); @@ -155,7 +155,7 @@ } string_vector -Cell::string_vector_value (void) const +Cell::string_vector_value () const { octave_idx_type n = numel (); @@ -288,7 +288,7 @@ } octave_idx_type -Cell::nnz (void) const +Cell::nnz () const { err_wrong_type_arg ("nnz", "cell array"); } @@ -355,7 +355,7 @@ } octave_value -Cell::resize_fill_value (void) const +Cell::resize_fill_value () const { static octave_value rfv = octave_value (Matrix ()); return rfv; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/Cell.h --- a/libinterp/corefcn/Cell.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/Cell.h Tue Jan 24 17:19:44 2023 -0800 @@ -43,13 +43,13 @@ { public: - Cell (void) = default; + Cell () = default; Cell (const Cell& c) = default; Cell& operator = (const Cell& c) = default; - ~Cell (void) = default; + ~Cell () = default; Cell (const octave_value& val) : Array (dim_vector (1, 1), val) { } @@ -97,11 +97,11 @@ Cell (const dim_vector& dv, const string_vector& sv, bool trim = false); - bool iscellstr (void) const; + bool iscellstr () const; - Array cellstr_value (void) const; + Array cellstr_value () const; - string_vector string_vector_value (void) const; + string_vector string_vector_value () const; using Array::index; @@ -119,7 +119,7 @@ Cell reshape (const dim_vector& new_dims) const { return Array::reshape (new_dims); } - octave_idx_type nnz (void) const; + octave_idx_type nnz () const; Cell column (octave_idx_type i) const; @@ -135,33 +135,33 @@ Cell& insert (const Cell& a, const Array& ra_idx); // FIXME - bool any_element_is_nan (void) const { return false; } - bool is_true (void) const { return false; } + bool any_element_is_nan () const { return false; } + bool is_true () const { return false; } - octave_value resize_fill_value (void) const; + octave_value resize_fill_value () const; Cell diag (octave_idx_type k = 0) const; Cell diag (octave_idx_type m, octave_idx_type n) const; - Cell xisalnum (void) const { return map (&octave_value::xisalnum); } - Cell xisalpha (void) const { return map (&octave_value::xisalpha); } - Cell xisascii (void) const { return map (&octave_value::xisascii); } - Cell xiscntrl (void) const { return map (&octave_value::xiscntrl); } - Cell xisdigit (void) const { return map (&octave_value::xisdigit); } - Cell xisgraph (void) const { return map (&octave_value::xisgraph); } - Cell xislower (void) const { return map (&octave_value::xislower); } - Cell xisprint (void) const { return map (&octave_value::xisprint); } - Cell xispunct (void) const { return map (&octave_value::xispunct); } - Cell xisspace (void) const { return map (&octave_value::xisspace); } - Cell xisupper (void) const { return map (&octave_value::xisupper); } - Cell xisxdigit (void) const { return map (&octave_value::xisxdigit); } - Cell xtolower (void) const { return map (&octave_value::xtolower); } - Cell xtoupper (void) const { return map (&octave_value::xtoupper); } + Cell xisalnum () const { return map (&octave_value::xisalnum); } + Cell xisalpha () const { return map (&octave_value::xisalpha); } + Cell xisascii () const { return map (&octave_value::xisascii); } + Cell xiscntrl () const { return map (&octave_value::xiscntrl); } + Cell xisdigit () const { return map (&octave_value::xisdigit); } + Cell xisgraph () const { return map (&octave_value::xisgraph); } + Cell xislower () const { return map (&octave_value::xislower); } + Cell xisprint () const { return map (&octave_value::xisprint); } + Cell xispunct () const { return map (&octave_value::xispunct); } + Cell xisspace () const { return map (&octave_value::xisspace); } + Cell xisupper () const { return map (&octave_value::xisupper); } + Cell xisxdigit () const { return map (&octave_value::xisxdigit); } + Cell xtolower () const { return map (&octave_value::xtolower); } + Cell xtoupper () const { return map (&octave_value::xtoupper); } private: - typedef octave_value (octave_value::*ctype_mapper) (void) const; + typedef octave_value (octave_value::*ctype_mapper) () const; Cell map (ctype_mapper) const; }; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/__contourc__.cc --- a/libinterp/corefcn/__contourc__.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/__contourc__.cc Tue Jan 24 17:19:44 2023 -0800 @@ -71,7 +71,7 @@ // Add contents of current contour to contourc. // this_contour.cols () - 1; static void -end_contour (void) +end_contour () { if (elem > 2) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/__magick_read__.cc --- a/libinterp/corefcn/__magick_read__.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/__magick_read__.cc Tue Jan 24 17:19:44 2023 -0800 @@ -216,28 +216,28 @@ image_region& operator = (const image_region&) = default; image_region& operator = (image_region&&) = default; - ~image_region (void) = default; + ~image_region () = default; - octave_idx_type row_start (void) const { return m_row_start; } - octave_idx_type col_start (void) const { return m_col_start; } - octave_idx_type row_end (void) const { return m_row_end; } - octave_idx_type col_end (void) const { return m_col_end; } + octave_idx_type row_start () const { return m_row_start; } + octave_idx_type col_start () const { return m_col_start; } + octave_idx_type row_end () const { return m_row_end; } + octave_idx_type col_end () const { return m_col_end; } // Length of the area to load into the Image Pixel Cache. We use max and // min to account for cases where last element of range is the range limit. - octave_idx_type row_cache (void) const { return m_row_cache; } - octave_idx_type col_cache (void) const { return m_col_cache; } + octave_idx_type row_cache () const { return m_row_cache; } + octave_idx_type col_cache () const { return m_col_cache; } // How much we have to shift in the memory when doing the loops. - octave_idx_type row_shift (void) const { return m_row_shift; } - octave_idx_type col_shift (void) const { return m_col_shift; } + octave_idx_type row_shift () const { return m_row_shift; } + octave_idx_type col_shift () const { return m_col_shift; } // The actual height and width of the output image - octave_idx_type row_out (void) const { return m_row_out; } - octave_idx_type col_out (void) const { return m_col_out; } + octave_idx_type row_out () const { return m_row_out; } + octave_idx_type col_out () const { return m_col_out; } private: @@ -794,7 +794,7 @@ } static void -maybe_initialize_magick (void) +maybe_initialize_magick () { static bool initialized = false; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/auto-shlib.cc --- a/libinterp/corefcn/auto-shlib.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/auto-shlib.cc Tue Jan 24 17:19:44 2023 -0800 @@ -34,7 +34,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) -auto_shlib::auto_shlib (void) +auto_shlib::auto_shlib () : dynamic_library (get_current_shlib ()) { } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/auto-shlib.h --- a/libinterp/corefcn/auto-shlib.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/auto-shlib.h Tue Jan 24 17:19:44 2023 -0800 @@ -43,9 +43,9 @@ { public: - auto_shlib (void); + auto_shlib (); - ~auto_shlib (void) = default; + ~auto_shlib () = default; auto_shlib (const auto_shlib&) = default; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/base-text-renderer.h --- a/libinterp/corefcn/base-text-renderer.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/base-text-renderer.h Tue Jan 24 17:19:44 2023 -0800 @@ -53,7 +53,7 @@ ROTATION_270 = 3 }; - base_text_renderer (void) : text_processor () { } + base_text_renderer () : text_processor () { } // No copying! @@ -61,7 +61,7 @@ base_text_renderer& operator = (const base_text_renderer&) = delete; - virtual ~base_text_renderer (void) = default; + virtual ~base_text_renderer () = default; virtual void set_anti_aliasing (bool val) = 0; @@ -78,10 +78,10 @@ const std::string& angle, double size) = 0; virtual bool - ok (void) { return true; }; + ok () { return true; }; virtual octave_map - get_system_fonts (void) = 0; + get_system_fonts () = 0; virtual void set_color (const Matrix& c) = 0; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/bsxfun.cc --- a/libinterp/corefcn/bsxfun.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/bsxfun.cc Tue Jan 24 17:19:44 2023 -0800 @@ -130,7 +130,7 @@ return octave_value (bsxfun_pow (xa, ya)); } -static void maybe_fill_table (void) +static void maybe_fill_table () { static bool filled = false; if (filled) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/c-file-ptr-stream.cc --- a/libinterp/corefcn/c-file-ptr-stream.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/c-file-ptr-stream.cc Tue Jan 24 17:19:44 2023 -0800 @@ -47,7 +47,7 @@ # define SEEK_END 2 #endif -c_file_ptr_buf::~c_file_ptr_buf (void) +c_file_ptr_buf::~c_file_ptr_buf () { buf_close (); } @@ -142,7 +142,7 @@ } int -c_file_ptr_buf::sync (void) +c_file_ptr_buf::sync () { flush (); @@ -150,13 +150,13 @@ } int -c_file_ptr_buf::flush (void) +c_file_ptr_buf::flush () { return m_f ? std::fflush (m_f) : traits_type::eof (); } int -c_file_ptr_buf::buf_close (void) +c_file_ptr_buf::buf_close () { int retval = -1; @@ -178,7 +178,7 @@ } off_t -c_file_ptr_buf::tell (void) +c_file_ptr_buf::tell () { return m_f ? octave_ftello_wrapper (m_f) : -1; } @@ -191,7 +191,7 @@ #if defined (HAVE_ZLIB) -c_zfile_ptr_buf::~c_zfile_ptr_buf (void) +c_zfile_ptr_buf::~c_zfile_ptr_buf () { buf_close (); } @@ -285,7 +285,7 @@ } int -c_zfile_ptr_buf::sync (void) +c_zfile_ptr_buf::sync () { flush (); @@ -293,7 +293,7 @@ } int -c_zfile_ptr_buf::flush (void) +c_zfile_ptr_buf::flush () { // FIXME: do we need something more complex here, passing // something other than 0 for the second argument to gzflush and @@ -303,7 +303,7 @@ } int -c_zfile_ptr_buf::buf_close (void) +c_zfile_ptr_buf::buf_close () { int retval = -1; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/c-file-ptr-stream.h --- a/libinterp/corefcn/c-file-ptr-stream.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/c-file-ptr-stream.h Tue Jan 24 17:19:44 2023 -0800 @@ -46,7 +46,7 @@ typedef int (*close_fcn) (FILE *); - FILE * stdiofile (void) { return m_f; } + FILE * stdiofile () { return m_f; } c_file_ptr_buf (FILE *f, close_fcn cf = file_close) : std::streambuf (), m_f (f), m_cf (cf) @@ -58,13 +58,13 @@ c_file_ptr_buf& operator = (const c_file_ptr_buf&) = delete; - ~c_file_ptr_buf (void); + ~c_file_ptr_buf (); int_type overflow (int_type); - int_type underflow (void) { return underflow_common (false); } + int_type underflow () { return underflow_common (false); } - int_type uflow (void) { return underflow_common (true); } + int_type uflow () { return underflow_common (true); } int_type pbackfail (int_type); @@ -78,19 +78,19 @@ std::streampos seekpos (std::streampos, std::ios::openmode = std::ios::in | std::ios::out); - int sync (void); + int sync (); - int flush (void); + int flush (); - int buf_close (void); + int buf_close (); int file_number () const { return m_f ? fileno (m_f) : -1; } int seek (off_t offset, int origin); - off_t tell (void); + off_t tell (); - void clear (void) { if (m_f) clearerr (m_f); } + void clear () { if (m_f) clearerr (m_f); } static int file_close (FILE *m_f); @@ -124,18 +124,18 @@ c_file_ptr_stream& operator = (const c_file_ptr_stream&) = delete; - ~c_file_ptr_stream (void) { delete m_buf; m_buf = nullptr; } + ~c_file_ptr_stream () { delete m_buf; m_buf = nullptr; } - BUF_T * rdbuf (void) { return m_buf; } + BUF_T * rdbuf () { return m_buf; } - void stream_close (void) { if (m_buf) m_buf->buf_close (); } + void stream_close () { if (m_buf) m_buf->buf_close (); } int seek (off_t offset, int origin) { return m_buf ? m_buf->seek (offset, origin) : -1; } - off_t tell (void) { return m_buf ? m_buf->tell () : -1; } + off_t tell () { return m_buf ? m_buf->tell () : -1; } - void clear (void) { if (m_buf) m_buf->clear (); STREAM_T::clear (); } + void clear () { if (m_buf) m_buf->clear (); STREAM_T::clear (); } private: @@ -161,7 +161,7 @@ typedef int (*close_fcn) (gzFile); - gzFile stdiofile (void) { return m_f; } + gzFile stdiofile () { return m_f; } c_zfile_ptr_buf (gzFile f, close_fcn cf = file_close) : std::streambuf (), m_f (f), m_cf (cf) @@ -173,13 +173,13 @@ c_zfile_ptr_buf& operator = (const c_zfile_ptr_buf&) = delete; - ~c_zfile_ptr_buf (void); + ~c_zfile_ptr_buf (); int_type overflow (int_type); - int_type underflow (void) { return underflow_common (false); } + int_type underflow () { return underflow_common (false); } - int_type uflow (void) { return underflow_common (true); } + int_type uflow () { return underflow_common (true); } int_type pbackfail (int_type); @@ -193,20 +193,20 @@ std::streampos seekpos (std::streampos, std::ios::openmode = std::ios::in | std::ios::out); - int sync (void); + int sync (); - int flush (void); + int flush (); - int buf_close (void); + int buf_close (); int file_number () const { return -1; } int seek (off_t offset, int origin) { return m_f ? gzseek (m_f, offset, origin) >= 0 : -1; } - off_t tell (void) { return m_f ? gztell (m_f) : -1; } + off_t tell () { return m_f ? gztell (m_f) : -1; } - void clear (void) { if (m_f) gzclearerr (m_f); } + void clear () { if (m_f) gzclearerr (m_f); } static int file_close (gzFile m_f) { return ::gzclose (m_f); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/call-stack.cc --- a/libinterp/corefcn/call-stack.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/call-stack.cc Tue Jan 24 17:19:44 2023 -0800 @@ -87,7 +87,7 @@ return fcn; } -int call_stack::current_line (void) const +int call_stack::current_line () const { int retval = -1; @@ -100,7 +100,7 @@ return retval; } -int call_stack::current_column (void) const +int call_stack::current_column () const { int retval = -1; @@ -113,7 +113,7 @@ return retval; } -octave_user_code *call_stack::current_user_code (void) const +octave_user_code *call_stack::current_user_code () const { // Start at current frame. @@ -132,7 +132,7 @@ return nullptr; } -int call_stack::current_user_code_line (void) const +int call_stack::current_user_code_line () const { // Start at current frame. @@ -156,7 +156,7 @@ return -1; } -int call_stack::current_user_code_column (void) const +int call_stack::current_user_code_column () const { // Start at current frame. @@ -180,7 +180,7 @@ return -1; } -unwind_protect *call_stack::curr_fcn_unwind_protect_frame (void) +unwind_protect *call_stack::curr_fcn_unwind_protect_frame () { // Start at current frame. @@ -199,7 +199,7 @@ return nullptr; } -octave_user_code *call_stack::debug_user_code (void) const +octave_user_code *call_stack::debug_user_code () const { octave_user_code *retval = nullptr; @@ -225,7 +225,7 @@ return retval; } -int call_stack::debug_user_code_line (void) const +int call_stack::debug_user_code_line () const { int retval = -1; @@ -254,7 +254,7 @@ return retval; } -int call_stack::debug_user_code_column (void) const +int call_stack::debug_user_code_column () const { int retval = -1; @@ -284,7 +284,7 @@ return retval; } -std::string call_stack::get_dispatch_class (void) const +std::string call_stack::get_dispatch_class () const { return m_cs[m_curr_frame]->get_dispatch_class (); } @@ -322,7 +322,7 @@ return retval; } -bool call_stack::all_scripts (void) const +bool call_stack::all_scripts () const { bool retval = true; @@ -485,7 +485,7 @@ return retval; } -std::size_t call_stack::find_current_user_frame (void) const +std::size_t call_stack::find_current_user_frame () const { std::size_t user_frame = m_curr_frame; @@ -502,7 +502,7 @@ return user_frame; } -std::shared_ptr call_stack::current_user_frame (void) const +std::shared_ptr call_stack::current_user_frame () const { std::size_t frame = find_current_user_frame (); @@ -615,7 +615,7 @@ // value of m_curr_frame would be wiped out when dbup returns and the // stack frame for dbup is popped. -void call_stack::goto_caller_frame (void) +void call_stack::goto_caller_frame () { std::size_t start = find_current_user_frame (); @@ -627,7 +627,7 @@ m_curr_frame = caller_frame ? caller_frame->index () : 0; } -void call_stack::goto_base_frame (void) +void call_stack::goto_base_frame () { if (m_curr_frame > 0) m_curr_frame = 0; @@ -668,7 +668,7 @@ } std::list> - call_stack::backtrace_frames (void) const + call_stack::backtrace_frames () const { octave_idx_type curr_user_frame = -1; @@ -698,7 +698,7 @@ return retval; } -std::list call_stack::backtrace_info (void) const +std::list call_stack::backtrace_info () const { octave_idx_type curr_user_frame = -1; @@ -739,19 +739,19 @@ return retval; } -octave_map call_stack::backtrace (void) const +octave_map call_stack::backtrace () const { octave_idx_type curr_user_frame = -1; return backtrace (curr_user_frame, true); } -octave_map call_stack::empty_backtrace (void) const +octave_map call_stack::empty_backtrace () const { return octave_map (dim_vector (0, 1), bt_fields); } -void call_stack::pop (void) +void call_stack::pop () { // Never pop top scope. // FIXME: is it possible for this case to happen? @@ -771,18 +771,18 @@ } } -void call_stack::clear (void) +void call_stack::clear () { while (! m_cs.empty ()) pop (); } -symbol_info_list call_stack::all_variables (void) +symbol_info_list call_stack::all_variables () { return m_cs[m_curr_frame]->all_variables (); } -std::list call_stack::global_variable_names (void) const +std::list call_stack::global_variable_names () const { std::list retval; @@ -797,12 +797,12 @@ return retval; } -std::list call_stack::top_level_variable_names (void) const +std::list call_stack::top_level_variable_names () const { return m_cs[0]->variable_names (); } -std::list call_stack::variable_names (void) const +std::list call_stack::variable_names () const { return m_cs[m_curr_frame]->variable_names (); } @@ -837,7 +837,7 @@ } } -void call_stack::clear_global_variables (void) +void call_stack::clear_global_variables () { for (auto& nm_ov : m_global_values) nm_ov.second = octave_value (); @@ -855,12 +855,12 @@ return m_cs[m_curr_frame]->regexp_symbol_info (pattern); } -symbol_info_list call_stack::get_symbol_info (void) +symbol_info_list call_stack::get_symbol_info () { return m_cs[m_curr_frame]->get_symbol_info (); } -symbol_info_list call_stack::top_scope_symbol_info (void) const +symbol_info_list call_stack::top_scope_symbol_info () const { return m_cs[0]->get_symbol_info (); } @@ -979,7 +979,7 @@ push (tmp_scope); - unwind_action restore_scope ([=] (void) { pop (); }); + unwind_action restore_scope ([=] () { pop (); }); interpreter& interp = m_evaluator.get_interpreter (); @@ -1110,7 +1110,7 @@ return octave_value (); } -void call_stack::display (void) const +void call_stack::display () const { std::ostream& os = octave_stdout; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/call-stack.h --- a/libinterp/corefcn/call-stack.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/call-stack.h Tue Jan 24 17:19:44 2023 -0800 @@ -73,39 +73,39 @@ octave_function * current_function (bool skip_first = false) const; - octave_function * caller_function (void) const + octave_function * caller_function () const { return current_function (true); } // Current line in current function. - int current_line (void) const; + int current_line () const; // Current column in current function. - int current_column (void) const; + int current_column () const; - std::size_t current_frame (void) const { return m_curr_frame; } + std::size_t current_frame () const { return m_curr_frame; } - std::size_t size (void) const { return m_cs.size (); } + std::size_t size () const { return m_cs.size (); } - std::shared_ptr get_current_stack_frame (void) const + std::shared_ptr get_current_stack_frame () const { return m_cs[m_curr_frame]; } - symbol_scope top_scope (void) const + symbol_scope top_scope () const { return m_cs[0]->get_scope (); } - symbol_scope current_scope (void) const + symbol_scope current_scope () const { // FIXME: Can m_curr_frame ever be invalid? return (m_curr_frame < m_cs.size () ? m_cs[m_curr_frame]->get_scope () : symbol_scope ()); } - bool at_top_level (void) const + bool at_top_level () const { return current_scope () == top_scope (); } @@ -123,26 +123,26 @@ } // User code caller. - octave_user_code * current_user_code (void) const; + octave_user_code * current_user_code () const; - unwind_protect * curr_fcn_unwind_protect_frame (void); + unwind_protect * curr_fcn_unwind_protect_frame (); // Line in user code caller. - int current_user_code_line (void) const; + int current_user_code_line () const; // Column in user code caller. - int current_user_code_column (void) const; + int current_user_code_column () const; // Current function that we are debugging. - octave_user_code * debug_user_code (void) const; + octave_user_code * debug_user_code () const; // Line number in current function that we are debugging. - int debug_user_code_line (void) const; + int debug_user_code_line () const; // Column number in current function that we are debugging. - int debug_user_code_column (void) const; + int debug_user_code_column () const; - std::string get_dispatch_class (void) const; + std::string get_dispatch_class () const; void set_dispatch_class (const std::string& class_name); @@ -151,7 +151,7 @@ bool is_class_constructor_executing (std::string& dispatch_class) const; // Return TRUE if all elements on the call stack are scripts. - bool all_scripts (void) const; + bool all_scripts () const; void push (const symbol_scope& scope); @@ -204,23 +204,23 @@ goto_frame (n); } - std::size_t find_current_user_frame (void) const; + std::size_t find_current_user_frame () const; - std::shared_ptr current_user_frame (void) const; + std::shared_ptr current_user_frame () const; std::size_t dbupdown (std::size_t start, int n, bool verbose); std::size_t dbupdown (int n = -1, bool verbose = false); - void goto_caller_frame (void); + void goto_caller_frame (); - void goto_base_frame (void); + void goto_base_frame (); std::list> backtrace_frames (octave_idx_type& curr_user_frame) const; // List of raw stack frames. - std::list> backtrace_frames (void) const; + std::list> backtrace_frames () const; // List of stack_info objects that can be used in liboctave and // stored in the execution_exception object. @@ -228,7 +228,7 @@ std::list backtrace_info (octave_idx_type& curr_user_frame, bool print_subfn = true) const; - std::list backtrace_info (void) const; + std::list backtrace_info () const; // The same as backtrace_info but in the form of a struct array // object that may be used in the interpreter. @@ -236,21 +236,21 @@ octave_map backtrace (octave_idx_type& curr_user_frame, bool print_subfn = true) const; - octave_map backtrace (void) const; + octave_map backtrace () const; - octave_map empty_backtrace (void) const; + octave_map empty_backtrace () const; - void pop (void); + void pop (); - void clear (void); + void clear (); - symbol_info_list all_variables (void); + symbol_info_list all_variables (); - std::list global_variable_names (void) const; + std::list global_variable_names () const; - std::list top_level_variable_names (void) const; + std::list top_level_variable_names () const; - std::list variable_names (void) const; + std::list variable_names () const; void clear_global_variable (const std::string& name); @@ -258,15 +258,15 @@ void clear_global_variable_regexp(const std::string& pattern); - void clear_global_variables (void); + void clear_global_variables (); symbol_info_list glob_symbol_info (const std::string& pattern) const; symbol_info_list regexp_symbol_info (const std::string& pattern) const; - symbol_info_list get_symbol_info (void); + symbol_info_list get_symbol_info (); - symbol_info_list top_scope_symbol_info (void) const; + symbol_info_list top_scope_symbol_info () const; octave_value max_stack_depth (const octave_value_list& args, int nargout); @@ -294,7 +294,7 @@ bool have_regexp, bool return_list, bool verbose, const std::string& msg = ""); - void display (void) const; + void display () const; void set_auto_fcn_var (stack_frame::auto_var_type avt, const octave_value& val); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/debug.cc --- a/libinterp/corefcn/debug.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/debug.cc Tue Jan 24 17:19:44 2023 -0800 @@ -935,7 +935,7 @@ // for example. void -show_octave_dbstack (void) +show_octave_dbstack () { do_dbstack (octave::__get_interpreter__ (), octave_value_list (), 0, std::cerr); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/defaults.cc --- a/libinterp/corefcn/defaults.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/defaults.cc Tue Jan 24 17:19:44 2023 -0800 @@ -74,7 +74,7 @@ return retval; } -static std::string get_octave_home (void) +static std::string get_octave_home () { std::string op = OCTAVE_PREFIX; @@ -86,7 +86,7 @@ return oh.empty () ? op : oh; } -static std::string get_octave_exec_home (void) +static std::string get_octave_exec_home () { std::string op = OCTAVE_PREFIX; std::string oep = OCTAVE_EXEC_PREFIX; @@ -108,14 +108,14 @@ return oep; } -static std::string get_local_site_defaults_file (void) +static std::string get_local_site_defaults_file () { std::string lsf = sys::env::getenv ("OCTAVE_SITE_INITFILE"); return lsf.empty () ? local_startupfile_dir () + "/octaverc" : lsf; } -static std::string get_site_defaults_file (void) +static std::string get_site_defaults_file () { std::string sf = sys::env::getenv ("OCTAVE_VERSION_INITFILE"); @@ -132,7 +132,7 @@ return prepend_home_dir (octave_exec_home (), s); } -std::string canonical_host_type (void) +std::string canonical_host_type () { static const std::string s_canonical_host_type = OCTAVE_CANONICAL_HOST_TYPE; @@ -140,35 +140,35 @@ return s_canonical_host_type; } -std::string release (void) +std::string release () { static const std::string s_octave_release = OCTAVE_RELEASE; return s_octave_release; } -std::string default_pager (void) +std::string default_pager () { static const std::string s_default_pager = OCTAVE_DEFAULT_PAGER; return s_default_pager; } -std::string octave_home (void) +std::string octave_home () { static const std::string s_octave_home = get_octave_home (); return s_octave_home; } -std::string octave_exec_home (void) +std::string octave_exec_home () { static const std::string s_octave_exec_home = get_octave_exec_home (); return s_octave_exec_home; } -std::string bin_dir (void) +std::string bin_dir () { static const std::string s_bin_dir = prepend_octave_exec_home (OCTAVE_BINDIR); @@ -176,7 +176,7 @@ return s_bin_dir; } -std::string data_dir (void) +std::string data_dir () { static const std::string s_data_dir = prepend_octave_home (OCTAVE_DATADIR); @@ -184,7 +184,7 @@ return s_data_dir; } -std::string dataroot_dir (void) +std::string dataroot_dir () { static const std::string s_dataroot_dir = prepend_octave_home (OCTAVE_DATAROOTDIR); @@ -192,7 +192,7 @@ return s_dataroot_dir; } -std::string include_dir (void) +std::string include_dir () { static const std::string s_include_dir = prepend_octave_home (OCTAVE_INCLUDEDIR); @@ -200,7 +200,7 @@ return s_include_dir; } -std::string lib_dir (void) +std::string lib_dir () { static const std::string s_lib_dir = prepend_octave_exec_home (OCTAVE_LIBDIR); @@ -208,7 +208,7 @@ return s_lib_dir; } -std::string libexec_dir (void) +std::string libexec_dir () { static const std::string s_libexec_dir = prepend_octave_exec_home (OCTAVE_LIBEXECDIR); @@ -216,7 +216,7 @@ return s_libexec_dir; } -std::string arch_lib_dir (void) +std::string arch_lib_dir () { static const std::string s_arch_lib_dir = prepend_octave_exec_home (OCTAVE_ARCHLIBDIR); @@ -224,7 +224,7 @@ return s_arch_lib_dir; } -std::string info_dir (void) +std::string info_dir () { static const std::string s_info_dir = prepend_octave_exec_home (OCTAVE_INFODIR); @@ -232,7 +232,7 @@ return s_info_dir; } -std::string local_ver_arch_lib_dir (void) +std::string local_ver_arch_lib_dir () { static const std::string s_local_ver_arch_lib_dir = prepend_octave_exec_home (OCTAVE_LOCALVERARCHLIBDIR); @@ -240,7 +240,7 @@ return s_local_ver_arch_lib_dir; } -std::string local_api_arch_lib_dir (void) +std::string local_api_arch_lib_dir () { static const std::string s_local_api_arch_lib_dir = prepend_octave_exec_home (OCTAVE_LOCALAPIARCHLIBDIR); @@ -248,7 +248,7 @@ return s_local_api_arch_lib_dir; } -std::string local_arch_lib_dir (void) +std::string local_arch_lib_dir () { static const std::string s_local_arch_lib_dir = prepend_octave_exec_home (OCTAVE_LOCALARCHLIBDIR); @@ -256,7 +256,7 @@ return s_local_arch_lib_dir; } -std::string local_ver_oct_file_dir (void) +std::string local_ver_oct_file_dir () { static const std::string s_local_ver_oct_file_dir = prepend_octave_exec_home (OCTAVE_LOCALVEROCTFILEDIR); @@ -264,7 +264,7 @@ return s_local_ver_oct_file_dir; } -std::string local_api_oct_file_dir (void) +std::string local_api_oct_file_dir () { static const std::string s_local_api_oct_file_dir = prepend_octave_exec_home (OCTAVE_LOCALAPIOCTFILEDIR); @@ -272,7 +272,7 @@ return s_local_api_oct_file_dir; } -std::string local_oct_file_dir (void) +std::string local_oct_file_dir () { static const std::string s_local_oct_file_dir = prepend_octave_exec_home (OCTAVE_LOCALOCTFILEDIR); @@ -280,7 +280,7 @@ return s_local_oct_file_dir; } -std::string oct_file_dir (void) +std::string oct_file_dir () { static const std::string s_oct_file_dir = prepend_octave_exec_home (OCTAVE_OCTFILEDIR); @@ -288,7 +288,7 @@ return s_oct_file_dir; } -std::string local_ver_fcn_file_dir (void) +std::string local_ver_fcn_file_dir () { static const std::string s_local_ver_fcn_file_dir = prepend_octave_home (OCTAVE_LOCALVERFCNFILEDIR); @@ -296,7 +296,7 @@ return s_local_ver_fcn_file_dir; } -std::string local_api_fcn_file_dir (void) +std::string local_api_fcn_file_dir () { static const std::string s_local_api_fcn_file_dir = prepend_octave_home (OCTAVE_LOCALAPIFCNFILEDIR); @@ -304,7 +304,7 @@ return s_local_api_fcn_file_dir; } -std::string local_fcn_file_dir (void) +std::string local_fcn_file_dir () { static const std::string s_local_fcn_file_dir = prepend_octave_home (OCTAVE_LOCALFCNFILEDIR); @@ -312,7 +312,7 @@ return s_local_fcn_file_dir; } -std::string fcn_file_dir (void) +std::string fcn_file_dir () { static const std::string s_fcn_file_dir = prepend_octave_home (OCTAVE_FCNFILEDIR); @@ -320,7 +320,7 @@ return s_fcn_file_dir; } -std::string oct_data_dir (void) +std::string oct_data_dir () { static const std::string s_oct_data_dir = prepend_octave_home (OCTAVE_OCTDATADIR); @@ -328,7 +328,7 @@ return s_oct_data_dir; } -std::string oct_doc_dir (void) +std::string oct_doc_dir () { static const std::string s_oct_doc_dir = prepend_octave_home (OCTAVE_OCTDOCDIR); @@ -336,7 +336,7 @@ return s_oct_doc_dir; } -std::string oct_etc_dir (void) +std::string oct_etc_dir () { static const std::string s_oct_etc_dir = prepend_octave_home (OCTAVE_OCTETCDIR); @@ -344,7 +344,7 @@ return s_oct_etc_dir; } -std::string oct_fonts_dir (void) +std::string oct_fonts_dir () { static const std::string s_oct_fonts_dir = prepend_octave_home (OCTAVE_OCTFONTSDIR); @@ -352,7 +352,7 @@ return s_oct_fonts_dir; } -std::string oct_include_dir (void) +std::string oct_include_dir () { static const std::string s_oct_include_dir = prepend_octave_home (OCTAVE_OCTINCLUDEDIR); @@ -360,7 +360,7 @@ return s_oct_include_dir; } -std::string oct_lib_dir (void) +std::string oct_lib_dir () { static const std::string s_oct_lib_dir = prepend_octave_exec_home (OCTAVE_OCTLIBDIR); @@ -368,7 +368,7 @@ return s_oct_lib_dir; } -std::string oct_locale_dir (void) +std::string oct_locale_dir () { static const std::string s_oct_locale_dir = prepend_octave_home (OCTAVE_OCTLOCALEDIR); @@ -376,7 +376,7 @@ return s_oct_locale_dir; } -std::string oct_tests_dir (void) +std::string oct_tests_dir () { static const std::string s_oct_tests_dir = prepend_octave_home (OCTAVE_OCTTESTSDIR); @@ -384,7 +384,7 @@ return s_oct_tests_dir; } -std::string man_dir (void) +std::string man_dir () { static const std::string s_man_dir = prepend_octave_home (OCTAVE_MANDIR); @@ -392,7 +392,7 @@ return s_man_dir; } -std::string man1_dir (void) +std::string man1_dir () { static const std::string s_man1_dir = prepend_octave_home (OCTAVE_MAN1DIR); @@ -400,14 +400,14 @@ return s_man1_dir; } -std::string man1_ext (void) +std::string man1_ext () { static const std::string s_man1_ext = OCTAVE_MAN1EXT; return s_man1_ext; } -std::string image_dir (void) +std::string image_dir () { static const std::string s_image_dir = prepend_octave_home (OCTAVE_IMAGEDIR); @@ -415,7 +415,7 @@ return s_image_dir; } -std::string local_startupfile_dir (void) +std::string local_startupfile_dir () { static const std::string s_local_startupfile_dir = prepend_octave_home (OCTAVE_LOCALSTARTUPFILEDIR); @@ -423,7 +423,7 @@ return s_local_startupfile_dir; } -std::string startupfile_dir (void) +std::string startupfile_dir () { static const std::string s_startupfile_dir = prepend_octave_home (OCTAVE_STARTUPFILEDIR); @@ -431,7 +431,7 @@ return s_startupfile_dir; } -std::string local_site_defaults_file (void) +std::string local_site_defaults_file () { static const std::string s_local_site_defaults_file = get_local_site_defaults_file (); @@ -439,7 +439,7 @@ return s_local_site_defaults_file; } -std::string site_defaults_file (void) +std::string site_defaults_file () { static const std::string s_site_defaults_file = get_site_defaults_file (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/defaults.h --- a/libinterp/corefcn/defaults.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/defaults.h Tue Jan 24 17:19:44 2023 -0800 @@ -46,61 +46,61 @@ // functions to be consistent with the values that require // initialization. -extern OCTINTERP_API std::string canonical_host_type (void); -extern OCTINTERP_API std::string release (void); -extern OCTINTERP_API std::string default_pager (void); +extern OCTINTERP_API std::string canonical_host_type (); +extern OCTINTERP_API std::string release (); +extern OCTINTERP_API std::string default_pager (); // These require initialization, so can't be defined as pure // constants. We use functions to access these values so that // they can't be modified by users. -extern OCTINTERP_API std::string octave_home (void); -extern OCTINTERP_API std::string octave_exec_home (void); +extern OCTINTERP_API std::string octave_home (); +extern OCTINTERP_API std::string octave_exec_home (); -extern OCTINTERP_API std::string bin_dir (void); -extern OCTINTERP_API std::string data_dir (void); -extern OCTINTERP_API std::string dataroot_dir (void); -extern OCTINTERP_API std::string include_dir (void); -extern OCTINTERP_API std::string lib_dir (void); -extern OCTINTERP_API std::string libexec_dir (void); +extern OCTINTERP_API std::string bin_dir (); +extern OCTINTERP_API std::string data_dir (); +extern OCTINTERP_API std::string dataroot_dir (); +extern OCTINTERP_API std::string include_dir (); +extern OCTINTERP_API std::string lib_dir (); +extern OCTINTERP_API std::string libexec_dir (); -extern OCTINTERP_API std::string local_ver_arch_lib_dir (void); -extern OCTINTERP_API std::string local_api_arch_lib_dir (void); -extern OCTINTERP_API std::string local_arch_lib_dir (void); -extern OCTINTERP_API std::string arch_lib_dir (void); +extern OCTINTERP_API std::string local_ver_arch_lib_dir (); +extern OCTINTERP_API std::string local_api_arch_lib_dir (); +extern OCTINTERP_API std::string local_arch_lib_dir (); +extern OCTINTERP_API std::string arch_lib_dir (); -extern OCTINTERP_API std::string local_ver_oct_file_dir (void); -extern OCTINTERP_API std::string local_api_oct_file_dir (void); -extern OCTINTERP_API std::string local_oct_file_dir (void); -extern OCTINTERP_API std::string oct_file_dir (void); +extern OCTINTERP_API std::string local_ver_oct_file_dir (); +extern OCTINTERP_API std::string local_api_oct_file_dir (); +extern OCTINTERP_API std::string local_oct_file_dir (); +extern OCTINTERP_API std::string oct_file_dir (); -extern OCTINTERP_API std::string local_ver_fcn_file_dir (void); -extern OCTINTERP_API std::string local_api_fcn_file_dir (void); -extern OCTINTERP_API std::string local_fcn_file_dir (void); -extern OCTINTERP_API std::string fcn_file_dir (void); +extern OCTINTERP_API std::string local_ver_fcn_file_dir (); +extern OCTINTERP_API std::string local_api_fcn_file_dir (); +extern OCTINTERP_API std::string local_fcn_file_dir (); +extern OCTINTERP_API std::string fcn_file_dir (); -extern OCTINTERP_API std::string oct_data_dir (void); -extern OCTINTERP_API std::string oct_doc_dir (void); -extern OCTINTERP_API std::string oct_etc_dir (void); -extern OCTINTERP_API std::string oct_fonts_dir (void); -extern OCTINTERP_API std::string oct_include_dir (void); -extern OCTINTERP_API std::string oct_lib_dir (void); -extern OCTINTERP_API std::string oct_locale_dir (void); -extern OCTINTERP_API std::string oct_tests_dir (void); +extern OCTINTERP_API std::string oct_data_dir (); +extern OCTINTERP_API std::string oct_doc_dir (); +extern OCTINTERP_API std::string oct_etc_dir (); +extern OCTINTERP_API std::string oct_fonts_dir (); +extern OCTINTERP_API std::string oct_include_dir (); +extern OCTINTERP_API std::string oct_lib_dir (); +extern OCTINTERP_API std::string oct_locale_dir (); +extern OCTINTERP_API std::string oct_tests_dir (); -extern OCTINTERP_API std::string info_dir (void); +extern OCTINTERP_API std::string info_dir (); -extern OCTINTERP_API std::string man_dir (void); -extern OCTINTERP_API std::string man1_dir (void); -extern OCTINTERP_API std::string man1_ext (void); +extern OCTINTERP_API std::string man_dir (); +extern OCTINTERP_API std::string man1_dir (); +extern OCTINTERP_API std::string man1_ext (); -extern OCTINTERP_API std::string image_dir (void); +extern OCTINTERP_API std::string image_dir (); -extern OCTINTERP_API std::string local_startupfile_dir (void); -extern OCTINTERP_API std::string startupfile_dir (void); +extern OCTINTERP_API std::string local_startupfile_dir (); +extern OCTINTERP_API std::string startupfile_dir (); -extern OCTINTERP_API std::string local_site_defaults_file (void); -extern OCTINTERP_API std::string site_defaults_file (void); +extern OCTINTERP_API std::string local_site_defaults_file (); +extern OCTINTERP_API std::string site_defaults_file (); OCTAVE_END_NAMESPACE(config) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/defun.cc --- a/libinterp/corefcn/defun.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/defun.cc Tue Jan 24 17:19:44 2023 -0800 @@ -51,7 +51,7 @@ // Print the usage part of the doc string of FCN (user-defined or DEFUN). void -print_usage (void) +print_usage () { tree_evaluator& tw = __get_evaluator__ (); @@ -137,7 +137,7 @@ } dynamic_library -get_current_shlib (void) +get_current_shlib () { dynamic_library retval; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/display.cc --- a/libinterp/corefcn/display.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/display.cc Tue Jan 24 17:19:44 2023 -0800 @@ -39,7 +39,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) -void display_info::initialize (void) +void display_info::initialize () { int avail = 0; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/display.h --- a/libinterp/corefcn/display.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/display.h Tue Jan 24 17:19:44 2023 -0800 @@ -42,32 +42,32 @@ // initialize to find the actual system parameters for the given // display. - display_info (void) + display_info () : m_rx (72), m_ry (72), m_ht (1), m_wd (1), m_dp (0), m_dpy_avail (false), m_msg () { } - ~display_info (void) = default; + ~display_info () = default; display_info (const display_info&) = default; display_info& operator = (const display_info&) = default; - void initialize (void); + void initialize (); - double x_dpi (void) const { return m_rx; } + double x_dpi () const { return m_rx; } - double y_dpi (void) const { return m_ry; } + double y_dpi () const { return m_ry; } - int height (void) const { return m_ht; } + int height () const { return m_ht; } - int width (void) const { return m_wd; } + int width () const { return m_wd; } - int depth (void) const { return m_dp; } + int depth () const { return m_dp; } - bool display_available (void) const { return m_dpy_avail; } + bool display_available () const { return m_dpy_avail; } - std::string message (void) const { return m_msg; } + std::string message () const { return m_msg; } private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/dynamic-ld.cc --- a/libinterp/corefcn/dynamic-ld.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/dynamic-ld.cc Tue Jan 24 17:19:44 2023 -0800 @@ -95,7 +95,7 @@ } void -dynamic_loader::shlibs_list::display (void) const +dynamic_loader::shlibs_list::display () const { std::cerr << "current shared libraries:" << std::endl; for (const auto& lib : m_lib_list) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/dynamic-ld.h --- a/libinterp/corefcn/dynamic-ld.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/dynamic-ld.h Tue Jan 24 17:19:44 2023 -0800 @@ -52,7 +52,7 @@ typedef std::list::iterator iterator; typedef std::list::const_iterator const_iterator; - shlibs_list (void) : m_lib_list () { } + shlibs_list () : m_lib_list () { } // No copying! @@ -60,7 +60,7 @@ shlibs_list& operator = (const shlibs_list&) = delete; - ~shlibs_list (void) = default; + ~shlibs_list () = default; void append (const dynamic_library& shl); @@ -68,7 +68,7 @@ dynamic_library find_file (const std::string& file_name) const; - void display (void) const; + void display () const; private: @@ -89,7 +89,7 @@ dynamic_loader& operator = (const dynamic_loader&) = delete; - virtual ~dynamic_loader (void) = default; + virtual ~dynamic_loader () = default; octave_function * load_oct (const std::string& fcn_name, diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/environment.cc --- a/libinterp/corefcn/environment.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/environment.cc Tue Jan 24 17:19:44 2023 -0800 @@ -104,7 +104,7 @@ false); } -std::string environment::init_editor (void) +std::string environment::init_editor () { std::string retval = "emacs"; @@ -116,7 +116,7 @@ return retval; } -std::string environment::init_exec_path (void) +std::string environment::init_exec_path () { std::string exec_path = sys::env::getenv ("OCTAVE_EXEC_PATH"); @@ -134,7 +134,7 @@ return exec_path; } -std::string environment::init_image_path (void) +std::string environment::init_image_path () { std::string image_path = "."; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/environment.h --- a/libinterp/corefcn/environment.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/environment.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,7 +39,7 @@ { public: - environment (void) + environment () : m_editor (init_editor ()), m_exec_path (init_exec_path ()), m_image_path (init_image_path ()) @@ -47,7 +47,7 @@ octave_value editor (const octave_value_list& args, int nargout); - std::string editor (void) const { return m_editor; } + std::string editor () const { return m_editor; } std::string editor (const std::string& ed) { @@ -56,13 +56,13 @@ octave_value exec_path (const octave_value_list& args, int nargout); - std::string exec_path (void) const { return m_exec_path; } + std::string exec_path () const { return m_exec_path; } std::string exec_path (const std::string& path); octave_value image_path (const octave_value_list& args, int nargout); - std::string image_path (void) const { return m_image_path; } + std::string image_path () const { return m_image_path; } std::string image_path (const std::string& path) { @@ -77,11 +77,11 @@ std::string m_image_path; - static std::string init_editor (void); + static std::string init_editor (); - static std::string init_exec_path (void); + static std::string init_exec_path (); - static std::string init_image_path (void); + static std::string init_image_path (); std::string set (std::string& var, const std::string& new_val) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/error.cc --- a/libinterp/corefcn/error.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/error.cc Tue Jan 24 17:19:44 2023 -0800 @@ -697,7 +697,7 @@ return retval; } -std::string error_system::default_warning_state (void) +std::string error_system::default_warning_state () { std::string retval = "on"; @@ -829,7 +829,7 @@ set_warning_option ("off", id); } -void error_system::initialize_default_warning_state (void) +void error_system::initialize_default_warning_state () { warning_options (init_warning_options ("on")); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/error.h --- a/libinterp/corefcn/error.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/error.h Tue Jan 24 17:19:44 2023 -0800 @@ -52,14 +52,14 @@ error_system& operator = (const error_system&) = delete; - ~error_system (void) = default; + ~error_system () = default; OCTINTERP_API octave_value debug_on_error (const octave_value_list& args, int nargout); void set_debug_on_error (bool flag) { m_debug_on_error = flag; } - bool debug_on_error (void) const { return m_debug_on_error; } + bool debug_on_error () const { return m_debug_on_error; } bool debug_on_error (bool flag) { @@ -73,7 +73,7 @@ void set_debug_on_caught (bool flag) { m_debug_on_caught = flag; } - bool debug_on_caught (void) const { return m_debug_on_caught; } + bool debug_on_caught () const { return m_debug_on_caught; } bool debug_on_caught (bool flag) { @@ -87,7 +87,7 @@ void set_debug_on_warning (bool flag) { m_debug_on_warning = flag; } - bool debug_on_warning (void) const { return m_debug_on_warning; } + bool debug_on_warning () const { return m_debug_on_warning; } bool debug_on_warning (bool flag) { @@ -104,7 +104,7 @@ m_discard_warning_messages = flag; } - bool discard_warning_messages (void) const + bool discard_warning_messages () const { return m_discard_warning_messages; } @@ -121,7 +121,7 @@ void set_beep_on_error (bool flag) { m_beep_on_error = flag; } - bool beep_on_error (void) const { return m_beep_on_error; } + bool beep_on_error () const { return m_beep_on_error; } bool beep_on_error (bool flag) { @@ -135,7 +135,7 @@ void set_backtrace_on_warning (bool flag) { m_backtrace_on_warning = flag; } - bool backtrace_on_warning (void) const { return m_backtrace_on_warning; } + bool backtrace_on_warning () const { return m_backtrace_on_warning; } bool backtrace_on_warning (bool flag) { @@ -149,7 +149,7 @@ void set_verbose_warning (bool flag) { m_verbose_warning = flag; } - bool verbose_warning (void) const { return m_verbose_warning; } + bool verbose_warning () const { return m_verbose_warning; } bool verbose_warning (bool flag) { @@ -163,7 +163,7 @@ void set_quiet_warning (bool flag) { m_quiet_warning = flag; } - bool quiet_warning (void) const { return m_quiet_warning; } + bool quiet_warning () const { return m_quiet_warning; } bool quiet_warning (bool flag) { @@ -172,7 +172,7 @@ return val; } - octave_map warning_options (void) const { return m_warning_options; } + octave_map warning_options () const { return m_warning_options; } void set_warning_options (const octave_map& val) { m_warning_options = val; } @@ -190,7 +190,7 @@ void set_last_error_message (const std::string& val) { m_last_error_message = val; } - std::string last_error_message (void) const { return m_last_error_message; } + std::string last_error_message () const { return m_last_error_message; } std::string last_error_message (const std::string& s) { @@ -205,7 +205,7 @@ void set_last_warning_message (const std::string& val) { m_last_warning_message = val; } - std::string last_warning_message (void) const + std::string last_warning_message () const { return m_last_warning_message; } std::string last_warning_message (const std::string& s) @@ -221,7 +221,7 @@ void set_last_warning_id (const std::string& val) { m_last_warning_id = val; } - std::string last_warning_id (void) const { return m_last_warning_id; } + std::string last_warning_id () const { return m_last_warning_id; } std::string last_warning_id (const std::string& s) { @@ -235,7 +235,7 @@ void set_last_error_id (const std::string& val) { m_last_error_id = val; } - std::string last_error_id (void) const { return m_last_error_id; } + std::string last_error_id () const { return m_last_error_id; } std::string last_error_id (const std::string& s) { @@ -249,7 +249,7 @@ m_last_error_stack = val; } - octave_map last_error_stack (void) const { return m_last_error_stack; } + octave_map last_error_stack () const { return m_last_error_stack; } octave_map last_error_stack (const octave_map& new_val) { @@ -305,7 +305,7 @@ OCTINTERP_API octave_scalar_map warning_query (const std::string& id_arg); - OCTINTERP_API std::string default_warning_state (void); + OCTINTERP_API std::string default_warning_state (); OCTINTERP_API void display_warning_options (std::ostream& os); @@ -314,7 +314,7 @@ OCTINTERP_API void disable_warning (const std::string& id); - OCTINTERP_API void initialize_default_warning_state (void); + OCTINTERP_API void initialize_default_warning_state (); OCTINTERP_API void interpreter_try (unwind_protect& frame); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/errwarn.cc --- a/libinterp/corefcn/errwarn.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/errwarn.cc Tue Jan 24 17:19:44 2023 -0800 @@ -38,7 +38,7 @@ //////////////////////////////////////////////////////////////////////////////// void -err_2_or_3_dim_plot (void) +err_2_or_3_dim_plot () { error ("plot: can only plot in 2 or 3 dimensions"); } @@ -62,7 +62,7 @@ } void -err_indexed_cs_list (void) +err_indexed_cs_list () { error ("a cs-list cannot be further indexed"); } @@ -74,25 +74,25 @@ } void -err_invalid_inquiry_subscript (void) +err_invalid_inquiry_subscript () { error ("invalid dimension inquiry of a non-existent value"); } void -err_invalid_structure_assignment (void) +err_invalid_structure_assignment () { error ("invalid dot name structure assignment because the structure array is empty. Specify a subscript on the structure array to resolve."); } void -err_nonbraced_cs_list_assignment (void) +err_nonbraced_cs_list_assignment () { error ("invalid assignment to cs-list outside multiple assignment"); } void -err_nonconformant (void) +err_nonconformant () { error ("nonconformant matrices"); } @@ -113,7 +113,7 @@ } void -err_range_invalid (void) +err_range_invalid () { error ("range constant used in invalid context"); } @@ -125,7 +125,7 @@ } void -err_string_invalid (void) +err_string_invalid () { error ("std::string constant used in invalid context"); } @@ -137,7 +137,7 @@ } void -err_unrecognized_float_fmt (void) +err_unrecognized_float_fmt () { error ("unrecognized floating point format requested"); } @@ -300,7 +300,7 @@ */ void -warn_complex_cmp (void) +warn_complex_cmp () { warning_with_id ("Octave:language-extension", "comparing complex numbers is not supported in Matlab"); @@ -362,7 +362,7 @@ } void -warn_logical_conversion (void) +warn_logical_conversion () { warning_with_id ("Octave:logical-conversion", "value not equal to 1 or 0 converted to logical 1"); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/errwarn.h --- a/libinterp/corefcn/errwarn.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/errwarn.h Tue Jan 24 17:19:44 2023 -0800 @@ -44,7 +44,7 @@ //////////////////////////////////////////////////////////////////////////////// OCTAVE_NORETURN extern OCTINTERP_API void -err_2_or_3_dim_plot (void); +err_2_or_3_dim_plot (); OCTAVE_NORETURN extern OCTINTERP_API void err_data_conversion (const char *from, const char *to); @@ -54,22 +54,22 @@ const std::string& pkg = "Octave"); OCTAVE_NORETURN extern OCTINTERP_API void -err_indexed_cs_list (void); +err_indexed_cs_list (); OCTAVE_NORETURN extern OCTINTERP_API void err_invalid_conversion (const std::string& from, const std::string& to); OCTAVE_NORETURN extern OCTINTERP_API void -err_invalid_inquiry_subscript (void); +err_invalid_inquiry_subscript (); OCTAVE_NORETURN extern OCTINTERP_API void -err_invalid_structure_assignment (void); +err_invalid_structure_assignment (); OCTAVE_NORETURN extern OCTINTERP_API void -err_nonbraced_cs_list_assignment (void); +err_nonbraced_cs_list_assignment (); OCTAVE_NORETURN extern OCTINTERP_API void -err_nonconformant (void); +err_nonconformant (); OCTAVE_NORETURN extern OCTINTERP_API void err_nonconformant (octave_idx_type r1, octave_idx_type c1, @@ -79,19 +79,19 @@ err_not_implemented (const char *); OCTAVE_NORETURN extern OCTINTERP_API void -err_range_invalid (void); +err_range_invalid (); OCTAVE_NORETURN extern OCTINTERP_API void err_square_matrix_required (const char *fcn, const char *name); OCTAVE_NORETURN extern OCTINTERP_API void -err_string_invalid (void); +err_string_invalid (); OCTAVE_NORETURN extern OCTINTERP_API void err_unrecognized_data_fmt (const char *name); OCTAVE_NORETURN extern OCTINTERP_API void -err_unrecognized_float_fmt (void); +err_unrecognized_float_fmt (); OCTAVE_NORETURN extern OCTINTERP_API void err_user_returned_invalid (const char *name); @@ -158,7 +158,7 @@ warn_array_as_logical (const dim_vector& dv); extern OCTINTERP_API void -warn_complex_cmp (void); +warn_complex_cmp (); extern OCTINTERP_API void warn_data_file_in_path (const std::string& fcn, const std::string& file); @@ -184,7 +184,7 @@ warn_invalid_value_specified (const char *name); extern OCTINTERP_API void -warn_logical_conversion (void); +warn_logical_conversion (); extern OCTINTERP_API void warn_wrong_type_arg (const char *name, const octave_value& tc); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/event-manager.cc --- a/libinterp/corefcn/event-manager.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/event-manager.cc Tue Jan 24 17:19:44 2023 -0800 @@ -46,7 +46,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) -static int readline_event_hook (void) +static int readline_event_hook () { event_manager& evmgr = __get_event_manager__ (); @@ -74,7 +74,7 @@ command_editor::add_event_hook (readline_event_hook); } -event_manager::~event_manager (void) +event_manager::~event_manager () { delete m_event_queue_mutex; } @@ -94,7 +94,7 @@ m_instance = obj; } -bool event_manager::enable (void) +bool event_manager::enable () { bool retval = m_link_enabled; @@ -121,7 +121,7 @@ } } -void event_manager::discard_events (void) +void event_manager::discard_events () { if (enabled ()) { @@ -133,13 +133,13 @@ } } -void event_manager::push_event_queue (void) +void event_manager::push_event_queue () { std::shared_ptr evq (new event_queue ()); m_gui_event_queue.push (evq); } -void event_manager::pop_event_queue (void) +void event_manager::pop_event_queue () { // FIXME: Should we worry about the possibility of events remaining // in the queue when we pop back to the previous queue? If so, then @@ -172,7 +172,7 @@ } } -void event_manager::set_workspace (void) +void event_manager::set_workspace () { if (enabled ()) { @@ -183,7 +183,7 @@ } } -void event_manager::set_history (void) +void event_manager::set_history () { if (enabled ()) m_instance->set_history (command_history::list ()); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/event-manager.h --- a/libinterp/corefcn/event-manager.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/event-manager.h Tue Jan 24 17:19:44 2023 -0800 @@ -44,7 +44,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) -typedef std::function fcn_callback; +typedef std::function fcn_callback; typedef std::function meth_callback; class execution_exception; @@ -79,13 +79,13 @@ { public: - interpreter_events (void) = default; + interpreter_events () = default; interpreter_events (const interpreter_events&) = default; interpreter_events& operator = (const interpreter_events&) = default; - virtual ~interpreter_events (void) = default; + virtual ~interpreter_events () = default; // Note: START_GUI and CLOSE_GUI currently only work with the new // experimental terminal widget. @@ -96,11 +96,11 @@ // command line application. virtual void start_gui (bool /*gui_app*/ = false) { } - virtual void close_gui (void) { } + virtual void close_gui () { } // Dialogs. - virtual bool have_dialogs (void) const { return false; } + virtual bool have_dialogs () const { return false; } typedef std::list> filter_list; @@ -144,27 +144,27 @@ return ""; } - virtual void update_path_dialog (void) { } + virtual void update_path_dialog () { } - virtual void show_preferences (void) { } + virtual void show_preferences () { } - virtual void apply_preferences (void) { } + virtual void apply_preferences () { } - virtual void show_terminal_window (void) { } + virtual void show_terminal_window () { } virtual bool show_documentation (const std::string& /*file*/) { return false; } - virtual void show_file_browser (void) { } + virtual void show_file_browser () { } - virtual void show_command_history (void) { } + virtual void show_command_history () { } - virtual void show_workspace (void) { } + virtual void show_workspace () { } virtual void show_community_news (int /*serial*/) { } - virtual void show_release_notes (void) { } + virtual void show_release_notes () { } virtual bool edit_file (const std::string& /*file*/) { return false; } @@ -176,7 +176,7 @@ // confirmation before another action. Could these be reformulated // using the question_dialog action? - virtual bool confirm_shutdown (void) { return true; } + virtual bool confirm_shutdown () { return true; } virtual bool prompt_new_edit_file (const std::string& /*file*/) { @@ -231,7 +231,7 @@ virtual void gui_status_update (const std::string& /*feature*/, const std::string& /*status*/) { } - virtual void update_gui_lexer (void) { } + virtual void update_gui_lexer () { } // Notifications of events in the interpreter that a GUI will // normally wish to respond to. @@ -250,7 +250,7 @@ bool /*update_variable_editor*/) { } - virtual void clear_workspace (void) { } + virtual void clear_workspace () { } virtual void update_prompt (const std::string& /*prompt*/) { } @@ -258,11 +258,11 @@ virtual void append_history (const std::string& /*hist_entry*/) { } - virtual void clear_history (void) { } + virtual void clear_history () { } - virtual void pre_input_event (void) { } + virtual void pre_input_event () { } - virtual void post_input_event (void) { } + virtual void post_input_event () { } virtual void enter_debugger_event (const std::string& /*fcn_name*/, @@ -273,14 +273,14 @@ virtual void execute_in_debugger_event (const std::string& /*file*/, int /*line*/) { } - virtual void exit_debugger_event (void) { } + virtual void exit_debugger_event () { } virtual void update_breakpoint (bool /*insert*/, const std::string& /*file*/, int /*line*/, const std::string& /*cond*/) { } - virtual void interpreter_interrupted (void) { } + virtual void interpreter_interrupted () { } }; //! Provides threadsafe access to octave. @@ -303,7 +303,7 @@ event_manager& operator = (const event_manager&) = delete; - virtual ~event_manager (void); + virtual ~event_manager (); // OBJ should be an object of a class that is derived from the base // class interpreter_events, or nullptr to disconnect and delete the @@ -312,16 +312,16 @@ OCTINTERP_API void connect_link (const std::shared_ptr& obj); - OCTINTERP_API bool enable (void); + OCTINTERP_API bool enable (); - bool disable (void) + bool disable () { bool retval = m_link_enabled; m_link_enabled = false; return retval; } - bool enabled (void) const + bool enabled () const { return m_link_enabled; } @@ -337,22 +337,22 @@ } std::shared_ptr - qt_event_handlers (void) const { return m_qt_event_handlers; } + qt_event_handlers () const { return m_qt_event_handlers; } // If disable is TRUE, then no additional events will be processed // other than exit. OCTINTERP_API void process_events (bool disable = false); - OCTINTERP_API void discard_events (void); + OCTINTERP_API void discard_events (); // The post_event and post_exception functions provide a thread-safe // way for the GUI to queue interpreter functions for execution. // The queued functions are executed when the interpreter is // otherwise idle. - void push_event_queue (void); - void pop_event_queue (void); + void push_event_queue (); + void pop_event_queue (); OCTINTERP_API void post_event (const fcn_callback& fcn); OCTINTERP_API void post_event (const meth_callback& meth); @@ -376,7 +376,7 @@ m_instance->start_gui (gui_app); } - void close_gui (void) + void close_gui () { if (enabled ()) m_instance->close_gui (); @@ -384,7 +384,7 @@ // Dialogs - bool have_dialogs (void) const + bool have_dialogs () const { return m_qt_event_handlers && m_qt_event_handlers->have_dialogs (); } @@ -442,13 +442,13 @@ : ""); } - void update_path_dialog (void) + void update_path_dialog () { if (application::is_gui_running () && enabled ()) m_instance->update_path_dialog (); } - bool show_preferences (void) + bool show_preferences () { if (enabled ()) { @@ -459,7 +459,7 @@ return false; } - bool apply_preferences (void) + bool apply_preferences () { if (enabled ()) { @@ -470,7 +470,7 @@ return false; } - void show_terminal_window (void) + void show_terminal_window () { if (enabled ()) m_instance->show_terminal_window (); @@ -481,19 +481,19 @@ return enabled () ? m_instance->show_documentation (file) : false; } - void show_file_browser (void) + void show_file_browser () { if (enabled ()) m_instance->show_file_browser (); } - void show_command_history (void) + void show_command_history () { if (enabled ()) m_instance->show_command_history (); } - void show_workspace (void) + void show_workspace () { if (enabled ()) m_instance->show_workspace (); @@ -505,7 +505,7 @@ m_instance->show_community_news (serial); } - void show_release_notes (void) + void show_release_notes () { if (enabled ()) m_instance->show_release_notes (); @@ -527,7 +527,7 @@ return false; } - bool confirm_shutdown (void) + bool confirm_shutdown () { bool retval = true; @@ -637,7 +637,7 @@ return false; } - bool update_gui_lexer (void) + bool update_gui_lexer () { if (enabled ()) { @@ -667,7 +667,7 @@ m_instance->file_renamed (load_new); } - OCTINTERP_API void set_workspace (void); + OCTINTERP_API void set_workspace (); void set_workspace (bool top_level, const symbol_info_list& syminfo, bool update_variable_editor = true) @@ -677,7 +677,7 @@ update_variable_editor); } - void clear_workspace (void) + void clear_workspace () { if (enabled ()) m_instance->clear_workspace (); @@ -689,7 +689,7 @@ m_instance->update_prompt (prompt); } - OCTINTERP_API void set_history (void); + OCTINTERP_API void set_history (); void set_history (const string_vector& hist) { @@ -703,19 +703,19 @@ m_instance->append_history (hist_entry); } - void clear_history (void) + void clear_history () { if (enabled ()) m_instance->clear_history (); } - void pre_input_event (void) + void pre_input_event () { if (enabled ()) m_instance->pre_input_event (); } - void post_input_event (void) + void post_input_event () { if (enabled ()) m_instance->post_input_event (); @@ -738,7 +738,7 @@ m_instance->execute_in_debugger_event (file, line); } - void exit_debugger_event (void) + void exit_debugger_event () { if (enabled () && m_debugging) { @@ -755,7 +755,7 @@ m_instance->update_breakpoint (insert, file, line, cond); } - void interpreter_interrupted (void) + void interpreter_interrupted () { if (enabled ()) m_instance->interpreter_interrupted (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/event-queue.cc --- a/libinterp/corefcn/event-queue.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/event-queue.cc Tue Jan 24 17:19:44 2023 -0800 @@ -33,7 +33,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) void -event_queue_safe::warn_unhandled_exception (void) const +event_queue_safe::warn_unhandled_exception () const { warning ("unhandled exception in event_queue_safe handler. " "It is a bug in Octave for this to happen. " diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/event-queue.h --- a/libinterp/corefcn/event-queue.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/event-queue.h Tue Jan 24 17:19:44 2023 -0800 @@ -40,7 +40,7 @@ { public: - event_queue (void) : m_fifo () { } + event_queue () : m_fifo () { } // No copying! @@ -51,9 +51,9 @@ // Destructor should not raise an exception, so all actions registered // should be exception-safe. If you're not sure, see event_queue_safe. - ~event_queue (void) { run (); } + ~event_queue () { run (); } - void run_first (void) + void run_first () { if (! empty ()) { @@ -64,7 +64,7 @@ } } - void discard_first (void) + void discard_first () { if (! empty ()) { @@ -74,7 +74,7 @@ } } - std::size_t size (void) const { return m_fifo.size (); } + std::size_t size () const { return m_fifo.size (); } protected: @@ -97,7 +97,7 @@ { public: - event_queue_safe (void) : event_queue () { } + event_queue_safe () : event_queue () { } // No copying! @@ -105,7 +105,7 @@ event_queue_safe& operator = (const event_queue_safe&) = delete; - ~event_queue_safe (void) + ~event_queue_safe () { while (! empty ()) { @@ -122,7 +122,7 @@ private: - void warn_unhandled_exception (void) const; + void warn_unhandled_exception () const; }; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/fcn-info.cc --- a/libinterp/corefcn/fcn-info.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/fcn-info.cc Tue Jan 24 17:19:44 2023 -0800 @@ -91,7 +91,7 @@ } octave_value -fcn_info::fcn_info_rep::load_class_constructor (void) +fcn_info::fcn_info_rep::load_class_constructor () { octave_value retval; @@ -241,7 +241,7 @@ // to btyp_num_types (static constant). Only the leftmost dimension can be // variable in C/C++. Typedefs are boring. -static builtin_type_t (* build_sup_table (void))[btyp_num_types] +static builtin_type_t (* build_sup_table ())[btyp_num_types] { static builtin_type_t sup_table[btyp_num_types][btyp_num_types]; for (int i = 0; i < btyp_num_types; i++) @@ -999,7 +999,7 @@ } octave_value -fcn_info::fcn_info_rep::find_autoload (void) +fcn_info::fcn_info_rep::find_autoload () { // Autoloaded function. @@ -1030,7 +1030,7 @@ } octave_value -fcn_info::fcn_info_rep::find_user_function (void) +fcn_info::fcn_info_rep::find_user_function () { // Function on the path. @@ -1060,7 +1060,7 @@ } octave_value -fcn_info::fcn_info_rep::find_package (void) +fcn_info::fcn_info_rep::find_package () { // FIXME: implement correct way to check out of date package //if (package.is_defined ()) @@ -1098,7 +1098,7 @@ } octave_value -fcn_info::fcn_info_rep::dump (void) const +fcn_info::fcn_info_rep::dump () const { std::map m = {{ "name", full_name () }, diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/fcn-info.h --- a/libinterp/corefcn/fcn-info.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/fcn-info.h Tue Jan 24 17:19:44 2023 -0800 @@ -74,13 +74,13 @@ fcn_info_rep& operator = (const fcn_info_rep&) = delete; - ~fcn_info_rep (void) = default; + ~fcn_info_rep () = default; octave_value install_local_function (const std::string& file_name); octave_value load_private_function (const std::string& dir_name); - octave_value load_class_constructor (void); + octave_value load_class_constructor (); octave_value load_class_method (const std::string& dispatch_type); @@ -97,13 +97,13 @@ octave_value find_method (const octave_value_list& args); - octave_value find_autoload (void); + octave_value find_autoload (); - octave_value find_package (void); + octave_value find_package (); - octave_value find_user_function (void); + octave_value find_user_function (); - bool is_user_function_defined (void) const + bool is_user_function_defined () const { return function_on_path.is_defined (); } @@ -171,13 +171,13 @@ cmdline_function = octave_value (); } - void clear_mex_function (void) + void clear_mex_function () { if (function_on_path.is_mex_function ()) clear_user_function (); } - void clear_package (void) + void clear_package () { package = octave_value (); } @@ -194,9 +194,9 @@ clear_package (); } - octave_value dump (void) const; + octave_value dump () const; - std::string full_name (void) const + std::string full_name () const { if (package_name.empty ()) return name; @@ -247,7 +247,7 @@ fcn_info& operator = (const fcn_info&) = default; - ~fcn_info (void) = default; + ~fcn_info () = default; octave_value find (const symbol_scope& search_scope, const octave_value_list& args = octave_value_list ()) @@ -276,28 +276,28 @@ return m_rep->find_method (dispatch_type); } - octave_value find_built_in_function (void) const + octave_value find_built_in_function () const { return m_rep->built_in_function; } - octave_value find_cmdline_function (void) const + octave_value find_cmdline_function () const { return m_rep->cmdline_function; } - octave_value find_autoload (void) + octave_value find_autoload () { return m_rep->find_autoload (); } // FIXME: find_function_on_path might be a better name? - octave_value find_user_function (void) + octave_value find_user_function () { return m_rep->find_user_function (); } - bool is_user_function_defined (void) const + bool is_user_function_defined () const { return m_rep->is_user_function_defined (); } @@ -347,9 +347,9 @@ m_rep->clear_autoload_function (force); } - void clear_mex_function (void) { m_rep->clear_mex_function (); } + void clear_mex_function () { m_rep->clear_mex_function (); } - octave_value dump (void) const { return m_rep->dump (); } + octave_value dump () const { return m_rep->dump (); } private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/ft-text-renderer.cc --- a/libinterp/corefcn/ft-text-renderer.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/ft-text-renderer.cc Tue Jan 24 17:19:44 2023 -0800 @@ -102,7 +102,7 @@ { private: - ft_manager (void) + ft_manager () : m_library (), m_freetype_initialized (false), m_fontconfig_initialized (false) { @@ -129,7 +129,7 @@ private: - ~ft_manager (void) + ~ft_manager () { if (m_freetype_initialized) FT_Done_FreeType (m_library); @@ -146,7 +146,7 @@ public: - static bool instance_ok (void) + static bool instance_ok () { bool retval = true; @@ -159,7 +159,7 @@ return retval; } - static void cleanup_instance (void) + static void cleanup_instance () { delete m_instance; m_instance = nullptr; } static FT_Face get_font (const std::string& name, const std::string& weight, @@ -171,7 +171,7 @@ : nullptr); } - static octave_map get_system_fonts (void) + static octave_map get_system_fonts () { return (instance_ok () ? m_instance->do_get_system_fonts () @@ -189,7 +189,7 @@ typedef std::pair ft_key; typedef std::map ft_cache; - static octave_map do_get_system_fonts (void) + static octave_map do_get_system_fonts () { static octave_map font_map; @@ -468,7 +468,7 @@ public: - ft_text_renderer (void) + ft_text_renderer () : base_text_renderer (), m_font (), m_bbox (1, 4, 0.0), m_halign (0), m_xoffset (0), m_line_yoffset (0), m_yoffset (0), m_mode (MODE_BBOX), m_color (dim_vector (1, 3), 0), m_do_strlist (false), m_strlist (), @@ -482,7 +482,7 @@ ft_text_renderer& operator = (const ft_text_renderer&) = delete; - ~ft_text_renderer (void) = default; + ~ft_text_renderer () = default; void visit (text_element_string& e); @@ -504,11 +504,11 @@ void visit (text_element_combined& e); - void reset (void); + void reset (); - uint8NDArray get_pixels (void) const { return m_pixels; } + uint8NDArray get_pixels () const { return m_pixels; } - Matrix get_boundingbox (void) const { return m_bbox; } + Matrix get_boundingbox () const { return m_bbox; } uint8NDArray render (text_element *elt, Matrix& box, int rotation = ROTATION_0); @@ -522,7 +522,7 @@ void set_font (const std::string& name, const std::string& weight, const std::string& angle, double size); - octave_map get_system_fonts (void); + octave_map get_system_fonts (); void set_color (const Matrix& c); @@ -543,7 +543,7 @@ { public: - ft_font (void) + ft_font () : text_renderer::font (), m_face (nullptr) { } ft_font (const std::string& nm, const std::string& wt, @@ -553,7 +553,7 @@ ft_font (const ft_font& ft); - ~ft_font (void) + ~ft_font () { if (m_face) FT_Done_Face (m_face); @@ -561,20 +561,20 @@ ft_font& operator = (const ft_font& ft); - bool is_valid (void) const { return get_face (); } + bool is_valid () const { return get_face (); } - FT_Face get_face (void) const; + FT_Face get_face () const; private: mutable FT_Face m_face; }; - void push_new_line (void); + void push_new_line (); - void update_line_bbox (void); + void update_line_bbox (); - void compute_bbox (void); + void compute_bbox (); int compute_line_xoffset (const Matrix& lb) const; @@ -660,13 +660,13 @@ } octave_map -ft_text_renderer::get_system_fonts (void) +ft_text_renderer::get_system_fonts () { return ft_manager::get_system_fonts (); } void -ft_text_renderer::push_new_line (void) +ft_text_renderer::push_new_line () { switch (m_mode) { @@ -727,7 +727,7 @@ } void -ft_text_renderer::compute_bbox (void) +ft_text_renderer::compute_bbox () { // Stack the various line bbox together and compute the final // bounding box for the entire text string. @@ -761,7 +761,7 @@ } void -ft_text_renderer::update_line_bbox (void) +ft_text_renderer::update_line_bbox () { // Called after a font change, when in MODE_BBOX mode, to update the // current line bbox with the new font metrics. This also includes the @@ -1368,7 +1368,7 @@ } void -ft_text_renderer::reset (void) +ft_text_renderer::reset () { set_mode (MODE_BBOX); set_color (Matrix (1, 3, 0.0)); @@ -1509,7 +1509,7 @@ } FT_Face -ft_text_renderer::ft_font::get_face (void) const +ft_text_renderer::ft_font::get_face () const { if (! m_face && ! m_name.empty ()) { @@ -1534,7 +1534,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) base_text_renderer * -make_ft_text_renderer (void) +make_ft_text_renderer () { #if defined (HAVE_FREETYPE) return new ft_text_renderer (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/ft-text-renderer.h --- a/libinterp/corefcn/ft-text-renderer.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/ft-text-renderer.h Tue Jan 24 17:19:44 2023 -0800 @@ -32,7 +32,7 @@ class base_text_renderer; -extern base_text_renderer * make_ft_text_renderer (void); +extern base_text_renderer * make_ft_text_renderer (); OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/genprops.awk --- a/libinterp/corefcn/genprops.awk Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/genprops.awk Tue Jan 24 17:19:44 2023 -0800 @@ -44,7 +44,7 @@ ## in the class declaration: ## ## TYPE -## get_NAME (void) const +## get_NAME () const ## { ## return NAME; ## } @@ -151,7 +151,7 @@ function emit_get_accessor (i, rtype, faccess) { - printf (" %s get_%s (void) const", rtype, name[i]); + printf (" %s get_%s () const", rtype, name[i]); if (emit_get[i] == "definition" && deprecated[i]) printf ("\n {\n warning_with_id (\"Octave:deprecated-property\",\"'%s' is deprecated and will be removed from a future version of Octave\");\n return m_%s.%s ();\n }\n", name[i], name[i], faccess); @@ -165,7 +165,7 @@ function emit_get_bool (i) { - printf (" bool is_%s (void) const", name[i]); + printf (" bool is_%s () const", name[i]); if (emit_get[i] == "definition") printf (" { return m_%s.is_on (); }\n", name[i]); @@ -193,7 +193,7 @@ function emit_get_color (i) { - printf (" bool %s_is_rgb (void) const { return m_%s.is_rgb (); }\n", name[i], name[i]); + printf (" bool %s_is_rgb () const { return m_%s.is_rgb (); }\n", name[i], name[i]); printf (" bool %s_is (const std::string& v) const", name[i]); @@ -202,7 +202,7 @@ else printf (";\n"); - printf (" Matrix get_%s_rgb (void) const", name[i]); + printf (" Matrix get_%s_rgb () const", name[i]); if (emit_get[i] == "definition") printf (" { return (m_%s.is_rgb () ? m_%s.rgb () : Matrix ()); }\n", name[i], name[i]); @@ -216,7 +216,7 @@ function emit_get_double_radio (i) { - printf (" bool %s_is_double (void) const { return m_%s.is_double (); }\n", name[i], name[i]); + printf (" bool %s_is_double () const { return m_%s.is_double (); }\n", name[i], name[i]); printf (" bool %s_is (const std::string& v) const", name[i]); @@ -225,7 +225,7 @@ else printf (";\n"); - printf (" double get_%s_double (void) const", name[i]); + printf (" double get_%s_double () const", name[i]); if (emit_get[i] == "definition") printf (" { return (m_%s.is_double () ? m_%s.double_value () : 0); }\n", name[i], name[i]); @@ -260,14 +260,14 @@ function emit_get_string_array (i) { - printf (" std::string get_%s_string (void) const", name[i]); + printf (" std::string get_%s_string () const", name[i]); if (emit_get[i] == "definition") printf (" { return m_%s.string_value (); }\n", name[i]); else printf (";\n"); - printf (" string_vector get_%s_vector (void) const", name[i]); + printf (" string_vector get_%s_vector () const", name[i]); if (emit_get[i] == "definition") printf (" { return m_%s.string_vector_value (); }\n", name[i]); @@ -283,15 +283,15 @@ { printf ("public:\n"); printf (" properties (const graphics_handle& mh, const graphics_handle& p);\n\n"); - printf (" ~properties (void) { }\n\n"); + printf (" ~properties () { }\n\n"); printf (" void set (const caseless_str& pname, const octave_value& val);\n\n"); printf (" octave_value get (bool all = false) const;\n\n"); printf (" octave_value get (const caseless_str& pname) const;\n\n"); printf (" octave_value get (const std::string& pname) const\n {\n return get (caseless_str (pname));\n }\n\n"); printf (" octave_value get (const char *pname) const\n {\n return get (caseless_str (pname));\n }\n\n"); printf (" property get_property (const caseless_str& pname);\n\n"); - printf (" std::string graphics_object_name (void) const { return s_go_name; }\n\n"); - printf (" static property_list::pval_map_type factory_defaults (void);\n\n"); + printf (" std::string graphics_object_name () const { return s_go_name; }\n\n"); + printf (" static property_list::pval_map_type factory_defaults ();\n\n"); printf ("private:\n static std::string s_go_name;\n\n"); } @@ -300,7 +300,7 @@ if (class_name && ! base) emit_common_declarations(); - printf ("public:\n\n\n static std::set core_property_names (void);\n\n static std::set readonly_property_names (void);\n\n static bool has_core_property (const caseless_str& pname);\n\n static bool has_readonly_property (const caseless_str& pname);\n\n std::set all_property_names (void) const;\n\n"); + printf ("public:\n\n\n static std::set core_property_names ();\n\n static std::set readonly_property_names ();\n\n static bool has_core_property (const caseless_str& pname);\n\n static bool has_readonly_property (const caseless_str& pname);\n\n std::set all_property_names () const;\n\n"); if (! base) printf (" bool has_property (const caseless_str& pname) const;\n\n"); @@ -357,7 +357,7 @@ emit_get_string_array(i); else { - printf (" %s get_%s (void) const", type[i], name[i]); + printf (" %s get_%s () const", type[i], name[i]); if (emit_get[i] == "definition") printf (" { return m_%s; }\n", name[i]); @@ -418,7 +418,7 @@ if (updater[i] == "extern") { - printf (" void update_%s (void);\n\n", name[i]); + printf (" void update_%s ();\n\n", name[i]); } ## if (emit_ov_set[i]) @@ -593,12 +593,12 @@ if (base) { - printf ("property_list::pval_map_type\nbase_properties::factory_defaults (void)\n{\n"); + printf ("property_list::pval_map_type\nbase_properties::factory_defaults ()\n{\n"); printf (" property_list::pval_map_type m;\n\n"); } else { - printf ("property_list::pval_map_type\n%s::properties::factory_defaults (void)\n{\n", + printf ("property_list::pval_map_type\n%s::properties::factory_defaults ()\n{\n", class_name); printf (" property_list::pval_map_type m = base_properties::factory_defaults ();\n\n"); } @@ -638,7 +638,7 @@ printf ("base_properties"); else printf ("%s::properties", class_name); - printf ("::core_property_names (void)\n{\n static std::set all_pnames;\n\n static bool initialized = false;\n\n if (! initialized)\n {\n"); + printf ("::core_property_names ()\n{\n static std::set all_pnames;\n\n static bool initialized = false;\n\n if (! initialized)\n {\n"); for (i = 1; i <= idx; i++) printf (" all_pnames.insert (\"%s\");\n", name[i]); if (! base) @@ -658,7 +658,7 @@ printf ("base_properties"); else printf ("%s::properties", class_name); - printf ("::readonly_property_names (void)\n{\n static std::set all_pnames;\n\n static bool initialized = false;\n\n if (! initialized)\n {\n"); + printf ("::readonly_property_names ()\n{\n static std::set all_pnames;\n\n static bool initialized = false;\n\n if (! initialized)\n {\n"); for (i = 1; i <= idx; i++) if (readonly[i]) { @@ -681,7 +681,7 @@ printf ("base_properties"); else printf ("%s::properties", class_name); - printf ("::all_property_names (void) const\n{\n static std::set all_pnames = core_property_names ();\n\n"); + printf ("::all_property_names () const\n{\n static std::set all_pnames = core_property_names ();\n\n"); if (base) printf (" std::set retval = all_pnames;\n std::set dyn_props = dynamic_property_names ();\n retval.insert (dyn_props.begin (), dyn_props.end ());\n for (std::map::const_iterator p = m_all_props.begin ();\n p != m_all_props.end (); p++)\n retval.insert (p->first);\n\n return retval;\n}\n\n"); else diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/gh-manager.cc --- a/libinterp/corefcn/gh-manager.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/gh-manager.cc Tue Jan 24 17:19:44 2023 -0800 @@ -39,7 +39,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) static double -make_handle_fraction (void) +make_handle_fraction () { static double maxrand = RAND_MAX + 2.0; @@ -180,7 +180,7 @@ } void -gh_manager::close_all_figures (void) +gh_manager::close_all_figures () { // FIXME: should we process or discard pending events? @@ -349,7 +349,7 @@ } void -gh_manager::restore_gcbo (void) +gh_manager::restore_gcbo () { octave::autolock guard (m_graphics_lock); @@ -475,7 +475,7 @@ } static int -process_graphics_events (void) +process_graphics_events () { gh_manager& gh_mgr = octave::__get_gh_manager__ (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/gh-manager.h --- a/libinterp/corefcn/gh-manager.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/gh-manager.h Tue Jan 24 17:19:44 2023 -0800 @@ -91,7 +91,7 @@ OCTINTERP_API void pop_figure (const graphics_handle& h); - graphics_handle current_figure (void) const + graphics_handle current_figure () const { graphics_handle retval; @@ -122,11 +122,11 @@ return retval; } - void lock (void) { m_graphics_lock.lock (); } + void lock () { m_graphics_lock.lock (); } - bool try_lock (void) { return m_graphics_lock.try_lock (); } + bool try_lock () { return m_graphics_lock.try_lock (); } - void unlock (void) { m_graphics_lock.unlock (); } + void unlock () { m_graphics_lock.unlock (); } Matrix figure_handle_list (bool show_hidden = false) { @@ -198,13 +198,13 @@ return retval; } - OCTINTERP_API void close_all_figures (void); + OCTINTERP_API void close_all_figures (); - OCTINTERP_API void restore_gcbo (void); + OCTINTERP_API void restore_gcbo (); OCTINTERP_API void post_event (const graphics_event& e); - octave::mutex graphics_lock (void) + octave::mutex graphics_lock () { return m_graphics_lock; } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/gl-render.cc --- a/libinterp/corefcn/gl-render.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/gl-render.cc Tue Jan 24 17:19:44 2023 -0800 @@ -114,7 +114,7 @@ m_tx (double(m_w)/m_tw), m_ty (double(m_h)/m_th), m_valid (true) { } - ~texture_rep (void) + ~texture_rep () { if (m_valid) m_glfcns.glDeleteTextures (1, &m_id); @@ -153,7 +153,7 @@ opengl_texture (const opengl_texture&) = default; - ~opengl_texture (void) = default; + ~opengl_texture () = default; opengl_texture& operator = (const opengl_texture&) = default; @@ -164,7 +164,7 @@ void tex_coord (double q, double r) const { m_rep->tex_coord (q, r); } - bool is_valid (void) const { return m_rep->m_valid; } + bool is_valid () const { return m_rep->m_valid; } private: @@ -346,12 +346,12 @@ #if defined (HAVE_FRAMEWORK_OPENGL) && defined (HAVE_GLUTESSCALLBACK_THREEDOTS) typedef GLvoid (CALLBACK *fcn) (...); #else - typedef void (CALLBACK *fcn) (void); + typedef void (CALLBACK *fcn) (); #endif public: - opengl_tessellator (void) : m_glu_tess (nullptr), m_fill () { init (); } + opengl_tessellator () : m_glu_tess (nullptr), m_fill () { init (); } // No copying! @@ -359,7 +359,7 @@ opengl_tessellator operator = (const opengl_tessellator&) = delete; - virtual ~opengl_tessellator (void) + virtual ~opengl_tessellator () { if (m_glu_tess) gluDeleteTess (m_glu_tess); } void begin_polygon (bool filled = true) @@ -370,13 +370,13 @@ gluTessBeginPolygon (m_glu_tess, this); } - void end_polygon (void) const + void end_polygon () const { gluTessEndPolygon (m_glu_tess); } - void begin_contour (void) const + void begin_contour () const { gluTessBeginContour (m_glu_tess); } - void end_contour (void) const + void end_contour () const { gluTessEndContour (m_glu_tess); } void add_vertex (double *loc, void *data) const @@ -385,7 +385,7 @@ protected: virtual void begin (GLenum /*type*/) { } - virtual void end (void) { } + virtual void end () { } virtual void vertex (void * /*data*/) { } @@ -397,7 +397,7 @@ virtual void error (GLenum err) { ::error ("OpenGL tessellation error (%d)", err); } - virtual void init (void) + virtual void init () { m_glu_tess = gluNewTess (); @@ -415,7 +415,7 @@ reinterpret_cast (tess_error)); } - bool is_filled (void) const { return m_fill; } + bool is_filled () const { return m_fill; } private: static void CALLBACK tess_begin (GLenum type, void *t) @@ -451,7 +451,7 @@ { public: - vertex_data_rep (void) + vertex_data_rep () : m_coords (), m_color (), m_vertex_normal (), m_face_normal (), m_alpha (), m_ambient (), m_diffuse (), m_specular (), m_specular_exp (), m_specular_color_refl () @@ -480,7 +480,7 @@ public: // Required to instantiate std::list objects. - vertex_data (void) : m_rep (nil_rep ()) { } + vertex_data () : m_rep (nil_rep ()) { } vertex_data (const Matrix& c, const Matrix& col, const Matrix& vn, const Matrix& fn, double a, float as, float ds, float ss, @@ -490,15 +490,15 @@ vertex_data (const vertex_data&) = default; - ~vertex_data (void) = default; + ~vertex_data () = default; vertex_data& operator = (const vertex_data&) = default; - vertex_data_rep * get_rep (void) const { return m_rep.get (); } + vertex_data_rep * get_rep () const { return m_rep.get (); } private: - static std::shared_ptr nil_rep (void) + static std::shared_ptr nil_rep () { static std::shared_ptr nr (new vertex_data_rep ()); @@ -538,7 +538,7 @@ glfcns.glBegin (type); } - void end (void) + void end () { opengl_functions& glfcns = m_renderer->get_opengl_functions (); @@ -1253,7 +1253,7 @@ } void -opengl_renderer::finish (void) +opengl_renderer::finish () { #if defined (HAVE_OPENGL) @@ -3881,7 +3881,7 @@ } void -opengl_renderer::set_ortho_coordinates (void) +opengl_renderer::set_ortho_coordinates () { #if defined (HAVE_OPENGL) @@ -3906,7 +3906,7 @@ } void -opengl_renderer::restore_previous_coordinates (void) +opengl_renderer::restore_previous_coordinates () { #if defined (HAVE_OPENGL) @@ -4192,7 +4192,7 @@ } Matrix -opengl_renderer::get_viewport_scaled (void) const +opengl_renderer::get_viewport_scaled () const { Matrix retval (1, 4, 0.0); @@ -4498,7 +4498,7 @@ } void -opengl_renderer::end_marker (void) +opengl_renderer::end_marker () { #if defined (HAVE_OPENGL) @@ -4574,7 +4574,7 @@ } void -opengl_renderer::init_maxlights (void) +opengl_renderer::init_maxlights () { #if defined (HAVE_OPENGL) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/gl-render.h --- a/libinterp/corefcn/gl-render.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/gl-render.h Tue Jan 24 17:19:44 2023 -0800 @@ -49,9 +49,9 @@ opengl_renderer& operator = (const opengl_renderer&) = delete; - virtual ~opengl_renderer (void) = default; + virtual ~opengl_renderer () = default; - opengl_functions& get_opengl_functions (void) const { return m_glfcns; } + opengl_functions& get_opengl_functions () const { return m_glfcns; } virtual void draw (const graphics_object& go, bool toplevel = true); @@ -62,8 +62,8 @@ virtual void set_viewport (int w, int h); virtual void set_device_pixel_ratio (double dpr) { m_devpixratio = dpr; } - virtual Matrix get_viewport_scaled (void) const; - virtual graphics_xform get_transform (void) const { return m_xform; } + virtual Matrix get_viewport_scaled () const; + virtual graphics_xform get_transform () const { return m_xform; } virtual uint8NDArray get_pixels (int width, int height); virtual void draw_zoom_box (int width, int height, @@ -73,7 +73,7 @@ const Matrix& bordercolor, double borderalpha, double borderwidth); - virtual void finish (void); + virtual void finish (); protected: @@ -118,7 +118,7 @@ virtual void init_marker (const std::string& m, double size, float width); virtual void change_marker (const std::string& m, double size); - virtual void end_marker (void); + virtual void end_marker (); virtual void draw_marker (double x, double y, double z, const Matrix& lc, const Matrix& fc, const double la = 1.0, const double fa = 1.0); @@ -180,7 +180,7 @@ class patch_tessellator; - void init_maxlights (void); + void init_maxlights (); std::string get_string (unsigned int id) const; @@ -208,9 +208,9 @@ void set_normal (int bfl_mode, const NDArray& n, int j, int i); - void set_ortho_coordinates (void); + void set_ortho_coordinates (); - void restore_previous_coordinates (void); + void restore_previous_coordinates (); double points_to_pixels (const double val) const; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/gl2ps-print.cc --- a/libinterp/corefcn/gl2ps-print.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/gl2ps-print.cc Tue Jan 24 17:19:44 2023 -0800 @@ -69,7 +69,7 @@ m_fontname (), m_buffer_overflow (false), m_svg_def_index (0) { } - ~gl2ps_renderer (void) = default; + ~gl2ps_renderer () = default; // FIXME: should we import the functions from the base class and // overload them here, or should we use a different name so we don't diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/graphics-toolkit.h --- a/libinterp/corefcn/graphics-toolkit.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/graphics-toolkit.h Tue Jan 24 17:19:44 2023 -0800 @@ -55,14 +55,14 @@ : m_name (nm) { } - virtual ~base_graphics_toolkit (void) = default; + virtual ~base_graphics_toolkit () = default; - std::string get_name (void) const + std::string get_name () const { return m_name; } - virtual bool is_valid (void) const + virtual bool is_valid () const { return false; } @@ -96,13 +96,13 @@ return Matrix (1, 2, 0.0); } - virtual double get_screen_resolution (void) const + virtual double get_screen_resolution () const { gripe_if_tkit_invalid ("get_screen_resolution"); return 72.0; } - virtual Matrix get_screen_size (void) const + virtual Matrix get_screen_size () const { gripe_if_tkit_invalid ("get_screen_size"); return Matrix (1, 2, 0.0); @@ -146,7 +146,7 @@ void finalize (const graphics_handle&); // Close the graphics toolkit. - virtual void close (void) + virtual void close () { gripe_if_tkit_invalid ("base_graphics_toolkit::close"); } @@ -183,14 +183,14 @@ graphics_toolkit& operator = (const graphics_toolkit& b) = default; - ~graphics_toolkit (void) = default; + ~graphics_toolkit () = default; - operator bool (void) const + operator bool () const { return m_rep->is_valid (); } - std::string get_name (void) const + std::string get_name () const { return m_rep->get_name (); } @@ -222,12 +222,12 @@ return m_rep->get_canvas_size (fh); } - double get_screen_resolution (void) const + double get_screen_resolution () const { return m_rep->get_screen_resolution (); } - Matrix get_screen_size (void) const + Matrix get_screen_size () const { return m_rep->get_screen_size (); } @@ -273,7 +273,7 @@ } // Close the graphics toolkit. - void close (void) + void close () { m_rep->close (); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/graphics.cc --- a/libinterp/corefcn/graphics.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/graphics.cc Tue Jan 24 17:19:44 2023 -0800 @@ -136,7 +136,7 @@ } static Matrix -viridis_colormap (void) +viridis_colormap () { // The values below have been produced by viridis (64)(:) // It would be nice to be able to feval the @@ -220,7 +220,7 @@ } static double -default_screendepth (void) +default_screendepth () { octave::display_info& dpy_info = octave::__get_display_info__ (); @@ -228,7 +228,7 @@ } static Matrix -default_screensize (void) +default_screensize () { Matrix retval (1, 4); @@ -243,7 +243,7 @@ } static double -default_screenpixelsperinch (void) +default_screenpixelsperinch () { octave::display_info& dpy_info = octave::__get_display_info__ (); @@ -251,7 +251,7 @@ } static Matrix -default_colororder (void) +default_colororder () { Matrix retval (7, 3, 0.0); @@ -305,7 +305,7 @@ } static Matrix -default_data (void) +default_data () { Matrix retval (1, 2); @@ -316,7 +316,7 @@ } static Matrix -default_data_lim (void) +default_data_lim () { Matrix retval (1, 4); @@ -329,7 +329,7 @@ } static Matrix -default_image_cdata (void) +default_image_cdata () { Matrix m (64, 64); @@ -345,7 +345,7 @@ } static Matrix -default_surface_xdata (void) +default_surface_xdata () { Matrix m (3, 3); @@ -357,7 +357,7 @@ } static Matrix -default_surface_ydata (void) +default_surface_ydata () { Matrix m (3, 3); @@ -369,7 +369,7 @@ } static Matrix -default_surface_zdata (void) +default_surface_zdata () { Matrix m (3, 3, 0.0); @@ -380,13 +380,13 @@ } static Matrix -default_surface_cdata (void) +default_surface_cdata () { return default_surface_zdata (); } static Matrix -default_patch_faces (void) +default_patch_faces () { Matrix m (1, 3); @@ -398,7 +398,7 @@ } static Matrix -default_patch_vertices (void) +default_patch_vertices () { Matrix m (3, 2, 0.0); @@ -410,7 +410,7 @@ } static Matrix -default_patch_xdata (void) +default_patch_xdata () { Matrix m (3, 1, 0.0); @@ -420,7 +420,7 @@ } static Matrix -default_patch_ydata (void) +default_patch_ydata () { Matrix m (3, 1, 1.0); @@ -430,7 +430,7 @@ } static Matrix -default_axes_position (void) +default_axes_position () { Matrix m (1, 4); @@ -443,7 +443,7 @@ } static Matrix -default_axes_outerposition (void) +default_axes_outerposition () { Matrix m (1, 4); @@ -456,7 +456,7 @@ } static Matrix -default_axes_view (void) +default_axes_view () { Matrix m (1, 2); @@ -467,7 +467,7 @@ } static Matrix -default_axes_tick (void) +default_axes_tick () { Matrix m (1, 6); @@ -482,7 +482,7 @@ } static Matrix -default_axes_ticklength (void) +default_axes_ticklength () { Matrix m (1, 2); @@ -493,7 +493,7 @@ } static Matrix -default_figure_position (void) +default_figure_position () { Matrix m (1, 4); @@ -506,7 +506,7 @@ } static Matrix -default_figure_papersize (void) +default_figure_papersize () { Matrix m (1, 2); @@ -517,7 +517,7 @@ } static Matrix -default_figure_paperposition (void) +default_figure_paperposition () { Matrix m (1, 4); @@ -531,7 +531,7 @@ } static std::string -default_graphics_toolkit (void) +default_graphics_toolkit () { octave::gtk_manager& gtk_mgr = octave::__get_gtk_manager__ (); @@ -539,7 +539,7 @@ } static Matrix -default_control_position (void) +default_control_position () { Matrix retval (1, 4); @@ -552,7 +552,7 @@ } static Matrix -default_control_sliderstep (void) +default_control_sliderstep () { Matrix retval (1, 2); @@ -563,7 +563,7 @@ } static Matrix -default_panel_position (void) +default_panel_position () { Matrix retval (1, 4); @@ -576,7 +576,7 @@ } static Matrix -default_light_position (void) +default_light_position () { Matrix m (1, 3); @@ -588,7 +588,7 @@ } static Matrix -default_table_position (void) +default_table_position () { Matrix retval (1, 4); @@ -601,7 +601,7 @@ } static Matrix -default_table_backgroundcolor (void) +default_table_backgroundcolor () { Matrix retval (2, 3); retval(0, 0) = 1; @@ -920,7 +920,7 @@ // This function always returns the screensize in pixels static Matrix -screen_size_pixels (void) +screen_size_pixels () { gh_manager& gh_mgr = octave::__get_gh_manager__ (); @@ -1328,7 +1328,7 @@ } std::string -radio_values::values_as_string (void) const +radio_values::values_as_string () const { std::string retval; @@ -1357,7 +1357,7 @@ } Cell -radio_values::values_as_cell (void) const +radio_values::values_as_cell () const { octave_idx_type i = 0; Cell retval (nelem (), 1); @@ -1723,7 +1723,7 @@ } void -array_property::get_data_limits (void) +array_property::get_data_limits () { m_min_val = m_min_pos = octave::numeric_limits::Inf (); m_max_val = m_max_neg = -octave::numeric_limits::Inf (); @@ -1935,15 +1935,15 @@ { public: - callback_props (void) : m_set () { } + callback_props () : m_set () { } callback_props (const callback_props&) = delete; callback_props& operator = (const callback_props&) = delete; - ~callback_props (void) = default; - - bool empty (void) const { return m_set.empty (); } + ~callback_props () = default; + + bool empty () const { return m_set.empty (); } void insert (const callback_property *ptr) { @@ -2232,7 +2232,7 @@ } void -figure::properties::update_handlevisibility (void) +figure::properties::update_handlevisibility () { if (! is_handle_visible ()) { @@ -2291,7 +2291,7 @@ } void -figure::properties::update___device_pixel_ratio__ (void) +figure::properties::update___device_pixel_ratio__ () { update_text_pos (get___myhandle__ ()); } @@ -2817,7 +2817,7 @@ // This function is NOT equivalent to the scripting language function gcf. graphics_handle -gcf (void) +gcf () { octave_value val = xget (0, "currentfigure"); @@ -2827,7 +2827,7 @@ // This function is NOT equivalent to the scripting language function gca. graphics_handle -gca (void) +gca () { octave_value val = xget (gcf (), "currentaxes"); @@ -3040,7 +3040,7 @@ } std::set -base_properties::dynamic_property_names (void) const +base_properties::dynamic_property_names () const { return m_dynamic_properties; } @@ -3133,7 +3133,7 @@ */ void -base_properties::mark_modified (void) +base_properties::mark_modified () { // Mark existing object as modified m___modified__ = "on"; @@ -3183,7 +3183,7 @@ } void -base_properties::update_contextmenu (void) const +base_properties::update_contextmenu () const { if (m_contextmenu.get ().isempty ()) return; @@ -3201,14 +3201,14 @@ } bool -base_properties::is_handle_visible (void) const +base_properties::is_handle_visible () const { return (m_handlevisibility.is ("on") || (! executing_callbacks.empty () && ! m_handlevisibility.is ("off"))); } octave::graphics_toolkit -base_properties::get_toolkit (void) const +base_properties::get_toolkit () const { gh_manager& gh_mgr = octave::__get_gh_manager__ (); @@ -3221,7 +3221,7 @@ } void -base_properties::update_boundingbox (void) +base_properties::update_boundingbox () { Matrix kids = get_children (); @@ -3248,7 +3248,7 @@ } void -base_properties::update_handlevisibility (void) +base_properties::update_handlevisibility () { if (is_handle_visible ()) return; @@ -3397,7 +3397,7 @@ } void -base_graphics_object::remove_all_listeners (void) +base_graphics_object::remove_all_listeners () { int state = toggle_warn ("Octave:deprecated-property", false); octave_map m = get (true).map_value (); @@ -3456,7 +3456,7 @@ } void -base_graphics_object::reset_default_properties (void) +base_graphics_object::reset_default_properties () { if (valid_object ()) { @@ -3471,7 +3471,7 @@ } std::string -base_graphics_object::values_as_string (void) +base_graphics_object::values_as_string () { if (! valid_object ()) error ("base_graphics_object::values_as_string: invalid graphics object"); @@ -3535,7 +3535,7 @@ } octave_scalar_map -base_graphics_object::values_as_struct (void) +base_graphics_object::values_as_struct () { octave_scalar_map retval; @@ -3691,7 +3691,7 @@ // FIXME: This should update monitorpositions and pointerlocation, but as these // properties aren't yet used, it doesn't matter that they aren't set either. void -root_figure::properties::update_units (void) +root_figure::properties::update_units () { std::string xunits = get_units (); @@ -3796,7 +3796,7 @@ } void -root_figure::reset_default_properties (void) +root_figure::reset_default_properties () { // empty list of local defaults m_default_properties = property_list (); @@ -3850,7 +3850,7 @@ } octave_value -figure::properties::get_number (void) const +figure::properties::get_number () const { if (m_integerhandle.is_on ()) return m___myhandle__.value (); @@ -3859,7 +3859,7 @@ } octave::graphics_toolkit -figure::properties::get_toolkit (void) const +figure::properties::get_toolkit () const { return m_toolkit; } @@ -4243,7 +4243,7 @@ } Matrix -figure::properties::get_auto_paperposition (void) +figure::properties::get_auto_paperposition () { Matrix pos = get_position ().matrix_value (); Matrix sz; @@ -4413,7 +4413,7 @@ } void -figure::properties::update_papertype (void) +figure::properties::update_papertype () { std::string typ = get_papertype (); if (typ != "") @@ -4431,7 +4431,7 @@ } void -figure::properties::update_papersize (void) +figure::properties::update_papersize () { Matrix sz = get_papersize ().matrix_value (); if (sz(0) > sz(1)) @@ -4599,7 +4599,7 @@ */ void -figure::properties::update_paperorientation (void) +figure::properties::update_paperorientation () { std::string porient = get_paperorientation (); Matrix sz = get_papersize ().matrix_value (); @@ -4682,7 +4682,7 @@ */ std::string -figure::properties::get_title (void) const +figure::properties::get_title () const { std::string title; if (! get_number ().isempty () && is_numbertitle ()) @@ -4727,7 +4727,7 @@ } void -figure::reset_default_properties (void) +figure::reset_default_properties () { // empty list of local defaults m_default_properties = property_list (); @@ -4747,7 +4747,7 @@ // --------------------------------------------------------------------- void -axes::properties::init (void) +axes::properties::init () { m_position.add_constraint (dim_vector (1, 4)); m_outerposition.add_constraint (dim_vector (1, 4)); @@ -4945,7 +4945,7 @@ } void -axes::properties::sync_positions (void) +axes::properties::sync_positions () { // First part is equivalent to 'update_tightinset ()' if (m_positionconstraint.is ("innerposition")) @@ -5337,7 +5337,7 @@ } octave_value -axes::properties::get_colormap (void) const +axes::properties::get_colormap () const { if (m___colormap__.get ().isempty ()) { @@ -5454,7 +5454,7 @@ } inline Matrix -xform_matrix (void) +xform_matrix () { Matrix m (4, 4, 0.0); @@ -5465,7 +5465,7 @@ } inline ColumnVector -xform_vector (void) +xform_vector () { ColumnVector v (4, 0.0); @@ -5584,7 +5584,7 @@ } inline Matrix -unit_cube (void) +unit_cube () { static double data[32] = { @@ -5621,7 +5621,7 @@ } void -axes::properties::update_camera (void) +axes::properties::update_camera () { double xd = (xdir_is ("normal") ? 1 : -1); double yd = (ydir_is ("normal") ? 1 : -1); @@ -5837,7 +5837,7 @@ static bool updating_axes_layout = false; void -axes::properties::update_axes_layout (void) +axes::properties::update_axes_layout () { if (updating_axes_layout) return; @@ -6000,7 +6000,7 @@ } void -axes::properties::update_ticklength (void) +axes::properties::update_ticklength () { bool mode2D = (((m_xstate > AXE_DEPTH_DIR ? 1 : 0) + (m_ystate > AXE_DEPTH_DIR ? 1 : 0) + @@ -6087,7 +6087,7 @@ static bool updating_xlabel_position = false; void -axes::properties::update_xlabel_position (void) +axes::properties::update_xlabel_position () { if (updating_xlabel_position) return; @@ -6191,7 +6191,7 @@ static bool updating_ylabel_position = false; void -axes::properties::update_ylabel_position (void) +axes::properties::update_ylabel_position () { if (updating_ylabel_position) return; @@ -6295,7 +6295,7 @@ static bool updating_zlabel_position = false; void -axes::properties::update_zlabel_position (void) +axes::properties::update_zlabel_position () { if (updating_zlabel_position) return; @@ -6421,7 +6421,7 @@ static bool updating_title_position = false; void -axes::properties::update_title_position (void) +axes::properties::update_title_position () { if (updating_title_position) return; @@ -6522,7 +6522,7 @@ static std::set updating_aspectratios; void -axes::properties::update_aspectratios (void) +axes::properties::update_aspectratios () { if (updating_aspectratios.find (get___myhandle__ ().value ()) != updating_aspectratios.end ()) @@ -7031,7 +7031,7 @@ } Matrix -graphics_xform::xform_eye (void) +graphics_xform::xform_eye () { return octave::xform_matrix (); } @@ -7162,7 +7162,7 @@ } void -axes::properties::update_outerposition (void) +axes::properties::update_outerposition () { set_positionconstraint ("outerposition"); caseless_str old_units = get_units (); @@ -7221,7 +7221,7 @@ } void -axes::properties::update_position (void) +axes::properties::update_position () { set_positionconstraint ("innerposition"); caseless_str old_units = get_units (); @@ -7269,7 +7269,7 @@ } void -axes::properties::update_looseinset (void) +axes::properties::update_looseinset () { caseless_str old_units = get_units (); set_units ("normalized"); @@ -8715,7 +8715,7 @@ } void -axes::properties::push_zoom_stack (void) +axes::properties::push_zoom_stack () { if (m_zoom_stack.empty ()) { @@ -8941,7 +8941,7 @@ } void -axes::properties::unzoom (void) +axes::properties::unzoom () { if (m_zoom_stack.size () >= 7) { @@ -8977,7 +8977,7 @@ } void -axes::properties::update_handlevisibility (void) +axes::properties::update_handlevisibility () { if (! is_handle_visible ()) { @@ -9006,7 +9006,7 @@ } void -figure::properties::init_toolkit (void) +figure::properties::init_toolkit () { octave::gtk_manager& gtk_mgr = octave::__get_gtk_manager__ (); @@ -9026,7 +9026,7 @@ } void -axes::properties::trigger_normals_calc (void) +axes::properties::trigger_normals_calc () { // Find all patch (and surface) objects within axes std::list children_list; @@ -9055,7 +9055,7 @@ } void -axes::reset_default_properties (void) +axes::reset_default_properties () { // empty list of local defaults m_default_properties = property_list (); @@ -9086,7 +9086,7 @@ // --------------------------------------------------------------------- Matrix -line::properties::compute_xlim (void) const +line::properties::compute_xlim () const { Matrix m (1, 4); @@ -9099,7 +9099,7 @@ } Matrix -line::properties::compute_ylim (void) const +line::properties::compute_ylim () const { Matrix m (1, 4); @@ -9114,7 +9114,7 @@ // --------------------------------------------------------------------- Matrix -text::properties::get_data_position (void) const +text::properties::get_data_position () const { Matrix pos = get_position ().matrix_value (); @@ -9169,7 +9169,7 @@ } octave_value -text::properties::get_extent (void) const +text::properties::get_extent () const { // FIXME: This doesn't work right for 3D plots. // (It doesn't in Matlab either, at least not in version 6.5.) @@ -9226,7 +9226,7 @@ } void -text::properties::update_font (void) +text::properties::update_font () { double dpr = device_pixel_ratio (get___myhandle__ ()); @@ -9248,7 +9248,7 @@ } void -text::properties::update_text_extent (void) +text::properties::update_text_extent () { int halign = 0; int valign = 0; @@ -9293,7 +9293,7 @@ } void -text::properties::request_autopos (void) +text::properties::request_autopos () { if (__autopos_tag___is ("xlabel") || __autopos_tag___is ("ylabel") || __autopos_tag___is ("zlabel") || __autopos_tag___is ("title")) @@ -9301,7 +9301,7 @@ } void -text::properties::update_units (void) +text::properties::update_units () { if (! units_is ("data")) { @@ -9358,7 +9358,7 @@ // --------------------------------------------------------------------- octave_value -image::properties::get_color_data (void) const +image::properties::get_color_data () const { return convert_cdata (*this, get_cdata (), cdatamapping_is ("scaled"), 3); } @@ -9377,7 +9377,7 @@ } void -light::properties::update_visible (void) +light::properties::update_visible () { gh_manager& gh_mgr = octave::__get_gh_manager__ (); @@ -9394,7 +9394,7 @@ // --------------------------------------------------------------------- bool -patch::properties::get_do_lighting (void) const +patch::properties::get_do_lighting () const { gh_manager& gh_mgr = octave::__get_gh_manager__ (); @@ -9407,7 +9407,7 @@ } octave_value -patch::properties::get_color_data (void) const +patch::properties::get_color_data () const { octave_value fvc = get_facevertexcdata (); if (fvc.is_undefined () || fvc.isempty ()) @@ -9419,7 +9419,7 @@ static bool updating_patch_data = false; void -patch::properties::update_fvc (void) +patch::properties::update_fvc () { if (updating_patch_data) return; @@ -9598,7 +9598,7 @@ } void -patch::properties::update_data (void) +patch::properties::update_data () { if (updating_patch_data) return; @@ -9979,7 +9979,7 @@ void -patch::reset_default_properties (void) +patch::reset_default_properties () { // empty list of local defaults m_default_properties = property_list (); @@ -9994,7 +9994,7 @@ // --------------------------------------------------------------------- octave_value -scatter::properties::get_color_data (void) const +scatter::properties::get_color_data () const { octave_value c = get_cdata (); if (c.is_undefined () || c.isempty ()) @@ -10004,7 +10004,7 @@ } void -scatter::properties::update_data (void) +scatter::properties::update_data () { Matrix xd = get_xdata ().matrix_value (); Matrix yd = get_ydata ().matrix_value (); @@ -10044,7 +10044,7 @@ static bool updating_scatter_cdata = false; void -scatter::properties::update_color (void) +scatter::properties::update_color () { if (updating_scatter_cdata) return; @@ -10107,13 +10107,13 @@ // --------------------------------------------------------------------- octave_value -surface::properties::get_color_data (void) const +surface::properties::get_color_data () const { return convert_cdata (*this, get_cdata (), cdatamapping_is ("scaled"), 3); } bool -surface::properties::get_do_lighting (void) const +surface::properties::get_do_lighting () const { gh_manager& gh_mgr = octave::__get_gh_manager__ (); @@ -10439,7 +10439,7 @@ } void -hggroup::properties::update_limits (void) const +hggroup::properties::update_limits () const { gh_manager& gh_mgr = octave::__get_gh_manager__ (); @@ -10673,7 +10673,7 @@ // --------------------------------------------------------------------- void -uicontextmenu::properties::update_beingdeleted (void) +uicontextmenu::properties::update_beingdeleted () { // Clear the uicontextmenu property of dependent objects if (m_beingdeleted.is ("on")) @@ -10723,7 +10723,7 @@ // --------------------------------------------------------------------- octave_value -uicontrol::properties::get_extent (void) const +uicontrol::properties::get_extent () const { Matrix m = m_extent.get ().matrix_value (); @@ -10738,7 +10738,7 @@ } void -uicontrol::properties::update_text_extent (void) +uicontrol::properties::update_text_extent () { // FIXME: support multiline text @@ -10750,7 +10750,7 @@ } void -uicontrol::properties::update_units (void) +uicontrol::properties::update_units () { Matrix pos = get_position ().matrix_value (); @@ -11488,14 +11488,14 @@ } Matrix -uitable::properties::get_backgroundcolor_rgb (void) +uitable::properties::get_backgroundcolor_rgb () { Matrix bg = m_backgroundcolor.get ().matrix_value (); return bg.row (0); } Matrix -uitable::properties::get_alternatebackgroundcolor_rgb (void) +uitable::properties::get_alternatebackgroundcolor_rgb () { int i = 0; Matrix bg = m_backgroundcolor.get ().matrix_value (); @@ -11506,13 +11506,13 @@ } Matrix -uitable::properties::get_extent_matrix (void) const +uitable::properties::get_extent_matrix () const { return m_extent.get ().matrix_value (); } octave_value -uitable::properties::get_extent (void) const +uitable::properties::get_extent () const { // FIXME: Is it really acceptable to just let the toolkit update the extent? Matrix m = m_extent.get ().matrix_value (); @@ -11554,7 +11554,7 @@ } void -uitoolbar::reset_default_properties (void) +uitoolbar::reset_default_properties () { // empty list of local defaults m_default_properties = property_list (); @@ -11603,7 +11603,7 @@ : base_graphics_event (busyaction), m_handle (h), m_callback_name (), m_callback (cb), m_callback_data (data) { } - void execute (void) + void execute () { gh_manager& gh_mgr = octave::__get_gh_manager__ (); @@ -11614,7 +11614,7 @@ } private: - callback_event (void) + callback_event () : base_graphics_event (), m_handle (), m_callback_name (), m_callback_data () { } @@ -11635,7 +11635,7 @@ : base_graphics_event (busyaction), m_handle (h), m_mcode (cmd) { } - void execute (void) + void execute () { if (! m_mcode.empty ()) { @@ -11652,7 +11652,7 @@ } private: - mcode_event (void) + mcode_event () : base_graphics_event (), m_handle (), m_mcode () { } @@ -11668,7 +11668,7 @@ // function_event objects must be created with at least a function. - function_event (void) = delete; + function_event () = delete; function_event (graphics_event::event_fcn fcn, void *data = nullptr) : base_graphics_event (), m_function (fcn), m_function_data (data) @@ -11680,7 +11680,7 @@ function_event& operator = (const function_event&) = delete; - void execute (void) + void execute () { m_function (m_function_data); } @@ -11704,7 +11704,7 @@ m_redraw_figure (redraw_figure) { } - void execute (void) + void execute () { gh_manager& gh_mgr = octave::__get_gh_manager__ (); @@ -11756,7 +11756,7 @@ } private: - set_event (void) + set_event () : base_graphics_event (), m_handle (), m_property_name (), m_property_value () { } @@ -11812,7 +11812,7 @@ } property_list::plist_map_type -root_figure::init_factory_properties (void) +root_figure::init_factory_properties () { property_list::plist_map_type plist_map; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/graphics.in.h --- a/libinterp/corefcn/graphics.in.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/graphics.in.h Tue Jan 24 17:19:44 2023 -0800 @@ -66,9 +66,9 @@ class OCTINTERP_API base_scaler { public: - base_scaler (void) { } - - virtual ~base_scaler (void) = default; + base_scaler () { } + + virtual ~base_scaler () = default; virtual Matrix scale (const Matrix&) const { @@ -93,14 +93,14 @@ virtual base_scaler * clone () const { return new base_scaler (); } - virtual bool is_linear (void) const + virtual bool is_linear () const { return false; } }; class lin_scaler : public base_scaler { public: - lin_scaler (void) { } + lin_scaler () { } Matrix scale (const Matrix& m) const { return m; } @@ -110,15 +110,15 @@ double unscale (double d) const { return d; } - base_scaler * clone (void) const { return new lin_scaler (); } - - bool is_linear (void) const { return true; } + base_scaler * clone () const { return new lin_scaler (); } + + bool is_linear () const { return true; } }; class log_scaler : public base_scaler { public: - log_scaler (void) { } + log_scaler () { } Matrix scale (const Matrix& m) const { @@ -144,7 +144,7 @@ double unscale (double d) const { return std::pow (10.0, d); } - base_scaler * clone (void) const + base_scaler * clone () const { return new log_scaler (); } private: @@ -158,7 +158,7 @@ class OCTINTERP_API neg_log_scaler : public base_scaler { public: - neg_log_scaler (void) { } + neg_log_scaler () { } Matrix scale (const Matrix& m) const { @@ -184,7 +184,7 @@ double unscale (double d) const { return -std::pow (10.0, -d); } - base_scaler * clone (void) const + base_scaler * clone () const { return new neg_log_scaler (); } private: @@ -198,7 +198,7 @@ class OCTINTERP_API scaler { public: - scaler (void) : m_rep (new base_scaler ()) { } + scaler () : m_rep (new base_scaler ()) { } scaler (const scaler& s) : m_rep (s.m_rep->clone ()) { } @@ -212,7 +212,7 @@ : new base_scaler ()))) { } - ~scaler (void) { delete m_rep; } + ~scaler () { delete m_rep; } Matrix scale (const Matrix& m) const { return m_rep->scale (m); } @@ -226,7 +226,7 @@ double unscale (double d) const { return m_rep->unscale (d); } - bool is_linear (void) const + bool is_linear () const { return m_rep->is_linear (); } scaler& operator = (const scaler& s) @@ -286,7 +286,7 @@ friend class property; public: - base_property (void) + base_property () : m_id (-1), m_count (1), m_name (), m_parent (), m_hidden (), m_listeners () { } @@ -301,25 +301,25 @@ m_hidden (p.m_hidden), m_listeners () { } - virtual ~base_property (void) = default; - - bool ok (void) const { return m_parent.ok (); } - - std::string get_name (void) const { return m_name; } + virtual ~base_property () = default; + + bool ok () const { return m_parent.ok (); } + + std::string get_name () const { return m_name; } void set_name (const std::string& s) { m_name = s; } - graphics_handle get_parent (void) const { return m_parent; } + graphics_handle get_parent () const { return m_parent; } void set_parent (const graphics_handle& h) { m_parent = h; } - bool is_hidden (void) const { return m_hidden; } + bool is_hidden () const { return m_hidden; } void set_hidden (bool flag) { m_hidden = flag; } - virtual bool is_radio (void) const { return false; } - - int get_id (void) const { return m_id; } + virtual bool is_radio () const { return false; } + + int get_id () const { return m_id; } void set_id (int d) { m_id = d; } @@ -328,17 +328,17 @@ OCTINTERP_API bool set (const octave_value& v, bool do_run = true, bool do_notify_toolkit = true); - virtual octave_value get (void) const + virtual octave_value get () const { error (R"(get: invalid property "%s")", m_name.c_str ()); } - virtual std::string values_as_string (void) const + virtual std::string values_as_string () const { error (R"(values_as_string: invalid property "%s")", m_name.c_str ()); } - virtual Cell values_as_cell (void) const + virtual Cell values_as_cell () const { error (R"(values_as_cell: invalid property "%s")", m_name.c_str ()); } @@ -408,7 +408,7 @@ OCTINTERP_API void run_listeners (listener_mode mode = GCB_POSTSET); - virtual base_property * clone (void) const + virtual base_property * clone () const { return new base_property (*this); } protected: @@ -445,10 +445,10 @@ string_property (const string_property& p) : base_property (p), m_str (p.m_str) { } - octave_value get (void) const + octave_value get () const { return octave_value (m_str); } - std::string string_value (void) const { return m_str; } + std::string string_value () const { return m_str; } string_property& operator = (const octave_value& val) { @@ -456,7 +456,7 @@ return *this; } - base_property * clone (void) const { return new string_property (*this); } + base_property * clone () const { return new string_property (*this); } protected: bool do_set (const octave_value& val) @@ -530,7 +530,7 @@ : base_property (p), m_desired_type (p.m_desired_type), m_separator (p.m_separator), m_str (p.m_str) { } - octave_value get (void) const + octave_value get () const { if (m_desired_type == string_t) return octave_value (string_value ()); @@ -538,7 +538,7 @@ return octave_value (cell_value ()); } - std::string string_value (void) const + std::string string_value () const { std::string s; @@ -552,9 +552,9 @@ return s; } - Cell cell_value (void) const {return Cell (m_str);} - - string_vector string_vector_value (void) const { return m_str; } + Cell cell_value () const {return Cell (m_str);} + + string_vector string_vector_value () const { return m_str; } string_array_property& operator = (const octave_value& val) { @@ -562,7 +562,7 @@ return *this; } - base_property * clone (void) const + base_property * clone () const { return new string_array_property (*this); } protected: @@ -736,13 +736,13 @@ : base_property (p), m_value (p.m_value), m_stored_type (p.m_stored_type) { } - bool empty (void) const + bool empty () const { octave_value tmp = get (); return tmp.isempty (); } - octave_value get (void) const + octave_value get () const { if (m_stored_type == char_t) return octave_value (char_value ()); @@ -750,16 +750,16 @@ return octave_value (cell_value ()); } - std::string string_value (void) const + std::string string_value () const { return m_value.empty () ? "" : m_value[0]; } - string_vector string_vector_value (void) const { return m_value; } - - charMatrix char_value (void) const { return charMatrix (m_value, ' '); } - - Cell cell_value (void) const {return Cell (m_value); } + string_vector string_vector_value () const { return m_value; } + + charMatrix char_value () const { return charMatrix (m_value, ' '); } + + Cell cell_value () const {return Cell (m_value); } text_label_property& operator = (const octave_value& val) { @@ -767,7 +767,7 @@ return *this; } - base_property * clone (void) const { return new text_label_property (*this); } + base_property * clone () const { return new text_label_property (*this); } protected: @@ -862,7 +862,7 @@ return *this; } - std::string default_value (void) const { return m_default_val; } + std::string default_value () const { return m_default_val; } bool validate (const std::string& val, std::string& match) { @@ -913,11 +913,11 @@ return false; } - OCTINTERP_API std::string values_as_string (void) const; - - OCTINTERP_API Cell values_as_cell (void) const; - - octave_idx_type nelem (void) const { return m_possible_vals.size (); } + OCTINTERP_API std::string values_as_string () const; + + OCTINTERP_API Cell values_as_cell () const; + + octave_idx_type nelem () const { return m_possible_vals.size (); } private: // Might also want to cache @@ -946,19 +946,19 @@ radio_property (const radio_property& p) : base_property (p), m_vals (p.m_vals), m_current_val (p.m_current_val) { } - octave_value get (void) const { return octave_value (m_current_val); } - - const std::string& current_value (void) const { return m_current_val; } - - std::string values_as_string (void) const + octave_value get () const { return octave_value (m_current_val); } + + const std::string& current_value () const { return m_current_val; } + + std::string values_as_string () const { return m_vals.values_as_string (); } - Cell values_as_cell (void) const { return m_vals.values_as_cell (); } + Cell values_as_cell () const { return m_vals.values_as_cell (); } bool is (const caseless_str& v) const { return v.compare (m_current_val); } - bool is_radio (void) const { return true; } + bool is_radio () const { return true; } radio_property& operator = (const octave_value& val) { @@ -966,7 +966,7 @@ return *this; } - base_property * clone (void) const { return new radio_property (*this); } + base_property * clone () const { return new radio_property (*this); } protected: bool do_set (const octave_value& newval) @@ -1045,11 +1045,11 @@ bool operator != (const color_values& c) const { return ! (*this == c); } - Matrix rgb (void) const { return m_rgb; } - - operator octave_value (void) const { return m_rgb; } - - void validate (void) const + Matrix rgb () const { return m_rgb; } + + operator octave_value () const { return m_rgb; } + + void validate () const { for (int i = 0; i < 3; i++) { @@ -1113,7 +1113,7 @@ m_color_val (p.m_color_val), m_radio_val (p.m_radio_val), m_current_val (p.m_current_val) { } - octave_value get (void) const + octave_value get () const { if (m_current_type == color_t) return m_color_val.rgb (); @@ -1121,14 +1121,14 @@ return m_current_val; } - bool is_rgb (void) const { return (m_current_type == color_t); } - - bool is_radio (void) const { return (m_current_type == radio_t); } + bool is_rgb () const { return (m_current_type == color_t); } + + bool is_radio () const { return (m_current_type == radio_t); } bool is (const std::string& v) const { return (is_radio () && m_current_val == v); } - Matrix rgb (void) const + Matrix rgb () const { if (m_current_type != color_t) error ("color has no RGB value"); @@ -1136,7 +1136,7 @@ return m_color_val.rgb (); } - const std::string& current_value (void) const + const std::string& current_value () const { if (m_current_type != radio_t) error ("color has no radio value"); @@ -1150,14 +1150,14 @@ return *this; } - operator octave_value (void) const { return get (); } - - base_property * clone (void) const { return new color_property (*this); } - - std::string values_as_string (void) const + operator octave_value () const { return get (); } + + base_property * clone () const { return new color_property (*this); } + + std::string values_as_string () const { return m_radio_val.values_as_string (); } - Cell values_as_cell (void) const { return m_radio_val.values_as_cell (); } + Cell values_as_cell () const { return m_radio_val.values_as_cell (); } protected: OCTINTERP_API bool do_set (const octave_value& newval); @@ -1195,9 +1195,9 @@ m_minval (std::pair (octave_NaN, true)), m_maxval (std::pair (octave_NaN, true)) { } - octave_value get (void) const { return octave_value (m_current_val); } - - double double_value (void) const { return m_current_val; } + octave_value get () const { return octave_value (m_current_val); } + + double double_value () const { return m_current_val; } double_property& operator = (const octave_value& val) { @@ -1205,7 +1205,7 @@ return *this; } - base_property * clone (void) const + base_property * clone () const { double_property *p = new double_property (*this); @@ -1319,7 +1319,7 @@ m_dval (p.m_dval), m_radio_val (p.m_radio_val), m_current_val (p.m_current_val) { } - octave_value get (void) const + octave_value get () const { if (m_current_type == double_t) return m_dval; @@ -1327,14 +1327,14 @@ return m_current_val; } - bool is_double (void) const { return (m_current_type == double_t); } - - bool is_radio (void) const { return (m_current_type == radio_t); } + bool is_double () const { return (m_current_type == double_t); } + + bool is_radio () const { return (m_current_type == radio_t); } bool is (const std::string& v) const { return (is_radio () && m_current_val == v); } - double double_value (void) const + double double_value () const { if (m_current_type != double_t) error ("%s: property has no double", get_name ().c_str ()); @@ -1342,7 +1342,7 @@ return m_dval; } - const std::string& current_value (void) const + const std::string& current_value () const { if (m_current_type != radio_t) error ("%s: property has no radio value", get_name ().c_str ()); @@ -1356,9 +1356,9 @@ return *this; } - operator octave_value (void) const { return get (); } - - base_property * clone (void) const + operator octave_value () const { return get (); } + + base_property * clone () const { return new double_radio_property (*this); } protected: @@ -1376,7 +1376,7 @@ class OCTINTERP_API array_property : public base_property { public: - array_property (void) + array_property () : base_property ("", graphics_handle ()), m_data (Matrix ()), m_min_val (), m_max_val (), m_min_pos (), m_max_neg (), m_type_constraints (), m_size_constraints (), @@ -1412,7 +1412,7 @@ m_maxval (std::pair (octave_NaN, true)) { } - octave_value get (void) const { return m_data; } + octave_value get () const { return m_data; } void add_constraint (const std::string& type) { m_type_constraints.insert (type); } @@ -1431,12 +1431,12 @@ m_maxval = std::pair (val, inclusive); } - double min_val (void) const { return m_min_val; } - double max_val (void) const { return m_max_val; } - double min_pos (void) const { return m_min_pos; } - double max_neg (void) const { return m_max_neg; } - - Matrix get_limits (void) const + double min_val () const { return m_min_val; } + double max_val () const { return m_max_val; } + double min_pos () const { return m_min_pos; } + double max_neg () const { return m_max_neg; } + + Matrix get_limits () const { Matrix m (1, 4); @@ -1454,7 +1454,7 @@ return *this; } - base_property * clone (void) const + base_property * clone () const { array_property *p = new array_property (*this); @@ -1494,7 +1494,7 @@ OCTINTERP_API bool is_equal (const octave_value& v) const; - OCTINTERP_API void get_data_limits (void); + OCTINTERP_API void get_data_limits (); protected: octave_value m_data; @@ -1564,7 +1564,7 @@ return *this; } - base_property * clone (void) const + base_property * clone () const { row_vector_property *p = new row_vector_property (*this); @@ -1619,7 +1619,7 @@ bool_property (const bool_property& p) : radio_property (p) { } - bool is_on (void) const { return is ("on"); } + bool is_on () const { return is ("on"); } bool_property& operator = (const octave_value& val) { @@ -1627,7 +1627,7 @@ return *this; } - base_property * clone (void) const { return new bool_property (*this); } + base_property * clone () const { return new bool_property (*this); } protected: bool do_set (const octave_value& val) @@ -1652,9 +1652,9 @@ handle_property (const handle_property& p) : base_property (p), m_current_val (p.m_current_val) { } - octave_value get (void) const { return m_current_val.as_octave_value (); } - - graphics_handle handle_value (void) const { return m_current_val; } + octave_value get () const { return m_current_val.as_octave_value (); } + + graphics_handle handle_value () const { return m_current_val; } handle_property& operator = (const octave_value& val) { @@ -1668,10 +1668,10 @@ return *this; } - void invalidate (void) + void invalidate () { m_current_val = octave::numeric_limits::NaN (); } - base_property * clone (void) const { return new handle_property (*this); } + base_property * clone () const { return new handle_property (*this); } void add_constraint (const std::string& type) { m_type_constraints.insert (type); } @@ -1696,7 +1696,7 @@ any_property (const any_property& p) : base_property (p), m_data (p.m_data) { } - octave_value get (void) const { return m_data; } + octave_value get () const { return m_data; } any_property& operator = (const octave_value& val) { @@ -1704,7 +1704,7 @@ return *this; } - base_property * clone (void) const { return new any_property (*this); } + base_property * clone () const { return new any_property (*this); } protected: bool do_set (const octave_value& v) @@ -1722,7 +1722,7 @@ class OCTINTERP_API children_property : public base_property { public: - children_property (void) + children_property () : base_property ("", graphics_handle ()), m_children_list () { do_init_children (Matrix ()); @@ -1747,7 +1747,7 @@ return *this; } - base_property * clone (void) const { return new children_property (*this); } + base_property * clone () const { return new children_property (*this); } bool remove_child (double val) { @@ -1759,22 +1759,22 @@ do_adopt_child (val); } - Matrix get_children (void) const + Matrix get_children () const { return do_get_children (false); } - Matrix get_hidden (void) const + Matrix get_hidden () const { return do_get_children (true); } - Matrix get_all (void) const + Matrix get_all () const { return do_get_all_children (); } - octave_value get (void) const + octave_value get () const { return octave_value (get_children ()); } @@ -1877,7 +1877,7 @@ OCTINTERP_API Matrix do_get_children (bool return_hidden) const; - Matrix do_get_all_children (void) const + Matrix do_get_all_children () const { Matrix retval (m_children_list.size (), 1); octave_idx_type i = 0; @@ -1921,11 +1921,11 @@ callback_property (const callback_property& p) : base_property (p), m_callback (p.m_callback) { } - octave_value get (void) const { return m_callback; } + octave_value get () const { return m_callback; } OCTINTERP_API void execute (const octave_value& data = octave_value ()) const; - bool is_defined (void) const + bool is_defined () const { return (m_callback.is_defined () && ! m_callback.isempty ()); } @@ -1936,7 +1936,7 @@ return *this; } - base_property * clone (void) const { return new callback_property (*this); } + base_property * clone () const { return new callback_property (*this); } protected: bool do_set (const octave_value& v) @@ -1962,7 +1962,7 @@ class OCTINTERP_API property { public: - property (void) : m_rep (new base_property ("", graphics_handle ())) + property () : m_rep (new base_property ("", graphics_handle ())) { } property (base_property *bp, bool persist = false) : m_rep (bp) @@ -1973,53 +1973,53 @@ m_rep->m_count++; } - ~property (void) + ~property () { if (--m_rep->m_count == 0) delete m_rep; } - bool ok (void) const + bool ok () const { return m_rep->ok (); } - std::string get_name (void) const + std::string get_name () const { return m_rep->get_name (); } void set_name (const std::string& name) { m_rep->set_name (name); } - graphics_handle get_parent (void) const + graphics_handle get_parent () const { return m_rep->get_parent (); } void set_parent (const graphics_handle& h) { m_rep->set_parent (h); } - bool is_hidden (void) const + bool is_hidden () const { return m_rep->is_hidden (); } void set_hidden (bool flag) { m_rep->set_hidden (flag); } - bool is_radio (void) const + bool is_radio () const { return m_rep->is_radio (); } - int get_id (void) const + int get_id () const { return m_rep->get_id (); } void set_id (int d) { m_rep->set_id (d); } - octave_value get (void) const + octave_value get () const { return m_rep->get (); } bool set (const octave_value& val, bool do_run = true, bool do_notify_toolkit = true) { return m_rep->set (val, do_run, do_notify_toolkit); } - std::string values_as_string (void) const + std::string values_as_string () const { return m_rep->values_as_string (); } - Cell values_as_cell (void) const + Cell values_as_cell () const { return m_rep->values_as_cell (); } property& operator = (const octave_value& val) @@ -2053,26 +2053,26 @@ create (const std::string& name, const graphics_handle& parent, const caseless_str& type, const octave_value_list& args); - property clone (void) const + property clone () const { return property (m_rep->clone ()); } #if 0 - const string_property& as_string_property (void) const + const string_property& as_string_property () const { return *(dynamic_cast (m_rep)); } - const radio_property& as_radio_property (void) const + const radio_property& as_radio_property () const { return *(dynamic_cast (m_rep)); } - const color_property& as_color_property (void) const + const color_property& as_color_property () const { return *(dynamic_cast (m_rep)); } - const double_property& as_double_property (void) const + const double_property& as_double_property () const { return *(dynamic_cast (m_rep)); } - const bool_property& as_bool_property (void) const + const bool_property& as_bool_property () const { return *(dynamic_cast (m_rep)); } - const handle_property& as_handle_property (void) const + const handle_property& as_handle_property () const { return *(dynamic_cast (m_rep)); } #endif @@ -2163,17 +2163,17 @@ property_list (const plist_map_type& m = plist_map_type ()) : m_plist_map (m) { } - ~property_list (void) = default; + ~property_list () = default; OCTINTERP_API void set (const caseless_str& name, const octave_value& val); OCTINTERP_API octave_value lookup (const caseless_str& name) const; - plist_map_iterator begin (void) { return m_plist_map.begin (); } - plist_map_const_iterator begin (void) const { return m_plist_map.begin (); } - - plist_map_iterator end (void) { return m_plist_map.end (); } - plist_map_const_iterator end (void) const { return m_plist_map.end (); } + plist_map_iterator begin () { return m_plist_map.begin (); } + plist_map_const_iterator begin () const { return m_plist_map.begin (); } + + plist_map_iterator end () { return m_plist_map.end (); } + plist_map_const_iterator end () const { return m_plist_map.end (); } plist_map_iterator find (const std::string& go_name) { @@ -2204,11 +2204,11 @@ const graphics_handle& mh = graphics_handle (), const graphics_handle& p = graphics_handle ()); - virtual ~base_properties (void) = default; - - virtual std::string graphics_object_name (void) const { return "unknown"; } - - OCTINTERP_API void mark_modified (void); + virtual ~base_properties () = default; + + virtual std::string graphics_object_name () const { return "unknown"; } + + OCTINTERP_API void mark_modified (); OCTINTERP_API void override_defaults (base_graphics_object& obj); @@ -2257,7 +2257,7 @@ return false; } - bool is_modified (void) const { return is___modified__ (); } + bool is_modified () const { return is___modified__ (); } virtual void remove_child (const graphics_handle& h, bool = false) { @@ -2275,14 +2275,14 @@ mark_modified (); } - virtual octave::graphics_toolkit get_toolkit (void) const; + virtual octave::graphics_toolkit get_toolkit () const; virtual Matrix get_boundingbox (bool /* finternal */ = false, const Matrix& /* parent_pix_size */ = Matrix ()) const { return Matrix (1, 4, 0.0); } - virtual void update_boundingbox (void); + virtual void update_boundingbox (); virtual void update_autopos (const std::string& elem_type); @@ -2302,17 +2302,17 @@ OCTINTERP_API void set_parent (const octave_value& val); - Matrix get_children (void) const + Matrix get_children () const { return m_children.get_children (); } - Matrix get_all_children (void) const + Matrix get_all_children () const { return m_children.get_all (); } - Matrix get_hidden_children (void) const + Matrix get_hidden_children () const { return m_children.get_hidden (); } @@ -2328,7 +2328,7 @@ // Redirect calls to "uicontextmenu" to "contextmenu". - graphics_handle get_uicontextmenu (void) const + graphics_handle get_uicontextmenu () const { return get_contextmenu (); } @@ -2348,7 +2348,7 @@ virtual void update_axis_limits (const std::string& axis_type, const graphics_handle& h) const; - virtual void update_contextmenu (void) const; + virtual void update_contextmenu () const; virtual void delete_children (bool clear = false, bool from_root = false) { @@ -2365,28 +2365,28 @@ m_parent = new_gh; } - static OCTINTERP_API property_list::pval_map_type factory_defaults (void); + static OCTINTERP_API property_list::pval_map_type factory_defaults (); // FIXME: These functions should be generated automatically by the // genprops.awk script. // // EMIT_BASE_PROPERTIES_GET_FUNCTIONS - virtual octave_value get_alim (void) const { return octave_value (); } - virtual octave_value get_clim (void) const { return octave_value (); } - virtual octave_value get_xlim (void) const { return octave_value (); } - virtual octave_value get_ylim (void) const { return octave_value (); } - virtual octave_value get_zlim (void) const { return octave_value (); } - - virtual bool is_aliminclude (void) const { return false; } - virtual bool is_climinclude (void) const { return false; } - virtual bool is_xliminclude (void) const { return false; } - virtual bool is_yliminclude (void) const { return false; } - virtual bool is_zliminclude (void) const { return false; } - - OCTINTERP_API bool is_handle_visible (void) const; - - OCTINTERP_API std::set dynamic_property_names (void) const; + virtual octave_value get_alim () const { return octave_value (); } + virtual octave_value get_clim () const { return octave_value (); } + virtual octave_value get_xlim () const { return octave_value (); } + virtual octave_value get_ylim () const { return octave_value (); } + virtual octave_value get_zlim () const { return octave_value (); } + + virtual bool is_aliminclude () const { return false; } + virtual bool is_climinclude () const { return false; } + virtual bool is_xliminclude () const { return false; } + virtual bool is_yliminclude () const { return false; } + virtual bool is_zliminclude () const { return false; } + + OCTINTERP_API bool is_handle_visible () const; + + OCTINTERP_API std::set dynamic_property_names () const; OCTINTERP_API bool has_dynamic_property (const std::string& pname) const; @@ -2431,11 +2431,11 @@ graphics_handle __myhandle__ fhrs , mh END_PROPERTIES - virtual void update_beingdeleted (void) { }; - - virtual void update_handlevisibility (void); - - virtual void update_visible (void) { }; + virtual void update_beingdeleted () { }; + + virtual void update_handlevisibility (); + + virtual void update_visible () { }; protected: struct cmp_caseless_str @@ -2456,7 +2456,7 @@ protected: - virtual void init (void) + virtual void init () { m_contextmenu.add_constraint ("uicontextmenu"); } @@ -2467,7 +2467,7 @@ public: friend class graphics_object; - base_graphics_object (void) : m_toolkit_flag (false) { } + base_graphics_object () : m_toolkit_flag (false) { } // No copying! @@ -2475,9 +2475,9 @@ base_graphics_object& operator = (const base_graphics_object&) = delete; - virtual ~base_graphics_object (void) = default; - - virtual void mark_modified (void) + virtual ~base_graphics_object () = default; + + virtual void mark_modified () { if (! valid_object ()) error ("base_graphics_object::mark_modified: invalid graphics object"); @@ -2539,12 +2539,12 @@ virtual octave_value get_factory_default (const caseless_str&) const; - virtual octave_value get_defaults (void) const + virtual octave_value get_defaults () const { error ("base_graphics_object::get_defaults: invalid graphics object"); } - virtual property_list get_defaults_list (void) const + virtual property_list get_defaults_list () const { if (! valid_object ()) error ("base_graphics_object::get_defaults_list: invalid graphics object"); @@ -2552,12 +2552,12 @@ return property_list (); } - virtual octave_value get_factory_defaults (void) const + virtual octave_value get_factory_defaults () const { error ("base_graphics_object::get_factory_defaults: invalid graphics object"); } - virtual property_list get_factory_defaults_list (void) const + virtual property_list get_factory_defaults_list () const { error ("base_graphics_object::get_factory_defaults_list: invalid graphics object"); } @@ -2569,7 +2569,7 @@ // FIXME: It seems like this function should be const, but that is // currently not possible. - virtual std::string values_as_string (void); + virtual std::string values_as_string (); // FIXME: It seems like this function should be const, but that is // currently not possible. @@ -2577,9 +2577,9 @@ // FIXME: It seems like this function should be const, but that is // currently not possible. - virtual octave_scalar_map values_as_struct (void); - - virtual graphics_handle get_parent (void) const + virtual octave_scalar_map values_as_struct (); + + virtual graphics_handle get_parent () const { if (! valid_object ()) error ("base_graphics_object::get_parent: invalid graphics object"); @@ -2587,7 +2587,7 @@ return get_properties ().get_parent (); } - graphics_handle get_handle (void) const + graphics_handle get_handle () const { if (! valid_object ()) error ("base_graphics_object::get_handle: invalid graphics object"); @@ -2619,7 +2619,7 @@ get_properties ().reparent (np); } - virtual void defaults (void) const + virtual void defaults () const { if (! valid_object ()) error ("base_graphics_object::default: invalid graphics object"); @@ -2628,14 +2628,14 @@ err_not_implemented (msg.c_str ()); } - virtual base_properties& get_properties (void) + virtual base_properties& get_properties () { static base_properties properties; warning ("base_graphics_object::get_properties: invalid graphics object"); return properties; } - virtual const base_properties& get_properties (void) const + virtual const base_properties& get_properties () const { static base_properties properties; warning ("base_graphics_object::get_properties: invalid graphics object"); @@ -2647,11 +2647,11 @@ virtual void update_axis_limits (const std::string& axis_type, const graphics_handle& h); - virtual bool valid_object (void) const { return false; } - - bool valid_toolkit_object (void) const { return m_toolkit_flag; } - - virtual std::string type (void) const + virtual bool valid_object () const { return false; } + + bool valid_toolkit_object () const { return m_toolkit_flag; } + + virtual std::string type () const { return (valid_object () ? get_properties ().graphics_object_name () : "unknown"); @@ -2662,7 +2662,7 @@ return type () == go_name; } - virtual octave::graphics_toolkit get_toolkit (void) const + virtual octave::graphics_toolkit get_toolkit () const { if (! valid_object ()) error ("base_graphics_object::get_toolkit: invalid graphics object"); @@ -2686,9 +2686,9 @@ get_properties ().delete_listener (nm, v, mode); } - virtual void remove_all_listeners (void); - - virtual void reset_default_properties (void); + virtual void remove_all_listeners (); + + virtual void reset_default_properties (); protected: virtual void initialize (const graphics_object& go) @@ -2723,7 +2723,7 @@ { public: - graphics_object (void) : m_rep (new base_graphics_object ()) { } + graphics_object () : m_rep (new base_graphics_object ()) { } graphics_object (base_graphics_object *new_rep) : m_rep (new_rep) { } @@ -2731,16 +2731,16 @@ graphics_object& operator = (const graphics_object&) = default; - ~graphics_object (void) = default; - - void mark_modified (void) { m_rep->mark_modified (); } + ~graphics_object () = default; + + void mark_modified () { m_rep->mark_modified (); } void override_defaults (base_graphics_object& obj) { m_rep->override_defaults (obj); } - void override_defaults (void) + void override_defaults () { m_rep->override_defaults (*m_rep); } @@ -2800,19 +2800,19 @@ return m_rep->get_factory_default (name); } - octave_value get_defaults (void) const { return m_rep->get_defaults (); } - - property_list get_defaults_list (void) const + octave_value get_defaults () const { return m_rep->get_defaults (); } + + property_list get_defaults_list () const { return m_rep->get_defaults_list (); } - octave_value get_factory_defaults (void) const + octave_value get_factory_defaults () const { return m_rep->get_factory_defaults (); } - property_list get_factory_defaults_list (void) const + property_list get_factory_defaults_list () const { return m_rep->get_factory_defaults_list (); } @@ -2824,7 +2824,7 @@ // FIXME: It seems like this function should be const, but that is // currently not possible. - std::string values_as_string (void) { return m_rep->values_as_string (); } + std::string values_as_string () { return m_rep->values_as_string (); } // FIXME: It seems like this function should be const, but that is // currently not possible. @@ -2835,11 +2835,11 @@ // FIXME: It seems like this function should be const, but that is // currently not possible. - octave_map values_as_struct (void) { return m_rep->values_as_struct (); } - - graphics_handle get_parent (void) const { return m_rep->get_parent (); } - - graphics_handle get_handle (void) const { return m_rep->get_handle (); } + octave_map values_as_struct () { return m_rep->values_as_struct (); } + + graphics_handle get_parent () const { return m_rep->get_parent (); } + + graphics_handle get_handle () const { return m_rep->get_handle (); } OCTINTERP_API graphics_object get_ancestor (const std::string& type) const; @@ -2849,13 +2849,13 @@ void reparent (const graphics_handle& h) { m_rep->reparent (h); } - void defaults (void) const { m_rep->defaults (); } + void defaults () const { m_rep->defaults (); } bool isa (const std::string& go_name) const { return m_rep->isa (go_name); } - base_properties& get_properties (void) { return m_rep->get_properties (); } - - const base_properties& get_properties (void) const + base_properties& get_properties () { return m_rep->get_properties (); } + + const base_properties& get_properties () const { return m_rep->get_properties (); } @@ -2871,51 +2871,51 @@ m_rep->update_axis_limits (axis_type, h); } - bool valid_object (void) const { return m_rep->valid_object (); } - - std::string type (void) const { return m_rep->type (); } - - operator bool (void) const { return m_rep->valid_object (); } + bool valid_object () const { return m_rep->valid_object (); } + + std::string type () const { return m_rep->type (); } + + operator bool () const { return m_rep->valid_object (); } // FIXME: These functions should be generated automatically by the // genprops.awk script. // // EMIT_GRAPHICS_OBJECT_GET_FUNCTIONS - octave_value get_alim (void) const + octave_value get_alim () const { return get_properties ().get_alim (); } - octave_value get_clim (void) const + octave_value get_clim () const { return get_properties ().get_clim (); } - octave_value get_xlim (void) const + octave_value get_xlim () const { return get_properties ().get_xlim (); } - octave_value get_ylim (void) const + octave_value get_ylim () const { return get_properties ().get_ylim (); } - octave_value get_zlim (void) const + octave_value get_zlim () const { return get_properties ().get_zlim (); } - bool is_aliminclude (void) const + bool is_aliminclude () const { return get_properties ().is_aliminclude (); } - bool is_climinclude (void) const + bool is_climinclude () const { return get_properties ().is_climinclude (); } - bool is_xliminclude (void) const + bool is_xliminclude () const { return get_properties ().is_xliminclude (); } - bool is_yliminclude (void) const + bool is_yliminclude () const { return get_properties ().is_yliminclude (); } - bool is_zliminclude (void) const + bool is_zliminclude () const { return get_properties ().is_zliminclude (); } - bool is_handle_visible (void) const + bool is_handle_visible () const { return get_properties ().is_handle_visible (); } - octave::graphics_toolkit get_toolkit (void) const + octave::graphics_toolkit get_toolkit () const { return m_rep->get_toolkit (); } void add_property_listener (const std::string& nm, const octave_value& v, @@ -2926,15 +2926,15 @@ listener_mode mode = GCB_POSTSET) { m_rep->delete_property_listener (nm, v, mode); } - void remove_all_listeners (void) { m_rep->remove_all_listeners (); } - - void initialize (void) { m_rep->initialize (*this); } - - void finalize (void) { m_rep->finalize (*this); } + void remove_all_listeners () { m_rep->remove_all_listeners (); } + + void initialize () { m_rep->initialize (*this); } + + void finalize () { m_rep->finalize (*this); } void update (int id) { m_rep->update (*this, id); } - void reset_default_properties (void) + void reset_default_properties () { m_rep->reset_default_properties (); } private: @@ -3001,20 +3001,20 @@ protected: - root_figure (void) + root_figure () : m_properties (0, graphics_handle ()), m_default_properties (), m_factory_properties (init_factory_properties ()) { } public: - ~root_figure (void) = default; + ~root_figure () = default; root_figure (const root_figure&) = delete; root_figure& operator = (const root_figure&) = delete; - void mark_modified (void) { } + void mark_modified () { } void override_defaults (base_graphics_object& obj) { @@ -3077,33 +3077,33 @@ return retval; } - octave_value get_defaults (void) const + octave_value get_defaults () const { return m_default_properties.as_struct ("default"); } - property_list get_defaults_list (void) const + property_list get_defaults_list () const { return m_default_properties; } - octave_value get_factory_defaults (void) const + octave_value get_factory_defaults () const { return m_factory_properties.as_struct ("factory"); } - property_list get_factory_defaults_list (void) const + property_list get_factory_defaults_list () const { return m_factory_properties; } - base_properties& get_properties (void) { return m_properties; } - - const base_properties& get_properties (void) const { return m_properties; } - - bool valid_object (void) const { return true; } - - OCTINTERP_API void reset_default_properties (void); + base_properties& get_properties () { return m_properties; } + + const base_properties& get_properties () const { return m_properties; } + + bool valid_object () const { return true; } + + OCTINTERP_API void reset_default_properties (); bool has_readonly_property (const caseless_str& pname) const { @@ -3120,7 +3120,7 @@ property_list m_factory_properties; static OCTINTERP_API property_list::plist_map_type - init_factory_properties (void); + init_factory_properties (); }; // --------------------------------------------------------------------- @@ -3142,7 +3142,7 @@ OCTINTERP_API void set_visible (const octave_value& val); - OCTINTERP_API octave::graphics_toolkit get_toolkit (void) const; + OCTINTERP_API octave::graphics_toolkit get_toolkit () const; OCTINTERP_API void set_toolkit (const octave::graphics_toolkit& b); @@ -3151,7 +3151,7 @@ OCTINTERP_API void adopt (const graphics_handle& h); // Alias "innerposition" to "position". - octave_value get_innerposition (void) const + octave_value get_innerposition () const { return get_position (); } @@ -3185,7 +3185,7 @@ OCTINTERP_API void update_paperunits (const caseless_str& old_paperunits); - OCTINTERP_API std::string get_title (void) const; + OCTINTERP_API std::string get_title () const; // See the genprops.awk script for an explanation of the // properties declarations. @@ -3270,7 +3270,7 @@ END_PROPERTIES protected: - void init (void) + void init () { m_alphamap.add_constraint (dim_vector (-1, 1)); m_alphamap.add_constraint (dim_vector (1, -1)); @@ -3292,17 +3292,17 @@ } private: - OCTINTERP_API Matrix get_auto_paperposition (void); - - void update_paperpositionmode (void) + OCTINTERP_API Matrix get_auto_paperposition (); + + void update_paperpositionmode () { if (m_paperpositionmode.is ("auto")) m_paperposition.set (get_auto_paperposition ()); } - OCTINTERP_API void update_handlevisibility (void); - - OCTINTERP_API void init_toolkit (void); + OCTINTERP_API void update_handlevisibility (); + + OCTINTERP_API void init_toolkit (); octave::graphics_toolkit m_toolkit; }; @@ -3315,7 +3315,7 @@ : base_graphics_object (), m_properties (mh, p), m_default_properties () { } - ~figure (void) = default; + ~figure () = default; void override_defaults (base_graphics_object& obj) { @@ -3356,23 +3356,23 @@ OCTINTERP_API octave_value get_default (const caseless_str& name) const; - octave_value get_defaults (void) const + octave_value get_defaults () const { return m_default_properties.as_struct ("default"); } - property_list get_defaults_list (void) const + property_list get_defaults_list () const { return m_default_properties; } - base_properties& get_properties (void) { return m_properties; } - - const base_properties& get_properties (void) const { return m_properties; } - - bool valid_object (void) const { return true; } - - OCTINTERP_API void reset_default_properties (void); + base_properties& get_properties () { return m_properties; } + + const base_properties& get_properties () const { return m_properties; } + + bool valid_object () const { return true; } + + OCTINTERP_API void reset_default_properties (); bool has_readonly_property (const caseless_str& pname) const { @@ -3392,7 +3392,7 @@ { public: - graphics_xform (void) + graphics_xform () : m_xform (xform_eye ()), m_xform_inv (xform_eye ()), m_sx ("linear"), m_sy ("linear"), m_sz ("linear"), m_zlim (1, 2, 0.0) { @@ -3410,7 +3410,7 @@ : m_xform (g.m_xform), m_xform_inv (g.m_xform_inv), m_sx (g.m_sx), m_sy (g.m_sy), m_sz (g.m_sz), m_zlim (g.m_zlim) { } - ~graphics_xform (void) = default; + ~graphics_xform () = default; graphics_xform& operator = (const graphics_xform& g) { @@ -3426,7 +3426,7 @@ static OCTINTERP_API ColumnVector xform_vector (double x, double y, double z); - static OCTINTERP_API Matrix xform_eye (void); + static OCTINTERP_API Matrix xform_eye (); OCTINTERP_API ColumnVector transform (double x, double y, double z, bool use_scale = true) const; @@ -3495,9 +3495,9 @@ OCTINTERP_API void adopt (const graphics_handle& h); - const scaler& get_x_scaler (void) const { return m_sx; } - const scaler& get_y_scaler (void) const { return m_sy; } - const scaler& get_z_scaler (void) const { return m_sz; } + const scaler& get_x_scaler () const { return m_sx; } + const scaler& get_y_scaler () const { return m_sy; } + const scaler& get_z_scaler () const { return m_sz; } OCTINTERP_API Matrix get_boundingbox (bool internal = false, @@ -3509,7 +3509,7 @@ OCTINTERP_API double get___fontsize_points__ (double box_pix_height = 0) const; - void update_boundingbox (void) + void update_boundingbox () { if (units_is ("normalized")) { @@ -3518,21 +3518,21 @@ } } - OCTINTERP_API void update_camera (void); - OCTINTERP_API void update_axes_layout (void); - OCTINTERP_API void update_aspectratios (void); - void update_transform (void) + OCTINTERP_API void update_camera (); + OCTINTERP_API void update_axes_layout (); + OCTINTERP_API void update_aspectratios (); + void update_transform () { update_aspectratios (); update_camera (); update_axes_layout (); } - OCTINTERP_API void sync_positions (void); + OCTINTERP_API void sync_positions (); // Redirect calls to "activepositionproperty" to "positionconstraint". - std::string get_activepositionproperty (void) const + std::string get_activepositionproperty () const { std::string cur_val; @@ -3557,7 +3557,7 @@ // Redirect calls to "innerposition" to "position". - octave_value get_innerposition (void) const + octave_value get_innerposition () const { return get_position (); } @@ -3568,63 +3568,63 @@ } OCTINTERP_API void update_autopos (const std::string& elem_type); - OCTINTERP_API void update_xlabel_position (void); - OCTINTERP_API void update_ylabel_position (void); - OCTINTERP_API void update_zlabel_position (void); - OCTINTERP_API void update_title_position (void); - - graphics_xform get_transform (void) const + OCTINTERP_API void update_xlabel_position (); + OCTINTERP_API void update_ylabel_position (); + OCTINTERP_API void update_zlabel_position (); + OCTINTERP_API void update_title_position (); + + graphics_xform get_transform () const { return graphics_xform (m_x_render, m_x_render_inv, m_sx, m_sy, m_sz, m_x_zlim); } - Matrix get_transform_matrix (void) const { return m_x_render; } - Matrix get_inverse_transform_matrix (void) const { return m_x_render_inv; } - Matrix get_opengl_matrix_1 (void) const { return m_x_gl_mat1; } - Matrix get_opengl_matrix_2 (void) const { return m_x_gl_mat2; } - Matrix get_transform_zlim (void) const { return m_x_zlim; } - - int get_xstate (void) const { return m_xstate; } - int get_ystate (void) const { return m_ystate; } - int get_zstate (void) const { return m_zstate; } - double get_xPlane (void) const { return m_xPlane; } - double get_xPlaneN (void) const { return m_xPlaneN; } - double get_yPlane (void) const { return m_yPlane; } - double get_yPlaneN (void) const { return m_yPlaneN; } - double get_zPlane (void) const { return m_zPlane; } - double get_zPlaneN (void) const { return m_zPlaneN; } - double get_xpTick (void) const { return m_xpTick; } - double get_xpTickN (void) const { return m_xpTickN; } - double get_ypTick (void) const { return m_ypTick; } - double get_ypTickN (void) const { return m_ypTickN; } - double get_zpTick (void) const { return m_zpTick; } - double get_zpTickN (void) const { return m_zpTickN; } - double get_x_min (void) const { return std::min (m_xPlane, m_xPlaneN); } - double get_x_max (void) const { return std::max (m_xPlane, m_xPlaneN); } - double get_y_min (void) const { return std::min (m_yPlane, m_yPlaneN); } - double get_y_max (void) const { return std::max (m_yPlane, m_yPlaneN); } - double get_z_min (void) const { return std::min (m_zPlane, m_zPlaneN); } - double get_z_max (void) const { return std::max (m_zPlane, m_zPlaneN); } - double get_fx (void) const { return m_fx; } - double get_fy (void) const { return m_fy; } - double get_fz (void) const { return m_fz; } - double get_xticklen (void) const { return m_xticklen; } - double get_yticklen (void) const { return m_yticklen; } - double get_zticklen (void) const { return m_zticklen; } - double get_xtickoffset (void) const { return m_xtickoffset; } - double get_ytickoffset (void) const { return m_ytickoffset; } - double get_ztickoffset (void) const { return m_ztickoffset; } - bool get_x2Dtop (void) const { return m_x2Dtop; } - bool get_y2Dright (void) const { return m_y2Dright; } - bool get_layer2Dtop (void) const { return m_layer2Dtop; } + Matrix get_transform_matrix () const { return m_x_render; } + Matrix get_inverse_transform_matrix () const { return m_x_render_inv; } + Matrix get_opengl_matrix_1 () const { return m_x_gl_mat1; } + Matrix get_opengl_matrix_2 () const { return m_x_gl_mat2; } + Matrix get_transform_zlim () const { return m_x_zlim; } + + int get_xstate () const { return m_xstate; } + int get_ystate () const { return m_ystate; } + int get_zstate () const { return m_zstate; } + double get_xPlane () const { return m_xPlane; } + double get_xPlaneN () const { return m_xPlaneN; } + double get_yPlane () const { return m_yPlane; } + double get_yPlaneN () const { return m_yPlaneN; } + double get_zPlane () const { return m_zPlane; } + double get_zPlaneN () const { return m_zPlaneN; } + double get_xpTick () const { return m_xpTick; } + double get_xpTickN () const { return m_xpTickN; } + double get_ypTick () const { return m_ypTick; } + double get_ypTickN () const { return m_ypTickN; } + double get_zpTick () const { return m_zpTick; } + double get_zpTickN () const { return m_zpTickN; } + double get_x_min () const { return std::min (m_xPlane, m_xPlaneN); } + double get_x_max () const { return std::max (m_xPlane, m_xPlaneN); } + double get_y_min () const { return std::min (m_yPlane, m_yPlaneN); } + double get_y_max () const { return std::max (m_yPlane, m_yPlaneN); } + double get_z_min () const { return std::min (m_zPlane, m_zPlaneN); } + double get_z_max () const { return std::max (m_zPlane, m_zPlaneN); } + double get_fx () const { return m_fx; } + double get_fy () const { return m_fy; } + double get_fz () const { return m_fz; } + double get_xticklen () const { return m_xticklen; } + double get_yticklen () const { return m_yticklen; } + double get_zticklen () const { return m_zticklen; } + double get_xtickoffset () const { return m_xtickoffset; } + double get_ytickoffset () const { return m_ytickoffset; } + double get_ztickoffset () const { return m_ztickoffset; } + bool get_x2Dtop () const { return m_x2Dtop; } + bool get_y2Dright () const { return m_y2Dright; } + bool get_layer2Dtop () const { return m_layer2Dtop; } bool get_is2D (bool include_kids = false) const { return (include_kids ? (m_is2D && ! m_has3Dkids) : m_is2D); } void set_has3Dkids (bool val) { m_has3Dkids = val; } - bool get_xySym (void) const { return m_xySym; } - bool get_xyzSym (void) const { return m_xyzSym; } - bool get_zSign (void) const { return m_zSign; } - bool get_nearhoriz (void) const { return m_nearhoriz; } + bool get_xySym () const { return m_xySym; } + bool get_xyzSym () const { return m_xyzSym; } + bool get_zSign () const { return m_zSign; } + bool get_nearhoriz () const { return m_nearhoriz; } ColumnVector pixel2coord (double px, double py) const { @@ -3662,9 +3662,9 @@ rotate_view (double delta_az, double delta_el, bool push_to_zoom_stack = true); - OCTINTERP_API void unzoom (void); - OCTINTERP_API void update_handlevisibility (void); - OCTINTERP_API void push_zoom_stack (void); + OCTINTERP_API void unzoom (); + OCTINTERP_API void update_handlevisibility (); + OCTINTERP_API void push_zoom_stack (); OCTINTERP_API void clear_zoom_stack (bool do_unzoom = true); OCTINTERP_API void update_units (const caseless_str& old_units); @@ -3673,9 +3673,9 @@ OCTINTERP_API void update_fontunits (const caseless_str& old_fontunits); - void increase_num_lights (void) { m_num_lights++; } - void decrease_num_lights (void) { m_num_lights--; } - unsigned int get_num_lights (void) const { return m_num_lights; } + void increase_num_lights () { m_num_lights++; } + void decrease_num_lights () { m_num_lights--; } + unsigned int get_num_lights () const { return m_num_lights; } private: @@ -3908,7 +3908,7 @@ END_PROPERTIES protected: - OCTINTERP_API void init (void); + OCTINTERP_API void init (); private: @@ -3923,67 +3923,67 @@ return retval; } - void update_xscale (void) + void update_xscale () { m_sx = get_scale (get_xscale (), m_xlim.get ().matrix_value ()); } - void update_yscale (void) + void update_yscale () { m_sy = get_scale (get_yscale (), m_ylim.get ().matrix_value ()); } - void update_zscale (void) + void update_zscale () { m_sz = get_scale (get_zscale (), m_zlim.get ().matrix_value ()); } OCTINTERP_API void update_label_color (handle_property label, color_property col); - void update_xcolor (void) + void update_xcolor () { update_label_color (m_xlabel, m_xcolor); } - void update_ycolor (void) + void update_ycolor () { update_label_color (m_ylabel, m_ycolor); } - void update_zcolor (void) + void update_zcolor () { update_label_color (m_zlabel, m_zcolor); } - void update_view (void) { sync_positions (); } - - void update_cameraposition (void) { update_transform (); } - void update_cameratarget (void) { update_transform (); } - void update_cameraupvector (void) { update_transform (); } - void update_cameraviewangle (void) { update_transform (); } - - void update_camerapositionmode (void) + void update_view () { sync_positions (); } + + void update_cameraposition () { update_transform (); } + void update_cameratarget () { update_transform (); } + void update_cameraupvector () { update_transform (); } + void update_cameraviewangle () { update_transform (); } + + void update_camerapositionmode () { if (camerapositionmode_is ("auto")) update_cameraposition (); } - void update_cameratargetmode (void) + void update_cameratargetmode () { if (cameratargetmode_is ("auto")) update_cameratarget (); } - void update_cameraupvectormode (void) + void update_cameraupvectormode () { if (cameraupvectormode_is ("auto")) update_cameraupvector (); } - void update_cameraviewanglemode (void) + void update_cameraviewanglemode () { if (cameraviewanglemode_is ("auto")) update_cameraviewangle (); } - void update_dataaspectratio (void) { sync_positions (); } - void update_dataaspectratiomode (void) { sync_positions (); } - void update_plotboxaspectratio (void) { sync_positions (); } - void update_plotboxaspectratiomode (void) { sync_positions (); } - - void update_layer (void) { update_axes_layout (); } - void update_box (void) + void update_dataaspectratio () { sync_positions (); } + void update_dataaspectratiomode () { sync_positions (); } + void update_plotboxaspectratio () { sync_positions (); } + void update_plotboxaspectratiomode () { sync_positions (); } + + void update_layer () { update_axes_layout (); } + void update_box () { if (m_xticklabelmode.is ("auto")) calc_ticklabels (m_xtick, m_xticklabel, m_xscale.is ("log"), @@ -4000,7 +4000,7 @@ (xaxislocation_is ("bottom") ? -1 : 1)), m_ylim); } - void update_yaxislocation (void) + void update_yaxislocation () { sync_positions (); update_axes_layout (); @@ -4020,7 +4020,7 @@ m_ylim); update_ylabel_position (); } - void update_xaxislocation (void) + void update_xaxislocation () { sync_positions (); update_axes_layout (); @@ -4041,15 +4041,15 @@ update_xlabel_position (); } - void update_xdir (void) { update_camera (); update_axes_layout (); } - void update_ydir (void) { update_camera (); update_axes_layout (); } - void update_zdir (void) { update_camera (); update_axes_layout (); } - - void update_ticklength (void); - void update_tickdir (void) { update_ticklength (); } - void update_tickdirmode (void) { update_ticklength (); } - - void update_ticklabelinterpreter (void) + void update_xdir () { update_camera (); update_axes_layout (); } + void update_ydir () { update_camera (); update_axes_layout (); } + void update_zdir () { update_camera (); update_axes_layout (); } + + void update_ticklength (); + void update_tickdir () { update_ticklength (); } + void update_tickdirmode () { update_ticklength (); } + + void update_ticklabelinterpreter () { update_xtick (false); update_ytick (false); @@ -4104,23 +4104,23 @@ sync_positions (); } - void update_xtickmode (void) + void update_xtickmode () { if (m_xtickmode.is ("auto")) update_xtick (); } - void update_ytickmode (void) + void update_ytickmode () { if (m_ytickmode.is ("auto")) update_ytick (); } - void update_ztickmode (void) + void update_ztickmode () { if (m_ztickmode.is ("auto")) update_ztick (); } - void update_xticklabelmode (void) + void update_xticklabelmode () { if (m_xticklabelmode.is ("auto")) calc_ticklabels (m_xtick, m_xticklabel, m_xscale.is ("log"), @@ -4130,7 +4130,7 @@ (yaxislocation_is ("left") ? -1 : 1)), m_xlim); } - void update_yticklabelmode (void) + void update_yticklabelmode () { if (m_yticklabelmode.is ("auto")) calc_ticklabels (m_ytick, m_yticklabel, m_yscale.is ("log"), @@ -4140,61 +4140,61 @@ (xaxislocation_is ("bottom") ? -1 : 1)), m_ylim); } - void update_zticklabelmode (void) + void update_zticklabelmode () { if (m_zticklabelmode.is ("auto")) calc_ticklabels (m_ztick, m_zticklabel, m_zscale.is ("log"), false, 2, m_zlim); } - void update_fontname (void) + void update_fontname () { update_font ("fontname"); sync_positions (); } - void update_fontsize (void) + void update_fontsize () { update_font ("fontsize"); sync_positions (); } - void update_fontsmoothing (void) + void update_fontsmoothing () { update_font ("fontsmoothing"); } - void update_fontangle (void) + void update_fontangle () { update_font ("fontangle"); sync_positions (); } - void update_fontweight (void) + void update_fontweight () { update_font ("fontweight"); sync_positions (); } - void update_titlefontsizemultiplier (void) + void update_titlefontsizemultiplier () { // update_font handles title and axis labels update_font ("fontsize"); sync_positions (); } - void update_labelfontsizemultiplier (void) + void update_labelfontsizemultiplier () { update_font ("fontsize"); sync_positions (); } - void update_titlefontweight (void) + void update_titlefontweight () { // update_font handles title and axis labels update_font ("fontweight"); sync_positions (); } - OCTINTERP_API void update_outerposition (void); - OCTINTERP_API void update_position (void); - OCTINTERP_API void update_looseinset (void); + OCTINTERP_API void update_outerposition (); + OCTINTERP_API void update_position (); + OCTINTERP_API void update_looseinset (); OCTINTERP_API double calc_tick_sep (double minval, double maxval); OCTINTERP_API void @@ -4239,12 +4239,12 @@ set___colormap__ (val); } - void update___colormap__ (void) + void update___colormap__ () { m_colormap.run_listeners (GCB_POSTSET); } - OCTINTERP_API octave_value get_colormap (void) const; + OCTINTERP_API octave_value get_colormap () const; public: OCTINTERP_API Matrix @@ -4284,7 +4284,7 @@ update_xlim (); } - void update_ylim (void) + void update_ylim () { update_axis_limits ("ylim"); @@ -4312,7 +4312,7 @@ update_ylim (); } - void update_zlim (void) + void update_zlim () { update_axis_limits ("zlim"); @@ -4336,7 +4336,7 @@ update_zlim (); } - void trigger_normals_calc (void); + void trigger_normals_calc (); }; @@ -4350,7 +4350,7 @@ m_properties.update_transform (); } - ~axes (void) = default; + ~axes () = default; void override_defaults (base_graphics_object& obj) { @@ -4397,28 +4397,28 @@ OCTINTERP_API octave_value get_default (const caseless_str& name) const; - octave_value get_defaults (void) const + octave_value get_defaults () const { return m_default_properties.as_struct ("default"); } - property_list get_defaults_list (void) const + property_list get_defaults_list () const { return m_default_properties; } - base_properties& get_properties (void) { return m_properties; } - - const base_properties& get_properties (void) const { return m_properties; } + base_properties& get_properties () { return m_properties; } + + const base_properties& get_properties () const { return m_properties; } OCTINTERP_API void update_axis_limits (const std::string& axis_type); OCTINTERP_API void update_axis_limits (const std::string& axis_type, const graphics_handle& h); - bool valid_object (void) const { return true; } - - OCTINTERP_API void reset_default_properties (void); + bool valid_object () const { return true; } + + OCTINTERP_API void reset_default_properties (); bool has_readonly_property (const caseless_str& pname) const { @@ -4476,21 +4476,21 @@ END_PROPERTIES protected: - void init (void) + void init () { m_linewidth.add_constraint ("min", 0, false); m_markersize.add_constraint ("min", 0, false); } private: - OCTINTERP_API Matrix compute_xlim (void) const; - OCTINTERP_API Matrix compute_ylim (void) const; - - void update_xdata (void) { set_xlim (compute_xlim ()); } - - void update_ydata (void) { set_ylim (compute_ylim ()); } - - void update_zdata (void) { set_zlim (m_zdata.get_limits ()); } + OCTINTERP_API Matrix compute_xlim () const; + OCTINTERP_API Matrix compute_ylim () const; + + void update_xdata () { set_xlim (compute_xlim ()); } + + void update_ydata () { set_ylim (compute_ylim ()); } + + void update_zdata () { set_zlim (m_zdata.get_limits ()); } }; private: @@ -4501,13 +4501,13 @@ : base_graphics_object (), m_properties (mh, p) { } - ~line (void) = default; - - base_properties& get_properties (void) { return m_properties; } - - const base_properties& get_properties (void) const { return m_properties; } - - bool valid_object (void) const { return true; } + ~line () = default; + + base_properties& get_properties () { return m_properties; } + + const base_properties& get_properties () const { return m_properties; } + + bool valid_object () const { return true; } bool has_readonly_property (const caseless_str& pname) const { @@ -4531,9 +4531,9 @@ OCTINTERP_API double get___fontsize_points__ (double box_pix_height = 0) const; - OCTINTERP_API void update_text_extent (void); - - OCTINTERP_API void update_font (void); + OCTINTERP_API void update_text_extent (); + + OCTINTERP_API void update_font (); void set_position (const octave_value& val) { @@ -4601,15 +4601,15 @@ double_property __fontsize_points__ hgr , 0 END_PROPERTIES - OCTINTERP_API Matrix get_data_position (void) const; + OCTINTERP_API Matrix get_data_position () const; OCTINTERP_API Matrix get_extent_matrix (bool rotated = false) const; - const uint8NDArray& get_pixels (void) const { return m_pixels; } + const uint8NDArray& get_pixels () const { return m_pixels; } // Text renderer, used for calculation of text size octave::text_renderer m_txt_renderer; protected: - void init (void) + void init () { m_position.add_constraint (dim_vector (1, 3)); m_fontsize.add_constraint ("min", 0.0, false); @@ -4620,7 +4620,7 @@ } private: - void update_position (void) + void update_position () { Matrix pos = get_data_position (); Matrix lim; @@ -4646,19 +4646,19 @@ } } - OCTINTERP_API void request_autopos (void); - void update_positionmode (void) { request_autopos (); } - void update_rotationmode (void) { request_autopos (); } - void update_horizontalalignmentmode (void) { request_autopos (); } - void update_verticalalignmentmode (void) { request_autopos (); } - - void update_string (void) { request_autopos (); update_text_extent (); } - void update_rotation (void) { update_text_extent (); } - void update_fontname (void) { update_font (); update_text_extent (); } - void update_fontsize (void) { update_font (); update_text_extent (); } - void update_fontsmoothing (void) { update_font (); update_text_extent (); } - - void update_color (void) + OCTINTERP_API void request_autopos (); + void update_positionmode () { request_autopos (); } + void update_rotationmode () { request_autopos (); } + void update_horizontalalignmentmode () { request_autopos (); } + void update_verticalalignmentmode () { request_autopos (); } + + void update_string () { request_autopos (); update_text_extent (); } + void update_rotation () { update_text_extent (); } + void update_fontname () { update_font (); update_text_extent (); } + void update_fontsize () { update_font (); update_text_extent (); } + void update_fontsmoothing () { update_font (); update_text_extent (); } + + void update_color () { if (! m_color.is ("none")) { @@ -4667,18 +4667,18 @@ } } - void update_fontangle (void) + void update_fontangle () { update_font (); update_text_extent (); } - void update_fontweight (void) { update_font (); update_text_extent (); } - - void update_interpreter (void) { update_text_extent (); } - void update_horizontalalignment (void) { update_text_extent (); } - void update_verticalalignment (void) { update_text_extent (); } - - OCTINTERP_API void update_units (void); + void update_fontweight () { update_font (); update_text_extent (); } + + void update_interpreter () { update_text_extent (); } + void update_horizontalalignment () { update_text_extent (); } + void update_verticalalignment () { update_text_extent (); } + + OCTINTERP_API void update_units (); OCTINTERP_API void update_fontunits (const caseless_str& old_fontunits); private: @@ -4696,13 +4696,13 @@ m_properties.set_clipping ("off"); } - ~text (void) = default; - - base_properties& get_properties (void) { return m_properties; } - - const base_properties& get_properties (void) const { return m_properties; } - - bool valid_object (void) const { return true; } + ~text () = default; + + base_properties& get_properties () { return m_properties; } + + const base_properties& get_properties () const { return m_properties; } + + bool valid_object () const { return true; } bool has_readonly_property (const caseless_str& pname) const { @@ -4723,19 +4723,19 @@ { public: - bool is_aliminclude (void) const + bool is_aliminclude () const { return (m_aliminclude.is_on () && m_alphadatamapping.is ("scaled")); } - std::string get_aliminclude (void) const + std::string get_aliminclude () const { return m_aliminclude.current_value (); } - bool is_climinclude (void) const + bool is_climinclude () const { return (m_climinclude.is_on () && m_cdatamapping.is ("scaled")); } - std::string get_climinclude (void) const + std::string get_climinclude () const { return m_climinclude.current_value (); } - OCTINTERP_API octave_value get_color_data (void) const; - - void initialize_data (void) { update_cdata (); } + OCTINTERP_API octave_value get_color_data () const; + + void initialize_data () { update_cdata (); } // See the genprops.awk script for an explanation of the // properties declarations. @@ -4762,7 +4762,7 @@ END_PROPERTIES protected: - void init (void) + void init () { m_xdata.add_constraint (2); m_xdata.add_constraint (dim_vector (0, 0)); @@ -4788,7 +4788,7 @@ } private: - void update_alphadata (void) + void update_alphadata () { if (alphadatamapping_is ("scaled")) set_alim (m_alphadata.get_limits ()); @@ -4796,7 +4796,7 @@ m_alim = m_alphadata.get_limits (); } - void update_cdata (void) + void update_cdata () { if (cdatamapping_is ("scaled")) set_clim (m_cdata.get_limits ()); @@ -4810,7 +4810,7 @@ update_ydata (); } - void update_xdata (void) + void update_xdata () { if (m_xdata.get ().isempty ()) set_xdatamode ("auto"); @@ -4829,7 +4829,7 @@ set_xlim (limits); } - void update_ydata (void) + void update_ydata () { if (m_ydata.get ().isempty ()) set_ydatamode ("auto"); @@ -4848,7 +4848,7 @@ set_ylim (limits); } - Matrix get_auto_xdata (void) + Matrix get_auto_xdata () { dim_vector dv = get_cdata ().dims (); Matrix data; @@ -4860,7 +4860,7 @@ return data; } - Matrix get_auto_ydata (void) + Matrix get_auto_ydata () { dim_vector dv = get_cdata ().dims (); Matrix data; @@ -4890,12 +4890,12 @@ } public: - float pixel_xsize (void) + float pixel_xsize () { return pixel_size ((get_cdata ().dims ())(1), m_xdata.get_limits ()); } - float pixel_ysize (void) + float pixel_ysize () { return pixel_size ((get_cdata ().dims ())(0), m_ydata.get_limits ()); } @@ -4911,13 +4911,13 @@ m_properties.initialize_data (); } - ~image (void) = default; - - base_properties& get_properties (void) { return m_properties; } - - const base_properties& get_properties (void) const { return m_properties; } - - bool valid_object (void) const { return true; } + ~image () = default; + + base_properties& get_properties () { return m_properties; } + + const base_properties& get_properties () const { return m_properties; } + + bool valid_object () const { return true; } bool has_readonly_property (const caseless_str& pname) const { @@ -4947,13 +4947,13 @@ END_PROPERTIES protected: - void init (void) + void init () { m_position.add_constraint (dim_vector (1, 3)); } private: - OCTINTERP_API void update_visible (void); + OCTINTERP_API void update_visible (); }; private: @@ -4964,13 +4964,13 @@ : base_graphics_object (), m_properties (mh, p) { } - ~light (void) = default; - - base_properties& get_properties (void) { return m_properties; } - - const base_properties& get_properties (void) const { return m_properties; } - - bool valid_object (void) const { return true; } + ~light () = default; + + base_properties& get_properties () { return m_properties; } + + const base_properties& get_properties () const { return m_properties; } + + bool valid_object () const { return true; } bool has_readonly_property (const caseless_str& pname) const { @@ -4994,7 +4994,7 @@ { public: - octave_value get_color_data (void) const; + octave_value get_color_data () const; // Matlab allows incoherent data to be stored into patch properties. // The patch should then be ignored by the renderer. @@ -5004,17 +5004,17 @@ return ! msg.empty (); } - bool is_aliminclude (void) const + bool is_aliminclude () const { return (m_aliminclude.is_on () && m_alphadatamapping.is ("scaled")); } - std::string get_aliminclude (void) const + std::string get_aliminclude () const { return m_aliminclude.current_value (); } - bool is_climinclude (void) const + bool is_climinclude () const { return (m_climinclude.is_on () && m_cdatamapping.is ("scaled")); } - std::string get_climinclude (void) const + std::string get_climinclude () const { return m_climinclude.current_value (); } - OCTINTERP_API bool get_do_lighting (void) const; + OCTINTERP_API bool get_do_lighting () const; std::vector> m_coplanar_last_idx; @@ -5071,7 +5071,7 @@ END_PROPERTIES protected: - void init (void) + void init () { m_xdata.add_constraint (dim_vector (-1, -1)); m_ydata.add_constraint (dim_vector (-1, -1)); @@ -5127,15 +5127,15 @@ private: std::string m_bad_data_msg; - void update_faces (void) { update_data ();} - - void update_vertices (void) { update_data ();} - - void update_facevertexcdata (void) { update_data ();} - - OCTINTERP_API void update_fvc (void); - - void update_xdata (void) + void update_faces () { update_data ();} + + void update_vertices () { update_data ();} + + void update_facevertexcdata () { update_data ();} + + OCTINTERP_API void update_fvc (); + + void update_xdata () { if (get_xdata ().isempty ()) { @@ -5156,7 +5156,7 @@ set_xlim (m_xdata.get_limits ()); } - void update_ydata (void) + void update_ydata () { if (get_ydata ().isempty ()) { @@ -5174,14 +5174,14 @@ set_ylim (m_ydata.get_limits ()); } - void update_zdata (void) + void update_zdata () { update_fvc (); update_normals (true); set_zlim (m_zdata.get_limits ()); } - void update_cdata (void) + void update_cdata () { update_fvc (); update_normals (false); @@ -5192,33 +5192,33 @@ m_clim = m_cdata.get_limits (); } - OCTINTERP_API void update_data (void); + OCTINTERP_API void update_data (); OCTINTERP_API void calc_face_normals (Matrix& normals); OCTINTERP_API void update_face_normals (bool reset, bool force = false); OCTINTERP_API void update_vertex_normals (bool reset, bool force = false); - void update_edgelighting (void) + void update_edgelighting () { update_normals (false); } - void update_facelighting (void) + void update_facelighting () { update_normals (false); } - void update_facenormalsmode (void) + void update_facenormalsmode () { update_face_normals (false); } - void update_vertexnormalsmode (void) + void update_vertexnormalsmode () { update_vertex_normals (false); } - void update_visible (void) + void update_visible () { if (is_visible ()) update_normals (false); @@ -5234,13 +5234,13 @@ : base_graphics_object (), m_properties (mh, p) { } - ~patch (void) = default; - - base_properties& get_properties (void) { return m_properties; } - - const base_properties& get_properties (void) const { return m_properties; } - - bool valid_object (void) const { return true; } + ~patch () = default; + + base_properties& get_properties () { return m_properties; } + + const base_properties& get_properties () const { return m_properties; } + + bool valid_object () const { return true; } bool has_readonly_property (const caseless_str& pname) const { @@ -5250,7 +5250,7 @@ return retval; } - OCTINTERP_API void reset_default_properties (void); + OCTINTERP_API void reset_default_properties (); protected: OCTINTERP_API void initialize (const graphics_object& go); @@ -5267,7 +5267,7 @@ { public: - OCTINTERP_API octave_value get_color_data (void) const; + OCTINTERP_API octave_value get_color_data () const; // Matlab allows incoherent data to be stored in scatter properties. // The scatter object should then be ignored by the renderer. @@ -5277,14 +5277,14 @@ return ! msg.empty (); } - bool is_aliminclude (void) const + bool is_aliminclude () const { return m_aliminclude.is_on (); } - std::string get_aliminclude (void) const + std::string get_aliminclude () const { return m_aliminclude.current_value (); } - bool is_climinclude (void) const + bool is_climinclude () const { return m_climinclude.is_on (); } - std::string get_climinclude (void) const + std::string get_climinclude () const { return m_climinclude.current_value (); } // See the genprops.awk script for an explanation of the @@ -5336,7 +5336,7 @@ END_PROPERTIES protected: - void init (void) + void init () { m_xdata.add_constraint (dim_vector (-1, 1)); m_xdata.add_constraint (dim_vector (1, -1)); @@ -5379,12 +5379,12 @@ } public: - OCTINTERP_API void update_color (void); + OCTINTERP_API void update_color (); private: std::string m_bad_data_msg; - void update_xdata (void) + void update_xdata () { if (get_xdata ().isempty ()) { @@ -5403,7 +5403,7 @@ update_data (); } - void update_ydata (void) + void update_ydata () { if (get_ydata ().isempty ()) { @@ -5420,19 +5420,19 @@ update_data (); } - void update_zdata (void) + void update_zdata () { set_zlim (m_zdata.get_limits ()); update_data (); } - void update_sizedata (void) + void update_sizedata () { update_data (); } - void update_cdata (void) + void update_cdata () { if (get_cdata ().matrix_value ().rows () == 1) set_clim (m_cdata.get_limits ()); @@ -5442,19 +5442,19 @@ update_data (); } - void update_cdatamode (void) + void update_cdatamode () { if (m_cdatamode.is ("auto")) update_color (); } - void update_seriesindex (void) + void update_seriesindex () { if (m_cdatamode.is ("auto")) update_color (); } - void update_data (void); + void update_data (); }; @@ -5470,13 +5470,13 @@ // object is added to the axes. } - ~scatter (void) = default; - - base_properties& get_properties (void) { return m_properties; } - - const base_properties& get_properties (void) const { return m_properties; } - - bool valid_object (void) const { return true; } + ~scatter () = default; + + base_properties& get_properties () { return m_properties; } + + const base_properties& get_properties () const { return m_properties; } + + bool valid_object () const { return true; } bool has_readonly_property (const caseless_str& pname) const { @@ -5501,19 +5501,19 @@ { public: - octave_value get_color_data (void) const; - - bool is_aliminclude (void) const + octave_value get_color_data () const; + + bool is_aliminclude () const { return (m_aliminclude.is_on () && m_alphadatamapping.is ("scaled")); } - std::string get_aliminclude (void) const + std::string get_aliminclude () const { return m_aliminclude.current_value (); } - bool is_climinclude (void) const + bool is_climinclude () const { return (m_climinclude.is_on () && m_cdatamapping.is ("scaled")); } - std::string get_climinclude (void) const + std::string get_climinclude () const { return m_climinclude.current_value (); } - OCTINTERP_API bool get_do_lighting (void) const; + OCTINTERP_API bool get_do_lighting () const; // See the genprops.awk script for an explanation of the // properties declarations. @@ -5570,7 +5570,7 @@ END_PROPERTIES protected: - void init (void) + void init () { m_xdata.add_constraint (dim_vector (-1, -1)); m_ydata.add_constraint (dim_vector (-1, -1)); @@ -5619,7 +5619,7 @@ private: - void update_alphadata (void) + void update_alphadata () { if (alphadatamapping_is ("scaled")) set_alim (m_alphadata.get_limits ()); @@ -5627,7 +5627,7 @@ m_alim = m_alphadata.get_limits (); } - void update_cdata (void) + void update_cdata () { if (cdatamapping_is ("scaled")) set_clim (m_cdata.get_limits ()); @@ -5635,19 +5635,19 @@ m_clim = m_cdata.get_limits (); } - void update_xdata (void) + void update_xdata () { update_normals (true); set_xlim (m_xdata.get_limits ()); } - void update_ydata (void) + void update_ydata () { update_normals (true); set_ylim (m_ydata.get_limits ()); } - void update_zdata (void) + void update_zdata () { update_normals (true); set_zlim (m_zdata.get_limits ()); @@ -5656,19 +5656,19 @@ OCTINTERP_API void update_face_normals (bool reset, bool force = false); OCTINTERP_API void update_vertex_normals (bool reset, bool force = false); - void update_facenormalsmode (void) + void update_facenormalsmode () { update_face_normals (false); } - void update_vertexnormalsmode (void) + void update_vertexnormalsmode () { update_vertex_normals (false); } - void update_edgelighting (void) + void update_edgelighting () { update_normals (false); } - void update_facelighting (void) + void update_facelighting () { update_normals (false); } - void update_visible (void) + void update_visible () { if (is_visible ()) update_normals (false); @@ -5684,13 +5684,13 @@ : base_graphics_object (), m_properties (mh, p) { } - ~surface (void) = default; - - base_properties& get_properties (void) { return m_properties; } - - const base_properties& get_properties (void) const { return m_properties; } - - bool valid_object (void) const { return true; } + ~surface () = default; + + base_properties& get_properties () { return m_properties; } + + const base_properties& get_properties () const { return m_properties; } + + bool valid_object () const { return true; } bool has_readonly_property (const caseless_str& pname) const { @@ -5737,12 +5737,12 @@ END_PROPERTIES private: - OCTINTERP_API void update_limits (void) const; + OCTINTERP_API void update_limits () const; OCTINTERP_API void update_limits (const graphics_handle& h) const; protected: - void init (void) + void init () { } }; @@ -5755,13 +5755,13 @@ : base_graphics_object (), m_properties (mh, p) { } - ~hggroup (void) = default; - - base_properties& get_properties (void) { return m_properties; } - - const base_properties& get_properties (void) const { return m_properties; } - - bool valid_object (void) const { return true; } + ~hggroup () = default; + + base_properties& get_properties () { return m_properties; } + + const base_properties& get_properties () const { return m_properties; } + + bool valid_object () const { return true; } OCTINTERP_API void update_axis_limits (const std::string& axis_type); @@ -5824,7 +5824,7 @@ END_PROPERTIES // Make "Label" an alias for "Text". - std::string get_label (void) const + std::string get_label () const { return get_text (); } @@ -5835,7 +5835,7 @@ } // Make "Callback" an alias for "MenuSelectedFcn". - octave_value get_callback (void) const + octave_value get_callback () const { return get_menuselectedfcn (); } @@ -5846,7 +5846,7 @@ } protected: - void init (void) + void init () { m_position.add_constraint ("min", 0, true); } @@ -5860,13 +5860,13 @@ : base_graphics_object (), m_properties (mh, p) { } - ~uimenu (void) = default; - - base_properties& get_properties (void) { return m_properties; } - - const base_properties& get_properties (void) const { return m_properties; } - - bool valid_object (void) const { return true; } + ~uimenu () = default; + + base_properties& get_properties () { return m_properties; } + + const base_properties& get_properties () const { return m_properties; } + + bool valid_object () const { return true; } bool has_readonly_property (const caseless_str& pname) const { @@ -5894,7 +5894,7 @@ // FIXME: the list may contain duplicates. // Should we return only unique elements? - const std::list get_dependent_obj_list (void) + const std::list get_dependent_obj_list () { return m_dependent_obj_list; } // See the genprops.awk script for an explanation of the @@ -5910,7 +5910,7 @@ END_PROPERTIES protected: - void init (void) + void init () { m_position.add_constraint (dim_vector (1, 2)); m_position.add_constraint (dim_vector (2, 1)); @@ -5921,7 +5921,7 @@ // List of objects that might depend on this uicontextmenu object std::list m_dependent_obj_list; - OCTINTERP_API void update_beingdeleted (void); + OCTINTERP_API void update_beingdeleted (); }; @@ -5933,13 +5933,13 @@ : base_graphics_object (), m_properties (mh, p) { } - ~uicontextmenu (void) = default; - - base_properties& get_properties (void) { return m_properties; } - - const base_properties& get_properties (void) const { return m_properties; } - - bool valid_object (void) const { return true; } + ~uicontextmenu () = default; + + base_properties& get_properties () { return m_properties; } + + const base_properties& get_properties () const { return m_properties; } + + bool valid_object () const { return true; } bool has_readonly_property (const caseless_str& pname) const { @@ -6008,7 +6008,7 @@ std::string m_cached_units; protected: - void init (void) + void init () { m_cdata.add_constraint ("double"); m_cdata.add_constraint ("single"); @@ -6021,20 +6021,20 @@ m_cached_units = get_units (); } - OCTINTERP_API void update_text_extent (void); - - void update_string (void) { update_text_extent (); } - void update_fontname (void) { update_text_extent (); } - void update_fontsize (void) { update_text_extent (); } - void update_fontangle (void) + OCTINTERP_API void update_text_extent (); + + void update_string () { update_text_extent (); } + void update_fontname () { update_text_extent (); } + void update_fontsize () { update_text_extent (); } + void update_fontangle () { update_text_extent (); } - void update_fontweight (void) { update_text_extent (); } + void update_fontweight () { update_text_extent (); } OCTINTERP_API void update_fontunits (const caseless_str& old_units); - OCTINTERP_API void update_units (void); + OCTINTERP_API void update_units (); }; @@ -6046,13 +6046,13 @@ : base_graphics_object (), m_properties (mh, p) { } - ~uicontrol (void) = default; - - base_properties& get_properties (void) { return m_properties; } - - const base_properties& get_properties (void) const { return m_properties; } - - bool valid_object (void) const { return true; } + ~uicontrol () = default; + + base_properties& get_properties () { return m_properties; } + + const base_properties& get_properties () const { return m_properties; } + + bool valid_object () const { return true; } bool has_readonly_property (const caseless_str& pname) const { @@ -6119,19 +6119,19 @@ END_PROPERTIES protected: - void init (void) + void init () { m_position.add_constraint (dim_vector (1, 4)); m_borderwidth.add_constraint ("min", 0.0, true); m_fontsize.add_constraint ("min", 0.0, false); } - // void update_text_extent (void); - // void update_string (void) { update_text_extent (); } - // void update_fontname (void) { update_text_extent (); } - // void update_fontsize (void) { update_text_extent (); } - // void update_fontangle (void) { update_text_extent (); } - // void update_fontweight (void) { update_fontweight (); } + // void update_text_extent (); + // void update_string () { update_text_extent (); } + // void update_fontname () { update_text_extent (); } + // void update_fontsize () { update_text_extent (); } + // void update_fontangle () { update_text_extent (); } + // void update_fontweight () { update_fontweight (); } OCTINTERP_API void update_units (const caseless_str& old_units); OCTINTERP_API void update_fontunits (const caseless_str& old_units); @@ -6146,13 +6146,13 @@ : base_graphics_object (), m_properties (mh, p) { } - ~uibuttongroup (void) = default; - - base_properties& get_properties (void) { return m_properties; } - - const base_properties& get_properties (void) const { return m_properties; } - - bool valid_object (void) const { return true; } + ~uibuttongroup () = default; + + base_properties& get_properties () { return m_properties; } + + const base_properties& get_properties () const { return m_properties; } + + bool valid_object () const { return true; } bool has_readonly_property (const caseless_str& pname) const { @@ -6211,7 +6211,7 @@ END_PROPERTIES protected: - void init (void) + void init () { m_borderwidth.add_constraint ("min", 0.0, true); m_fontsize.add_constraint ("min", 0.0, false); @@ -6231,13 +6231,13 @@ : base_graphics_object (), m_properties (mh, p) { } - ~uipanel (void) = default; - - base_properties& get_properties (void) { return m_properties; } - - const base_properties& get_properties (void) const { return m_properties; } - - bool valid_object (void) const { return true; } + ~uipanel () = default; + + base_properties& get_properties () { return m_properties; } + + const base_properties& get_properties () const { return m_properties; } + + bool valid_object () const { return true; } bool has_readonly_property (const caseless_str& pname) const { @@ -6303,14 +6303,14 @@ radio_property units S , "normalized|inches|centimeters|points|{pixels}|characters" END_PROPERTIES - OCTINTERP_API Matrix get_extent_matrix (void) const; - - OCTINTERP_API Matrix get_backgroundcolor_rgb (void); - - OCTINTERP_API Matrix get_alternatebackgroundcolor_rgb (void); + OCTINTERP_API Matrix get_extent_matrix () const; + + OCTINTERP_API Matrix get_backgroundcolor_rgb (); + + OCTINTERP_API Matrix get_alternatebackgroundcolor_rgb (); protected: - void init (void) + void init () { m_position.add_constraint (dim_vector (1, 4)); m_extent.add_constraint (dim_vector (1, 4)); @@ -6321,15 +6321,15 @@ OCTINTERP_API void update_units (const caseless_str& old_units); OCTINTERP_API void update_fontunits (const caseless_str& old_units); - void update_table_extent (void) { }; - void update_data (void) { update_table_extent (); } - void update_fontname (void) { update_table_extent (); } - void update_fontsize (void) { update_table_extent (); } - void update_fontangle (void) + void update_table_extent () { }; + void update_data () { update_table_extent (); } + void update_fontname () { update_table_extent (); } + void update_fontsize () { update_table_extent (); } + void update_fontangle () { update_table_extent (); } - void update_fontweight (void) { update_table_extent (); } + void update_fontweight () { update_table_extent (); } }; private: @@ -6340,13 +6340,13 @@ : base_graphics_object (), m_properties (mh, p) { } - ~uitable (void) { } - - base_properties& get_properties (void) { return m_properties; } - - const base_properties& get_properties (void) const { return m_properties; } - - bool valid_object (void) const { return true; } + ~uitable () { } + + base_properties& get_properties () { return m_properties; } + + const base_properties& get_properties () const { return m_properties; } + + bool valid_object () const { return true; } bool has_readonly_property (const caseless_str& pname) const { @@ -6377,7 +6377,7 @@ END_PROPERTIES protected: - void init (void) + void init () { } }; @@ -6389,7 +6389,7 @@ : base_graphics_object (), m_properties (mh, p), m_default_properties () { } - ~uitoolbar (void) = default; + ~uitoolbar () = default; void override_defaults (base_graphics_object& obj) { @@ -6430,23 +6430,23 @@ OCTINTERP_API octave_value get_default (const caseless_str& name) const; - octave_value get_defaults (void) const + octave_value get_defaults () const { return m_default_properties.as_struct ("default"); } - property_list get_defaults_list (void) const + property_list get_defaults_list () const { return m_default_properties; } - base_properties& get_properties (void) { return m_properties; } - - const base_properties& get_properties (void) const { return m_properties; } - - bool valid_object (void) const { return true; } - - OCTINTERP_API void reset_default_properties (void); + base_properties& get_properties () { return m_properties; } + + const base_properties& get_properties () const { return m_properties; } + + bool valid_object () const { return true; } + + OCTINTERP_API void reset_default_properties (); bool has_readonly_property (const caseless_str& pname) const { @@ -6487,7 +6487,7 @@ END_PROPERTIES protected: - void init (void) + void init () { m_cdata.add_constraint ("double"); m_cdata.add_constraint ("single"); @@ -6505,13 +6505,13 @@ : base_graphics_object (), m_properties (mh, p) { } - ~uipushtool (void) = default; - - base_properties& get_properties (void) { return m_properties; } - - const base_properties& get_properties (void) const { return m_properties; } - - bool valid_object (void) const { return true; } + ~uipushtool () = default; + + base_properties& get_properties () { return m_properties; } + + const base_properties& get_properties () const { return m_properties; } + + bool valid_object () const { return true; } bool has_readonly_property (const caseless_str& pname) const { @@ -6553,7 +6553,7 @@ END_PROPERTIES protected: - void init (void) + void init () { m_cdata.add_constraint ("double"); m_cdata.add_constraint ("single"); @@ -6571,13 +6571,13 @@ : base_graphics_object (), m_properties (mh, p) { } - ~uitoggletool (void) = default; - - base_properties& get_properties (void) { return m_properties; } - - const base_properties& get_properties (void) const { return m_properties; } - - bool valid_object (void) const { return true; } + ~uitoggletool () = default; + + base_properties& get_properties () { return m_properties; } + + const base_properties& get_properties () const { return m_properties; } + + bool valid_object () const { return true; } bool has_readonly_property (const caseless_str& pname) const { @@ -6611,7 +6611,7 @@ friend class graphics_event; - base_graphics_event (void) + base_graphics_event () : m_busyaction (QUEUE) { }; @@ -6619,11 +6619,11 @@ : m_busyaction (busyaction) { }; - virtual ~base_graphics_event (void) = default; - - int get_busyaction (void) { return m_busyaction; }; - - virtual void execute (void) = 0; + virtual ~base_graphics_event () = default; + + int get_busyaction () { return m_busyaction; }; + + virtual void execute () = 0; private: int m_busyaction; @@ -6637,17 +6637,17 @@ typedef void (*event_fcn) (void *); - graphics_event (void) = default; + graphics_event () = default; graphics_event (base_graphics_event *new_rep) : m_rep (new_rep) { } graphics_event (const graphics_event&) = default; - ~graphics_event (void) = default; + ~graphics_event () = default; graphics_event& operator = (const graphics_event&) = default; - int get_busyaction (void) + int get_busyaction () { if (ok ()) return m_rep->get_busyaction (); @@ -6655,13 +6655,13 @@ error ("graphics_event::busyaction: invalid graphics_event"); } - void execute (void) + void execute () { if (ok ()) m_rep->execute (); } - bool ok (void) const { return (m_rep != nullptr); } + bool ok () const { return (m_rep != nullptr); } static OCTINTERP_API graphics_event create_callback_event (const graphics_handle& h, @@ -6704,12 +6704,12 @@ OCTINTERP_API int calc_dimensions (const graphics_object& gh); // This function is NOT equivalent to the scripting language function gcf. -OCTINTERP_API graphics_handle gcf (void); +OCTINTERP_API graphics_handle gcf (); // This function is NOT equivalent to the scripting language function gca. -OCTINTERP_API graphics_handle gca (void); - -OCTINTERP_API void close_all_figures (void); +OCTINTERP_API graphics_handle gca (); + +OCTINTERP_API void close_all_figures (); OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/gtk-manager.cc --- a/libinterp/corefcn/gtk-manager.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/gtk-manager.cc Tue Jan 24 17:19:44 2023 -0800 @@ -36,7 +36,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) graphics_toolkit -gtk_manager::get_toolkit (void) const +gtk_manager::get_toolkit () const { graphics_toolkit retval; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/gtk-manager.h --- a/libinterp/corefcn/gtk-manager.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/gtk-manager.h Tue Jan 24 17:19:44 2023 -0800 @@ -45,12 +45,12 @@ gtk_manager (interpreter& interp) : m_interpreter (interp) { } - ~gtk_manager (void) + ~gtk_manager () { unload_all_toolkits (); } - graphics_toolkit get_toolkit (void) const; + graphics_toolkit get_toolkit () const; void register_toolkit (const std::string& name); @@ -76,7 +76,7 @@ return graphics_toolkit (); } - Cell available_toolkits_list (void) const + Cell available_toolkits_list () const { Cell m (1, m_available_toolkits.size ()); @@ -87,7 +87,7 @@ return m; } - Cell loaded_toolkits_list (void) const + Cell loaded_toolkits_list () const { Cell m (1, m_loaded_toolkits.size ()); @@ -98,7 +98,7 @@ return m; } - void unload_all_toolkits (void) + void unload_all_toolkits () { while (! m_loaded_toolkits.empty ()) { @@ -114,7 +114,7 @@ } } - std::string default_toolkit (void) const { return m_dtk; } + std::string default_toolkit () const { return m_dtk; } private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/help.cc --- a/libinterp/corefcn/help.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/help.cc Tue Jan 24 17:19:44 2023 -0800 @@ -320,7 +320,7 @@ return which (name, type); } -string_vector help_system::make_name_list (void) const +string_vector help_system::make_name_list () const { const static string_vector keywords = Fiskeyword ()(0).string_vector_value (); @@ -447,7 +447,7 @@ } } -std::string help_system::init_built_in_docstrings_file (void) +std::string help_system::init_built_in_docstrings_file () { std::string df = sys::env::getenv ("OCTAVE_BUILT_IN_DOCSTRINGS_FILE"); @@ -459,7 +459,7 @@ return df; } -std::string help_system::init_doc_cache_file (void) +std::string help_system::init_doc_cache_file () { std::string def_file = config::prepend_octave_home (OCTAVE_DOC_CACHE_FILE); @@ -468,7 +468,7 @@ return (env_file.empty () ? def_file : env_file); } -std::string help_system::init_info_file (void) +std::string help_system::init_info_file () { std::string std_info_file = config::prepend_octave_home (OCTAVE_INFOFILE); @@ -477,7 +477,7 @@ return (oct_info_file.empty () ? std_info_file : oct_info_file); } -std::string help_system::init_info_program (void) +std::string help_system::init_info_program () { std::string info_prog = sys::env::getenv ("OCTAVE_INFO_PROGRAM"); @@ -487,7 +487,7 @@ return info_prog; } -std::string help_system::init_texi_macros_file (void) +std::string help_system::init_texi_macros_file () { std::string def_file = config::prepend_octave_home (OCTAVE_TEXI_MACROS_FILE); @@ -499,7 +499,7 @@ // Return a vector of all functions from this file, // for use in command line auto-completion. -string_vector help_system::local_functions (void) const +string_vector help_system::local_functions () const { string_vector retval; @@ -725,7 +725,7 @@ // FIXME: It's not likely that this does the right thing now. -string_vector make_name_list (void) +string_vector make_name_list () { help_system& help_sys = __get_help_system__ (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/help.h --- a/libinterp/corefcn/help.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/help.h Tue Jan 24 17:19:44 2023 -0800 @@ -59,7 +59,7 @@ built_in_docstrings_file (const octave_value_list& args, int nargout); std::string - built_in_docstrings_file (void) const { return m_built_in_docstrings_file; } + built_in_docstrings_file () const { return m_built_in_docstrings_file; } std::string built_in_docstrings_file (const std::string& file) { @@ -68,7 +68,7 @@ octave_value doc_cache_file (const octave_value_list& args, int nargout); - std::string doc_cache_file (void) const { return m_doc_cache_file; } + std::string doc_cache_file () const { return m_doc_cache_file; } std::string doc_cache_file (const std::string& file) { @@ -77,7 +77,7 @@ octave_value info_file (const octave_value_list& args, int nargout); - std::string info_file (void) const { return m_info_file; } + std::string info_file () const { return m_info_file; } std::string info_file (const std::string& file) { @@ -86,7 +86,7 @@ octave_value info_program (const octave_value_list& args, int nargout); - std::string info_program (void) const { return m_info_program; } + std::string info_program () const { return m_info_program; } std::string info_program (const std::string& file) { @@ -95,7 +95,7 @@ octave_value makeinfo_program (const octave_value_list& args, int nargout); - std::string makeinfo_program (void) const { return m_makeinfo_program; } + std::string makeinfo_program () const { return m_makeinfo_program; } std::string makeinfo_program (const std::string& file) { @@ -105,7 +105,7 @@ octave_value suppress_verbose_help_message (const octave_value_list& args, int nargout); - bool suppress_verbose_help_message (void) const + bool suppress_verbose_help_message () const { return m_suppress_verbose_help_message; } @@ -117,7 +117,7 @@ octave_value texi_macros_file (const octave_value_list& args, int nargout); - std::string texi_macros_file (void) const { return m_texi_macros_file; } + std::string texi_macros_file () const { return m_texi_macros_file; } std::string texi_macros_file (const std::string& file) { @@ -129,7 +129,7 @@ std::string which (const std::string& name) const; std::string which (const std::string& name, std::string& type) const; - string_vector make_name_list (void) const; + string_vector make_name_list () const; void get_help_text (const std::string& name, std::string& text, std::string& format) const; @@ -169,15 +169,15 @@ // (--texi-macros-file) std::string m_texi_macros_file; - static std::string init_built_in_docstrings_file (void); + static std::string init_built_in_docstrings_file (); - static std::string init_doc_cache_file (void); + static std::string init_doc_cache_file (); - static std::string init_info_file (void); + static std::string init_info_file (); - static std::string init_info_program (void); + static std::string init_info_program (); - static std::string init_texi_macros_file (void); + static std::string init_texi_macros_file (); template T set (T& var, const T& new_val) @@ -187,7 +187,7 @@ return old_val; } - string_vector local_functions (void) const; + string_vector local_functions () const; bool raw_help_from_symbol_table (const std::string& nm, std::string& h, std::string& w, @@ -201,7 +201,7 @@ bool& symbol_found) const; }; -extern string_vector make_name_list (void); +extern string_vector make_name_list (); OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/hook-fcn.h --- a/libinterp/corefcn/hook-fcn.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/hook-fcn.h Tue Jan 24 17:19:44 2023 -0800 @@ -42,15 +42,15 @@ { public: - base_hook_function (void) = default; + base_hook_function () = default; base_hook_function (const base_hook_function&) = default; - virtual ~base_hook_function (void) = default; + virtual ~base_hook_function () = default; - virtual std::string id (void) const { return ""; } + virtual std::string id () const { return ""; } - virtual bool is_valid (void) const { return false; } + virtual bool is_valid () const { return false; } virtual void eval (const octave_value_list&) { } }; @@ -59,7 +59,7 @@ { public: - hook_function (void) + hook_function () { static std::shared_ptr nil_rep (new base_hook_function ()); @@ -70,15 +70,15 @@ hook_function (const octave_value& f, const octave_value& d = octave_value ()); - ~hook_function (void) = default; + ~hook_function () = default; hook_function (const hook_function& hf) = default; hook_function& operator = (const hook_function& hf) = default; - std::string id (void) const { return m_rep->id (); } + std::string id () const { return m_rep->id (); } - bool is_valid (void) const { return m_rep->is_valid (); } + bool is_valid () const { return m_rep->is_valid (); } void eval (const octave_value_list& initial_args) { @@ -100,9 +100,9 @@ void eval (const octave_value_list& initial_args); - std::string id (void) const { return m_name; } + std::string id () const { return m_name; } - bool is_valid (void) const { return is_valid_function (m_name); } + bool is_valid () const { return is_valid_function (m_name); } private: @@ -132,9 +132,9 @@ void eval (const octave_value_list& initial_args); - std::string id (void) const { return m_ident; } + std::string id () const { return m_ident; } - bool is_valid (void) const { return m_valid; } + bool is_valid () const { return m_valid; } private: @@ -156,17 +156,17 @@ typedef map_type::iterator iterator; typedef map_type::const_iterator const_iterator; - hook_function_list (void) = default; + hook_function_list () = default; - ~hook_function_list (void) = default; + ~hook_function_list () = default; hook_function_list (const hook_function_list& lst) = default; hook_function_list& operator = (const hook_function_list& lst) = default; - bool empty (void) const { return m_fcn_map.empty (); } + bool empty () const { return m_fcn_map.empty (); } - void clear (void) { m_fcn_map.clear (); } + void clear () { m_fcn_map.clear (); } void insert (const std::string& id, const hook_function& f) { @@ -183,9 +183,9 @@ return m_fcn_map.find (id); } - iterator end (void) { return m_fcn_map.end (); } + iterator end () { return m_fcn_map.end (); } - const_iterator end (void) const { return m_fcn_map.end (); } + const_iterator end () const { return m_fcn_map.end (); } void erase (iterator p) { m_fcn_map.erase (p); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/input.cc --- a/libinterp/corefcn/input.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/input.cc Tue Jan 24 17:19:44 2023 -0800 @@ -258,7 +258,7 @@ } static bool -is_completing_dirfns (void) +is_completing_dirfns () { static std::string dirfns_commands[] = {"cd", "isfile", "isfolder", "ls"}; static const std::size_t dirfns_commands_length = 4; @@ -385,7 +385,7 @@ return retval; } -static int internal_input_event_hook_fcn (void) +static int internal_input_event_hook_fcn () { octave_quit (); @@ -746,7 +746,7 @@ return retval; } -bool input_system::have_input_event_hooks (void) const +bool input_system::have_input_event_hooks () const { return ! m_input_event_hook_functions.empty (); } @@ -768,12 +768,12 @@ return true; } -void input_system::clear_input_event_hooks (void) +void input_system::clear_input_event_hooks () { m_input_event_hook_functions.clear (); } -void input_system::run_input_event_hooks (void) +void input_system::run_input_event_hooks () { m_input_event_hook_functions.run (); } @@ -888,9 +888,9 @@ std::string get_input (const std::string& prompt, bool& eof); - std::string input_source (void) const { return s_in_src; } + std::string input_source () const { return s_in_src; } - bool input_from_terminal (void) const { return true; } + bool input_from_terminal () const { return true; } private: @@ -917,9 +917,9 @@ std::string get_input (const std::string& prompt, bool& eof); - std::string input_source (void) const { return s_in_src; } + std::string input_source () const { return s_in_src; } - bool input_from_file (void) const { return true; } + bool input_from_file () const { return true; } private: @@ -941,9 +941,9 @@ std::string get_input (const std::string& prompt, bool& eof); - std::string input_source (void) const { return s_in_src; } + std::string input_source () const { return s_in_src; } - bool input_from_eval_string (void) const { return true; } + bool input_from_eval_string () const { return true; } private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/input.h --- a/libinterp/corefcn/input.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/input.h Tue Jan 24 17:19:44 2023 -0800 @@ -66,7 +66,7 @@ octave_value PS1 (const octave_value_list& args, int nargout); - std::string PS1 (void) const { return m_PS1; } + std::string PS1 () const { return m_PS1; } std::string PS1 (const std::string& s) { @@ -79,7 +79,7 @@ octave_value PS2 (const octave_value_list& args, int nargout); - std::string PS2 (void) const { return m_PS2; } + std::string PS2 () const { return m_PS2; } std::string PS2 (const std::string& s) { @@ -90,7 +90,7 @@ void set_PS2 (const std::string& s) { m_PS2 = s; } - std::string last_debugging_command (void) const + std::string last_debugging_command () const { return m_last_debugging_command; } @@ -105,7 +105,7 @@ octave_value completion_append_char (const octave_value_list& args, int nargout); - char completion_append_char (void) const + char completion_append_char () const { return m_completion_append_char; } @@ -121,7 +121,7 @@ octave_value gud_mode (const octave_value_list& args, int nargout); - bool gud_mode (void) const { return m_gud_mode; } + bool gud_mode () const { return m_gud_mode; } bool gud_mode (bool flag) { @@ -134,7 +134,7 @@ octave_value mfile_encoding (const octave_value_list& args, int nargout); - std::string mfile_encoding (void) const { return m_mfile_encoding; } + std::string mfile_encoding () const { return m_mfile_encoding; } std::string mfile_encoding (const std::string& s) { @@ -152,7 +152,7 @@ octave_value auto_repeat_debug_command (const octave_value_list& args, int nargout); - bool auto_repeat_debug_command (void) const + bool auto_repeat_debug_command () const { return m_auto_repeat_debug_command; } @@ -171,15 +171,15 @@ octave_value_list get_user_input (const octave_value_list& args, int nargout); - bool have_input_event_hooks (void) const; + bool have_input_event_hooks () const; void add_input_event_hook (const hook_function& hook_fcn); bool remove_input_event_hook (const std::string& hook_fcn_id); - void clear_input_event_hooks (void); + void clear_input_event_hooks (); - void run_input_event_hooks (void); + void run_input_event_hooks (); private: @@ -233,19 +233,19 @@ : m_interpreter (x.m_interpreter) { } - virtual ~base_reader (void) = default; + virtual ~base_reader () = default; virtual std::string get_input (const std::string& prompt, bool& eof) = 0; - virtual std::string input_source (void) const { return s_in_src; } + virtual std::string input_source () const { return s_in_src; } std::string octave_gets (const std::string& prompt, bool& eof); - virtual bool input_from_terminal (void) const { return false; } + virtual bool input_from_terminal () const { return false; } - virtual bool input_from_file (void) const { return false; } + virtual bool input_from_file () const { return false; } - virtual bool input_from_eval_string (void) const { return false; } + virtual bool input_from_eval_string () const { return false; } protected: @@ -272,29 +272,29 @@ input_reader& operator = (const input_reader& ir) = default; - ~input_reader (void) = default; + ~input_reader () = default; std::string get_input (const std::string& prompt, bool& eof) { return m_rep->get_input (prompt, eof); } - std::string input_source (void) const + std::string input_source () const { return m_rep->input_source (); } - bool input_from_terminal (void) const + bool input_from_terminal () const { return m_rep->input_from_terminal (); } - bool input_from_file (void) const + bool input_from_file () const { return m_rep->input_from_file (); } - bool input_from_eval_string (void) const + bool input_from_eval_string () const { return m_rep->input_from_eval_string (); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/interpreter-private.cc --- a/libinterp/corefcn/interpreter-private.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/interpreter-private.cc Tue Jan 24 17:19:44 2023 -0800 @@ -51,7 +51,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) -interpreter& __get_interpreter__ (void) +interpreter& __get_interpreter__ () { interpreter *interp = interpreter::the_interpreter (); @@ -64,91 +64,91 @@ return *interp; } -dynamic_loader& __get_dynamic_loader__ (void) +dynamic_loader& __get_dynamic_loader__ () { interpreter& interp = __get_interpreter__ (); return interp.get_dynamic_loader (); } -error_system& __get_error_system__ (void) +error_system& __get_error_system__ () { interpreter& interp = __get_interpreter__ (); return interp.get_error_system (); } -gh_manager& __get_gh_manager__ (void) +gh_manager& __get_gh_manager__ () { interpreter& interp = __get_interpreter__ (); return interp.get_gh_manager (); } -help_system& __get_help_system__ (void) +help_system& __get_help_system__ () { interpreter& interp = __get_interpreter__ (); return interp.get_help_system (); } -input_system& __get_input_system__ (void) +input_system& __get_input_system__ () { interpreter& interp = __get_interpreter__ (); return interp.get_input_system (); } -output_system& __get_output_system__ (void) +output_system& __get_output_system__ () { interpreter& interp = __get_interpreter__ (); return interp.get_output_system (); } -load_path& __get_load_path__ (void) +load_path& __get_load_path__ () { interpreter& interp = __get_interpreter__ (); return interp.get_load_path (); } -load_save_system& __get_load_save_system__ (void) +load_save_system& __get_load_save_system__ () { interpreter& interp = __get_interpreter__ (); return interp.get_load_save_system (); } -event_manager& __get_event_manager__ (void) +event_manager& __get_event_manager__ () { interpreter& interp = __get_interpreter__ (); return interp.get_event_manager (); } -type_info& __get_type_info__ (void) +type_info& __get_type_info__ () { interpreter& interp = __get_interpreter__ (); return interp.get_type_info (); } -symbol_table& __get_symbol_table__ (void) +symbol_table& __get_symbol_table__ () { interpreter& interp = __get_interpreter__ (); return interp.get_symbol_table (); } -symbol_scope __get_current_scope__ (void) +symbol_scope __get_current_scope__ () { interpreter& interp = __get_interpreter__ (); return interp.get_current_scope (); } -symbol_scope __require_current_scope__ (void) +symbol_scope __require_current_scope__ () { symbol_scope scope = __get_current_scope__ (); @@ -158,42 +158,42 @@ return scope; } -tree_evaluator& __get_evaluator__ (void) +tree_evaluator& __get_evaluator__ () { interpreter& interp = __get_interpreter__ (); return interp.get_evaluator (); } -bp_table& __get_bp_table__ (void) +bp_table& __get_bp_table__ () { tree_evaluator& tw = __get_evaluator__ (); return tw.get_bp_table (); } -child_list& __get_child_list__ (void) +child_list& __get_child_list__ () { interpreter& interp = __get_interpreter__ (); return interp.get_child_list (); } -cdef_manager& __get_cdef_manager__ (void) +cdef_manager& __get_cdef_manager__ () { interpreter& interp = __get_interpreter__ (); return interp.get_cdef_manager (); } -display_info& __get_display_info__ (void) +display_info& __get_display_info__ () { interpreter& interp = __get_interpreter__ (); return interp.get_display_info (); } -gtk_manager& __get_gtk_manager__ (void) +gtk_manager& __get_gtk_manager__ () { interpreter& interp = __get_interpreter__ (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/interpreter-private.h --- a/libinterp/corefcn/interpreter-private.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/interpreter-private.h Tue Jan 24 17:19:44 2023 -0800 @@ -53,45 +53,45 @@ class tree_evaluator; class type_info; -extern OCTINTERP_API interpreter& __get_interpreter__ (void); +extern OCTINTERP_API interpreter& __get_interpreter__ (); -extern OCTINTERP_API dynamic_loader& __get_dynamic_loader__ (void); +extern OCTINTERP_API dynamic_loader& __get_dynamic_loader__ (); -extern OCTINTERP_API error_system& __get_error_system__ (void); +extern OCTINTERP_API error_system& __get_error_system__ (); -extern OCTINTERP_API gh_manager& __get_gh_manager__ (void); +extern OCTINTERP_API gh_manager& __get_gh_manager__ (); -extern OCTINTERP_API help_system& __get_help_system__ (void); +extern OCTINTERP_API help_system& __get_help_system__ (); -extern OCTINTERP_API input_system& __get_input_system__ (void); +extern OCTINTERP_API input_system& __get_input_system__ (); -extern OCTINTERP_API load_path& __get_load_path__ (void); +extern OCTINTERP_API load_path& __get_load_path__ (); -extern OCTINTERP_API load_save_system& __get_load_save_system__ (void); +extern OCTINTERP_API load_save_system& __get_load_save_system__ (); -extern OCTINTERP_API event_manager& __get_event_manager__ (void); +extern OCTINTERP_API event_manager& __get_event_manager__ (); -extern OCTINTERP_API output_system& __get_output_system__ (void); +extern OCTINTERP_API output_system& __get_output_system__ (); -extern OCTINTERP_API type_info& __get_type_info__ (void); +extern OCTINTERP_API type_info& __get_type_info__ (); -extern OCTINTERP_API symbol_table& __get_symbol_table__ (void); +extern OCTINTERP_API symbol_table& __get_symbol_table__ (); -extern OCTINTERP_API symbol_scope __get_current_scope__ (void); +extern OCTINTERP_API symbol_scope __get_current_scope__ (); -extern OCTINTERP_API symbol_scope __require_current_scope__ (void); +extern OCTINTERP_API symbol_scope __require_current_scope__ (); -extern OCTINTERP_API tree_evaluator& __get_evaluator__ (void); +extern OCTINTERP_API tree_evaluator& __get_evaluator__ (); -extern OCTINTERP_API bp_table& __get_bp_table__ (void); +extern OCTINTERP_API bp_table& __get_bp_table__ (); -extern OCTINTERP_API child_list& __get_child_list__ (void); +extern OCTINTERP_API child_list& __get_child_list__ (); -extern OCTINTERP_API cdef_manager& __get_cdef_manager__ (void); +extern OCTINTERP_API cdef_manager& __get_cdef_manager__ (); -extern OCTINTERP_API display_info& __get_display_info__ (void); +extern OCTINTERP_API display_info& __get_display_info__ (); -extern OCTINTERP_API gtk_manager& __get_gtk_manager__ (void); +extern OCTINTERP_API gtk_manager& __get_gtk_manager__ (); // Functions that could be methods in the interpreter class but maybe // shouldn't be exposed as part of the public interface. diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/interpreter.cc --- a/libinterp/corefcn/interpreter.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/interpreter.cc Tue Jan 24 17:19:44 2023 -0800 @@ -314,7 +314,7 @@ return ovl (interp.traditional ()); } -temporary_file_list::~temporary_file_list (void) +temporary_file_list::~temporary_file_list () { cleanup (); } @@ -324,7 +324,7 @@ m_files.insert (file); } -void temporary_file_list::cleanup (void) +void temporary_file_list::cleanup () { while (! m_files.empty ()) { @@ -339,7 +339,7 @@ // The time we last time we changed directories. sys::time Vlast_chdir_time = 0.0; -static void initialize_version_info (void) +static void initialize_version_info () { octave_value_list args; @@ -351,12 +351,12 @@ F__version_info__ (args, 0); } -static void xerbla_abort (void) +static void xerbla_abort () { error ("Fortran procedure terminated by call to XERBLA"); } -static void initialize_xerbla_error_handler (void) +static void initialize_xerbla_error_handler () { // The idea here is to force xerbla to be referenced so that we will // link to our own version instead of the one provided by the BLAS @@ -368,7 +368,7 @@ if (numeric_limits::NaN () == -1) F77_FUNC (xerbla, XERBLA) ("octave", 13 F77_CHAR_ARG_LEN (6)); - typedef void (*xerbla_handler_ptr) (void); + typedef void (*xerbla_handler_ptr) (); typedef void (*octave_set_xerbla_handler_ptr) (xerbla_handler_ptr); @@ -407,7 +407,7 @@ throw execution_exception (); } -static void initialize_error_handlers (void) +static void initialize_error_handlers () { set_liboctave_error_handler (lo_error_handler); set_liboctave_error_with_id_handler (lo_error_with_id_handler); @@ -625,7 +625,7 @@ OCTAVE_THREAD_LOCAL interpreter *interpreter::m_instance = nullptr; -interpreter::~interpreter (void) +interpreter::~interpreter () { if (! m_app_context) shutdown (); @@ -704,7 +704,7 @@ // This may be called separately from execute -void interpreter::initialize (void) +void interpreter::initialize () { if (m_initialized) return; @@ -757,7 +757,7 @@ // Note: this function is currently only used with the new // experimental terminal widget. -void interpreter::get_line_and_eval (void) +void interpreter::get_line_and_eval () { m_evaluator.get_line_and_eval (); } @@ -776,7 +776,7 @@ cli_input_reader& operator = (const cli_input_reader&) = delete; - ~cli_input_reader (void) + ~cli_input_reader () { // FIXME: Would it be better to ensure that // interpreter::get_line_and_eval exits and then call @@ -785,7 +785,7 @@ m_thread.detach (); } - void start (void) + void start () { m_thread = std::thread (&interpreter::get_line_and_eval, &m_interpreter); } @@ -806,7 +806,7 @@ // FIXME: this function is intended to be executed only once. Should // we enforce that restriction? -int interpreter::execute (void) +int interpreter::execute () { int exit_status = 0; @@ -933,7 +933,7 @@ } \ while (0) -void interpreter::shutdown (void) +void interpreter::shutdown () { // Attempt to prevent more than one call to shutdown. @@ -1043,7 +1043,7 @@ // OCTAVE_SAFE_CALL (singleton_cleanup_list::cleanup, ()); } -void interpreter::execute_atexit_fcns (void) +void interpreter::execute_atexit_fcns () { // Prevent atexit functions from adding new functions to the list. m_executing_atexit = true; @@ -1060,7 +1060,7 @@ } } -void interpreter::display_startup_message (void) const +void interpreter::display_startup_message () const { bool inhibit_startup_message = false; @@ -1079,7 +1079,7 @@ // occurs when reading any of them, but don't exit early because of an // exception. -int interpreter::execute_startup_files (void) +int interpreter::execute_startup_files () { bool read_site_files = m_read_site_files; bool read_init_files = m_read_init_files; @@ -1229,7 +1229,7 @@ // Execute any code specified with --eval 'CODE' -int interpreter::execute_eval_option_code (void) +int interpreter::execute_eval_option_code () { if (! m_app_context) return 0; @@ -1262,7 +1262,7 @@ return parse_status; } -int interpreter::execute_command_line_file (void) +int interpreter::execute_command_line_file () { if (! m_app_context) return 0; @@ -1311,41 +1311,41 @@ return safe_source_file (fname, context, verbose, require_file); } -int interpreter::main_loop (void) +int interpreter::main_loop () { command_editor::add_event_hook (release_unreferenced_dynamic_libraries); return m_evaluator.repl (); } -int interpreter::server_loop (void) +int interpreter::server_loop () { return m_evaluator.server_loop (); } -tree_evaluator& interpreter::get_evaluator (void) +tree_evaluator& interpreter::get_evaluator () { return m_evaluator; } -stream_list& interpreter::get_stream_list (void) +stream_list& interpreter::get_stream_list () { return m_stream_list; } -url_handle_manager& interpreter::get_url_handle_manager (void) +url_handle_manager& interpreter::get_url_handle_manager () { return m_url_handle_manager; } symbol_scope -interpreter::get_top_scope (void) const +interpreter::get_top_scope () const { return m_evaluator.get_top_scope (); } symbol_scope -interpreter::get_current_scope (void) const +interpreter::get_current_scope () const { return m_evaluator.get_current_scope (); } @@ -1361,7 +1361,7 @@ return scope; } -profiler& interpreter::get_profiler (void) +profiler& interpreter::get_profiler () { return m_evaluator.get_profiler (); } @@ -1678,7 +1678,7 @@ m_evaluator.source_file (file_name, context, verbose, require_file); } -bool interpreter::at_top_level (void) const +bool interpreter::at_top_level () const { return m_evaluator.at_top_level (); } @@ -1698,7 +1698,7 @@ m_evaluator.clear_all (force); } -void interpreter::clear_objects (void) +void interpreter::clear_objects () { m_evaluator.clear_objects (); } @@ -1718,7 +1718,7 @@ m_evaluator.clear_variable_regexp (pattern); } -void interpreter::clear_variables (void) +void interpreter::clear_variables () { m_evaluator.clear_variables (); } @@ -1738,7 +1738,7 @@ m_evaluator.clear_global_variable_regexp (pattern); } -void interpreter::clear_global_variables (void) +void interpreter::clear_global_variables () { m_evaluator.clear_global_variables (); } @@ -1778,27 +1778,27 @@ return m_evaluator.clear_symbol_regexp (pat); } -std::list interpreter::global_variable_names (void) +std::list interpreter::global_variable_names () { return m_evaluator.global_variable_names (); } -std::list interpreter::top_level_variable_names (void) +std::list interpreter::top_level_variable_names () { return m_evaluator.top_level_variable_names (); } -std::list interpreter::variable_names (void) +std::list interpreter::variable_names () { return m_evaluator.variable_names (); } -std::list interpreter::user_function_names (void) +std::list interpreter::user_function_names () { return m_symbol_table.user_function_names (); } -std::list interpreter::autoloaded_functions (void) const +std::list interpreter::autoloaded_functions () const { return m_evaluator.autoloaded_functions (); } @@ -1806,7 +1806,7 @@ // May be used to send an interrupt signal to the the interpreter from // another thread (for example, the GUI). -void interpreter::interrupt (void) +void interpreter::interrupt () { static int sigint = 0; static bool first = true; @@ -1834,7 +1834,7 @@ octave_kill_wrapper (pid, sigint); } -void interpreter::pause (void) +void interpreter::pause () { // FIXME: To be reliable, these tree_evaluator functions must be // made thread safe. @@ -1843,7 +1843,7 @@ m_evaluator.reset_debug_state (); } -void interpreter::stop (void) +void interpreter::stop () { // FIXME: To be reliable, these tree_evaluator functions must be // made thread safe. @@ -1854,7 +1854,7 @@ interrupt (); } -void interpreter::resume (void) +void interpreter::resume () { // FIXME: To be reliable, these tree_evaluator functions must be // made thread safe. @@ -1871,7 +1871,7 @@ return m_input_system.PS1 (args, nargout); } -std::string interpreter::PS1 (void) const +std::string interpreter::PS1 () const { return m_input_system.PS1 (); } @@ -1891,7 +1891,7 @@ return m_input_system.PS2 (args, nargout); } -std::string interpreter::PS2 (void) const +std::string interpreter::PS2 () const { return m_input_system.PS2 (); } @@ -1911,7 +1911,7 @@ return m_evaluator.PS4 (args, nargout); } -std::string interpreter::PS4 (void) const +std::string interpreter::PS4 () const { return m_evaluator.PS4 (); } @@ -1928,7 +1928,7 @@ // Provided for convenience. Will be removed once we eliminate the // old terminal widget. -bool interpreter::experimental_terminal_widget (void) const +bool interpreter::experimental_terminal_widget () const { if (! m_app_context) return false; @@ -1949,12 +1949,12 @@ m_evaluator.remove_debug_watch_expression (expr); } -void interpreter::clear_debug_watch_expressions (void) +void interpreter::clear_debug_watch_expressions () { m_evaluator.clear_debug_watch_expressions (); } -std::set interpreter::debug_watch_expressions (void) const +std::set interpreter::debug_watch_expressions () const { return m_evaluator.debug_watch_expressions (); } @@ -1971,7 +1971,7 @@ recover_from_exception (); } -void interpreter::recover_from_exception (void) +void interpreter::recover_from_exception () { if (octave_interrupt_state) m_event_manager.interpreter_interrupted (); @@ -1988,7 +1988,7 @@ m_tmp_files.insert (file); } -void interpreter::cleanup_tmp_files (void) +void interpreter::cleanup_tmp_files () { m_tmp_files.cleanup (); } @@ -2063,7 +2063,7 @@ // What internal options get configured by --traditional. -void interpreter::maximum_braindamage (void) +void interpreter::maximum_braindamage () { PS1 (">> "); PS2 (""); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/interpreter.h --- a/libinterp/corefcn/interpreter.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/interpreter.h Tue Jan 24 17:19:44 2023 -0800 @@ -91,7 +91,7 @@ { public: - temporary_file_list (void) : m_files () { } + temporary_file_list () : m_files () { } // No copying! @@ -99,11 +99,11 @@ temporary_file_list& operator = (const temporary_file_list&) = delete; - ~temporary_file_list (void); + ~temporary_file_list (); void insert (const std::string& file); - void cleanup (void); + void cleanup (); private: @@ -128,7 +128,7 @@ // Clean up the interpreter object. - ~interpreter (void); + ~interpreter (); void intern_nargin (octave_idx_type nargs); @@ -148,12 +148,12 @@ // Load command line history, set the load path. - void initialize (void); + void initialize (); // Note: GET_LINE_AND_EVAL is only used by new experimental terminal // widget. - void get_line_and_eval (void); + void get_line_and_eval (); // Parse a line of input. If input ends at a complete statement // boundary, execute the resulting parse tree. Useful to handle @@ -165,11 +165,11 @@ // call to initialize), execute startup files, --eval option code, // script files, and/or interactive commands. - int execute (void); + int execute (); - bool server_mode (void) const { return m_evaluator.server_mode (); } + bool server_mode () const { return m_evaluator.server_mode (); } - bool interactive (void) const + bool interactive () const { return m_interactive; } @@ -199,7 +199,7 @@ m_traditional = flag; } - bool traditional (void) const + bool traditional () const { return m_traditional; } @@ -209,12 +209,12 @@ m_inhibit_startup_message = flag; } - bool in_top_level_repl (void) const + bool in_top_level_repl () const { return m_evaluator.in_top_level_repl (); } - bool initialized (void) const + bool initialized () const { return m_initialized; } @@ -224,114 +224,114 @@ m_interrupt_all_in_process_group = b; } - bool interrupt_all_in_process_group (void) const + bool interrupt_all_in_process_group () const { return m_interrupt_all_in_process_group; } - application * get_app_context (void) + application * get_app_context () { return m_app_context; } - display_info& get_display_info (void) + display_info& get_display_info () { return m_display_info; } - environment& get_environment (void) + environment& get_environment () { return m_environment; } - settings& get_settings (void) + settings& get_settings () { return m_settings; } - error_system& get_error_system (void) + error_system& get_error_system () { return m_error_system; } - tree_evaluator& get_evaluator (void); + tree_evaluator& get_evaluator (); - help_system& get_help_system (void) + help_system& get_help_system () { return m_help_system; } - input_system& get_input_system (void) + input_system& get_input_system () { return m_input_system; } - output_system& get_output_system (void) + output_system& get_output_system () { return m_output_system; } - history_system& get_history_system (void) + history_system& get_history_system () { return m_history_system; } - dynamic_loader& get_dynamic_loader (void) + dynamic_loader& get_dynamic_loader () { return m_dynamic_loader; } - load_path& get_load_path (void) + load_path& get_load_path () { return m_load_path; } - load_save_system& get_load_save_system (void) + load_save_system& get_load_save_system () { return m_load_save_system; } - type_info& get_type_info (void) + type_info& get_type_info () { return m_type_info; } - symbol_table& get_symbol_table (void) + symbol_table& get_symbol_table () { return m_symbol_table; } - symbol_scope get_top_scope (void) const; - symbol_scope get_current_scope (void) const; + symbol_scope get_top_scope () const; + symbol_scope get_current_scope () const; symbol_scope require_current_scope (const std::string& who) const; - profiler& get_profiler (void); + profiler& get_profiler (); - stream_list& get_stream_list (void); + stream_list& get_stream_list (); - child_list& get_child_list (void) + child_list& get_child_list () { return m_child_list; } - url_handle_manager& get_url_handle_manager (void); + url_handle_manager& get_url_handle_manager (); - cdef_manager& get_cdef_manager (void) + cdef_manager& get_cdef_manager () { return m_cdef_manager; } - gtk_manager& get_gtk_manager (void) + gtk_manager& get_gtk_manager () { return m_gtk_manager; } - event_manager& get_event_manager (void) + event_manager& get_event_manager () { return m_event_manager; } - gh_manager& get_gh_manager (void) + gh_manager& get_gh_manager () { return *m_gh_manager; } @@ -433,7 +433,7 @@ const std::string& context = "", bool verbose = false, bool require_file = true); - bool at_top_level (void) const; + bool at_top_level () const; bool isglobal (const std::string& name) const; @@ -441,7 +441,7 @@ void clear_all (bool force = false); - void clear_objects (void); + void clear_objects (); void clear_variable (const std::string& name); @@ -449,7 +449,7 @@ void clear_variable_regexp (const std::string& pattern); - void clear_variables (void); + void clear_variables (); void clear_global_variable (const std::string& name); @@ -457,7 +457,7 @@ void clear_global_variable_regexp (const std::string& pattern); - void clear_global_variables (void); + void clear_global_variables (); void clear_functions (bool force = false); @@ -473,25 +473,25 @@ void clear_symbol_regexp (const std::string& pat); - std::list variable_names (void); + std::list variable_names (); - std::list top_level_variable_names (void); + std::list top_level_variable_names (); - std::list global_variable_names (void); + std::list global_variable_names (); - std::list user_function_names (void); + std::list user_function_names (); - std::list autoloaded_functions (void) const; + std::list autoloaded_functions () const; - void interrupt (void); + void interrupt (); // Pause interpreter execution at the next available statement and // enter the debugger. - void pause (void); + void pause (); // Exit debugger or stop execution and return to the top-level REPL // or server loop. - void stop (void); + void stop (); // Add EXPR to the set of expressions that may be evaluated when the // debugger stops at a breakpoint. @@ -503,47 +503,47 @@ // Clear the set of expressions that may be evaluated when the // debugger stops at a breakpoint. - void clear_debug_watch_expressions (void); + void clear_debug_watch_expressions (); // Return the set of expressions that may be evaluated when the // debugger stops at a breakpoint. - std::set debug_watch_expressions (void) const; + std::set debug_watch_expressions () const; // Resume interpreter execution if paused. - void resume (void); + void resume (); octave_value PS1 (const octave_value_list& args, int nargout); - std::string PS1 (void) const; + std::string PS1 () const; std::string PS1 (const std::string& s); void set_PS1 (const std::string& s); octave_value PS2 (const octave_value_list& args, int nargout); - std::string PS2 (void) const; + std::string PS2 () const; std::string PS2 (const std::string& s); void set_PS2 (const std::string& s); octave_value PS4 (const octave_value_list& args, int nargout); - std::string PS4 (void) const; + std::string PS4 () const; std::string PS4 (const std::string& s); void set_PS4 (const std::string& s); // Provided for convenience. Will be removed once we eliminate the // old terminal widget. - bool experimental_terminal_widget (void) const; + bool experimental_terminal_widget () const; void handle_exception (const execution_exception& ee); - void recover_from_exception (void); + void recover_from_exception (); void mark_for_deletion (const std::string& file); - void cleanup_tmp_files (void); + void cleanup_tmp_files (); void quit (int exit_status, bool force = false, bool confirm = true); void cancel_quit (bool flag) { m_cancel_quit = flag; } - bool executing_finish_script (void) const + bool executing_finish_script () const { return m_executing_finish_script; } @@ -552,27 +552,27 @@ bool remove_atexit_fcn (const std::string& fname); - static interpreter * the_interpreter (void) { return m_instance; } + static interpreter * the_interpreter () { return m_instance; } private: - void display_startup_message (void) const; + void display_startup_message () const; - int execute_startup_files (void); + int execute_startup_files (); - int execute_eval_option_code (void); + int execute_eval_option_code (); - int execute_command_line_file (void); + int execute_command_line_file (); - int main_loop (void); + int main_loop (); - int server_loop (void); + int server_loop (); - void shutdown (void); + void shutdown (); - void execute_atexit_fcns (void); + void execute_atexit_fcns (); - void maximum_braindamage (void); + void maximum_braindamage (); void execute_pkg_add (const std::string& dir); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/jsondecode.cc --- a/libinterp/corefcn/jsondecode.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/jsondecode.cc Tue Jan 24 17:19:44 2023 -0800 @@ -612,7 +612,7 @@ = use_makeValidName ? new make_valid_name_options (make_valid_name_params) : nullptr; - unwind_action del_opts ([options] (void) { if (options) delete options; }); + unwind_action del_opts ([options] () { if (options) delete options; }); if (! args(0).is_string ()) error ("jsondecode: JSON_TXT must be a character string"); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/latex-text-renderer.cc --- a/libinterp/corefcn/latex-text-renderer.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/latex-text-renderer.cc Tue Jan 24 17:19:44 2023 -0800 @@ -56,7 +56,7 @@ public: - latex_renderer (void) + latex_renderer () : m_fontsize (10.0), m_fontname ("cmr"), m_tmp_dir (), m_color (dim_vector (1, 3), 0), m_latex_binary ("latex"), m_dvipng_binary ("dvipng"), m_dvisvg_binary ("dvisvgm"), @@ -77,7 +77,7 @@ m_debug = ! sys::env::getenv ("OCTAVE_LATEX_DEBUG_FLAG").empty (); } - ~latex_renderer (void) + ~latex_renderer () { if (! m_tmp_dir.empty () && ! m_debug) sys::recursive_rmdir (m_tmp_dir); @@ -144,9 +144,9 @@ void set_anti_aliasing (bool /*val*/) { } - octave_map get_system_fonts (void) { return octave_map (); } + octave_map get_system_fonts () { return octave_map (); } - bool ok (void); + bool ok (); private: @@ -183,7 +183,7 @@ }; bool -latex_renderer::ok (void) +latex_renderer::ok () { // Only run the test once in a session static bool tested = false; @@ -522,7 +522,7 @@ } base_text_renderer * -make_latex_text_renderer (void) +make_latex_text_renderer () { latex_renderer *renderer = new latex_renderer (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/latex-text-renderer.h --- a/libinterp/corefcn/latex-text-renderer.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/latex-text-renderer.h Tue Jan 24 17:19:44 2023 -0800 @@ -32,7 +32,7 @@ class base_text_renderer; -extern base_text_renderer * make_latex_text_renderer (void); +extern base_text_renderer * make_latex_text_renderer (); OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/load-path.cc --- a/libinterp/corefcn/load-path.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/load-path.cc Tue Jan 24 17:19:44 2023 -0800 @@ -278,7 +278,7 @@ } void -load_path::clear (void) +load_path::clear () { m_dir_info_list.clear (); @@ -397,7 +397,7 @@ } void -load_path::update (void) +load_path::update () { // I don't see a better way to do this because we need to // preserve the correct directory ordering for new files that @@ -836,7 +836,7 @@ } string_vector -load_path::dirs (void) const +load_path::dirs () const { std::size_t len = m_dir_info_list.size (); @@ -851,7 +851,7 @@ } std::list -load_path::dir_list (void) const +load_path::dir_list () const { std::list retval; @@ -890,13 +890,13 @@ } string_vector -load_path::fcn_names (void) const +load_path::fcn_names () const { return m_top_level_package.fcn_names (); } std::string -load_path::path (void) const +load_path::path () const { std::string xpath; @@ -964,7 +964,7 @@ execute_pkg_add_or_del (dir, "PKG_DEL"); } -void load_path::rehash (void) +void load_path::rehash () { update (); @@ -1183,7 +1183,7 @@ return; } - unwind_action close_file ([cfile] (void) { fclose (cfile); }); + unwind_action close_file ([cfile] () { fclose (cfile); }); // find line with character encoding and read it bool eof = false; @@ -1388,7 +1388,7 @@ } bool -load_path::dir_info::update (void) +load_path::dir_info::update () { sys::file_stat fs (dir_name); @@ -1482,7 +1482,7 @@ } void -load_path::dir_info::initialize (void) +load_path::dir_info::initialize () { is_relative = ! sys::env::absolute_pathname (dir_name); @@ -1896,7 +1896,7 @@ } string_vector -load_path::package_info::fcn_names (void) const +load_path::package_info::fcn_names () const { std::size_t len = m_fcn_map.size (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/load-path.h --- a/libinterp/corefcn/load-path.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/load-path.h Tue Jan 24 17:19:44 2023 -0800 @@ -55,11 +55,11 @@ load_path& operator = (const load_path&) = delete; - ~load_path (void) = default; + ~load_path () = default; void initialize (bool set_initial_path = false); - void clear (void); + void clear (); void set (const std::string& p, bool warn = false, bool is_init = false); @@ -69,7 +69,7 @@ bool remove (const std::string& dir); - void update (void); + void update (); bool contains_canonical (const std::string& dir_name) const; @@ -159,24 +159,24 @@ string_vector find_all_first_of (const string_vector& files) const; - string_vector dirs (void) const; + string_vector dirs () const; - std::list dir_list (void) const; + std::list dir_list () const; string_vector files (const std::string& dir, bool omit_exts = false) const; - string_vector fcn_names (void) const; + string_vector fcn_names () const; - std::string path (void) const; + std::string path () const; void display (std::ostream& os) const; - std::function get_add_hook (void) + std::function get_add_hook () { return add_hook; } - std::function get_remove_hook (void) + std::function get_remove_hook () { return remove_hook; } @@ -204,14 +204,14 @@ m_command_line_path += directory_path::path_sep_str () + p; } - std::string get_command_line_path (void) const + std::string get_command_line_path () const { return m_command_line_path; } - std::string system_path (void) const { return s_sys_path; } + std::string system_path () const { return s_sys_path; } - void rehash (void); + void rehash (); static const int M_FILE = 1; static const int OCT_FILE = 2; @@ -232,7 +232,7 @@ struct class_info { public: - class_info (void) : method_file_map (), private_file_map () { } + class_info () : method_file_map (), private_file_map () { } class_info (const class_info& ci) : method_file_map (ci.method_file_map), @@ -249,7 +249,7 @@ return *this; } - ~class_info (void) = default; + ~class_info () = default; fcn_file_map_type method_file_map; fcn_file_map_type private_file_map; @@ -270,7 +270,7 @@ // This default constructor is only provided so we can create a // std::map of dir_info objects. You should not use this // constructor for any other purpose. - dir_info (void) = default; + dir_info () = default; dir_info (const std::string& d) : dir_name (d), abs_dir_name (), is_relative (false), @@ -282,11 +282,11 @@ dir_info (const dir_info&) = default; - ~dir_info (void) = default; + ~dir_info () = default; dir_info& operator = (const dir_info&) = default; - bool update (void); + bool update (); std::string dir_name; std::string abs_dir_name; @@ -303,7 +303,7 @@ private: - void initialize (void); + void initialize (); void get_file_list (const std::string& d); @@ -327,7 +327,7 @@ file_info (const file_info& fi) : dir_name (fi.dir_name), types (fi.types) { } - ~file_info (void) = default; + ~file_info () = default; file_info& operator = (const file_info& fi) { @@ -406,7 +406,7 @@ m_private_fcn_map (l.m_private_fcn_map), m_method_map (l.m_method_map) { } - ~package_info (void) = default; + ~package_info () = default; package_info& operator = (const package_info& l) { @@ -440,7 +440,7 @@ void remove (const dir_info& di); - void clear (void) + void clear () { m_dir_list.clear (); @@ -470,7 +470,7 @@ void overloads (const std::string& meth, std::list& l) const; - string_vector fcn_names (void) const; + string_vector fcn_names () const; private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/load-save.cc --- a/libinterp/corefcn/load-save.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/load-save.cc Tue Jan 24 17:19:44 2023 -0800 @@ -268,7 +268,7 @@ #endif } -load_save_system::~load_save_system (void) +load_save_system::~load_save_system () { #if defined (HAVE_HDF5) H5close (); @@ -732,7 +732,7 @@ } } -void load_save_system::dump_octave_core (void) +void load_save_system::dump_octave_core () { if (m_crash_dumps_octave_core) { @@ -1074,7 +1074,7 @@ m_interpreter.install_variable (name, val, global); } -std::string load_save_system::init_save_header_format (void) +std::string load_save_system::init_save_header_format () { return (std::string ("# Created by Octave " OCTAVE_VERSION diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/load-save.h --- a/libinterp/corefcn/load-save.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/load-save.h Tue Jan 24 17:19:44 2023 -0800 @@ -75,7 +75,7 @@ OCTINTERP_API load_save_system (interpreter& interp); - OCTINTERP_API ~load_save_system (void); + OCTINTERP_API ~load_save_system (); load_save_system (const load_save_system&) = delete; @@ -84,7 +84,7 @@ OCTINTERP_API octave_value crash_dumps_octave_core (const octave_value_list& args, int nargout); - bool crash_dumps_octave_core (void) const + bool crash_dumps_octave_core () const { return m_crash_dumps_octave_core; } @@ -97,7 +97,7 @@ octave_value octave_core_file_limit (const octave_value_list& args, int nargout); - double octave_core_file_limit (void) const + double octave_core_file_limit () const { return m_octave_core_file_limit; } @@ -110,7 +110,7 @@ OCTINTERP_API octave_value octave_core_file_name (const octave_value_list& args, int nargout); - std::string octave_core_file_name (void) const + std::string octave_core_file_name () const { return m_octave_core_file_name; } @@ -123,7 +123,7 @@ OCTINTERP_API octave_value save_default_options (const octave_value_list& args, int nargout); - std::string save_default_options (void) const + std::string save_default_options () const { return m_save_default_options; } @@ -136,7 +136,7 @@ OCTINTERP_API octave_value octave_core_file_options (const octave_value_list& args, int nargout); - std::string octave_core_file_options (void) const + std::string octave_core_file_options () const { return m_octave_core_file_options; } @@ -149,7 +149,7 @@ OCTINTERP_API octave_value save_header_format_string (const octave_value_list& args, int nargout); - std::string save_header_format_string (void) const + std::string save_header_format_string () const { return m_save_header_format_string; } @@ -186,7 +186,7 @@ std::ostream& os, const load_save_format& fmt, bool save_as_floats, bool write_header_info); - OCTINTERP_API void dump_octave_core (void); + OCTINTERP_API void dump_octave_core (); OCTINTERP_API octave_value_list load (const octave_value_list& args = octave_value_list (), @@ -252,7 +252,7 @@ install_loaded_variable (const std::string& name, const octave_value& val, bool global, const std::string& /*doc*/); - static OCTINTERP_API std::string init_save_header_format (void); + static OCTINTERP_API std::string init_save_header_format (); static OCTINTERP_API load_save_format get_file_format (std::istream& file, const std::string& filename); @@ -277,14 +277,14 @@ void set_type (load_save_system::format_type type) { m_type = type; } - load_save_system::format_type type (void) const { return m_type; } + load_save_system::format_type type () const { return m_type; } void set_option (load_save_system::format_options option) { m_options |= option; } - int options (void) const { return m_options; } + int options () const { return m_options; } private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/ls-hdf5.cc --- a/libinterp/corefcn/ls-hdf5.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/ls-hdf5.cc Tue Jan 24 17:19:44 2023 -0800 @@ -100,7 +100,7 @@ } void -hdf5_fstreambase::close (void) +hdf5_fstreambase::close () { #if defined (HAVE_HDF5) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/ls-hdf5.h --- a/libinterp/corefcn/ls-hdf5.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/ls-hdf5.h Tue Jan 24 17:19:44 2023 -0800 @@ -56,7 +56,7 @@ OCTINTERP_API hdf5_fstreambase (const char *name, int mode, int /* prot */ = 0); - OCTINTERP_API void close (void); + OCTINTERP_API void close (); OCTINTERP_API void open (const char *name, int mode, int); @@ -101,7 +101,7 @@ struct hdf5_callback_data { public: - hdf5_callback_data (void) + hdf5_callback_data () : name (), global (false), tc (), doc () { } // the following fields are set by hdf5_read_data on successful return: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/mxarray.h --- a/libinterp/corefcn/mxarray.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/mxarray.h Tue Jan 24 17:19:44 2023 -0800 @@ -94,17 +94,17 @@ public: - virtual mxArray_base * dup (void) const = 0; + virtual mxArray_base * dup () const = 0; - virtual mxArray * as_mxArray (void) const { return nullptr; } + virtual mxArray * as_mxArray () const { return nullptr; } - virtual ~mxArray_base (void) = default; + virtual ~mxArray_base () = default; - virtual bool is_octave_value (void) const { return false; } + virtual bool is_octave_value () const { return false; } - virtual int iscell (void) const = 0; + virtual int iscell () const = 0; - virtual int is_char (void) const = 0; + virtual int is_char () const = 0; virtual int is_class (const char *name_arg) const { @@ -118,52 +118,52 @@ return retval; } - virtual int is_complex (void) const = 0; + virtual int is_complex () const = 0; - virtual int is_double (void) const = 0; + virtual int is_double () const = 0; - virtual int is_function_handle (void) const = 0; + virtual int is_function_handle () const = 0; - virtual int is_int16 (void) const = 0; + virtual int is_int16 () const = 0; - virtual int is_int32 (void) const = 0; + virtual int is_int32 () const = 0; - virtual int is_int64 (void) const = 0; + virtual int is_int64 () const = 0; - virtual int is_int8 (void) const = 0; + virtual int is_int8 () const = 0; - virtual int is_logical (void) const = 0; + virtual int is_logical () const = 0; - virtual int is_numeric (void) const = 0; + virtual int is_numeric () const = 0; - virtual int is_single (void) const = 0; + virtual int is_single () const = 0; - virtual int is_sparse (void) const = 0; + virtual int is_sparse () const = 0; - virtual int is_struct (void) const = 0; + virtual int is_struct () const = 0; - virtual int is_uint16 (void) const = 0; + virtual int is_uint16 () const = 0; - virtual int is_uint32 (void) const = 0; + virtual int is_uint32 () const = 0; - virtual int is_uint64 (void) const = 0; + virtual int is_uint64 () const = 0; - virtual int is_uint8 (void) const = 0; + virtual int is_uint8 () const = 0; - virtual int is_logical_scalar (void) const + virtual int is_logical_scalar () const { return is_logical () && get_number_of_elements () == 1; } - virtual int is_logical_scalar_true (void) const = 0; + virtual int is_logical_scalar_true () const = 0; - virtual mwSize get_m (void) const = 0; + virtual mwSize get_m () const = 0; - virtual mwSize get_n (void) const = 0; + virtual mwSize get_n () const = 0; - virtual mwSize * get_dimensions (void) const = 0; + virtual mwSize * get_dimensions () const = 0; - virtual mwSize get_number_of_dimensions (void) const = 0; + virtual mwSize get_number_of_dimensions () const = 0; virtual void set_m (mwSize m) = 0; @@ -171,15 +171,15 @@ virtual int set_dimensions (mwSize *dims_arg, mwSize ndims_arg) = 0; - virtual mwSize get_number_of_elements (void) const = 0; + virtual mwSize get_number_of_elements () const = 0; - virtual int isempty (void) const = 0; + virtual int isempty () const = 0; - virtual bool is_scalar (void) const = 0; + virtual bool is_scalar () const = 0; - virtual mxClassID get_class_id (void) const = 0; + virtual mxClassID get_class_id () const = 0; - virtual const char * get_class_name (void) const = 0; + virtual const char * get_class_name () const = 0; virtual void set_class_name (const char *name_arg) = 0; @@ -207,36 +207,36 @@ virtual void set_cell (mwIndex idx, mxArray *val) = 0; - virtual double get_scalar (void) const = 0; + virtual double get_scalar () const = 0; - virtual void * get_data (void) const = 0; + virtual void * get_data () const = 0; - virtual mxDouble * get_doubles (void) const = 0; - virtual mxSingle * get_singles (void) const = 0; - virtual mxInt8 * get_int8s (void) const = 0; - virtual mxInt16 * get_int16s (void) const = 0; - virtual mxInt32 * get_int32s (void) const = 0; - virtual mxInt64 * get_int64s (void) const = 0; - virtual mxUint8 * get_uint8s (void) const = 0; - virtual mxUint16 * get_uint16s (void) const = 0; - virtual mxUint32 * get_uint32s (void) const = 0; - virtual mxUint64 * get_uint64s (void) const = 0; + virtual mxDouble * get_doubles () const = 0; + virtual mxSingle * get_singles () const = 0; + virtual mxInt8 * get_int8s () const = 0; + virtual mxInt16 * get_int16s () const = 0; + virtual mxInt32 * get_int32s () const = 0; + virtual mxInt64 * get_int64s () const = 0; + virtual mxUint8 * get_uint8s () const = 0; + virtual mxUint16 * get_uint16s () const = 0; + virtual mxUint32 * get_uint32s () const = 0; + virtual mxUint64 * get_uint64s () const = 0; - virtual mxComplexDouble * get_complex_doubles (void) const = 0; - virtual mxComplexSingle * get_complex_singles (void) const = 0; + virtual mxComplexDouble * get_complex_doubles () const = 0; + virtual mxComplexSingle * get_complex_singles () const = 0; #if 0 /* We don't have these yet. */ - virtual mxComplexInt8 * get_complex_int8s (void) const = 0; - virtual mxComplexInt16 * get_complex_int16s (void) const = 0; - virtual mxComplexInt32 * get_complex_int32s (void) const = 0; - virtual mxComplexInt64 * get_complex_int64s (void) const = 0; - virtual mxComplexUint8 * get_complex_uint8s (void) const = 0; - virtual mxComplexUint16 * get_complex_uint16s (void) const = 0; - virtual mxComplexUint32 * get_complex_uint32s (void) const = 0; - virtual mxComplexUint64 * get_complex_uint64s (void) const = 0; + virtual mxComplexInt8 * get_complex_int8s () const = 0; + virtual mxComplexInt16 * get_complex_int16s () const = 0; + virtual mxComplexInt32 * get_complex_int32s () const = 0; + virtual mxComplexInt64 * get_complex_int64s () const = 0; + virtual mxComplexUint8 * get_complex_uint8s () const = 0; + virtual mxComplexUint16 * get_complex_uint16s () const = 0; + virtual mxComplexUint32 * get_complex_uint32s () const = 0; + virtual mxComplexUint64 * get_complex_uint64s () const = 0; #endif - virtual void * get_imag_data (void) const = 0; + virtual void * get_imag_data () const = 0; virtual void set_data (void *pr) = 0; @@ -267,11 +267,11 @@ virtual void set_imag_data (void *pi) = 0; - virtual mwIndex * get_ir (void) const = 0; + virtual mwIndex * get_ir () const = 0; - virtual mwIndex * get_jc (void) const = 0; + virtual mwIndex * get_jc () const = 0; - virtual mwSize get_nzmax (void) const = 0; + virtual mwSize get_nzmax () const = 0; virtual void set_ir (mwIndex *ir) = 0; @@ -288,7 +288,7 @@ virtual void set_field_by_number (mwIndex index, int key_num, mxArray *val) = 0; - virtual int get_number_of_fields (void) const = 0; + virtual int get_number_of_fields () const = 0; virtual const char * get_field_name_by_number (int key_num) const = 0; @@ -296,17 +296,17 @@ virtual int get_string (char *buf, mwSize buflen) const = 0; - virtual char * array_to_string (void) const = 0; + virtual char * array_to_string () const = 0; virtual mwIndex calc_single_subscript (mwSize nsubs, mwIndex *subs) const = 0; - virtual std::size_t get_element_size (void) const = 0; + virtual std::size_t get_element_size () const = 0; - virtual bool mutation_needed (void) const { return false; } + virtual bool mutation_needed () const { return false; } - virtual mxArray * mutate (void) const { return nullptr; } + virtual mxArray * mutate () const { return nullptr; } - virtual octave_value as_octave_value (void) const = 0; + virtual octave_value as_octave_value () const = 0; protected: @@ -377,7 +377,7 @@ OCTINTERP_API mxArray (bool interleaved, mwSize m, mwSize n); - mxArray * dup (void) const + mxArray * dup () const { mxArray *retval = m_rep->as_mxArray (); @@ -399,60 +399,60 @@ mxArray& operator = (const mxArray&) = delete; - OCTINTERP_API ~mxArray (void); + OCTINTERP_API ~mxArray (); - bool is_octave_value (void) const { return m_rep->is_octave_value (); } + bool is_octave_value () const { return m_rep->is_octave_value (); } - int iscell (void) const { return m_rep->iscell (); } + int iscell () const { return m_rep->iscell (); } - int is_char (void) const { return m_rep->is_char (); } + int is_char () const { return m_rep->is_char (); } int is_class (const char *name_arg) const { return m_rep->is_class (name_arg); } - int is_complex (void) const { return m_rep->is_complex (); } + int is_complex () const { return m_rep->is_complex (); } - int is_double (void) const { return m_rep->is_double (); } + int is_double () const { return m_rep->is_double (); } - int is_function_handle (void) const { return m_rep->is_function_handle (); } + int is_function_handle () const { return m_rep->is_function_handle (); } - int is_int16 (void) const { return m_rep->is_int16 (); } + int is_int16 () const { return m_rep->is_int16 (); } - int is_int32 (void) const { return m_rep->is_int32 (); } + int is_int32 () const { return m_rep->is_int32 (); } - int is_int64 (void) const { return m_rep->is_int64 (); } + int is_int64 () const { return m_rep->is_int64 (); } - int is_int8 (void) const { return m_rep->is_int8 (); } + int is_int8 () const { return m_rep->is_int8 (); } - int is_logical (void) const { return m_rep->is_logical (); } + int is_logical () const { return m_rep->is_logical (); } - int is_numeric (void) const { return m_rep->is_numeric (); } + int is_numeric () const { return m_rep->is_numeric (); } - int is_single (void) const { return m_rep->is_single (); } + int is_single () const { return m_rep->is_single (); } - int is_sparse (void) const { return m_rep->is_sparse (); } + int is_sparse () const { return m_rep->is_sparse (); } - int is_struct (void) const { return m_rep->is_struct (); } + int is_struct () const { return m_rep->is_struct (); } - int is_uint16 (void) const { return m_rep->is_uint16 (); } + int is_uint16 () const { return m_rep->is_uint16 (); } - int is_uint32 (void) const { return m_rep->is_uint32 (); } + int is_uint32 () const { return m_rep->is_uint32 (); } - int is_uint64 (void) const { return m_rep->is_uint64 (); } + int is_uint64 () const { return m_rep->is_uint64 (); } - int is_uint8 (void) const { return m_rep->is_uint8 (); } + int is_uint8 () const { return m_rep->is_uint8 (); } - int is_logical_scalar (void) const { return m_rep->is_logical_scalar (); } + int is_logical_scalar () const { return m_rep->is_logical_scalar (); } - int is_logical_scalar_true (void) const + int is_logical_scalar_true () const { return m_rep->is_logical_scalar_true (); } - mwSize get_m (void) const { return m_rep->get_m (); } + mwSize get_m () const { return m_rep->get_m (); } - mwSize get_n (void) const { return m_rep->get_n (); } + mwSize get_n () const { return m_rep->get_n (); } - mwSize * get_dimensions (void) const { return m_rep->get_dimensions (); } + mwSize * get_dimensions () const { return m_rep->get_dimensions (); } - mwSize get_number_of_dimensions (void) const + mwSize get_number_of_dimensions () const { return m_rep->get_number_of_dimensions (); } void set_m (mwSize m) { DO_VOID_MUTABLE_METHOD (set_m (m)); } @@ -462,20 +462,20 @@ int set_dimensions (mwSize *dims_arg, mwSize ndims_arg) { DO_MUTABLE_METHOD (int, set_dimensions (dims_arg, ndims_arg)); } - mwSize get_number_of_elements (void) const + mwSize get_number_of_elements () const { return m_rep->get_number_of_elements (); } - int isempty (void) const { return get_number_of_elements () == 0; } + int isempty () const { return get_number_of_elements () == 0; } - bool is_scalar (void) const { return m_rep->is_scalar (); } + bool is_scalar () const { return m_rep->is_scalar (); } - const char * get_name (void) const { return m_name; } + const char * get_name () const { return m_name; } OCTINTERP_API void set_name (const char *name); - mxClassID get_class_id (void) const { return m_rep->get_class_id (); } + mxClassID get_class_id () const { return m_rep->get_class_id (); } - const char * get_class_name (void) const { return m_rep->get_class_name (); } + const char * get_class_name () const { return m_rep->get_class_name (); } mxArray * get_property (mwIndex idx, const char *pname) const { return m_rep->get_property (idx, pname); } @@ -492,74 +492,74 @@ void set_cell (mwIndex idx, mxArray *val) { DO_VOID_MUTABLE_METHOD (set_cell (idx, val)); } - double get_scalar (void) const { return m_rep->get_scalar (); } + double get_scalar () const { return m_rep->get_scalar (); } - void * get_data (void) const { DO_MUTABLE_METHOD (void *, get_data ()); } + void * get_data () const { DO_MUTABLE_METHOD (void *, get_data ()); } - mxDouble * get_doubles (void) const + mxDouble * get_doubles () const { DO_MUTABLE_METHOD (mxDouble *, get_doubles ()); } - mxSingle * get_singles (void) const + mxSingle * get_singles () const { DO_MUTABLE_METHOD (mxSingle *, get_singles ()); } - mxInt8 * get_int8s (void) const + mxInt8 * get_int8s () const { DO_MUTABLE_METHOD (mxInt8 *, get_int8s ()); } - mxInt16 * get_int16s (void) const + mxInt16 * get_int16s () const { DO_MUTABLE_METHOD (mxInt16 *, get_int16s ()); } - mxInt32 * get_int32s (void) const + mxInt32 * get_int32s () const { DO_MUTABLE_METHOD (mxInt32 *, get_int32s ()); } - mxInt64 * get_int64s (void) const + mxInt64 * get_int64s () const { DO_MUTABLE_METHOD (mxInt64 *, get_int64s ()); } - mxUint8 * get_uint8s (void) const + mxUint8 * get_uint8s () const { DO_MUTABLE_METHOD (mxUint8 *, get_uint8s ()); } - mxUint16 * get_uint16s (void) const + mxUint16 * get_uint16s () const { DO_MUTABLE_METHOD (mxUint16 *, get_uint16s ()); } - mxUint32 * get_uint32s (void) const + mxUint32 * get_uint32s () const { DO_MUTABLE_METHOD (mxUint32 *, get_uint32s ()); } - mxUint64 * get_uint64s (void) const + mxUint64 * get_uint64s () const { DO_MUTABLE_METHOD (mxUint64 *, get_uint64s ()); } - mxComplexDouble * get_complex_doubles (void) const + mxComplexDouble * get_complex_doubles () const { DO_MUTABLE_METHOD (mxComplexDouble *, get_complex_doubles ()); } - mxComplexSingle * get_complex_singles (void) const + mxComplexSingle * get_complex_singles () const { DO_MUTABLE_METHOD (mxComplexSingle *, get_complex_singles ()); } #if 0 /* We don't have these yet. */ - mxComplexInt8 * get_complex_int8s (void) const + mxComplexInt8 * get_complex_int8s () const { DO_MUTABLE_METHOD (mxComplexInt8 *, get_complex_int8s ()); } - mxComplexInt16 * get_complex_int16s (void) const + mxComplexInt16 * get_complex_int16s () const { DO_MUTABLE_METHOD (mxComplexInt16 *, get_complex_int16s ()); } - mxComplexInt32 * get_complex_int32s (void) const + mxComplexInt32 * get_complex_int32s () const { DO_MUTABLE_METHOD (mxComplexInt32 *, get_complex_int32s ()); } - mxComplexInt64 * get_complex_int64s (void) const + mxComplexInt64 * get_complex_int64s () const { DO_MUTABLE_METHOD (mxComplexInt64 *, get_complex_int64s ()); } - mxComplexUint8 * get_complex_uint8s (void) const + mxComplexUint8 * get_complex_uint8s () const { DO_MUTABLE_METHOD (mxComplexUint8 *, get_complex_uint8s ()); } - mxComplexUint16 * get_complex_uint16s (void) const + mxComplexUint16 * get_complex_uint16s () const { DO_MUTABLE_METHOD (mxComplexUint16 *, get_complex_uint16s ()); } - mxComplexUint32 * get_complex_uint32s (void) const + mxComplexUint32 * get_complex_uint32s () const { DO_MUTABLE_METHOD (mxComplexUint32 *, get_complex_uint32s ()); } - mxComplexUint64 * get_complex_uint64s (void) const + mxComplexUint64 * get_complex_uint64s () const { DO_MUTABLE_METHOD (mxComplexUint64 *, get_complex_uint64s ()); } #endif - void * get_imag_data (void) const + void * get_imag_data () const { DO_MUTABLE_METHOD (void *, get_imag_data ()); } void set_data (void *pr) { DO_VOID_MUTABLE_METHOD (set_data (pr)); } @@ -629,11 +629,11 @@ void set_imag_data (void *pi) { DO_VOID_MUTABLE_METHOD (set_imag_data (pi)); } - mwIndex * get_ir (void) const { DO_MUTABLE_METHOD (mwIndex *, get_ir ()); } + mwIndex * get_ir () const { DO_MUTABLE_METHOD (mwIndex *, get_ir ()); } - mwIndex * get_jc (void) const { DO_MUTABLE_METHOD (mwIndex *, get_jc ()); } + mwIndex * get_jc () const { DO_MUTABLE_METHOD (mwIndex *, get_jc ()); } - mwSize get_nzmax (void) const { return m_rep->get_nzmax (); } + mwSize get_nzmax () const { return m_rep->get_nzmax (); } void set_ir (mwIndex *ir) { DO_VOID_MUTABLE_METHOD (set_ir (ir)); } @@ -652,7 +652,7 @@ void set_field_by_number (mwIndex index, int key_num, mxArray *val) { DO_VOID_MUTABLE_METHOD (set_field_by_number (index, key_num, val)); } - int get_number_of_fields (void) const + int get_number_of_fields () const { return m_rep->get_number_of_fields (); } const char * get_field_name_by_number (int key_num) const @@ -664,17 +664,17 @@ int get_string (char *buf, mwSize buflen) const { return m_rep->get_string (buf, buflen); } - char * array_to_string (void) const { return m_rep->array_to_string (); } + char * array_to_string () const { return m_rep->array_to_string (); } mwIndex calc_single_subscript (mwSize nsubs, mwIndex *subs) const { return m_rep->calc_single_subscript (nsubs, subs); } - std::size_t get_element_size (void) const + std::size_t get_element_size () const { return m_rep->get_element_size (); } - bool mutation_needed (void) const { return m_rep->mutation_needed (); } + bool mutation_needed () const { return m_rep->mutation_needed (); } - mxArray * mutate (void) const { return m_rep->mutate (); } + mxArray * mutate () const { return m_rep->mutate (); } static OCTINTERP_API void * malloc (std::size_t n); @@ -702,7 +702,7 @@ static OCTINTERP_API octave_value as_octave_value (const mxArray *ptr, bool null_is_empty = true); - OCTINTERP_API octave_value as_octave_value (void) const; + OCTINTERP_API octave_value as_octave_value () const; private: @@ -740,7 +740,7 @@ create_rep (bool interleaved, mxClassID id, mwSize m, mwSize n, mwSize nzmax, mxComplexity flag); - OCTINTERP_API void maybe_mutate (void) const; + OCTINTERP_API void maybe_mutate () const; //-------- diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-errno.h --- a/libinterp/corefcn/oct-errno.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-errno.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,22 +39,22 @@ { protected: - octave_errno (void); + octave_errno (); public: - ~octave_errno (void) = default; + ~octave_errno () = default; - static bool instance_ok (void); + static bool instance_ok (); - static void cleanup_instance (void) + static void cleanup_instance () { delete s_instance; s_instance = nullptr; } static int lookup (const std::string& name); - static octave_scalar_map list (void); + static octave_scalar_map list (); - static int get (void) { return errno; } + static int get () { return errno; } static int set (int val) { @@ -67,7 +67,7 @@ int do_lookup (const std::string& name); - octave_scalar_map do_list (void); + octave_scalar_map do_list (); //-------- diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-errno.in.cc --- a/libinterp/corefcn/oct-errno.in.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-errno.in.cc Tue Jan 24 17:19:44 2023 -0800 @@ -39,7 +39,7 @@ octave_errno *octave_errno::s_instance = nullptr; -octave_errno::octave_errno (void) +octave_errno::octave_errno () { struct errno_struct { @@ -293,7 +293,7 @@ } bool -octave_errno::instance_ok (void) +octave_errno::instance_ok () { bool retval = true; @@ -313,7 +313,7 @@ } octave_scalar_map -octave_errno::list (void) +octave_errno::list () { return (instance_ok ()) ? s_instance->do_list () : octave_scalar_map (); } @@ -326,7 +326,7 @@ } octave_scalar_map -octave_errno::do_list (void) +octave_errno::do_list () { octave_scalar_map retval; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-fstrm.cc --- a/libinterp/corefcn/oct-fstrm.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-fstrm.cc Tue Jan 24 17:19:44 2023 -0800 @@ -67,7 +67,7 @@ // Return current stream position. off_t -fstream::tell (void) +fstream::tell () { // Note: error is inherited from base_stream, not ::error. // This error function does not halt execution so "return ..." must exist. @@ -78,19 +78,19 @@ // Return nonzero if EOF has been reached on this stream. bool -fstream::eof (void) const +fstream::eof () const { return m_fstream.eof (); } void -fstream::do_close (void) +fstream::do_close () { m_fstream.close (); } std::istream * -fstream::input_stream (void) +fstream::input_stream () { std::istream *retval = nullptr; @@ -101,7 +101,7 @@ } std::ostream * -fstream::output_stream (void) +fstream::output_stream () { std::ostream *retval = nullptr; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-fstrm.h --- a/libinterp/corefcn/oct-fstrm.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-fstrm.h Tue Jan 24 17:19:44 2023 -0800 @@ -61,25 +61,25 @@ // Return current stream position. - off_t tell (void); + off_t tell (); // Return nonzero if EOF has been reached on this stream. - bool eof (void) const; + bool eof () const; - void do_close (void); + void do_close (); // The name of the file. - std::string name (void) const { return m_name; } + std::string name () const { return m_name; } - std::istream * input_stream (void); + std::istream * input_stream (); - std::ostream * output_stream (void); + std::ostream * output_stream (); protected: - ~fstream (void) = default; + ~fstream () = default; private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-handle.h --- a/libinterp/corefcn/oct-handle.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-handle.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,7 +39,7 @@ class octave_handle { public: - octave_handle (void) : m_dval (octave::numeric_limits::NaN ()) { } + octave_handle () : m_dval (octave::numeric_limits::NaN ()) { } octave_handle (const octave_value& a) : m_dval (octave::numeric_limits::NaN ()) @@ -73,23 +73,23 @@ return *this; } - ~octave_handle (void) = default; + ~octave_handle () = default; - double value (void) const { return m_dval; } + double value () const { return m_dval; } - octave_value as_octave_value (void) const + octave_value as_octave_value () const { return ok () ? octave_value (m_dval) : octave_value (Matrix ()); } // Prefix increment/decrement operators. - octave_handle& operator ++ (void) + octave_handle& operator ++ () { ++m_dval; return *this; } - octave_handle& operator -- (void) + octave_handle& operator -- () { --m_dval; return *this; @@ -110,7 +110,7 @@ return old_value; } - bool ok (void) const { return ! octave::math::isnan (m_dval); } + bool ok () const { return ! octave::math::isnan (m_dval); } private: double m_dval; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-hist.cc --- a/libinterp/corefcn/oct-hist.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-hist.cc Tue Jan 24 17:19:44 2023 -0800 @@ -276,7 +276,7 @@ evmgr.set_history (command_history::list ()); } -void history_system::write_timestamp (void) +void history_system::write_timestamp () { sys::localtime now; @@ -524,7 +524,7 @@ source_file (name); } -std::string history_system::default_file (void) +std::string history_system::default_file () { std::string file; @@ -550,7 +550,7 @@ return file; } -int history_system::default_size (void) +int history_system::default_size () { int size = 1000; @@ -567,7 +567,7 @@ return size; } -std::string history_system::default_timestamp_format (void) +std::string history_system::default_timestamp_format () { return "# Octave " OCTAVE_VERSION ", %a %b %d %H:%M:%S %Y %Z <" diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-hist.h --- a/libinterp/corefcn/oct-hist.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-hist.h Tue Jan 24 17:19:44 2023 -0800 @@ -48,16 +48,16 @@ history_system& operator = (const history_system&) = delete; - ~history_system (void) = default; + ~history_system () = default; void initialize (bool read_history_file = false); - void write_timestamp (void); + void write_timestamp (); octave_value input_from_tmp_file (const octave_value_list& args, int nargout); - bool input_from_tmp_file (void) const + bool input_from_tmp_file () const { return m_input_from_tmp_file; } @@ -70,7 +70,7 @@ octave_value timestamp_format_string (const octave_value_list& args, int nargout); - std::string timestamp_format_string (void) const + std::string timestamp_format_string () const { return m_timestamp_format_string; } @@ -99,11 +99,11 @@ // Octave exits. std::string m_timestamp_format_string; - static std::string default_file (void); + static std::string default_file (); - static int default_size (void); + static int default_size (); - static std::string default_timestamp_format (void); + static std::string default_timestamp_format (); template T set (T& var, const T& new_val) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-iostrm.cc --- a/libinterp/corefcn/oct-iostrm.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-iostrm.cc Tue Jan 24 17:19:44 2023 -0800 @@ -47,7 +47,7 @@ // Return current stream position. off_t -base_iostream::tell (void) +base_iostream::tell () { invalid_operation (); return -1; @@ -56,14 +56,14 @@ // Return nonzero if EOF has been reached on this stream. bool -base_iostream::eof (void) const +base_iostream::eof () const { invalid_operation (); return false; } void -base_iostream::invalid_operation (void) const +base_iostream::invalid_operation () const { // Note: use ::error to get error from error.h which halts operation. ::error ("%s: invalid operation", stream_type ()); @@ -72,7 +72,7 @@ // Return nonzero if EOF has been reached on this stream. bool -istream::eof (void) const +istream::eof () const { return m_istream && m_istream->eof (); } @@ -86,7 +86,7 @@ // Return nonzero if EOF has been reached on this stream. bool -ostream::eof (void) const +ostream::eof () const { return m_ostream && m_ostream->eof (); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-iostrm.h --- a/libinterp/corefcn/oct-iostrm.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-iostrm.h Tue Jan 24 17:19:44 2023 -0800 @@ -52,7 +52,7 @@ protected: - ~base_iostream (void) = default; + ~base_iostream () = default; public: @@ -62,25 +62,25 @@ // Return current stream position. - off_t tell (void); + off_t tell (); // Return nonzero if EOF has been reached on this stream. - bool eof (void) const; + bool eof () const; // The name of the file. - std::string name (void) const { return m_name; } + std::string name () const { return m_name; } protected: - void invalid_operation (void) const; + void invalid_operation () const; private: std::string m_name; - virtual const char * stream_type (void) const = 0; + virtual const char * stream_type () const = 0; }; class @@ -98,21 +98,21 @@ // Return nonzero if EOF has been reached on this stream. - bool eof (void) const; + bool eof () const; - std::istream * input_stream (void) { return m_istream; } + std::istream * input_stream () { return m_istream; } - std::ostream * output_stream (void) { return nullptr; } + std::ostream * output_stream () { return nullptr; } protected: - ~istream (void) = default; + ~istream () = default; private: std::istream *m_istream; - const char * stream_type (void) const { return "istream"; } + const char * stream_type () const { return "istream"; } // No copying! @@ -136,21 +136,21 @@ // Return nonzero if EOF has been reached on this stream. - bool eof (void) const; + bool eof () const; - std::istream * input_stream (void) { return nullptr; } + std::istream * input_stream () { return nullptr; } - std::ostream * output_stream (void) { return m_ostream; } + std::ostream * output_stream () { return m_ostream; } protected: - ~ostream (void) = default; + ~ostream () = default; private: std::ostream *m_ostream; - const char * stream_type (void) const { return "ostream"; } + const char * stream_type () const { return "ostream"; } // No copying! diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-map.cc --- a/libinterp/corefcn/oct-map.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-map.cc Tue Jan 24 17:19:44 2023 -0800 @@ -36,7 +36,7 @@ #include "utils.h" octave_fields::fields_rep * -octave_fields::nil_rep (void) +octave_fields::nil_rep () { static fields_rep nr; return &nr; @@ -155,7 +155,7 @@ } string_vector -octave_fields::fieldnames (void) const +octave_fields::fieldnames () const { octave_idx_type n = nfields (); string_vector retval(n); @@ -205,7 +205,7 @@ } octave_scalar_map -octave_scalar_map::orderfields (void) const +octave_scalar_map::orderfields () const { Array perm; return orderfields (perm); @@ -303,7 +303,7 @@ } octave_map -octave_map::orderfields (void) const +octave_map::orderfields () const { Array perm; return orderfields (perm); @@ -439,7 +439,7 @@ } octave_map -octave_map::squeeze (void) const +octave_map::squeeze () const { octave_map retval (*this); octave_idx_type nf = nfields (); @@ -496,7 +496,7 @@ */ octave_map -octave_map::transpose (void) const +octave_map::transpose () const { octave_map retval (m_keys); @@ -1344,7 +1344,7 @@ } void -octave_map::optimize_dimensions (void) +octave_map::optimize_dimensions () { octave_idx_type nf = nfields (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-map.h --- a/libinterp/corefcn/oct-map.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-map.h Tue Jan 24 17:19:44 2023 -0800 @@ -45,7 +45,7 @@ class fields_rep : public std::map { public: - fields_rep (void) : std::map (), m_count (1) { } + fields_rep () : std::map (), m_count (1) { } fields_rep (const fields_rep& other) : std::map (other), m_count (1) { } @@ -57,21 +57,21 @@ fields_rep *m_rep; - static fields_rep * nil_rep (void); + static fields_rep * nil_rep (); public: - octave_fields (void) : m_rep (nil_rep ()) { m_rep->m_count++; } + octave_fields () : m_rep (nil_rep ()) { m_rep->m_count++; } octave_fields (const string_vector&); octave_fields (const char *const *); - ~octave_fields (void) + ~octave_fields () { if (--m_rep->m_count == 0) delete m_rep; } - void make_unique (void) + void make_unique () { if (m_rep->m_count > 1) { @@ -105,11 +105,11 @@ typedef std::map::const_iterator const_iterator; typedef const_iterator iterator; - const_iterator begin (void) const { return m_rep->begin (); } - const_iterator end (void) const { return m_rep->end (); } + const_iterator begin () const { return m_rep->begin (); } + const_iterator end () const { return m_rep->end (); } - const_iterator cbegin (void) const { return m_rep->cbegin (); } - const_iterator cend (void) const { return m_rep->cend (); } + const_iterator cbegin () const { return m_rep->cbegin (); } + const_iterator cend () const { return m_rep->cend (); } std::string key (const_iterator p) const { return p->first; } octave_idx_type index (const_iterator p) const { return p->second; } @@ -120,7 +120,7 @@ // high-level methods. // number of fields. - octave_idx_type nfields (void) const { return m_rep->size (); } + octave_idx_type nfields () const { return m_rep->size (); } // check whether a field exists. bool isfield (const std::string& name) const; @@ -149,9 +149,9 @@ { return m_rep == other.m_rep; } // Returns the fields as a vector of strings. - string_vector fieldnames (void) const; + string_vector fieldnames () const; - void clear (void) + void clear () { *this = octave_fields (); } @@ -165,7 +165,7 @@ octave_scalar_map (const octave_fields& k) : m_keys (k), m_vals (k.nfields ()) { } - octave_scalar_map (void) : m_keys (), m_vals () { } + octave_scalar_map () : m_keys (), m_vals () { } octave_scalar_map (const string_vector& k) : m_keys (k), m_vals (k.numel ()) { } @@ -189,11 +189,11 @@ typedef octave_fields::const_iterator const_iterator; typedef const_iterator iterator; - const_iterator begin (void) const { return m_keys.begin (); } - const_iterator end (void) const { return m_keys.end (); } + const_iterator begin () const { return m_keys.begin (); } + const_iterator end () const { return m_keys.end (); } - const_iterator cbegin (void) const { return m_keys.cbegin (); } - const_iterator cend (void) const { return m_keys.cend (); } + const_iterator cbegin () const { return m_keys.cbegin (); } + const_iterator cend () const { return m_keys.cend (); } const_iterator seek (const std::string& k) const { return m_keys.seek (k); } @@ -215,7 +215,7 @@ { return m_vals[i]; } // number of fields. - octave_idx_type nfields (void) const { return m_keys.nfields (); } + octave_idx_type nfields () const { return m_keys.nfields (); } // check whether a field exists. bool isfield (const std::string& name) const @@ -224,10 +224,10 @@ bool contains (const std::string& name) const { return isfield (name); } - string_vector fieldnames (void) const + string_vector fieldnames () const { return m_keys.fieldnames (); } - string_vector keys (void) const + string_vector keys () const { return fieldnames (); } // get contents of a given field. empty value if not exist. @@ -243,7 +243,7 @@ void del (const std::string& k) { rmfield (k); } // return a copy with fields ordered, optionally along with permutation. - octave_scalar_map orderfields (void) const; + octave_scalar_map orderfields () const; octave_scalar_map orderfields (Array& perm) const; octave_scalar_map orderfields (const octave_scalar_map& other, Array& perm) const; @@ -252,7 +252,7 @@ octave_value contents (const std::string& k) const; octave_value& contents (const std::string& k); - void clear (void) + void clear () { m_keys.clear (); m_vals.clear (); @@ -285,7 +285,7 @@ typedef octave_scalar_map element_type; - octave_map (void) : m_keys (), m_vals (), m_dimensions () { } + octave_map () : m_keys (), m_vals (), m_dimensions () { } octave_map (const dim_vector& dv) : m_keys (), m_vals (), m_dimensions (dv) { } @@ -315,11 +315,11 @@ typedef octave_fields::const_iterator const_iterator; typedef const_iterator iterator; - const_iterator begin (void) const { return m_keys.begin (); } - const_iterator end (void) const { return m_keys.end (); } + const_iterator begin () const { return m_keys.begin (); } + const_iterator end () const { return m_keys.end (); } - const_iterator cbegin (void) const { return m_keys.cbegin (); } - const_iterator cend (void) const { return m_keys.cend (); } + const_iterator cbegin () const { return m_keys.cbegin (); } + const_iterator cend () const { return m_keys.cend (); } const_iterator seek (const std::string& k) const { return m_keys.seek (k); } @@ -341,7 +341,7 @@ { return m_vals[i]; } // number of fields. - octave_idx_type nfields (void) const { return m_keys.nfields (); } + octave_idx_type nfields () const { return m_keys.nfields (); } // check whether a field exists. bool isfield (const std::string& name) const @@ -350,10 +350,10 @@ bool contains (const std::string& name) const { return isfield (name); } - string_vector fieldnames (void) const + string_vector fieldnames () const { return m_keys.fieldnames (); } - string_vector keys (void) const + string_vector keys () const { return fieldnames (); } // get contents of a given field. empty value if not exist. @@ -370,7 +370,7 @@ void del (const std::string& k) { rmfield (k); } // return a copy with fields ordered, optionally along with permutation. - octave_map orderfields (void) const; + octave_map orderfields () const; octave_map orderfields (Array& perm) const; octave_map orderfields (const octave_map& other, Array& perm) const; @@ -379,20 +379,20 @@ Cell contents (const std::string& k) const; Cell& contents (const std::string& k); - void clear (void) + void clear () { m_keys.clear (); m_vals.clear (); } // The Array-like methods. - octave_idx_type numel (void) const { return m_dimensions.numel (); } - octave_idx_type length (void) const { return numel (); } - bool isempty (void) const { return m_dimensions.any_zero (); } + octave_idx_type numel () const { return m_dimensions.numel (); } + octave_idx_type length () const { return numel (); } + bool isempty () const { return m_dimensions.any_zero (); } - octave_idx_type rows (void) const { return m_dimensions(0); } - octave_idx_type cols (void) const { return m_dimensions(1); } - octave_idx_type columns (void) const { return m_dimensions(1); } + octave_idx_type rows () const { return m_dimensions(0); } + octave_idx_type cols () const { return m_dimensions(1); } + octave_idx_type columns () const { return m_dimensions(1); } // Extract a scalar substructure. // FIXME: actually check something. @@ -423,15 +423,15 @@ operator () (const Array& ra_idx) const { return elem (ra_idx); } - octave_map squeeze (void) const; + octave_map squeeze () const; octave_map permute (const Array& vec, bool inv = false) const; - dim_vector dims (void) const { return m_dimensions; } + dim_vector dims () const { return m_dimensions; } - int ndims (void) const { return m_dimensions.ndims (); } + int ndims () const { return m_dimensions.ndims (); } - octave_map transpose (void) const; + octave_map transpose () const; octave_map reshape (const dim_vector& dv) const; @@ -491,7 +491,7 @@ std::vector m_vals; dim_vector m_dimensions; - void optimize_dimensions (void); + void optimize_dimensions (); void extract_scalar (octave_scalar_map& dest, octave_idx_type index) const; static void do_cat (int dim, octave_idx_type n, diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-opengl.h --- a/libinterp/corefcn/oct-opengl.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-opengl.h Tue Jan 24 17:19:44 2023 -0800 @@ -56,13 +56,13 @@ { public: - opengl_functions (void) { } + opengl_functions () { } opengl_functions (const opengl_functions&) = default; opengl_functions& operator = (const opengl_functions&) = default; - virtual ~opengl_functions (void) = default; + virtual ~opengl_functions () = default; #if defined (HAVE_OPENGL) @@ -186,17 +186,17 @@ ::glEnable (cap); } - virtual void glEndList (void) + virtual void glEndList () { ::glEndList (); } - virtual void glEnd (void) + virtual void glEnd () { ::glEnd (); } - virtual void glFinish (void) + virtual void glFinish () { ::glFinish (); } @@ -221,7 +221,7 @@ ::glGetDoublev (pname, data); } - virtual GLenum glGetError (void) + virtual GLenum glGetError () { return ::glGetError (); } @@ -246,7 +246,7 @@ ::glHint (target, mode); } - virtual void glInitNames (void) + virtual void glInitNames () { ::glInitNames (); } @@ -271,7 +271,7 @@ ::glLineWidth (width); } - virtual void glLoadIdentity (void) + virtual void glLoadIdentity () { ::glLoadIdentity (); } @@ -337,17 +337,17 @@ ::glPolygonOffset (factor, units); } - virtual void glPopAttrib (void) + virtual void glPopAttrib () { ::glPopAttrib (); } - virtual void glPopMatrix (void) + virtual void glPopMatrix () { ::glPopMatrix (); } - virtual void glPopName (void) + virtual void glPopName () { ::glPopName (); } @@ -357,7 +357,7 @@ ::glPushAttrib (mask); } - virtual void glPushMatrix (void) + virtual void glPushMatrix () { ::glPushMatrix (); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-prcstrm.cc --- a/libinterp/corefcn/oct-prcstrm.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-prcstrm.cc Tue Jan 24 17:19:44 2023 -0800 @@ -50,7 +50,7 @@ arg_md, ff, encoding, octave::pclose) { } -octave_iprocstream::~octave_iprocstream (void) +octave_iprocstream::~octave_iprocstream () { do_close (); } @@ -71,7 +71,7 @@ arg_md, ff, encoding, octave::pclose) { } -octave_oprocstream::~octave_oprocstream (void) +octave_oprocstream::~octave_oprocstream () { do_close (); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-prcstrm.h --- a/libinterp/corefcn/oct-prcstrm.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-prcstrm.h Tue Jan 24 17:19:44 2023 -0800 @@ -65,7 +65,7 @@ protected: - ~octave_iprocstream (void); + ~octave_iprocstream (); }; class @@ -93,7 +93,7 @@ protected: - ~octave_oprocstream (void); + ~octave_oprocstream (); }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-procbuf.cc --- a/libinterp/corefcn/oct-procbuf.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-procbuf.cc Tue Jan 24 17:19:44 2023 -0800 @@ -182,7 +182,7 @@ } procbuf * -procbuf::close (void) +procbuf::close () { #if defined (__CYGWIN__) || defined (__MINGW32__) || defined (_MSC_VER) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-procbuf.h --- a/libinterp/corefcn/oct-procbuf.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-procbuf.h Tue Jan 24 17:19:44 2023 -0800 @@ -42,7 +42,7 @@ { public: - procbuf (void) + procbuf () : c_file_ptr_buf (nullptr), m_wstatus (-1), m_open_p (false), m_proc_pid (-1), m_next (nullptr) { } @@ -58,17 +58,17 @@ procbuf& operator = (const procbuf&) = delete; - ~procbuf (void) { close (); } + ~procbuf () { close (); } procbuf * open (const char *command, int mode); - procbuf * close (void); + procbuf * close (); - int wait_status (void) const { return m_wstatus; } + int wait_status () const { return m_wstatus; } - bool is_open (void) const { return m_open_p; } + bool is_open () const { return m_open_p; } - pid_t pid (void) const { return m_proc_pid; } + pid_t pid () const { return m_proc_pid; } protected: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-process.h --- a/libinterp/corefcn/oct-process.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-process.h Tue Jan 24 17:19:44 2023 -0800 @@ -37,7 +37,7 @@ { public: - process_execution_result (void) + process_execution_result () : m_status (-1), m_err_msg (), m_exit_status (-1), m_stdout_output () { } @@ -54,13 +54,13 @@ static OCTINTERP_API process_execution_result of_error (int status, const std::string& err_msg); - int status (void) const { return m_status; } + int status () const { return m_status; } - int exit_status (void) const { return m_exit_status; } + int exit_status () const { return m_exit_status; } - std::string err_msg (void) const { return m_err_msg; } + std::string err_msg () const { return m_err_msg; } - std::string stdout_output (void) const { return m_stdout_output; } + std::string stdout_output () const { return m_stdout_output; } private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-stdstrm.h --- a/libinterp/corefcn/oct-stdstrm.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-stdstrm.h Tue Jan 24 17:19:44 2023 -0800 @@ -65,43 +65,43 @@ // Return current stream position. - off_t tell (void) { return m_stream ? m_stream->tell () : -1; } + off_t tell () { return m_stream ? m_stream->tell () : -1; } // Return nonzero if EOF has been reached on this stream. - bool eof (void) const { return m_stream ? m_stream->eof () : true; } + bool eof () const { return m_stream ? m_stream->eof () : true; } // The name of the file. - std::string name (void) const { return m_name; } + std::string name () const { return m_name; } - std::istream * input_stream (void) + std::istream * input_stream () { return (m_mode & std::ios::in) ? m_stream : nullptr; } - std::ostream * output_stream (void) + std::ostream * output_stream () { return (m_mode & std::ios::out) ? m_stream : nullptr; } // FIXME: should not have to cast away const here. - BUF_T * rdbuf (void) const + BUF_T * rdbuf () const { return m_stream ? (const_cast (m_stream))->rdbuf () : nullptr; } - int file_number (void) const { return m_fnum; } + int file_number () const { return m_fnum; } - bool bad (void) const { return m_stream ? m_stream->bad () : true; } + bool bad () const { return m_stream ? m_stream->bad () : true; } - void clear (void) + void clear () { if (m_stream) m_stream->clear (); } - void do_close (void) + void do_close () { if (m_stream) m_stream->stream_close (); @@ -109,7 +109,7 @@ protected: - ~tstdiostream (void) { delete m_stream; } + ~tstdiostream () { delete m_stream; } //-------- @@ -155,7 +155,7 @@ protected: - ~stdiostream (void) = default; + ~stdiostream () = default; }; #if defined (HAVE_ZLIB) @@ -192,7 +192,7 @@ protected: - ~zstdiostream (void) = default; + ~zstdiostream () = default; }; #endif diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-stream.cc --- a/libinterp/corefcn/oct-stream.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-stream.cc Tue Jan 24 17:19:44 2023 -0800 @@ -262,7 +262,7 @@ scanf_format_elt& operator = (const scanf_format_elt&) = default; - ~scanf_format_elt (void) = default; + ~scanf_format_elt () = default; // The C-style format string. std::string text; @@ -297,24 +297,24 @@ scanf_format_list& operator = (const scanf_format_list&) = delete; - ~scanf_format_list (void); - - octave_idx_type num_conversions (void) { return m_nconv; } + ~scanf_format_list (); + + octave_idx_type num_conversions () { return m_nconv; } // The length can be different than the number of conversions. // For example, "x %d y %d z" has 2 conversions but the length of // the list is 3 because of the characters that appear after the // last conversion. - std::size_t length (void) const { return m_fmt_elts.size (); } - - const scanf_format_elt * first (void) + std::size_t length () const { return m_fmt_elts.size (); } + + const scanf_format_elt * first () { m_curr_idx = 0; return current (); } - const scanf_format_elt * current (void) const + const scanf_format_elt * current () const { return length () > 0 ? m_fmt_elts[m_curr_idx] : nullptr; } @@ -337,15 +337,15 @@ return current (); } - void printme (void) const; - - bool ok (void) const { return (m_nconv >= 0); } + void printme () const; + + bool ok () const { return (m_nconv >= 0); } operator bool () const { return ok (); } - bool all_character_conversions (void); - - bool all_numeric_conversions (void); + bool all_character_conversions (); + + bool all_numeric_conversions (); private: @@ -449,7 +449,7 @@ m_buf.str (""); } -scanf_format_list::~scanf_format_list (void) +scanf_format_list::~scanf_format_list () { std::size_t n = m_fmt_elts.size (); @@ -665,7 +665,7 @@ } void -scanf_format_list::printme (void) const +scanf_format_list::printme () const { std::size_t n = m_fmt_elts.size (); @@ -693,7 +693,7 @@ } bool -scanf_format_list::all_character_conversions (void) +scanf_format_list::all_character_conversions () { std::size_t n = m_fmt_elts.size (); @@ -723,7 +723,7 @@ } bool -scanf_format_list::all_numeric_conversions (void) +scanf_format_list::all_numeric_conversions () { std::size_t n = m_fmt_elts.size (); @@ -767,7 +767,7 @@ printf_format_elt& operator = (const printf_format_elt&) = default; - ~printf_format_elt (void) = default; + ~printf_format_elt () = default; // The C-style format string. std::string text; @@ -805,22 +805,22 @@ printf_format_list& operator = (const printf_format_list&) = delete; - ~printf_format_list (void); - - octave_idx_type num_conversions (void) { return m_nconv; } - - const printf_format_elt * first (void) + ~printf_format_list (); + + octave_idx_type num_conversions () { return m_nconv; } + + const printf_format_elt * first () { m_curr_idx = 0; return current (); } - const printf_format_elt * current (void) const + const printf_format_elt * current () const { return length () > 0 ? m_fmt_elts[m_curr_idx] : nullptr; } - std::size_t length (void) const { return m_fmt_elts.size (); } + std::size_t length () const { return m_fmt_elts.size (); } const printf_format_elt * next (bool cycle = true) { @@ -837,11 +837,11 @@ return current (); } - bool last_elt_p (void) { return (m_curr_idx + 1 == length ()); } - - void printme (void) const; - - bool ok (void) const { return (m_nconv >= 0); } + bool last_elt_p () { return (m_curr_idx + 1 == length ()); } + + void printme () const; + + bool ok () const { return (m_nconv >= 0); } operator bool () const { return ok (); } @@ -958,7 +958,7 @@ } } -printf_format_list::~printf_format_list (void) +printf_format_list::~printf_format_list () { std::size_t n = m_fmt_elts.size (); @@ -1160,7 +1160,7 @@ } void -printf_format_list::printme (void) const +printf_format_list::printme () const { std::size_t n = m_fmt_elts.size (); @@ -1198,7 +1198,7 @@ } static Cell -init_inf_nan (void) +init_inf_nan () { Cell retval (dim_vector (1, 2)); @@ -1237,11 +1237,11 @@ delimited_stream& operator = (const delimited_stream&) = delete; - ~delimited_stream (void); + ~delimited_stream (); // Called when optimized sequence of get is finished. Ensures that // there is a remaining delimiter in buf, or loads more data in. - void field_done (void) + void field_done () { if (m_idx >= m_last) refresh_buf (); @@ -1253,7 +1253,7 @@ // Get a character, relying on caller to call field_done if // a delimiter has been reached. - int get (void) + int get () { if (m_delimited) return eof () ? std::istream::traits_type::eof () : *m_idx++; @@ -1262,17 +1262,17 @@ } // Get a character, checking for underrun of the buffer. - int get_undelim (void); + int get_undelim (); // Read character that will be got by the next get. // FIXME: This will not set EOF if delimited stream is at EOF and a peek // is attempted. This does *NOT* behave like C++ input stream. // For a compatible peek function, use peek_undelim. See bug #56917. - int peek (void) + int peek () { return eof () ? std::istream::traits_type::eof () : *m_idx; } // Read character that will be got by the next get. - int peek_undelim (void); + int peek_undelim (); // Undo a 'get' or 'get_undelim'. It is the caller's responsibility // to avoid overflow by calling putbacks only for a character got by @@ -1288,22 +1288,22 @@ // Return a position suitable to "seekg", valid only within this // block between calls to field_done. - char * tellg (void) { return m_idx; } + char * tellg () { return m_idx; } void seekg (char *old_idx) { m_idx = old_idx; } - bool eof (void) + bool eof () { return (m_eob == m_buf + m_overlap && m_i_stream.eof ()) || (m_flags & std::ios_base::eofbit); } - operator const void *(void) + operator const void *() { return (! eof () && ! m_flags) ? this : nullptr; } - bool fail (void) { return m_flags & std::ios_base::failbit; } - - std::ios_base::iostate rdstate (void) { return m_flags; } + bool fail () { return m_flags & std::ios_base::failbit; } + + std::ios_base::iostate rdstate () { return m_flags; } void setstate (std::ios_base::iostate m) { m_flags = m_flags | m; } @@ -1316,14 +1316,14 @@ // Report if any characters have been consumed. // (get, read, etc. not cancelled by putback or seekg) - void progress_benchmark (void) { m_progress_marker = m_idx; } - - bool no_progress (void) { return m_progress_marker == m_idx; } + void progress_benchmark () { m_progress_marker = m_idx; } + + bool no_progress () { return m_progress_marker == m_idx; } // Number of characters remaining until end of stream if it is already // buffered. int_max otherwise. - std::ptrdiff_t remaining (void) + std::ptrdiff_t remaining () { if (m_eob < m_buf + m_bufsize) return m_eob - m_idx; @@ -1398,7 +1398,7 @@ : delimited_stream (is, ds.m_delims, ds.m_longest, ds.m_bufsize) { } -delimited_stream::~delimited_stream (void) +delimited_stream::~delimited_stream () { // Seek to the correct position in i_stream. if (! eof ()) @@ -1415,7 +1415,7 @@ // if necessary. int -delimited_stream::get_undelim (void) +delimited_stream::get_undelim () { int retval; if (eof ()) @@ -1449,7 +1449,7 @@ // pointer, refilling the buffer from the file if necessary. int -delimited_stream::peek_undelim (void) +delimited_stream::peek_undelim () { int retval = get_undelim (); putback (); @@ -1735,24 +1735,24 @@ textscan_format_list& operator = (const textscan_format_list&) = delete; - ~textscan_format_list (void); - - octave_idx_type num_conversions (void) const { return m_nconv; } + ~textscan_format_list (); + + octave_idx_type num_conversions () const { return m_nconv; } // The length can be different than the number of conversions. // For example, "x %d y %d z" has 2 conversions but the length of // the list is 3 because of the characters that appear after the // last conversion. - std::size_t numel (void) const { return m_fmt_elts.size (); } - - const textscan_format_elt * first (void) + std::size_t numel () const { return m_fmt_elts.size (); } + + const textscan_format_elt * first () { m_curr_idx = 0; return current (); } - const textscan_format_elt * current (void) const + const textscan_format_elt * current () const { return numel () > 0 ? m_fmt_elts[m_curr_idx] : nullptr; } @@ -1772,11 +1772,11 @@ return current (); } - void printme (void) const; - - bool ok (void) const { return (m_nconv >= 0); } - - operator const void *(void) const { return ok () ? this : nullptr; } + void printme () const; + + bool ok () const { return (m_nconv >= 0); } + + operator const void *() const { return ok () ? this : nullptr; } // What function name should be shown when reporting errors. std::string who; @@ -1789,7 +1789,7 @@ int read_first_row (delimited_stream& is, textscan& ts); - std::list out_buf (void) const + std::list out_buf () const { return (m_output_container); } private: @@ -1852,7 +1852,7 @@ textscan& operator = (const textscan&) = delete; - ~textscan (void) = default; + ~textscan () = default; octave_value scan (std::istream& isp, const std::string& fmt, octave_idx_type ntimes, @@ -1922,7 +1922,7 @@ { return m_whitespace_table[ch & 0xff]; } // True if the only delimiter is whitespace. - bool whitespace_delim (void) const { return m_delim_table.empty (); } + bool whitespace_delim () const { return m_delim_table.empty (); } //-------- @@ -2088,7 +2088,7 @@ m_buf.str (""); } -textscan_format_list::~textscan_format_list (void) +textscan_format_list::~textscan_format_list () { std::size_t n = numel (); @@ -2474,7 +2474,7 @@ } void -textscan_format_list::printme (void) const +textscan_format_list::printme () const { std::size_t n = numel (); @@ -4084,14 +4084,14 @@ } void -base_stream::clear (void) +base_stream::clear () { m_fail = false; m_errmsg = ""; } void -base_stream::clearerr (void) +base_stream::clearerr () { std::istream *is = input_stream (); std::ostream *os = preferred_output_stream (); @@ -5500,7 +5500,7 @@ // (output streams are those that define os). int -base_stream::flush (void) +base_stream::flush () { int retval = -1; @@ -5546,7 +5546,7 @@ printf_value_cache& operator = (const printf_value_cache&) = delete; - ~printf_value_cache (void) = default; + ~printf_value_cache () = default; // Get the current value as a double and advance the internal pointer. octave_value get_next_value (char type = 0); @@ -5555,16 +5555,16 @@ // pointer. Value before conversion to int must be >= 0 and less // than std::numeric_limits::max (). - int int_value (void); + int int_value (); operator bool () const { return (m_curr_state == ok); } - bool exhausted (void) { return (m_val_idx >= m_n_vals); } + bool exhausted () { return (m_val_idx >= m_n_vals); } private: // Must create value cache with values! - printf_value_cache (void); + printf_value_cache (); //-------- @@ -5694,7 +5694,7 @@ } int -printf_value_cache::int_value (void) +printf_value_cache::int_value () { octave_value val = get_next_value (); @@ -6162,7 +6162,7 @@ } int -stream::flush (void) +stream::flush () { int retval = -1; @@ -6402,7 +6402,7 @@ } off_t -stream::tell (void) +stream::tell () { off_t retval = -1; @@ -6413,13 +6413,13 @@ } int -stream::rewind (void) +stream::rewind () { return seek (0, SEEK_SET); } bool -stream::is_open (void) const +stream::is_open () const { bool retval = false; @@ -6430,7 +6430,7 @@ } void -stream::close (void) +stream::close () { if (stream_ok ()) { @@ -7327,7 +7327,7 @@ } bool -stream::eof (void) const +stream::eof () const { int retval = -1; @@ -7349,7 +7349,7 @@ } std::string -stream::name (void) const +stream::name () const { std::string retval; @@ -7360,7 +7360,7 @@ } int -stream::mode (void) const +stream::mode () const { int retval = 0; @@ -7371,7 +7371,7 @@ } mach_info::float_format -stream::float_format (void) const +stream::float_format () const { mach_info::float_format retval = mach_info::flt_fmt_unknown; @@ -7442,7 +7442,7 @@ m_stderr_file = insert (stderr_stream); } -stream_list::~stream_list (void) +stream_list::~stream_list () { clear (); } @@ -7650,7 +7650,7 @@ return get_info (int_fid); } -std::string stream_list::list_open_files (void) const +std::string stream_list::list_open_files () const { std::ostringstream buf; @@ -7682,7 +7682,7 @@ return buf.str (); } -octave_value stream_list::open_file_numbers (void) const +octave_value stream_list::open_file_numbers () const { Matrix retval (1, m_list.size (), 0.0); @@ -7740,17 +7740,17 @@ return retval; } -octave_value stream_list::stdin_file (void) const +octave_value stream_list::stdin_file () const { return octave_value (m_stdin_file); } -octave_value stream_list::stdout_file (void) const +octave_value stream_list::stdout_file () const { return octave_value (m_stdout_file); } -octave_value stream_list::stderr_file (void) const +octave_value stream_list::stderr_file () const { return octave_value (m_stderr_file); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-stream.h --- a/libinterp/corefcn/oct-stream.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-stream.h Tue Jan 24 17:19:44 2023 -0800 @@ -85,7 +85,7 @@ base_stream& operator = (const base_stream&) = delete; - virtual ~base_stream (void) = default; + virtual ~base_stream () = default; // The remaining functions are not specific to input or output only, // and must be provided by the derived classes. @@ -96,32 +96,32 @@ // Return current stream position. - virtual off_t tell (void) = 0; + virtual off_t tell () = 0; // Return TRUE if EOF has been reached on this stream. - virtual bool eof (void) const = 0; + virtual bool eof () const = 0; // The name of the file. - virtual std::string name (void) const = 0; + virtual std::string name () const = 0; // If the derived class provides this function and it returns a // pointer to a valid istream, scanf(), read(), getl(), and gets() // will automatically work for this stream. - virtual std::istream * input_stream (void) { return nullptr; } + virtual std::istream * input_stream () { return nullptr; } // If the derived class provides this function and it returns a // pointer to a valid ostream, flush(), write(), and printf() will // automatically work for this stream. - virtual std::ostream * output_stream (void) { return nullptr; } + virtual std::ostream * output_stream () { return nullptr; } // Return either the original output stream or one wrapped with the // encoding facet. - std::ostream * preferred_output_stream (void) + std::ostream * preferred_output_stream () { if (! m_encoding.compare ("utf-8")) return output_stream (); @@ -145,11 +145,11 @@ // Return TRUE if this stream is open. - bool is_open (void) const { return m_open_state; } + bool is_open () const { return m_open_state; } - virtual void do_close (void) { } + virtual void do_close () { } - void close (void) + void close () { if (is_open ()) { @@ -158,7 +158,7 @@ } } - virtual int file_number (void) const + virtual int file_number () const { // Kluge alert! @@ -172,7 +172,7 @@ return -1; } - bool ok (void) const { return ! m_fail; } + bool ok () const { return ! m_fail; } // Return current error message for this stream. @@ -180,11 +180,11 @@ protected: - int mode (void) const { return m_mode; } + int mode () const { return m_mode; } - mach_info::float_format float_format (void) const { return m_flt_fmt; } + mach_info::float_format float_format () const { return m_flt_fmt; } - std::string encoding (void) const { return m_encoding; } + std::string encoding () const { return m_encoding; } // Set current error state and set fail to TRUE. @@ -193,11 +193,11 @@ // Clear any error message and set fail to FALSE. - OCTINTERP_API void clear (void); + OCTINTERP_API void clear (); // Clear stream state. - OCTINTERP_API void clearerr (void); + OCTINTERP_API void clearerr (); private: @@ -273,7 +273,7 @@ // Functions that are defined for all output streams (output streams // are those that define os). - OCTINTERP_API int flush (void); + OCTINTERP_API int flush (); OCTINTERP_API int do_numeric_printf_conv (std::ostream& os, const printf_format_elt *elt, @@ -314,9 +314,9 @@ stream& operator = (const stream&) = default; - ~stream (void) = default; + ~stream () = default; - OCTINTERP_API int flush (void); + OCTINTERP_API int flush (); OCTINTERP_API std::string getl (octave_idx_type max_len, bool& err, @@ -346,13 +346,13 @@ OCTINTERP_API int seek (const octave_value& offset, const octave_value& origin); - OCTINTERP_API off_t tell (void); + OCTINTERP_API off_t tell (); - OCTINTERP_API int rewind (void); + OCTINTERP_API int rewind (); - OCTINTERP_API bool is_open (void) const; + OCTINTERP_API bool is_open () const; - OCTINTERP_API void close (void); + OCTINTERP_API void close (); OCTINTERP_API octave_value read (const Array& size, octave_idx_type block_size, @@ -408,7 +408,7 @@ OCTINTERP_API int puts (const octave_value& s, const std::string& who /* = "puts" */); - OCTINTERP_API bool eof (void) const; + OCTINTERP_API bool eof () const; OCTINTERP_API std::string error (bool clear, int& err_num); @@ -428,38 +428,38 @@ void error (const char *msg) { error (std::string (msg)); } - int file_number (void) { return m_rep ? m_rep->file_number () : -1; } + int file_number () { return m_rep ? m_rep->file_number () : -1; } - bool is_valid (void) const { return bool (m_rep); } + bool is_valid () const { return bool (m_rep); } - bool ok (void) const { return m_rep && m_rep->ok (); } + bool ok () const { return m_rep && m_rep->ok (); } operator bool () const { return ok (); } - OCTINTERP_API std::string name (void) const; + OCTINTERP_API std::string name () const; - OCTINTERP_API int mode (void) const; + OCTINTERP_API int mode () const; - OCTINTERP_API mach_info::float_format float_format (void) const; + OCTINTERP_API mach_info::float_format float_format () const; OCTINTERP_API static std::string mode_as_string (int mode); - std::string encoding (void) + std::string encoding () { return m_rep ? m_rep->encoding () : std::string (); } - std::istream * input_stream (void) + std::istream * input_stream () { return m_rep ? m_rep->input_stream () : nullptr; } - std::ostream * output_stream (void) + std::ostream * output_stream () { return (m_rep ? m_rep->preferred_output_stream () : nullptr); } - void clearerr (void) { if (m_rep) m_rep->clearerr (); } + void clearerr () { if (m_rep) m_rep->clearerr (); } private: @@ -508,7 +508,7 @@ stream_list (const stream_list&) = delete; stream_list& operator = (const stream_list&) = delete; - OCTINTERP_API ~stream_list (void); + OCTINTERP_API ~stream_list (); OCTINTERP_API int insert (stream& os); @@ -525,15 +525,15 @@ OCTINTERP_API string_vector get_info (int fid) const; OCTINTERP_API string_vector get_info (const octave_value& fid) const; - OCTINTERP_API std::string list_open_files (void) const; + OCTINTERP_API std::string list_open_files () const; - OCTINTERP_API octave_value open_file_numbers (void) const; + OCTINTERP_API octave_value open_file_numbers () const; OCTINTERP_API int get_file_number (const octave_value& fid) const; - OCTINTERP_API octave_value stdin_file (void) const; - OCTINTERP_API octave_value stdout_file (void) const; - OCTINTERP_API octave_value stderr_file (void) const; + OCTINTERP_API octave_value stdin_file () const; + OCTINTERP_API octave_value stdout_file () const; + OCTINTERP_API octave_value stderr_file () const; private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-strstrm.cc --- a/libinterp/corefcn/oct-strstrm.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-strstrm.cc Tue Jan 24 17:19:44 2023 -0800 @@ -45,7 +45,7 @@ // Return current stream position. off_t -base_strstream::tell (void) +base_strstream::tell () { // Note: error is inherited from base_stream, not ::error. // This error function does not halt execution so "return ..." must exist. diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-strstrm.h --- a/libinterp/corefcn/oct-strstrm.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-strstrm.h Tue Jan 24 17:19:44 2023 -0800 @@ -54,7 +54,7 @@ protected: - ~base_strstream (void) = default; + ~base_strstream () = default; public: @@ -64,17 +64,17 @@ // Return current stream position. - virtual off_t tell (void); + virtual off_t tell (); // The name of the file. - std::string name (void) const { return ""; } + std::string name () const { return ""; } - virtual std::streambuf * rdbuf (void) = 0; + virtual std::streambuf * rdbuf () = 0; - virtual bool bad (void) const = 0; + virtual bool bad () const = 0; - virtual void clear (void) = 0; + virtual void clear () = 0; }; class @@ -102,7 +102,7 @@ protected: - ~istrstream (void) = default; + ~istrstream () = default; public: @@ -119,22 +119,22 @@ // Return nonzero if EOF has been reached on this stream. - bool eof (void) const { return m_istream.eof (); } + bool eof () const { return m_istream.eof (); } - std::istream * input_stream (void) { return &m_istream; } + std::istream * input_stream () { return &m_istream; } - std::ostream * output_stream (void) { return nullptr; } + std::ostream * output_stream () { return nullptr; } - off_t tell (void) { return m_istream.tellg (); } + off_t tell () { return m_istream.tellg (); } - std::streambuf * rdbuf (void) + std::streambuf * rdbuf () { return m_istream ? m_istream.rdbuf () : nullptr; } - bool bad (void) const { return m_istream.bad (); } + bool bad () const { return m_istream.bad (); } - void clear (void) { m_istream.clear (); } + void clear () { m_istream.clear (); } private: @@ -159,7 +159,7 @@ protected: - ~ostrstream (void) = default; + ~ostrstream () = default; public: @@ -170,22 +170,22 @@ // Return nonzero if EOF has been reached on this stream. - bool eof (void) const { return m_ostream.eof (); } + bool eof () const { return m_ostream.eof (); } - std::istream * input_stream (void) { return nullptr; } + std::istream * input_stream () { return nullptr; } - std::ostream * output_stream (void) { return &m_ostream; } + std::ostream * output_stream () { return &m_ostream; } - std::string str (void) { return m_ostream.str (); } + std::string str () { return m_ostream.str (); } - std::streambuf * rdbuf (void) + std::streambuf * rdbuf () { return m_ostream ? m_ostream.rdbuf () : nullptr; } - bool bad (void) const { return m_ostream.bad (); } + bool bad () const { return m_ostream.bad (); } - void clear (void) { m_ostream.clear (); } + void clear () { m_ostream.clear (); } private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/oct-tex-lexer.in.ll --- a/libinterp/corefcn/oct-tex-lexer.in.ll Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/oct-tex-lexer.in.ll Tue Jan 24 17:19:44 2023 -0800 @@ -237,7 +237,7 @@ return (m_scanner && m_buffer_state); } - void text_parser_tex::destroy_lexer (void) + void text_parser_tex::destroy_lexer () { if (m_buffer_state) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/pager.cc --- a/libinterp/corefcn/pager.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/pager.cc Tue Jan 24 17:19:44 2023 -0800 @@ -114,7 +114,7 @@ return false; } -static std::string default_pager (void) +static std::string default_pager () { std::string pager_binary = sys::env::getenv ("PAGER"); @@ -125,7 +125,7 @@ } int -pager_buf::sync (void) +pager_buf::sync () { output_system& output_sys = __get_output_system__ (); @@ -144,7 +144,7 @@ } void -pager_buf::flush_current_contents_to_diary (void) +pager_buf::flush_current_contents_to_diary () { char *buf = pbase () + m_diary_skip; @@ -156,13 +156,13 @@ } void -pager_buf::set_diary_skip (void) +pager_buf::set_diary_skip () { m_diary_skip = pptr () - pbase (); } int -diary_buf::sync (void) +diary_buf::sync () { output_system& output_sys = __get_output_system__ (); @@ -183,31 +183,31 @@ return 0; } -pager_stream::pager_stream (void) : std::ostream (nullptr), m_pb (nullptr) +pager_stream::pager_stream () : std::ostream (nullptr), m_pb (nullptr) { m_pb = new pager_buf (); rdbuf (m_pb); setf (unitbuf); } -pager_stream::~pager_stream (void) +pager_stream::~pager_stream () { flush (); delete m_pb; } -std::ostream& pager_stream::stream (void) +std::ostream& pager_stream::stream () { return *this; } -void pager_stream::flush_current_contents_to_diary (void) +void pager_stream::flush_current_contents_to_diary () { if (m_pb) m_pb->flush_current_contents_to_diary (); } -void pager_stream::set_diary_skip (void) +void pager_stream::set_diary_skip () { if (m_pb) m_pb->set_diary_skip (); @@ -218,7 +218,7 @@ // called when the pager is not in use. For example, just before // getting command-line input. -void pager_stream::reset (void) +void pager_stream::reset () { delete m_pb; m_pb = new pager_buf (); @@ -226,20 +226,20 @@ setf (unitbuf); } -diary_stream::diary_stream (void) : std::ostream (nullptr), m_db (nullptr) +diary_stream::diary_stream () : std::ostream (nullptr), m_db (nullptr) { m_db = new diary_buf (); rdbuf (m_db); setf (unitbuf); } -diary_stream::~diary_stream (void) +diary_stream::~diary_stream () { flush (); delete m_db; } -std::ostream& diary_stream::stream (void) +std::ostream& diary_stream::stream () { return *this; } @@ -249,7 +249,7 @@ // called when the pager is not in use. For example, just before // getting command-line input. -void diary_stream::reset (void) +void diary_stream::reset () { delete m_db; m_db = new diary_buf (); @@ -257,7 +257,7 @@ setf (unitbuf); } -void flush_stdout (void) +void flush_stdout () { output_system& output_sys = __get_output_system__ (); @@ -302,7 +302,7 @@ "page_screen_output"); } -std::string output_system::pager_command (void) const +std::string output_system::pager_command () const { std::string cmd = m_PAGER; @@ -312,7 +312,7 @@ return cmd; } -void output_system::reset (void) +void output_system::reset () { flush_stdout (); @@ -320,7 +320,7 @@ m_diary_stream.reset (); } -void output_system::flush_stdout (void) +void output_system::flush_stdout () { if (! m_flushing_output_to_pager) { @@ -338,7 +338,7 @@ } } -void output_system::close_diary (void) +void output_system::close_diary () { // Try to flush the current buffer to the diary now, so that things // like @@ -360,7 +360,7 @@ } } -void output_system::open_diary (void) +void output_system::open_diary () { close_diary (); @@ -406,7 +406,7 @@ return false; } -void output_system::clear_external_pager (void) +void output_system::clear_external_pager () { if (m_external_pager) { @@ -419,7 +419,7 @@ } } -void output_system::start_external_pager (void) +void output_system::start_external_pager () { if (m_external_pager) return; @@ -489,14 +489,14 @@ } } -std::ostream& __stdout__ (void) +std::ostream& __stdout__ () { output_system& output_sys = __get_output_system__ (); return output_sys.__stdout__ (); } -std::ostream& __diary__ (void) +std::ostream& __diary__ () { output_system& output_sys = __get_output_system__ (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/pager.h --- a/libinterp/corefcn/pager.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/pager.h Tue Jan 24 17:19:44 2023 -0800 @@ -47,15 +47,15 @@ { public: - pager_buf (void) : std::stringbuf (), m_diary_skip (0) { } + pager_buf () : std::stringbuf (), m_diary_skip (0) { } - void flush_current_contents_to_diary (void); + void flush_current_contents_to_diary (); - void set_diary_skip (void); + void set_diary_skip (); protected: - int sync (void); + int sync (); private: @@ -68,7 +68,7 @@ { public: - pager_stream (void); + pager_stream (); // No copying! @@ -76,15 +76,15 @@ pager_stream& operator = (const pager_stream&) = delete; - ~pager_stream (void); + ~pager_stream (); - void flush_current_contents_to_diary (void); + void flush_current_contents_to_diary (); - void set_diary_skip (void); + void set_diary_skip (); - std::ostream& stream (void); + std::ostream& stream (); - void reset (void); + void reset (); private: @@ -97,11 +97,11 @@ { public: - diary_buf (void) : std::stringbuf () { } + diary_buf () : std::stringbuf () { } protected: - int sync (void); + int sync (); }; class @@ -110,7 +110,7 @@ { public: - diary_stream (void); + diary_stream (); // No copying! @@ -118,18 +118,18 @@ diary_stream& operator = (const diary_stream&) = delete; - ~diary_stream (void); + ~diary_stream (); - std::ostream& stream (void); + std::ostream& stream (); - void reset (void); + void reset (); private: diary_buf *m_db; }; -extern OCTINTERP_API void flush_stdout (void); +extern OCTINTERP_API void flush_stdout (); class output_system { @@ -141,13 +141,13 @@ output_system& operator = (const output_system&) = delete; - ~output_system (void) = default; + ~output_system () = default; - pager_stream& pager (void) { return m_pager_stream; } + pager_stream& pager () { return m_pager_stream; } - diary_stream& diary (void) { return m_diary_stream; } + diary_stream& diary () { return m_diary_stream; } - std::string diary_file_name (void) const { return m_diary_file_name; } + std::string diary_file_name () const { return m_diary_file_name; } std::string diary_file_name (const std::string& nm) { @@ -158,7 +158,7 @@ octave_value PAGER (const octave_value_list& args, int nargout); - std::string PAGER (void) const { return m_PAGER; } + std::string PAGER () const { return m_PAGER; } std::string PAGER (const std::string& s) { @@ -169,7 +169,7 @@ octave_value PAGER_FLAGS (const octave_value_list& args, int nargout); - std::string PAGER_FLAGS (void) const { return m_PAGER_FLAGS; } + std::string PAGER_FLAGS () const { return m_PAGER_FLAGS; } std::string PAGER_FLAGS (const std::string& s) { @@ -181,7 +181,7 @@ octave_value page_output_immediately (const octave_value_list& args, int nargout); - bool page_output_immediately (void) const + bool page_output_immediately () const { return m_page_output_immediately; } @@ -196,7 +196,7 @@ octave_value page_screen_output (const octave_value_list& args, int nargout); - bool page_screen_output (void) const { return m_page_screen_output; } + bool page_screen_output () const { return m_page_screen_output; } bool page_screen_output (bool flag) { @@ -205,7 +205,7 @@ return val; } - bool write_to_diary_file (void) const + bool write_to_diary_file () const { return m_write_to_diary_file; } @@ -217,7 +217,7 @@ return val; } - bool really_flush_to_pager (void) const + bool really_flush_to_pager () const { return m_really_flush_to_pager; } @@ -229,7 +229,7 @@ return val; } - bool flushing_output_to_pager (void) const + bool flushing_output_to_pager () const { return m_flushing_output_to_pager; } @@ -241,25 +241,25 @@ return val; } - std::string pager_command (void) const; + std::string pager_command () const; - std::ofstream& external_diary_file (void) { return m_external_diary_file; } + std::ofstream& external_diary_file () { return m_external_diary_file; } - void reset (void); + void reset (); - void flush_stdout (void); + void flush_stdout (); bool sync (const char *msg, int len); - void clear_external_pager (void); + void clear_external_pager (); - void open_diary (void); + void open_diary (); - void close_diary (void); + void close_diary (); - std::ostream& __stdout__ (void) { return m_pager_stream.stream (); } + std::ostream& __stdout__ () { return m_pager_stream.stream (); } - std::ostream& __diary__ (void) { return m_diary_stream.stream (); } + std::ostream& __diary__ () { return m_diary_stream.stream (); } private: @@ -300,14 +300,14 @@ bool m_flushing_output_to_pager; - void start_external_pager (void); + void start_external_pager (); void do_sync (const char *msg, int len, bool bypass_pager); }; -extern OCTINTERP_API std::ostream& __stdout__ (void); +extern OCTINTERP_API std::ostream& __stdout__ (); -extern OCTINTERP_API std::ostream& __diary__ (void); +extern OCTINTERP_API std::ostream& __diary__ (); OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/pr-flt-fmt.cc --- a/libinterp/corefcn/pr-flt-fmt.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/pr-flt-fmt.cc Tue Jan 24 17:19:44 2023 -0800 @@ -37,7 +37,7 @@ static int Voutput_precision = 5; int -output_precision (void) +output_precision () { return Voutput_precision; } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/pr-flt-fmt.h --- a/libinterp/corefcn/pr-flt-fmt.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/pr-flt-fmt.h Tue Jan 24 17:19:44 2023 -0800 @@ -40,7 +40,7 @@ template class pr_rational_float; -extern OCTINTERP_API int output_precision (void); +extern OCTINTERP_API int output_precision (); extern OCTINTERP_API void set_output_prec (int prec); @@ -60,33 +60,33 @@ float_format& operator = (const float_format&) = default; - ~float_format (void) = default; + ~float_format () = default; - float_format& scientific (void) + float_format& scientific () { m_fmt = std::ios::scientific; return *this; } - float_format& fixed (void) + float_format& fixed () { m_fmt = std::ios::fixed; return *this; } - float_format& general (void) + float_format& general () { m_fmt = 0; return *this; } - float_format& uppercase (void) + float_format& uppercase () { m_up = std::ios::uppercase; return *this; } - float_format& lowercase (void) + float_format& lowercase () { m_up = 0; return *this; @@ -117,57 +117,57 @@ return *this; } - std::ios::fmtflags format_flags (void) const + std::ios::fmtflags format_flags () const { return static_cast (m_fmt | m_up | m_sp); } - int format (void) const + int format () const { return m_fmt; } - bool is_scientific (void) const + bool is_scientific () const { return m_fmt == std::ios::scientific; } - bool is_fixed (void) const + bool is_fixed () const { return m_fmt == std::ios::fixed; } - bool is_general (void) const + bool is_general () const { return m_fmt == 0; } - bool is_uppercase (void) const + bool is_uppercase () const { return m_up == std::ios::uppercase; } - bool is_lowercase (void) const + bool is_lowercase () const { return m_up == 0; } - int precision (void) const + int precision () const { return m_prec; } - int width (void) const + int width () const { return m_fw; } - int exponent_width (void) const + int exponent_width () const { return m_ex; } - bool show_trailing_zeros (void) const + bool show_trailing_zeros () const { return m_sp == std::ios::showpoint; } @@ -211,7 +211,7 @@ { public: - float_display_format (void) = default; + float_display_format () = default; float_display_format (double scale, const float_format& real_fmt, const float_format& imag_fmt = float_format ()) @@ -227,13 +227,13 @@ float_display_format& operator = (const float_display_format&) = default; - ~float_display_format (void) = default; + ~float_display_format () = default; - double scale_factor (void) const { return m_scale; } + double scale_factor () const { return m_scale; } - float_format real_format (void) const { return m_real_fmt; } + float_format real_format () const { return m_real_fmt; } - float_format imag_format (void) const { return m_imag_fmt; } + float_format imag_format () const { return m_imag_fmt; } void set_precision (int prec) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/pr-output.cc --- a/libinterp/corefcn/pr-output.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/pr-output.cc Tue Jan 24 17:19:44 2023 -0800 @@ -170,14 +170,14 @@ template int -pr_engineering_float::exponent (void) const +pr_engineering_float::exponent () const { return engineering_exponent (m_val); } template T -pr_engineering_float::mantissa (void) const +pr_engineering_float::mantissa () const { return m_val / std::pow (static_cast (10), exponent ()); } @@ -3558,7 +3558,7 @@ */ static inline void -init_format_state (void) +init_format_state () { free_format = false; plus_format = false; @@ -3606,7 +3606,7 @@ frame.protect_var (Vcompact_format); frame.protect_var (uppercase_format); int prec = output_precision (); - frame.add ([=] (void) { set_output_prec (prec); }); + frame.add ([=] () { set_output_prec (prec); }); format = format_string; // Initialize with existing value while (argc-- > 0) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/pr-output.h --- a/libinterp/corefcn/pr-output.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/pr-output.h Tue Jan 24 17:19:44 2023 -0800 @@ -517,9 +517,9 @@ T m_val; - int exponent (void) const; + int exponent () const; - T mantissa (void) const; + T mantissa () const; pr_engineering_float (const float_format& ff, T val) : m_ff (ff), m_val (val) { } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/procstream.cc --- a/libinterp/corefcn/procstream.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/procstream.cc Tue Jan 24 17:19:44 2023 -0800 @@ -59,7 +59,7 @@ } int -procstreambase::close (void) +procstreambase::close () { int status = 0; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/procstream.h --- a/libinterp/corefcn/procstream.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/procstream.h Tue Jan 24 17:19:44 2023 -0800 @@ -43,13 +43,13 @@ { public: - procstreambase (void) : m_pb () { pb_init (); } + procstreambase () : m_pb () { pb_init (); } procstreambase (const std::string& name, int mode); procstreambase (const char *name, int mode); - ~procstreambase (void) { close (); } + ~procstreambase () { close (); } void open (const std::string& name, int mode) { @@ -58,19 +58,19 @@ void open (const char *name, int mode); - int is_open (void) const { return m_pb.is_open (); } + int is_open () const { return m_pb.is_open (); } - int close (void); + int close (); - pid_t pid (void) const { return m_pb.pid (); } + pid_t pid () const { return m_pb.pid (); } - int file_number (void) const { return m_pb.file_number (); } + int file_number () const { return m_pb.file_number (); } private: procbuf m_pb; - void pb_init (void) + void pb_init () { // Explicit initialization of the std::ios object is needed. // FIXME: is there a better way to organize these classes? @@ -88,7 +88,7 @@ { public: - iprocstream (void) : std::istream (nullptr), procstreambase () { } + iprocstream () : std::istream (nullptr), procstreambase () { } iprocstream (const std::string& name, int mode = std::ios::in) : std::istream (nullptr), procstreambase (name, mode) @@ -98,7 +98,7 @@ : std::istream (nullptr), procstreambase (name, mode) { } - ~iprocstream (void) = default; + ~iprocstream () = default; void open (const std::string& name, int mode = std::ios::in) { @@ -123,7 +123,7 @@ { public: - oprocstream (void) : std::ostream (nullptr), procstreambase () { } + oprocstream () : std::ostream (nullptr), procstreambase () { } oprocstream (const std::string& name, int mode = std::ios::out) : std::ostream (nullptr), procstreambase (name, mode) { } @@ -131,7 +131,7 @@ oprocstream (const char *name, int mode = std::ios::out) : std::ostream (nullptr), procstreambase (name, mode) { } - ~oprocstream (void) = default; + ~oprocstream () = default; void open (const std::string& name, int mode = std::ios::out) { @@ -156,7 +156,7 @@ { public: - procstream (void) : std::iostream (nullptr), procstreambase () { } + procstream () : std::iostream (nullptr), procstreambase () { } procstream (const std::string& name, int mode) : std::iostream (nullptr), procstreambase (name, mode) @@ -166,7 +166,7 @@ : std::iostream (nullptr), procstreambase (name, mode) { } - ~procstream (void) = default; + ~procstream () = default; void open (const std::string& name, int mode) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/settings.cc --- a/libinterp/corefcn/settings.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/settings.cc Tue Jan 24 17:19:44 2023 -0800 @@ -36,7 +36,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) -settings::settings (void) +settings::settings () : m_display_tokens (false), m_token_count (0), m_lexer_debug_flag (false) { } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/settings.h --- a/libinterp/corefcn/settings.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/settings.h Tue Jan 24 17:19:44 2023 -0800 @@ -45,17 +45,17 @@ { public: - settings (void); + settings (); settings (const settings&) = delete; settings& operator = (const settings&) = delete; - ~settings (void) = default; + ~settings () = default; octave_value display_tokens (const octave_value_list& args, int nargout); - bool display_tokens (void) const { return m_display_tokens; } + bool display_tokens () const { return m_display_tokens; } bool display_tokens (bool flag) { @@ -65,13 +65,13 @@ } // Read only. - std::size_t token_count (void) const { return m_token_count; } + std::size_t token_count () const { return m_token_count; } - void increment_token_count (void) { ++m_token_count; } + void increment_token_count () { ++m_token_count; } octave_value lexer_debug_flag (const octave_value_list& args, int nargout); - bool lexer_debug_flag (void) const { return m_lexer_debug_flag; } + bool lexer_debug_flag () const { return m_lexer_debug_flag; } bool lexer_debug_flag (bool flag) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/sighandlers.cc --- a/libinterp/corefcn/sighandlers.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/sighandlers.cc Tue Jan 24 17:19:44 2023 -0800 @@ -107,7 +107,7 @@ // we have caught. void -respond_to_pending_signals (void) +respond_to_pending_signals () { // The list of signals is relatively short, so we will just go // linearly through the list. @@ -323,7 +323,7 @@ } interrupt_handler -catch_interrupts (void) +catch_interrupts () { interrupt_handler retval; @@ -334,7 +334,7 @@ } interrupt_handler -ignore_interrupts (void) +ignore_interrupts () { interrupt_handler retval; @@ -362,7 +362,7 @@ // Install all the handlers for the signals we might care about. void -install_signal_handlers (void) +install_signal_handlers () { if (! signals_caught) signals_caught = new bool [octave_num_signals ()]; @@ -445,7 +445,7 @@ } static octave_scalar_map -make_sig_struct (void) +make_sig_struct () { octave_scalar_map m; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/sighandlers.h --- a/libinterp/corefcn/sighandlers.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/sighandlers.h Tue Jan 24 17:19:44 2023 -0800 @@ -66,13 +66,13 @@ set_signal_handler (const char *signame, sig_handler *h, bool restart_syscalls = true); -extern OCTINTERP_API void install_signal_handlers (void); +extern OCTINTERP_API void install_signal_handlers (); -extern OCTINTERP_API void respond_to_pending_signals (void); +extern OCTINTERP_API void respond_to_pending_signals (); -extern OCTINTERP_API interrupt_handler catch_interrupts (void); +extern OCTINTERP_API interrupt_handler catch_interrupts (); -extern OCTINTERP_API interrupt_handler ignore_interrupts (void); +extern OCTINTERP_API interrupt_handler ignore_interrupts (); extern OCTINTERP_API interrupt_handler set_interrupt_handler (const volatile interrupt_handler& h, diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/stack-frame.cc --- a/libinterp/corefcn/stack-frame.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/stack-frame.cc Tue Jan 24 17:19:44 2023 -0800 @@ -54,7 +54,7 @@ { public: - compiled_fcn_stack_frame (void) = delete; + compiled_fcn_stack_frame () = delete; compiled_fcn_stack_frame (tree_evaluator& tw, octave_function *fcn, std::size_t index, @@ -70,16 +70,16 @@ compiled_fcn_stack_frame& operator = (const compiled_fcn_stack_frame& elt) = delete; - ~compiled_fcn_stack_frame (void) = default; - - bool is_compiled_fcn_frame (void) const { return true; } - - symbol_scope get_scope (void) const + ~compiled_fcn_stack_frame () = default; + + bool is_compiled_fcn_frame () const { return true; } + + symbol_scope get_scope () const { return m_static_link->get_scope (); } - octave_function * function (void) const { return m_fcn; } + octave_function * function () const { return m_fcn; } symbol_record lookup_symbol (const std::string& name) const { @@ -175,7 +175,7 @@ { public: - script_stack_frame (void) = delete; + script_stack_frame () = delete; script_stack_frame (tree_evaluator& tw, octave_user_script *script, std::size_t index, @@ -186,36 +186,36 @@ script_stack_frame& operator = (const script_stack_frame& elt) = delete; - ~script_stack_frame (void) + ~script_stack_frame () { delete m_unwind_protect_frame; } - bool is_user_script_frame (void) const { return true; } + bool is_user_script_frame () const { return true; } static std::shared_ptr get_access_link (const std::shared_ptr& static_link); static std::size_t get_num_symbols (octave_user_script *script); - void set_script_offsets (void); + void set_script_offsets (); void set_script_offsets_internal (const std::map& symbols); void resize_and_update_script_offsets (const symbol_record& sym); - symbol_scope get_scope (void) const { return m_script->scope (); } - - octave_function * function (void) const { return m_script; } - - unwind_protect * unwind_protect_frame (void); + symbol_scope get_scope () const { return m_script->scope (); } + + octave_function * function () const { return m_script; } + + unwind_protect * unwind_protect_frame (); symbol_record lookup_symbol (const std::string& name) const; symbol_record insert_symbol (const std::string&); - std::size_t size (void) const { return m_lexical_frame_offsets.size (); } + std::size_t size () const { return m_lexical_frame_offsets.size (); } void resize (std::size_t size) { @@ -288,7 +288,7 @@ { public: - base_value_stack_frame (void) = delete; + base_value_stack_frame () = delete; base_value_stack_frame (tree_evaluator& tw, std::size_t num_symbols, std::size_t index, @@ -306,9 +306,9 @@ base_value_stack_frame& operator = (const base_value_stack_frame& elt) = delete; - ~base_value_stack_frame (void) = default; - - std::size_t size (void) const + ~base_value_stack_frame () = default; + + std::size_t size () const { return m_values.size (); } @@ -394,7 +394,7 @@ { public: - user_fcn_stack_frame (void) = delete; + user_fcn_stack_frame () = delete; user_fcn_stack_frame (tree_evaluator& tw, octave_user_function *fcn, std::size_t index, @@ -433,12 +433,12 @@ user_fcn_stack_frame& operator = (const user_fcn_stack_frame& elt) = delete; - ~user_fcn_stack_frame (void) + ~user_fcn_stack_frame () { delete m_unwind_protect_frame; } - bool is_user_fcn_frame (void) const { return true; } + bool is_user_fcn_frame () const { return true; } static std::shared_ptr get_access_link (octave_user_function *fcn, @@ -451,13 +451,13 @@ return fcn_scope.num_symbols (); } - void clear_values (void); - - symbol_scope get_scope (void) const { return m_fcn->scope (); } - - octave_function * function (void) const { return m_fcn; } - - unwind_protect * unwind_protect_frame (void); + void clear_values (); + + symbol_scope get_scope () const { return m_fcn->scope (); } + + octave_function * function () const { return m_fcn; } + + unwind_protect * unwind_protect_frame (); symbol_record lookup_symbol (const std::string& name) const; @@ -505,7 +505,7 @@ { public: - scope_stack_frame (void) = delete; + scope_stack_frame () = delete; scope_stack_frame (tree_evaluator& tw, const symbol_scope& scope, std::size_t index, @@ -520,11 +520,11 @@ scope_stack_frame& operator = (const scope_stack_frame& elt) = delete; - ~scope_stack_frame (void) = default; - - bool is_scope_frame (void) const { return true; } - - symbol_scope get_scope (void) const { return m_scope; } + ~scope_stack_frame () = default; + + bool is_scope_frame () const { return true; } + + symbol_scope get_scope () const { return m_scope; } symbol_record lookup_symbol (const std::string& name) const { @@ -588,9 +588,9 @@ { protected: - stack_frame_walker (void) { } - - virtual ~stack_frame_walker (void) = default; + stack_frame_walker () { } + + virtual ~stack_frame_walker () = default; public: @@ -639,7 +639,7 @@ symbol_cleaner& operator = (const symbol_cleaner&) = delete; - ~symbol_cleaner (void) = default; + ~symbol_cleaner () = default; void visit_compiled_fcn_stack_frame (compiled_fcn_stack_frame& frame) { @@ -800,9 +800,9 @@ symbol_info_accumulator& operator = (const symbol_info_accumulator&) = delete; - ~symbol_info_accumulator (void) = default; - - bool is_empty (void) const + ~symbol_info_accumulator () = default; + + bool is_empty () const { for (const auto& nm_sil : m_sym_inf_list) { @@ -815,7 +815,7 @@ return true; } - std::list names (void) const + std::list names () const { std::list retval; @@ -832,7 +832,7 @@ return retval; } - symbol_info_list symbol_info (void) const + symbol_info_list symbol_info () const { symbol_info_list retval; @@ -847,7 +847,7 @@ return retval; } - octave_map map_value (void) const + octave_map map_value () const { octave_map retval; @@ -1089,7 +1089,7 @@ // user_fcn stack frames. Anything else indicates an error in the // implementation, but we'll simply warn if that happens. -void stack_frame::clear_values (void) +void stack_frame::clear_values () { warning ("invalid call to stack_frame::clear_values; please report"); } @@ -1158,7 +1158,7 @@ // Return first occurrence of variables in current stack frame and any // parent frames reachable through access links. -symbol_info_list stack_frame::all_variables (void) +symbol_info_list stack_frame::all_variables () { symbol_info_accumulator sia (true, true); @@ -1167,7 +1167,7 @@ return sia.symbol_info (); } -octave_value stack_frame::workspace (void) +octave_value stack_frame::workspace () { std::list ws_list; @@ -1205,7 +1205,7 @@ // FIXME: Should this function also find any variables in parent // scopes accessible through access_links? -std::list stack_frame::variable_names (void) const +std::list stack_frame::variable_names () const { std::list retval; @@ -1242,7 +1242,7 @@ return sia.symbol_info (); } -std::size_t stack_frame::size (void) const +std::size_t stack_frame::size () const { // This function should only be called for user_fcn_stack_frame or // scope_stack_frame objects. Anything else indicates an error in @@ -1342,7 +1342,7 @@ panic_impossible (); } -void stack_frame::clear_objects (void) +void stack_frame::clear_objects () { symbol_cleaner sc (true, true); @@ -1384,7 +1384,7 @@ accept (sc); } -void stack_frame::clear_variables (void) +void stack_frame::clear_variables () { symbol_cleaner sc; @@ -1491,7 +1491,7 @@ return script_scope.num_symbols (); } -void script_stack_frame::set_script_offsets (void) +void script_stack_frame::set_script_offsets () { // Set frame and data offsets inside stack frame based on enclosing // scope(s). @@ -1639,7 +1639,7 @@ return alink; } -unwind_protect *script_stack_frame::unwind_protect_frame (void) +unwind_protect *script_stack_frame::unwind_protect_frame () { if (! m_unwind_protect_frame) m_unwind_protect_frame = new unwind_protect (); @@ -2131,7 +2131,7 @@ return alink; } -void user_fcn_stack_frame::clear_values (void) +void user_fcn_stack_frame::clear_values () { symbol_scope fcn_scope = m_fcn->scope (); @@ -2165,7 +2165,7 @@ } } -unwind_protect *user_fcn_stack_frame::unwind_protect_frame (void) +unwind_protect *user_fcn_stack_frame::unwind_protect_frame () { if (! m_unwind_protect_frame) m_unwind_protect_frame = new unwind_protect (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/stack-frame.h --- a/libinterp/corefcn/stack-frame.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/stack-frame.h Tue Jan 24 17:19:44 2023 -0800 @@ -137,7 +137,7 @@ NUM_AUTO_VARS }; - stack_frame (void) = delete; + stack_frame () = delete; stack_frame (tree_evaluator& tw, std::size_t index, const std::shared_ptr& parent_link, @@ -186,28 +186,28 @@ stack_frame& operator = (const stack_frame& elt) = delete; - virtual ~stack_frame (void) = default; + virtual ~stack_frame () = default; // FIXME: It would be nice to eliminate these but there are a few // places where we still need to know the specific type of the // stack frame that we are handling. - virtual bool is_compiled_fcn_frame (void) const { return false; } - virtual bool is_user_script_frame (void) const { return false; } - virtual bool is_user_fcn_frame (void) const { return false; } - virtual bool is_scope_frame (void) const { return false; } + virtual bool is_compiled_fcn_frame () const { return false; } + virtual bool is_user_script_frame () const { return false; } + virtual bool is_user_fcn_frame () const { return false; } + virtual bool is_scope_frame () const { return false; } - virtual void clear_values (void); + virtual void clear_values (); - std::size_t index (void) const { return m_index; } + std::size_t index () const { return m_index; } void line (int l) { m_line = l; } - int line (void) const { return m_line; } + int line () const { return m_line; } void column (int c) { m_column = c; } - int column (void) const { return m_column; } + int column () const { return m_column; } - std::string fcn_file_name (void) const + std::string fcn_file_name () const { octave_function *fcn = function (); @@ -238,11 +238,11 @@ return retval; } - virtual symbol_scope get_scope (void) const = 0; + virtual symbol_scope get_scope () const = 0; - virtual octave_function * function (void) const { return nullptr; } + virtual octave_function * function () const { return nullptr; } - virtual unwind_protect * unwind_protect_frame (void) { return nullptr; } + virtual unwind_protect * unwind_protect_frame () { return nullptr; } symbol_info_list make_symbol_info_list (const std::list& symrec_list) const; @@ -252,11 +252,11 @@ const std::string& whos_line_fmt, const std::string& msg); - symbol_info_list all_variables (void); + symbol_info_list all_variables (); - octave_value workspace (void); + octave_value workspace (); - std::list variable_names (void) const; + std::list variable_names () const; // Look for named symbol visible from current scope. Don't // attempt to insert if missing. @@ -270,7 +270,7 @@ symbol_info_list regexp_symbol_info (const std::string& pattern); - symbol_info_list get_symbol_info (void) + symbol_info_list get_symbol_info () { return all_variables (); } @@ -308,15 +308,15 @@ } std::shared_ptr - parent_link (void) const {return m_parent_link; } + parent_link () const {return m_parent_link; } std::shared_ptr - static_link (void) const {return m_static_link; } + static_link () const {return m_static_link; } std::shared_ptr - access_link (void) const {return m_access_link; } + access_link () const {return m_access_link; } - virtual std::size_t size (void) const; + virtual std::size_t size () const; virtual void resize (std::size_t); @@ -525,7 +525,7 @@ unmark_persistent (sym); } - void clear_objects (void); + void clear_objects (); void clear_variable (const std::string& name); @@ -535,9 +535,9 @@ void clear_variable_regexp (const std::string& pattern); void clear_variable_regexp (const string_vector& patterns); - void clear_variables (void); + void clear_variables (); - std::string get_dispatch_class (void) const { return m_dispatch_class; } + std::string get_dispatch_class () const { return m_dispatch_class; } void set_dispatch_class (const std::string& class_name) { @@ -554,8 +554,8 @@ virtual void break_closure_cycles (const std::shared_ptr&) { } - void mark_closure_context (void) { m_is_closure_context = true; } - bool is_closure_context (void) const { return m_is_closure_context; } + void mark_closure_context () { m_is_closure_context = true; } + bool is_closure_context () const { return m_is_closure_context; } protected: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/svd.cc --- a/libinterp/corefcn/svd.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/svd.cc Tue Jan 24 17:19:44 2023 -0800 @@ -62,7 +62,7 @@ template static typename math::svd::Driver -svd_driver (void) +svd_driver () { if (Vsvd_driver == "gejsv") return math::svd::Driver::GEJSV; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/syminfo.cc --- a/libinterp/corefcn/syminfo.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/syminfo.cc Tue Jan 24 17:19:44 2023 -0800 @@ -177,7 +177,7 @@ return octave_value (); } -std::list symbol_info_list::names (void) const +std::list symbol_info_list::names () const { std::list retval; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/syminfo.h --- a/libinterp/corefcn/syminfo.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/syminfo.h Tue Jan 24 17:19:44 2023 -0800 @@ -63,19 +63,19 @@ m_is_global (is_global), m_is_persistent (is_persistent) { } - std::string name (void) const { return m_name; } + std::string name () const { return m_name; } - octave_value value (void) const { return m_value; } + octave_value value () const { return m_value; } - bool is_complex (void) const { return m_is_complex; } + bool is_complex () const { return m_is_complex; } - bool is_sparse (void) const { return m_is_sparse; } + bool is_sparse () const { return m_is_sparse; } - bool is_formal (void) const { return m_is_formal; } + bool is_formal () const { return m_is_formal; } - bool is_global (void) const { return m_is_global; } + bool is_global () const { return m_is_global; } - bool is_persistent (void) const { return m_is_persistent; } + bool is_persistent () const { return m_is_persistent; } void display_line (std::ostream& os, const std::list& params) const; @@ -96,17 +96,17 @@ { public: - symbol_info_list (void) = default; + symbol_info_list () = default; symbol_info_list (const symbol_info_list&) = default; symbol_info_list& operator = (const symbol_info_list&) = default; - ~symbol_info_list (void) = default; + ~symbol_info_list () = default; octave_value varval (const std::string& name) const; - std::list names (void) const; + std::list names () const; octave_map map_value (const std::string& caller_function_name, int nesting_level) const; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/symrec.cc --- a/libinterp/corefcn/symrec.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/symrec.cc Tue Jan 24 17:19:44 2023 -0800 @@ -42,13 +42,13 @@ OCTAVE_BEGIN_NAMESPACE(octave) std::shared_ptr -symbol_record::symbol_record_rep::dup (void) const +symbol_record::symbol_record_rep::dup () const { return std::shared_ptr (new symbol_record_rep (*this)); } octave_value -symbol_record::symbol_record_rep::dump (void) const +symbol_record::symbol_record_rep::dump () const { std::map m = {{ "frame_offset", m_frame_offset }, diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/symrec.h --- a/libinterp/corefcn/symrec.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/symrec.h Tue Jan 24 17:19:44 2023 -0800 @@ -76,90 +76,90 @@ symbol_record_rep& operator = (const symbol_record_rep&) = default; - ~symbol_record_rep (void) = default; + ~symbol_record_rep () = default; // FIXME: use special storage class instead? - bool is_valid (void) const { return ! m_name.empty (); } + bool is_valid () const { return ! m_name.empty (); } void set_frame_offset (std::size_t offset) { m_frame_offset = offset; } - std::size_t frame_offset (void) const { return m_frame_offset; } + std::size_t frame_offset () const { return m_frame_offset; } void set_data_offset (std::size_t offset) { m_data_offset = offset; } - std::size_t data_offset (void) const { return m_data_offset; } + std::size_t data_offset () const { return m_data_offset; } - bool is_local (void) const + bool is_local () const { return m_storage_class & LOCAL; } - bool is_formal (void) const + bool is_formal () const { return m_storage_class & FORMAL; } - bool is_added_static (void) const + bool is_added_static () const { return m_storage_class & ADDED_STATIC; } - bool is_variable (void) const + bool is_variable () const { return m_storage_class & VARIABLE; } - void mark_local (void) + void mark_local () { m_storage_class = static_cast (m_storage_class | LOCAL); } - void mark_formal (void) + void mark_formal () { // Formal parameters are also variables. m_storage_class = static_cast (m_storage_class | FORMAL | VARIABLE); } - void mark_added_static (void) + void mark_added_static () { m_storage_class = static_cast (m_storage_class | ADDED_STATIC); } - void mark_as_variable (void) + void mark_as_variable () { m_storage_class = static_cast (m_storage_class | VARIABLE); } - void unmark_local (void) + void unmark_local () { m_storage_class = static_cast (m_storage_class & ~LOCAL); } - void unmark_formal (void) + void unmark_formal () { m_storage_class = static_cast (m_storage_class & ~FORMAL); } - void unmark_added_static (void) + void unmark_added_static () { m_storage_class = static_cast (m_storage_class & ~ADDED_STATIC); } - void unmark_as_variable (void) + void unmark_as_variable () { m_storage_class = static_cast (m_storage_class & ~VARIABLE); } - unsigned int storage_class (void) const { return m_storage_class; } + unsigned int storage_class () const { return m_storage_class; } - std::shared_ptr dup (void) const; + std::shared_ptr dup () const; - octave_value dump (void) const; + octave_value dump () const; - std::string name (void) const { return m_name; } + std::string name () const { return m_name; } void rename (const std::string& new_name) { m_name = new_name; } @@ -188,46 +188,46 @@ symbol_record& operator = (const symbol_record&) = default; - ~symbol_record (void) = default; + ~symbol_record () = default; - bool is_valid (void) const { return m_rep->is_valid (); } + bool is_valid () const { return m_rep->is_valid (); } explicit operator bool () const { return is_valid (); } void set_frame_offset (std::size_t offset) { m_rep->set_frame_offset (offset); } - std::size_t frame_offset (void) const { return m_rep->frame_offset (); } + std::size_t frame_offset () const { return m_rep->frame_offset (); } void set_data_offset (std::size_t offset) { m_rep->set_data_offset (offset); } - std::size_t data_offset (void) const { return m_rep->data_offset (); } + std::size_t data_offset () const { return m_rep->data_offset (); } - symbol_record dup (void) const { return symbol_record (m_rep->dup ()); } + symbol_record dup () const { return symbol_record (m_rep->dup ()); } - std::string name (void) const { return m_rep->name (); } + std::string name () const { return m_rep->name (); } void rename (const std::string& new_name) { m_rep->rename (new_name); } - bool is_local (void) const { return m_rep->is_local (); } - bool is_formal (void) const { return m_rep->is_formal (); } - bool is_added_static (void) const { return m_rep->is_added_static (); } - bool is_variable (void) const { return m_rep->is_variable (); } + bool is_local () const { return m_rep->is_local (); } + bool is_formal () const { return m_rep->is_formal (); } + bool is_added_static () const { return m_rep->is_added_static (); } + bool is_variable () const { return m_rep->is_variable (); } - void mark_local (void) { m_rep->mark_local (); } - void mark_formal (void) { m_rep->mark_formal (); } - void mark_added_static (void) { m_rep->mark_added_static (); } - void mark_as_variable (void) { m_rep->mark_as_variable (); } + void mark_local () { m_rep->mark_local (); } + void mark_formal () { m_rep->mark_formal (); } + void mark_added_static () { m_rep->mark_added_static (); } + void mark_as_variable () { m_rep->mark_as_variable (); } - void unmark_local (void) { m_rep->unmark_local (); } - void unmark_formal (void) { m_rep->unmark_formal (); } - void unmark_added_static (void) { m_rep->unmark_added_static (); } - void unmark_as_variable (void) { m_rep->unmark_as_variable (); } + void unmark_local () { m_rep->unmark_local (); } + void unmark_formal () { m_rep->unmark_formal (); } + void unmark_added_static () { m_rep->unmark_added_static (); } + void unmark_as_variable () { m_rep->unmark_as_variable (); } - unsigned int storage_class (void) const { return m_rep->storage_class (); } + unsigned int storage_class () const { return m_rep->storage_class (); } - octave_value dump (void) const { return m_rep->dump (); } + octave_value dump () const { return m_rep->dump (); } private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/symscope.cc --- a/libinterp/corefcn/symscope.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/symscope.cc Tue Jan 24 17:19:44 2023 -0800 @@ -92,7 +92,7 @@ return p->second; } -std::list symbol_scope_rep::localfunctions (void) const +std::list symbol_scope_rep::localfunctions () const { std::list retval; @@ -130,7 +130,7 @@ } octave_value -symbol_scope_rep::dump (void) const +symbol_scope_rep::dump () const { std::map m = {{ "name", m_name }, @@ -145,7 +145,7 @@ } octave_value -symbol_scope_rep::dump_symbols_map (void) const +symbol_scope_rep::dump_symbols_map () const { std::map info_map; @@ -159,7 +159,7 @@ return octave_value (info_map); } -std::list symbol_scope_rep::symbol_list (void) const +std::list symbol_scope_rep::symbol_list () const { std::list retval; @@ -198,7 +198,7 @@ } std::list -symbol_scope_rep::parent_fcn_names (void) const +symbol_scope_rep::parent_fcn_names () const { std::list retval; @@ -304,7 +304,7 @@ return false; } -void symbol_scope_rep::update_nest (void) +void symbol_scope_rep::update_nest () { auto t_parent = m_parent.lock (); @@ -370,7 +370,7 @@ return false; } -std::list symbol_scope::localfunctions (void) const +std::list symbol_scope::localfunctions () const { if (! m_rep) return std::list (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/symscope.h --- a/libinterp/corefcn/symscope.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/symscope.h Tue Jan 24 17:19:44 2023 -0800 @@ -83,9 +83,9 @@ symbol_scope_rep& operator = (const symbol_scope&) = delete; - ~symbol_scope_rep (void) = default; + ~symbol_scope_rep () = default; - std::size_t num_symbols (void) const { return m_symbols.size (); } + std::size_t num_symbols () const { return m_symbols.size (); } // Simply inserts symbol. No non-local searching. @@ -93,29 +93,29 @@ void insert_symbol_record (symbol_record& sr); - bool is_nested (void) const { return m_nesting_depth > 0; } + bool is_nested () const { return m_nesting_depth > 0; } - std::size_t nesting_depth (void) const { return m_nesting_depth; } + std::size_t nesting_depth () const { return m_nesting_depth; } void set_nesting_depth (std::size_t depth) { m_nesting_depth = depth; } - bool is_parent (void) const { return ! m_children.empty (); } + bool is_parent () const { return ! m_children.empty (); } - bool is_static (void) const { return m_is_static; } + bool is_static () const { return m_is_static; } - void mark_static (void) { m_is_static = true; } + void mark_static () { m_is_static = true; } - std::shared_ptr parent_scope_rep (void) const + std::shared_ptr parent_scope_rep () const { return m_parent.lock (); } - std::shared_ptr primary_parent_scope_rep (void) const + std::shared_ptr primary_parent_scope_rep () const { return m_primary_parent.lock (); } - std::shared_ptr dup (void) const + std::shared_ptr dup () const { std::shared_ptr new_sid = std::shared_ptr (new symbol_scope_rep (m_name)); @@ -204,32 +204,32 @@ octave_value find_subfunction (const std::string& name) const; - void lock_subfunctions (void) + void lock_subfunctions () { for (auto& nm_sf : m_subfunctions) nm_sf.second.lock (); } - void unlock_subfunctions (void) + void unlock_subfunctions () { for (auto& nm_sf : m_subfunctions) nm_sf.second.unlock (); } // Pairs of name, function objects. - std::map subfunctions (void) const + std::map subfunctions () const { return m_subfunctions; } - void erase_subfunctions (void) + void erase_subfunctions () { m_subfunctions.clear (); } void mark_subfunctions_in_scope_as_private (const std::string& class_name); - bool has_subfunctions (void) const + bool has_subfunctions () const { return ! m_subfunction_names.empty (); } @@ -239,26 +239,26 @@ m_subfunction_names = names; } - std::list subfunction_names (void) const + std::list subfunction_names () const { return m_subfunction_names; } - std::list localfunctions (void) const; + std::list localfunctions () const; - octave_value dump (void) const; + octave_value dump () const; - std::string name (void) const { return m_name; } + std::string name () const { return m_name; } void cache_name (const std::string& name) { m_name = name; } - std::string fcn_name (void) const { return m_fcn_name; } + std::string fcn_name () const { return m_fcn_name; } void cache_fcn_name (const std::string& name) { m_fcn_name = name; } - std::list parent_fcn_names (void) const; + std::list parent_fcn_names () const; - octave_user_code * user_code (void) const { return m_code; } + octave_user_code * user_code () const { return m_code; } void set_user_code (octave_user_code *code) { m_code = code; } @@ -271,15 +271,15 @@ m_fcn_file_name = name; } - std::string fcn_file_name (void) const { return m_fcn_file_name; } + std::string fcn_file_name () const { return m_fcn_file_name; } void cache_dir_name (const std::string& name); - std::string dir_name (void) const { return m_dir_name; } + std::string dir_name () const { return m_dir_name; } - void mark_primary_fcn_scope (void) { m_is_primary_fcn_scope = true; } + void mark_primary_fcn_scope () { m_is_primary_fcn_scope = true; } - bool is_primary_fcn_scope (void) const { return m_is_primary_fcn_scope; } + bool is_primary_fcn_scope () const { return m_is_primary_fcn_scope; } bool is_relative (const std::shared_ptr& scope) const; @@ -288,24 +288,24 @@ bool is_variable (const std::string& nm) const; - void update_nest (void); + void update_nest (); bool look_nonlocal (const std::string& name, std::size_t offset, symbol_record& result); - octave_value dump_symbols_map (void) const; + octave_value dump_symbols_map () const; - const std::map& symbols (void) const + const std::map& symbols () const { return m_symbols; } - std::map& symbols (void) + std::map& symbols () { return m_symbols; } - std::list symbol_list (void) const; + std::list symbol_list () const; private: @@ -390,13 +390,13 @@ symbol_scope& operator = (const symbol_scope&) = default; - ~symbol_scope (void) = default; + ~symbol_scope () = default; - bool is_valid (void) const { return bool (m_rep); } + bool is_valid () const { return bool (m_rep); } explicit operator bool () const { return bool (m_rep); } - std::size_t num_symbols (void) const + std::size_t num_symbols () const { return m_rep ? m_rep->num_symbols () : 0; } @@ -412,12 +412,12 @@ m_rep->insert_symbol_record (sr); } - bool is_nested (void) const + bool is_nested () const { return m_rep ? m_rep->is_nested () : false; } - bool is_parent (void) const + bool is_parent () const { return m_rep ? m_rep->is_parent () : false; } @@ -428,33 +428,33 @@ m_rep->set_nesting_depth (depth); } - std::size_t nesting_depth (void) const + std::size_t nesting_depth () const { return m_rep ? m_rep->nesting_depth () : 0; } - bool is_static (void) const + bool is_static () const { return m_rep ? m_rep->is_static () : false; } - void mark_static (void) + void mark_static () { if (m_rep) m_rep->mark_static (); } - std::shared_ptr parent_scope (void) const + std::shared_ptr parent_scope () const { return m_rep ? m_rep->parent_scope_rep () : nullptr; } - std::shared_ptr primary_parent_scope (void) const + std::shared_ptr primary_parent_scope () const { return m_rep ? m_rep->primary_parent_scope_rep () : nullptr; } - symbol_scope dup (void) const + symbol_scope dup () const { return symbol_scope (m_rep ? m_rep->dup () : nullptr); } @@ -513,26 +513,26 @@ return m_rep ? m_rep->find_subfunction (name) : octave_value (); } - void lock_subfunctions (void) + void lock_subfunctions () { if (m_rep) m_rep->lock_subfunctions (); } - void unlock_subfunctions (void) + void unlock_subfunctions () { if (m_rep) m_rep->unlock_subfunctions (); } - std::map subfunctions (void) const + std::map subfunctions () const { return (m_rep ? m_rep->subfunctions () : std::map ()); } - void erase_subfunctions (void) + void erase_subfunctions () { if (m_rep) m_rep->erase_subfunctions (); @@ -544,7 +544,7 @@ m_rep->mark_subfunctions_in_scope_as_private (class_name); } - bool has_subfunctions (void) const + bool has_subfunctions () const { return m_rep ? m_rep->has_subfunctions () : false; } @@ -555,20 +555,20 @@ m_rep->stash_subfunction_names (names); } - std::list subfunction_names (void) const + std::list subfunction_names () const { return m_rep ? m_rep->subfunction_names () : std::list (); } // List of function handle objects. - std::list localfunctions (void) const; + std::list localfunctions () const; - octave_value dump (void) const + octave_value dump () const { return m_rep ? m_rep->dump () : octave_value (); } - std::string name (void) const + std::string name () const { return m_rep ? m_rep->name () : ""; } @@ -579,7 +579,7 @@ m_rep->cache_name (name); } - std::string fcn_name (void) const + std::string fcn_name () const { return m_rep ? m_rep->fcn_name () : ""; } @@ -590,12 +590,12 @@ m_rep->cache_fcn_name (name); } - std::list parent_fcn_names (void) const + std::list parent_fcn_names () const { return m_rep ? m_rep->parent_fcn_names () : std::list (); } - octave_user_code * user_code (void) const + octave_user_code * user_code () const { return m_rep ? m_rep->user_code () : nullptr; } @@ -630,23 +630,23 @@ m_rep->cache_dir_name (name); } - std::string fcn_file_name (void) const + std::string fcn_file_name () const { return m_rep ? m_rep->fcn_file_name () : ""; } - std::string dir_name (void) const + std::string dir_name () const { return m_rep ? m_rep->dir_name () : ""; } - void mark_primary_fcn_scope (void) + void mark_primary_fcn_scope () { if (m_rep) m_rep->mark_primary_fcn_scope (); } - bool is_primary_fcn_scope (void) const + bool is_primary_fcn_scope () const { return m_rep ? m_rep->is_primary_fcn_scope () : false; } @@ -673,7 +673,7 @@ return m_rep ? m_rep->is_variable (nm) : false; } - void update_nest (void) + void update_nest () { if (m_rep) m_rep->update_nest (); @@ -685,7 +685,7 @@ return m_rep ? m_rep->look_nonlocal (name, offset, result) : false; } - std::shared_ptr get_rep (void) const + std::shared_ptr get_rep () const { return m_rep; } @@ -700,21 +700,21 @@ return a.m_rep != b.m_rep; } - const std::map& symbols (void) const + const std::map& symbols () const { static const std::map empty_map; return m_rep ? m_rep->symbols () : empty_map; } - std::map& symbols (void) + std::map& symbols () { static std::map empty_map; return m_rep ? m_rep->symbols () : empty_map; } - std::list symbol_list (void) const + std::list symbol_list () const { static const std::list empty_list; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/symtab.cc --- a/libinterp/corefcn/symtab.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/symtab.cc Tue Jan 24 17:19:44 2023 -0800 @@ -57,7 +57,7 @@ install_builtins (); } -symbol_scope symbol_table::current_scope (void) const +symbol_scope symbol_table::current_scope () const { tree_evaluator& tw = m_interpreter.get_evaluator (); @@ -495,7 +495,7 @@ } } -void symbol_table::clear_mex_functions (void) +void symbol_table::clear_mex_functions () { auto p = m_fcn_table.begin (); @@ -578,7 +578,7 @@ error ("install_built_in_dispatch: '%s' is undefined", name.c_str ()); } -std::list symbol_table::user_function_names (void) +std::list symbol_table::user_function_names () { std::list retval; @@ -594,7 +594,7 @@ return retval; } -std::list symbol_table::built_in_function_names (void) +std::list symbol_table::built_in_function_names () { std::list retval; @@ -612,7 +612,7 @@ return retval; } -std::list symbol_table::cmdline_function_names (void) +std::list symbol_table::cmdline_function_names () { std::list retval; @@ -650,7 +650,7 @@ return octave_value (info_map); } -octave_value symbol_table::dump (void) const +octave_value symbol_table::dump () const { std::map m = {{ "function_info", dump_fcn_table_map () }, @@ -691,7 +691,7 @@ return retval; } -void symbol_table::cleanup (void) +void symbol_table::cleanup () { clear_functions (); @@ -706,7 +706,7 @@ return p != m_fcn_table.end () ? &p->second : nullptr; } -octave_value symbol_table::dump_fcn_table_map (void) const +octave_value symbol_table::dump_fcn_table_map () const { if (m_fcn_table.empty ()) return octave_value (Matrix ()); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/symtab.h --- a/libinterp/corefcn/symtab.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/symtab.h Tue Jan 24 17:19:44 2023 -0800 @@ -66,9 +66,9 @@ symbol_table& operator = (const symbol_table&) = delete; - ~symbol_table (void) = default; + ~symbol_table () = default; - symbol_scope current_scope (void) const; + symbol_scope current_scope () const; bool is_built_in_function_name (const std::string& name); @@ -155,7 +155,7 @@ // This clears oct and mex files, including autoloads. void clear_dld_function (const std::string& name); - void clear_mex_functions (void); + void clear_mex_functions (); bool set_class_relationship (const std::string& sup_class, const std::string& inf_class); @@ -168,20 +168,20 @@ void install_built_in_dispatch (const std::string& name, const std::string& klass); - std::list user_function_names (void); + std::list user_function_names (); - std::list built_in_function_names (void); + std::list built_in_function_names (); - std::list cmdline_function_names (void); + std::list cmdline_function_names (); - octave_value dump (void) const; + octave_value dump () const; void add_to_parent_map (const std::string& classname, const std::list& parent_list); std::list parent_classes (const std::string& dispatch_type); - void cleanup (void); + void cleanup (); fcn_info * get_fcn_info (const std::string& name); @@ -222,10 +222,10 @@ typedef std::map>::iterator parent_map_iterator; - octave_value dump_fcn_table_map (void) const; + octave_value dump_fcn_table_map () const; // This function is generated automatically by mk-builtins.pl. - void install_builtins (void); + void install_builtins (); }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/sysdep.cc --- a/libinterp/corefcn/sysdep.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/sysdep.cc Tue Jan 24 17:19:44 2023 -0800 @@ -108,7 +108,7 @@ #if defined (__386BSD__) || defined (__FreeBSD__) || defined (__NetBSD__) static void -BSD_init (void) +BSD_init () { # if defined (HAVE_FLOATINGPOINT_H) // Disable trapping on common exceptions. @@ -124,7 +124,7 @@ #if defined (__MINGW32__) || defined (_MSC_VER) static void -w32_set_octave_home (void) +w32_set_octave_home () { std::string bin_dir; @@ -171,7 +171,7 @@ } static void -w32_init (void) +w32_init () { w32_set_octave_home (); @@ -180,7 +180,7 @@ #endif -void set_application_id (void) +void set_application_id () { #if defined (__MINGW32__) || defined (_MSC_VER) @@ -363,7 +363,7 @@ #if defined (__MINGW32__) static void -MINGW_init (void) +MINGW_init () { w32_init (); } @@ -373,7 +373,7 @@ #if defined (_MSC_VER) static void -MSVC_init (void) +MSVC_init () { w32_init (); } @@ -506,7 +506,7 @@ #endif } -void sysdep_init (void) +void sysdep_init () { // Use a function from libgomp to force loading of OpenMP library. // Otherwise, a dynamically loaded library making use of OpenMP such @@ -524,7 +524,7 @@ #endif } -void sysdep_cleanup (void) +void sysdep_cleanup () { #if defined (OCTAVE_USE_WINDOWS_API) // Let us fail immediately without displaying any dialog. @@ -763,7 +763,7 @@ return c; } -std::string get_P_tmpdir (void) +std::string get_P_tmpdir () { #if defined (OCTAVE_USE_WINDOWS_API) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/sysdep.h --- a/libinterp/corefcn/sysdep.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/sysdep.h Tue Jan 24 17:19:44 2023 -0800 @@ -37,11 +37,11 @@ OCTAVE_BEGIN_NAMESPACE(octave) -extern OCTINTERP_API void sysdep_init (void); +extern OCTINTERP_API void sysdep_init (); -extern OCTINTERP_API void set_application_id (void); +extern OCTINTERP_API void set_application_id (); -extern OCTINTERP_API void sysdep_cleanup (void); +extern OCTINTERP_API void sysdep_cleanup (); extern OCTINTERP_API void raw_mode (bool, bool wait = true); @@ -51,7 +51,7 @@ extern OCTINTERP_API int kbhit (bool wait = true); -extern OCTINTERP_API std::string get_P_tmpdir (void); +extern OCTINTERP_API std::string get_P_tmpdir (); extern OCTINTERP_API bool same_file_internal (const std::string&, const std::string&); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/text-engine.cc --- a/libinterp/corefcn/text-engine.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/text-engine.cc Tue Jan 24 17:19:44 2023 -0800 @@ -33,7 +33,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) uint32_t -text_element_symbol::get_symbol_code (void) const +text_element_symbol::get_symbol_code () const { uint32_t code = invalid_code; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/text-engine.h --- a/libinterp/corefcn/text-engine.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/text-engine.h Tue Jan 24 17:19:44 2023 -0800 @@ -56,9 +56,9 @@ text_element { public: - text_element (void) { } + text_element () { } - virtual ~text_element (void) = default; + virtual ~text_element () = default; virtual void accept (text_processor& p) = 0; @@ -74,9 +74,9 @@ text_element_string (const std::string& s = "") : text_element (), m_str (s) { } - ~text_element_string (void) = default; + ~text_element_string () = default; - std::string string_value (void) const { return m_str; } + std::string string_value () const { return m_str; } void accept (text_processor& p); @@ -98,11 +98,11 @@ text_element_symbol (int sym) : text_element (), m_symbol (sym) { } - ~text_element_symbol (void) = default; + ~text_element_symbol () = default; - int get_symbol (void) const { return m_symbol; } + int get_symbol () const { return m_symbol; } - uint32_t get_symbol_code (void) const; + uint32_t get_symbol_code () const; void accept (text_processor& p); @@ -116,7 +116,7 @@ : public text_element, public base_list { public: - text_element_list (void) + text_element_list () : text_element (), base_list () { } text_element_list (text_element *e) @@ -125,7 +125,7 @@ push_back (e); } - ~text_element_list (void) + ~text_element_list () { while (! empty ()) { @@ -150,15 +150,15 @@ : text_element () { m_elem = new text_element_string (std::string (1, c)); } - ~text_element_subscript (void) + ~text_element_subscript () { delete m_elem; } void accept (text_processor& p); - text_element * get_element (void) { return m_elem; } + text_element * get_element () { return m_elem; } private: - text_element_subscript (void); + text_element_subscript (); //-------- @@ -178,15 +178,15 @@ : text_element () { m_elem = new text_element_string (std::string (1, c)); } - ~text_element_superscript (void) + ~text_element_superscript () { delete m_elem; } void accept (text_processor& p); - text_element * get_element (void) { return m_elem; } + text_element * get_element () { return m_elem; } private: - text_element_superscript (void); + text_element_superscript (); //-------- @@ -225,14 +225,14 @@ text_element_fontstyle (fontstyle st) : text_element (), m_style (st) { } - ~text_element_fontstyle (void) = default; + ~text_element_fontstyle () = default; - fontstyle get_fontstyle (void) const { return m_style; } + fontstyle get_fontstyle () const { return m_style; } void accept (text_processor& p); private: - text_element_fontstyle (void); + text_element_fontstyle (); //-------- @@ -248,14 +248,14 @@ text_element_fontname (const std::string& fname) : text_element (), m_name (fname) { } - ~text_element_fontname (void) = default; + ~text_element_fontname () = default; - const std::string& get_fontname (void) const { return m_name; } + const std::string& get_fontname () const { return m_name; } void accept (text_processor& p); private: - text_element_fontname (void); + text_element_fontname (); //-------- @@ -271,14 +271,14 @@ text_element_fontsize (double fsize) : text_element (), m_size (fsize) { } - ~text_element_fontsize (void) = default; + ~text_element_fontsize () = default; - double get_fontsize (void) const { return m_size; } + double get_fontsize () const { return m_size; } void accept (text_processor& p); private: - text_element_fontsize (void); + text_element_fontsize (); //-------- @@ -317,9 +317,9 @@ #undef ASSIGN_COLOR } - ~text_element_color (void) = default; + ~text_element_color () = default; - Matrix get_color (void) { return m_rgb; } + Matrix get_color () { return m_rgb; } void accept (text_processor& p); @@ -360,12 +360,12 @@ virtual void visit (text_element_color&) { } - virtual void reset (void) { } + virtual void reset () { } protected: - text_processor (void) { } + text_processor () { } - virtual ~text_processor (void) = default; + virtual ~text_processor () = default; }; #define TEXT_ELEMENT_ACCEPT(cls) \ @@ -391,9 +391,9 @@ text_parser { public: - text_parser (void) { } + text_parser () { } - virtual ~text_parser (void) = default; + virtual ~text_parser () = default; virtual text_element * parse (const std::string& s) = 0; @@ -407,9 +407,9 @@ text_parser_none : public text_parser { public: - text_parser_none (void) : text_parser () { } + text_parser_none () : text_parser () { } - ~text_parser_none (void) = default; + ~text_parser_none () = default; // FIXME: is it possible to use reference counting to manage the // memory for the object returned by the text parser? That would be @@ -427,26 +427,26 @@ text_parser_tex : public text_parser { public: - text_parser_tex (void) + text_parser_tex () : text_parser (), m_scanner (nullptr), m_buffer_state (nullptr), m_result (nullptr) { } - ~text_parser_tex (void) + ~text_parser_tex () { destroy_lexer (); } text_element * parse (const std::string& s); - void * get_scanner (void) { return m_scanner; } + void * get_scanner () { return m_scanner; } void set_parse_result (text_element *e) { m_result = e; } - text_element * get_parse_result (void) { return m_result; } + text_element * get_parse_result () { return m_result; } private: bool init_lexer (const std::string& s); - void destroy_lexer (void); + void destroy_lexer (); //-------- diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/text-renderer.cc --- a/libinterp/corefcn/text-renderer.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/text-renderer.cc Tue Jan 24 17:19:44 2023 -0800 @@ -36,19 +36,19 @@ OCTAVE_BEGIN_NAMESPACE(octave) -text_renderer::text_renderer (void) +text_renderer::text_renderer () : m_rep (make_ft_text_renderer ()), m_latex_rep (make_latex_text_renderer ()) { } -text_renderer::~text_renderer (void) +text_renderer::~text_renderer () { delete m_rep; delete m_latex_rep; } bool -text_renderer::ok (void) const +text_renderer::ok () const { static bool warned = false; @@ -96,7 +96,7 @@ } octave_map -text_renderer::get_system_fonts (void) +text_renderer::get_system_fonts () { octave_map retval; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/text-renderer.h --- a/libinterp/corefcn/text-renderer.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/text-renderer.h Tue Jan 24 17:19:44 2023 -0800 @@ -47,7 +47,7 @@ { public: - text_renderer (void); + text_renderer (); // No copying! @@ -55,9 +55,9 @@ text_renderer& operator = (const text_renderer&) = delete; - ~text_renderer (void); + ~text_renderer (); - bool ok (void) const; + bool ok () const; Matrix get_extent (text_element *elt, double rotation = 0.0); @@ -69,7 +69,7 @@ void set_font (const std::string& name, const std::string& weight, const std::string& angle, double size); - octave_map get_system_fonts (void); + octave_map get_system_fonts (); void set_color (const Matrix& c); @@ -83,7 +83,7 @@ { public: - font (void) + font () : m_name (), m_weight (), m_angle (), m_size (0) { } @@ -97,7 +97,7 @@ m_size (ft.m_size) { } - ~font (void) = default; + ~font () = default; font& operator = (const font& ft) { @@ -112,13 +112,13 @@ return *this; } - std::string get_name (void) const { return m_name; } + std::string get_name () const { return m_name; } - std::string get_weight (void) const { return m_weight; } + std::string get_weight () const { return m_weight; } - std::string get_angle (void) const { return m_angle; } + std::string get_angle () const { return m_angle; } - double get_size (void) const { return m_size; } + double get_size () const { return m_size; } protected: @@ -146,7 +146,7 @@ m_color (s.m_color), m_svg_element (s.m_svg_element) { } - ~string (void) = default; + ~string () = default; string& operator = (const string& s) { @@ -168,43 +168,43 @@ void set_string (const std::string& s) { m_str = s; } - std::string get_string (void) const { return m_str; } + std::string get_string () const { return m_str; } - std::string get_name (void) const { return m_fnt.get_name (); } + std::string get_name () const { return m_fnt.get_name (); } - std::string get_family (void) const { return m_family; } + std::string get_family () const { return m_family; } void set_family (const std::string& nm) { m_family = nm; } - std::string get_weight (void) const { return m_fnt.get_weight (); } + std::string get_weight () const { return m_fnt.get_weight (); } - std::string get_angle (void) const { return m_fnt.get_angle (); } + std::string get_angle () const { return m_fnt.get_angle (); } - double get_size (void) const { return m_fnt.get_size (); } + double get_size () const { return m_fnt.get_size (); } void set_x (const double x) { m_x = x; } - double get_x (void) const { return m_x; } + double get_x () const { return m_x; } void set_xdata (const std::vector& x) { m_xdata = x; } - std::vector get_xdata (void) const { return m_xdata; } + std::vector get_xdata () const { return m_xdata; } void set_y (const double y) { m_y = y; } - double get_y (void) const { return m_y; } + double get_y () const { return m_y; } void set_z (const double z) { m_z = z; } - double get_z (void) const { return m_z; } + double get_z () const { return m_z; } void set_code (const uint32_t code) { m_code = code; } - uint32_t get_code (void) const { return m_code; } + uint32_t get_code () const { return m_code; } void set_svg_element (const std::string& svg) { m_svg_element = svg; } - std::string get_svg_element (void) const { return m_svg_element; } + std::string get_svg_element () const { return m_svg_element; } void set_color (const uint8NDArray& c) { @@ -213,7 +213,7 @@ m_color(2) = static_cast (c(2)) / 255; } - Matrix get_color (void) const { return m_color; } + Matrix get_color () const { return m_color; } private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/toplev.cc --- a/libinterp/corefcn/toplev.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/toplev.cc Tue Jan 24 17:19:44 2023 -0800 @@ -158,7 +158,7 @@ // Combine alloc+get in one action. static void * -get_signal_mask (void) +get_signal_mask () { void *mask = octave_alloc_signal_mask (); @@ -652,7 +652,7 @@ int debug_new_delete = 0; -typedef void (*vfp)(void); +typedef void (*vfp)(); extern vfp __new_handler; void * diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/url-handle-manager.cc --- a/libinterp/corefcn/url-handle-manager.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/url-handle-manager.cc Tue Jan 24 17:19:44 2023 -0800 @@ -36,14 +36,14 @@ OCTAVE_BEGIN_NAMESPACE(octave) static double -make_handle_fraction (void) +make_handle_fraction () { static double maxrand = RAND_MAX + 2.0; return (rand () + 1.0) / maxrand; } -url_handle url_handle_manager::get_handle (void) +url_handle url_handle_manager::get_handle () { url_handle retval; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/url-handle-manager.h --- a/libinterp/corefcn/url-handle-manager.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/url-handle-manager.h Tue Jan 24 17:19:44 2023 -0800 @@ -48,7 +48,7 @@ { public: - url_handle_manager (void) + url_handle_manager () : m_handle_map (), m_handle_free_list (), m_next_handle (-1.0 - (rand () + 1.0) / (RAND_MAX + 2.0)) { } @@ -56,9 +56,9 @@ url_handle_manager& operator = (const url_handle_manager&) = delete; - ~url_handle_manager (void) = default; + ~url_handle_manager () = default; - url_handle get_handle (void); + url_handle get_handle (); void free (const url_handle& h); @@ -110,7 +110,7 @@ return h; } - Matrix handle_list (void) + Matrix handle_list () { Matrix retval (1, m_handle_map.size ()); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/variables.cc --- a/libinterp/corefcn/variables.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/variables.cc Tue Jan 24 17:19:44 2023 -0800 @@ -557,7 +557,7 @@ } static octave::unwind_protect * -curr_fcn_unwind_protect_frame (void) +curr_fcn_unwind_protect_frame () { octave::tree_evaluator& tw = octave::__get_evaluator__ (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/corefcn/xpow.cc --- a/libinterp/corefcn/xpow.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/corefcn/xpow.cc Tue Jan 24 17:19:44 2023 -0800 @@ -59,13 +59,13 @@ OCTAVE_BEGIN_NAMESPACE(octave) static void -err_failed_diagonalization (void) +err_failed_diagonalization () { error ("Failed to diagonalize matrix while calculating matrix exponential"); } static void -err_nonsquare_matrix (void) +err_nonsquare_matrix () { error ("for x^y, only square matrix arguments are permitted and one " \ "argument must be scalar. Use .^ for elementwise power."); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/dldfcn/__init_fltk__.cc --- a/libinterp/dldfcn/__init_fltk__.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/dldfcn/__init_fltk__.cc Tue Jan 24 17:19:44 2023 -0800 @@ -144,7 +144,7 @@ #endif } - ~OpenGL_fltk (void) = default; + ~OpenGL_fltk () = default; void zoom (bool z) { @@ -153,7 +153,7 @@ hide_overlay (); } - bool zoom (void) { return m_in_zoom; } + bool zoom () { return m_in_zoom; } void set_zoom_box (const Matrix& zb) { m_zoom_box = zb; } void print (const std::string& cmd, const std::string& term) @@ -163,7 +163,7 @@ octave::gl2ps_print (m_glfcns, gh_mgr.get_object (m_number), cmd, term); } - uint8NDArray get_pixels (void) + uint8NDArray get_pixels () { gh_manager& gh_mgr = octave::__get_gh_manager__ (); @@ -218,7 +218,7 @@ // (x1,y1,x2,y2) Matrix m_zoom_box; - void draw (void) + void draw () { #if defined (HAVE_OPENGL) @@ -246,7 +246,7 @@ #endif } - void overlay (void) + void overlay () { Matrix overlaycolor (3, 1); overlaycolor(0) = 0.45; @@ -307,7 +307,7 @@ : m_menubar (new Fl_Menu_Bar (xx, yy, ww, hh)) { } - int items_to_show (void) + int items_to_show () { //returns the number of visible menu items int len = m_menubar->size (); @@ -324,19 +324,19 @@ return n; } - void show (void) + void show () { m_menubar->show (); m_menubar->redraw (); } - void hide (void) + void hide () { m_menubar->hide (); m_menubar->redraw (); } - bool is_visible (void) + bool is_visible () { return m_menubar->visible (); } @@ -757,7 +757,7 @@ fltk_uimenu operator = (const fltk_uimenu&) = delete; - ~fltk_uimenu (void) + ~fltk_uimenu () { // FLTK is supposed to manage memory for widgets. } @@ -888,7 +888,7 @@ plot_window& operator = (const plot_window&) = delete; - ~plot_window (void) + ~plot_window () { this->hide (); Fl::check (); @@ -898,7 +898,7 @@ // FLTK is supposed to manage memory for widgets. } - double number (void) { return m_fp.get___myhandle__ ().value (); } + double number () { return m_fp.get___myhandle__ ().value (); } void renumber (double new_number) { @@ -919,13 +919,13 @@ return m_canvas->get_pixels (); } - void show_menubar (void) + void show_menubar () { m_uimenu->show (); update_toolbar_position (); } - void hide_menubar (void) + void hide_menubar () { m_uimenu->hide (); update_toolbar_position (); @@ -996,7 +996,7 @@ } } - void show_canvas (void) + void show_canvas () { if (! m_canvas->can_do ()) error ("unable to plot due to insufficient OpenGL support"); @@ -1007,7 +1007,7 @@ } } - void hide_canvas (void) + void hide_canvas () { m_canvas->hide (); } @@ -1065,12 +1065,12 @@ resize (bb(0), bb(1), bb(2), bb(3)); } - void mark_modified (void) + void mark_modified () { m_canvas->redraw (); } - void set_name (void) + void set_name () { m_window_label = m_fp.get_title (); label (m_window_label.c_str ()); @@ -1168,7 +1168,7 @@ } } - void axis_auto (void) + void axis_auto () { octave_value_list args; if (m_fp.get_currentaxes ().ok ()) @@ -1184,7 +1184,7 @@ } } - void toggle_grid (void) + void toggle_grid () { interpreter& interp = __get_interpreter__ (); @@ -1475,7 +1475,7 @@ m_fp.set_boundingbox (outerposition2position (bb), true, false); } - bool pan_enabled (void) + bool pan_enabled () { // Getting pan mode property: octave_value ov_pm = m_fp.get___pan_mode__ (); @@ -1485,7 +1485,7 @@ return pm.contents ("Enable").string_value () == "on"; } - std::string pan_mode (void) + std::string pan_mode () { // Getting pan mode property: octave_value ov_pm = m_fp.get___pan_mode__ (); @@ -1495,7 +1495,7 @@ return pm.contents ("Motion").string_value (); } - bool rotate_enabled (void) + bool rotate_enabled () { // Getting rotate mode property: octave_value ov_rm = m_fp.get___rotate_mode__ (); @@ -1880,7 +1880,7 @@ { private: - figure_manager (void) = default; + figure_manager () = default; public: @@ -1890,12 +1890,12 @@ figure_manager& operator = (const figure_manager&) = delete; - ~figure_manager (void) + ~figure_manager () { close_all (); } - static bool instance_ok (void) + static bool instance_ok () { bool retval = true; @@ -1905,7 +1905,7 @@ return retval; } - static void close_all (void) + static void close_all () { if (instance_ok ()) instance->do_close_all (); @@ -2039,7 +2039,7 @@ static std::string fltk_idx_header; - void do_close_all (void) + void do_close_all () { wm_iterator win; for (win = windows.begin (); win != windows.end (); win++) @@ -2280,9 +2280,9 @@ Fl::visual (FL_RGB); } - ~fltk_graphics_toolkit (void) = default; - - bool is_valid (void) const { return true; } + ~fltk_graphics_toolkit () = default; + + bool is_valid () const { return true; } bool initialize (const graphics_object& go) { @@ -2449,7 +2449,7 @@ } /* - double get_screen_resolution (void) const + double get_screen_resolution () const { // FLTK doesn't give this info. return 72.0; @@ -2459,7 +2459,7 @@ } */ - Matrix get_screen_size (void) const + Matrix get_screen_size () const { Matrix sz (1, 2, 0.0); sz(0) = Fl::w (); @@ -2467,7 +2467,7 @@ return sz; } - void close (void) + void close () { if (toolkit_loaded) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/dldfcn/__init_gnuplot__.cc --- a/libinterp/dldfcn/__init_gnuplot__.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/dldfcn/__init_gnuplot__.cc Tue Jan 24 17:19:44 2023 -0800 @@ -85,9 +85,9 @@ } } - ~gnuplot_graphics_toolkit (void) = default; + ~gnuplot_graphics_toolkit () = default; - bool is_valid (void) const { return true; } + bool is_valid () const { return true; } bool initialize (const graphics_object& go) { @@ -162,13 +162,13 @@ return sz; } - double get_screen_resolution (void) const + double get_screen_resolution () const { return 72.0; } - Matrix get_screen_size (void) const + Matrix get_screen_size () const { return Matrix (1, 2, 0.0); } - void close (void) + void close () { if (m_interpreter.mislocked ("__init_gnuplot__")) m_interpreter.munlock ("__init_gnuplot__"); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/dldfcn/__ode15__.cc --- a/libinterp/dldfcn/__ode15__.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/dldfcn/__ode15__.cc Tue Jan 24 17:19:44 2023 -0800 @@ -169,7 +169,7 @@ SparseMatrix *dfdyp, realtype cj); //Default - IDA (void) + IDA () : m_t0 (0.0), m_y0 (), m_yp0 (), m_havejac (false), m_havejacfcn (false), m_havejacsparse (false), m_mem (nullptr), m_num (), m_ida_fcn (), m_ida_jac (), m_dfdy (nullptr), m_dfdyp (nullptr), m_spdfdy (nullptr), @@ -190,7 +190,7 @@ { } - ~IDA (void) + ~IDA () { IDAFree (&m_mem); SUNLinSolFree (m_sunLinearSolver); @@ -251,9 +251,9 @@ return *this; } - void set_userdata (void); + void set_userdata (); - void initialize (void); + void initialize (); static ColumnVector NVecToCol (N_Vector& v, octave_f77_int_type n); @@ -351,7 +351,7 @@ const octave_value& event_fcn, const octave_idx_type num_event_args); - void print_stat (void); + void print_stat (); private: @@ -572,7 +572,7 @@ } void -IDA::set_userdata (void) +IDA::set_userdata () { void *userdata = this; @@ -581,7 +581,7 @@ } void -IDA::initialize (void) +IDA::initialize () { m_num = to_f77_int (m_y0.numel ()); # if defined (HAVE_SUNDIALS_SUNCONTEXT) @@ -1046,7 +1046,7 @@ } void -IDA::print_stat (void) +IDA::print_stat () { long int nsteps = 0, netfails = 0, nrevals = 0; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/dldfcn/audiodevinfo.cc --- a/libinterp/dldfcn/audiodevinfo.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/dldfcn/audiodevinfo.cc Tue Jan 24 17:19:44 2023 -0800 @@ -522,55 +522,55 @@ class audioplayer : public octave_base_dld_value { public: - audioplayer (void); - ~audioplayer (void); + audioplayer (); + ~audioplayer (); // Overloaded base functions - double player_value (void) const { return 0; } + double player_value () const { return 0; } virtual double scalar_value (bool = false) const { return 0; } void print (std::ostream& os, bool pr_as_read_syntax = false); void print_raw (std::ostream& os, bool pr_as_read_syntax) const; // Properties - bool is_constant (void) const { return true; } - bool is_defined (void) const { return true; } - bool print_as_scalar (void) const { return true; } - - void init (void); - void init_fn (void); + bool is_constant () const { return true; } + bool is_defined () const { return true; } + bool print_as_scalar () const { return true; } + + void init (); + void init_fn (); void set_y (const octave_value& y); void set_y (octave_function *fcn); void set_y (std::string fcn); - Matrix& get_y (void); - RowVector get_left (void) const; - RowVector get_right (void) const; + Matrix& get_y (); + RowVector get_left () const; + RowVector get_right () const; void set_fs (int fs); - int get_fs (void); + int get_fs (); void set_nbits (int nbits); - int get_nbits (void); + int get_nbits (); void set_id (int id); - int get_id (void); - int get_channels (void); - audio_type get_type (void); + int get_id (); + int get_channels (); + audio_type get_type (); void set_sample_number (unsigned int sample); - unsigned int get_sample_number (void); - unsigned int get_total_samples (void); + unsigned int get_sample_number (); + unsigned int get_total_samples (); void set_end_sample (unsigned int sample); - unsigned int get_end_sample (void); - void reset_end_sample (void); + unsigned int get_end_sample (); + void reset_end_sample (); void set_tag (const charMatrix& tag); - charMatrix get_tag (void); + charMatrix get_tag (); void set_userdata (const octave_value& userdata); - octave_value get_userdata (void); - PaStream * get_stream (void); - - void play (void); - void playblocking (void); - void pause (void); - void resume (void); - void stop (void); - bool isplaying (void); + octave_value get_userdata (); + PaStream * get_stream (); + + void play (); + void playblocking (); + void pause (); + void resume (); + void stop (); + bool isplaying (); octave_function *octave_callback_function; @@ -876,14 +876,14 @@ return paContinue; } -audioplayer::audioplayer (void) +audioplayer::audioplayer () : octave_callback_function (nullptr), id (-1), fs (0), nbits (16), channels (0), sample_number (0), end_sample (-1), tag (""), y (), userdata (Matrix ()), left (), right (), stream (nullptr), output_parameters (), type () { } -audioplayer::~audioplayer (void) +audioplayer::~audioplayer () { if (isplaying ()) { @@ -907,7 +907,7 @@ } void -audioplayer::init_fn (void) +audioplayer::init_fn () { if (Pa_Initialize () != paNoError) error ("audioplayer: initialization error"); @@ -937,7 +937,7 @@ } void -audioplayer::init (void) +audioplayer::init () { // FIXME: Both of these variables are unused. // Should they be eliminated or is something not yet implemented? @@ -1015,19 +1015,19 @@ } Matrix& -audioplayer::get_y (void) +audioplayer::get_y () { return y; } RowVector -audioplayer::get_left (void) const +audioplayer::get_left () const { return left; } RowVector -audioplayer::get_right (void) const +audioplayer::get_right () const { return channels == 1 ? left : right; } @@ -1039,7 +1039,7 @@ } int -audioplayer::get_fs (void) +audioplayer::get_fs () { return fs; } @@ -1051,7 +1051,7 @@ } int -audioplayer::get_nbits (void) +audioplayer::get_nbits () { return nbits; } @@ -1063,19 +1063,19 @@ } int -audioplayer::get_id (void) +audioplayer::get_id () { return id; } int -audioplayer::get_channels (void) +audioplayer::get_channels () { return channels; } audio_type -audioplayer::get_type (void) +audioplayer::get_type () { return type; } @@ -1087,13 +1087,13 @@ } unsigned int -audioplayer::get_sample_number (void) +audioplayer::get_sample_number () { return sample_number; } unsigned int -audioplayer::get_total_samples (void) +audioplayer::get_total_samples () { return left.numel (); } @@ -1105,13 +1105,13 @@ } unsigned int -audioplayer::get_end_sample (void) +audioplayer::get_end_sample () { return end_sample; } void -audioplayer::reset_end_sample (void) +audioplayer::reset_end_sample () { set_end_sample (left.numel ()); } @@ -1123,7 +1123,7 @@ } charMatrix -audioplayer::get_tag (void) +audioplayer::get_tag () { return tag; } @@ -1135,13 +1135,13 @@ } octave_value -audioplayer::get_userdata (void) +audioplayer::get_userdata () { return userdata; } void -audioplayer::playblocking (void) +audioplayer::playblocking () { if (get_stream ()) stop (); @@ -1179,7 +1179,7 @@ } void -audioplayer::play (void) +audioplayer::play () { if (get_stream ()) stop (); @@ -1205,7 +1205,7 @@ } void -audioplayer::pause (void) +audioplayer::pause () { if (get_stream () == nullptr) return; @@ -1217,7 +1217,7 @@ } void -audioplayer::resume (void) +audioplayer::resume () { if (get_stream () == nullptr) return; @@ -1229,13 +1229,13 @@ } PaStream * -audioplayer::get_stream (void) +audioplayer::get_stream () { return stream; } void -audioplayer::stop (void) +audioplayer::stop () { if (get_stream () == nullptr) return; @@ -1258,7 +1258,7 @@ } bool -audioplayer::isplaying (void) +audioplayer::isplaying () { if (get_stream () == nullptr) return false; @@ -1274,53 +1274,53 @@ class audiorecorder : public octave_base_dld_value { public: - audiorecorder (void); - ~audiorecorder (void); + audiorecorder (); + ~audiorecorder (); // Overloaded base functions - double player_value (void) const { return 0; } + double player_value () const { return 0; } virtual double scalar_value (bool = false) const { return 0; } void print (std::ostream& os, bool pr_as_read_syntax = false); void print_raw (std::ostream& os, bool pr_as_read_syntax) const; // Properties - bool is_constant (void) const { return true; } - bool is_defined (void) const { return true; } - bool print_as_scalar (void) const { return true; } - - void init (void); + bool is_constant () const { return true; } + bool is_defined () const { return true; } + bool print_as_scalar () const { return true; } + + void init (); void set_fs (int fs); - int get_fs (void); + int get_fs (); void set_nbits (int nbits); - int get_nbits (void); - PaSampleFormat get_sampleFormat (void); + int get_nbits (); + PaSampleFormat get_sampleFormat (); void set_id (int id); - int get_id (void); + int get_id (); void set_channels (int channels); - int get_channels (void); - audio_type get_type (void); + int get_channels (); + audio_type get_type (); void set_sample_number (unsigned int sample); - unsigned int get_sample_number (void); - unsigned int get_total_samples (void); + unsigned int get_sample_number (); + unsigned int get_total_samples (); void set_end_sample (unsigned int sample); - unsigned int get_end_sample (void); - void reset_end_sample (void); + unsigned int get_end_sample (); + void reset_end_sample (); void set_tag (const charMatrix& tag); - charMatrix get_tag (void); + charMatrix get_tag (); void set_userdata (const octave_value& userdata); - octave_value get_userdata (void); - PaStream * get_stream (void); - - octave_value getaudiodata (void); - audioplayer * getplayer (void); - bool isrecording (void); - audioplayer play (void); - void record (void); + octave_value get_userdata (); + PaStream * get_stream (); + + octave_value getaudiodata (); + audioplayer * getplayer (); + bool isrecording (); + audioplayer play (); + void record (); void recordblocking (float seconds); - void pause (void); - void resume (void); - void stop (void); + void pause (); + void resume (); + void stop (); void append (float sample_l, float sample_r); octave_function *octave_callback_function; @@ -1550,14 +1550,14 @@ return paContinue; } -audiorecorder::audiorecorder (void) +audiorecorder::audiorecorder () : octave_callback_function (nullptr), id (-1), fs (8000), nbits (8), channels (1), sample_number (0), end_sample (-1), tag (""), y (), userdata (Matrix ()), left (), right (), stream (nullptr), input_parameters (), type () { } -audiorecorder::~audiorecorder (void) +audiorecorder::~audiorecorder () { if (isrecording ()) { @@ -1581,7 +1581,7 @@ } void -audiorecorder::init (void) +audiorecorder::init () { if (Pa_Initialize () != paNoError) error ("audiorecorder: initialization error"); @@ -1623,7 +1623,7 @@ } int -audiorecorder::get_fs (void) +audiorecorder::get_fs () { return fs; } @@ -1635,13 +1635,13 @@ } int -audiorecorder::get_nbits (void) +audiorecorder::get_nbits () { return nbits; } PaSampleFormat -audiorecorder::get_sampleFormat (void) +audiorecorder::get_sampleFormat () { return input_parameters.sampleFormat; } @@ -1653,7 +1653,7 @@ } int -audiorecorder::get_id (void) +audiorecorder::get_id () { return id; } @@ -1668,13 +1668,13 @@ } int -audiorecorder::get_channels (void) +audiorecorder::get_channels () { return channels; } audio_type -audiorecorder::get_type (void) +audiorecorder::get_type () { return type; } @@ -1686,13 +1686,13 @@ } unsigned int -audiorecorder::get_sample_number (void) +audiorecorder::get_sample_number () { return sample_number; } unsigned int -audiorecorder::get_total_samples (void) +audiorecorder::get_total_samples () { return left.size (); } @@ -1704,13 +1704,13 @@ } unsigned int -audiorecorder::get_end_sample (void) +audiorecorder::get_end_sample () { return end_sample; } void -audiorecorder::reset_end_sample (void) +audiorecorder::reset_end_sample () { set_end_sample (left.size ()); } @@ -1722,7 +1722,7 @@ } charMatrix -audiorecorder::get_tag (void) +audiorecorder::get_tag () { return tag; } @@ -1734,13 +1734,13 @@ } octave_value -audiorecorder::get_userdata (void) +audiorecorder::get_userdata () { return userdata; } octave_value -audiorecorder::getaudiodata (void) +audiorecorder::getaudiodata () { // Must get size before entering loop as the value of left.size() may change // during loop with simultaneous recording and playback (bug #50674). @@ -1757,7 +1757,7 @@ } audioplayer * -audiorecorder::getplayer (void) +audiorecorder::getplayer () { audioplayer *player = new audioplayer (); @@ -1770,7 +1770,7 @@ } bool -audiorecorder::isrecording (void) +audiorecorder::isrecording () { if (get_stream () == nullptr) return false; @@ -1784,7 +1784,7 @@ } void -audiorecorder::record (void) +audiorecorder::record () { if (get_stream ()) stop (); @@ -1855,7 +1855,7 @@ } void -audiorecorder::pause (void) +audiorecorder::pause () { if (get_stream () == nullptr) return; @@ -1867,7 +1867,7 @@ } void -audiorecorder::resume (void) +audiorecorder::resume () { if (get_stream () == nullptr) return; @@ -1879,7 +1879,7 @@ } void -audiorecorder::stop (void) +audiorecorder::stop () { if (get_stream () == nullptr) return; @@ -1910,7 +1910,7 @@ } PaStream * -audiorecorder::get_stream (void) +audiorecorder::get_stream () { return stream; } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/dldfcn/gzip.cc --- a/libinterp/dldfcn/gzip.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/dldfcn/gzip.cc Tue Jan 24 17:19:44 2023 -0800 @@ -98,7 +98,7 @@ { public: - CFile (void) = delete; + CFile () = delete; CFile (const std::string& path, const std::string& mode) : m_fp (sys::fopen (path, mode)) @@ -111,13 +111,13 @@ CFile& operator = (const CFile&) = delete; - ~CFile (void) + ~CFile () { if (m_fp) std::fclose (m_fp); } - void close (void) + void close () { if (std::fclose (m_fp)) throw std::runtime_error ("unable to close file"); @@ -150,7 +150,7 @@ { public: - zipper (void) = delete; + zipper () = delete; zipper (const std::string& source_path, const std::string& dest_path) : m_status (BZ_OK), m_source (source_path, "rb"), @@ -165,13 +165,13 @@ zipper& operator = (const zipper&) = delete; - ~zipper (void) + ~zipper () { if (m_bz != nullptr) BZ2_bzWriteClose (&m_status, m_bz, 1, nullptr, nullptr); } - void deflate (void) + void deflate () { const std::size_t buf_len = 8192; char buf[buf_len]; @@ -188,7 +188,7 @@ throw std::runtime_error ("failed to read from source file"); } - void close (void) + void close () { int abandon = (m_status == BZ_IO_ERROR) ? 1 : 0; BZ2_bzWriteClose (&m_status, m_bz, abandon, nullptr, nullptr); @@ -265,7 +265,7 @@ // Bytef is a typedef for unsigned char unsigned char *p; - uchar_array (void) = delete; + uchar_array () = delete; uchar_array (const std::string& str) { @@ -277,14 +277,14 @@ uchar_array& operator = (const uchar_array&) = delete; - ~uchar_array (void) { delete[] p; } + ~uchar_array () { delete[] p; } }; class gzip_header : public gz_header { public: - gzip_header (void) = delete; + gzip_header () = delete; gzip_header (const std::string& source_path) : m_basename (sys::env::base_pathname (source_path)) @@ -357,7 +357,7 @@ gzip_header& operator = (const gzip_header&) = delete; - ~gzip_header (void) = default; + ~gzip_header () = default; private: @@ -369,7 +369,7 @@ { public: - zipper (void) = delete; + zipper () = delete; zipper (const std::string& source_path, const std::string& dest_path) : m_source (source_path, "rb"), m_dest (dest_path, "wb"), @@ -384,14 +384,14 @@ zipper& operator = (const zipper&) = delete; - ~zipper (void) + ~zipper () { if (m_strm) deflateEnd (m_strm); delete m_strm; } - void deflate (void) + void deflate () { // int deflateInit2 (z_streamp m_strm, // int level, // compression level (default is 8) @@ -451,7 +451,7 @@ throw std::runtime_error ("failed to write file"); } - void close (void) + void close () { if (deflateEnd (m_strm) != Z_OK) throw std::runtime_error ("failed to close zlib stream"); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/liboctinterp-build-info.h --- a/libinterp/liboctinterp-build-info.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/liboctinterp-build-info.h Tue Jan 24 17:19:44 2023 -0800 @@ -30,6 +30,6 @@ #include -extern OCTINTERP_API std::string liboctinterp_hg_id (void); +extern OCTINTERP_API std::string liboctinterp_hg_id (); #endif diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/liboctinterp-build-info.in.cc --- a/libinterp/liboctinterp-build-info.in.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/liboctinterp-build-info.in.cc Tue Jan 24 17:19:44 2023 -0800 @@ -32,7 +32,7 @@ #include "liboctinterp-build-info.h" std::string -liboctinterp_hg_id (void) +liboctinterp_hg_id () { return "%OCTAVE_HG_ID%"; } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/mk-build-env-features.sh --- a/libinterp/mk-build-env-features.sh Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/mk-build-env-features.sh Tue Jan 24 17:19:44 2023 -0800 @@ -48,7 +48,7 @@ OCTAVE_BEGIN_NAMESPACE(build_env) octave_scalar_map - features (void) + features () { static bool initialized = false; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/mk-builtins.pl --- a/libinterp/mk-builtins.pl Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/mk-builtins.pl Tue Jan 24 17:19:44 2023 -0800 @@ -297,7 +297,7 @@ print " void - symbol_table::install_builtins (void) + symbol_table::install_builtins () { "; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/cdef-class.cc --- a/libinterp/octave-value/cdef-class.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/cdef-class.cc Tue Jan 24 17:19:44 2023 -0800 @@ -131,7 +131,7 @@ { public: - ctor_analyzer (void) = delete; + ctor_analyzer () = delete; ctor_analyzer (const std::string& ctor, const std::string& obj) : tree_walker (), m_who (ctor), m_obj_name (obj) { } @@ -140,7 +140,7 @@ ctor_analyzer& operator = (const ctor_analyzer&) = delete; - ~ctor_analyzer (void) = default; + ~ctor_analyzer () = default; void visit_statement (tree_statement& t) { @@ -163,7 +163,7 @@ t.expression ()->accept (*this); } - std::list get_constructor_list (void) const + std::list get_constructor_list () const { return m_ctor_list; } // NO-OP @@ -278,7 +278,7 @@ } void -cdef_class::cdef_class_rep::load_all_methods (void) +cdef_class::cdef_class_rep::load_all_methods () { // FIXME: re-scan class directory } @@ -515,7 +515,7 @@ } string_vector -cdef_class::cdef_class_rep::get_names (void) +cdef_class::cdef_class_rep::get_names () { std::set names; @@ -632,7 +632,7 @@ } void -cdef_class::cdef_class_rep::meta_release (void) +cdef_class::cdef_class_rep::meta_release () { cdef_manager& cdm = __get_cdef_manager__ (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/cdef-class.h --- a/libinterp/octave-value/cdef-class.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/cdef-class.h Tue Jan 24 17:19:44 2023 -0800 @@ -58,7 +58,7 @@ cdef_class_rep : public cdef_meta_object_rep { public: - cdef_class_rep (void) + cdef_class_rep () : cdef_meta_object_rep (), m_member_count (0), m_handle_class (false), m_meta (false) { } @@ -67,20 +67,20 @@ cdef_class_rep& operator = (const cdef_class_rep&) = delete; - ~cdef_class_rep (void) = default; + ~cdef_class_rep () = default; - cdef_object_rep * copy (void) const { return new cdef_class_rep (*this); } + cdef_object_rep * copy () const { return new cdef_class_rep (*this); } - bool is_class (void) const { return true; } + bool is_class () const { return true; } - std::string get_name (void) const + std::string get_name () const { return get ("Name").string_value (); } void set_name (const std::string& nm) { put ("Name", nm); } - bool is_abstract (void) const { return get ("Abstract").bool_value (); } + bool is_abstract () const { return get ("Abstract").bool_value (); } - bool is_sealed (void) const { return get ("Sealed").bool_value (); } + bool is_sealed () const { return get ("Sealed").bool_value (); } OCTINTERP_API cdef_method find_method (const std::string& nm, bool local = false); @@ -103,11 +103,11 @@ OCTINTERP_API std::map get_property_map (int mode); - OCTINTERP_API string_vector get_names (void); + OCTINTERP_API string_vector get_names (); void set_directory (const std::string& dir) { m_directory = dir; } - std::string get_directory (void) const { return m_directory; } + std::string get_directory () const { return m_directory; } OCTINTERP_API void delete_object (const cdef_object& obj); @@ -115,7 +115,7 @@ meta_subsref (const std::string& type, const std::list& idx, int nargout); - OCTINTERP_API void meta_release (void); + OCTINTERP_API void meta_release (); bool meta_accepts_postfix_index (char type) const { @@ -134,13 +134,13 @@ OCTINTERP_API void run_constructor (cdef_object& obj, const octave_value_list& args); - void mark_as_handle_class (void) { m_handle_class = true; } + void mark_as_handle_class () { m_handle_class = true; } - bool is_handle_class (void) const { return m_handle_class; } + bool is_handle_class () const { return m_handle_class; } - octave_idx_type static_count (void) const { return m_member_count; } + octave_idx_type static_count () const { return m_member_count; } - void destroy (void) + void destroy () { if (m_member_count) { @@ -155,21 +155,21 @@ delete this; } - void mark_as_meta_class (void) { m_meta = true; } + void mark_as_meta_class () { m_meta = true; } - bool is_meta_class (void) const { return m_meta; } + bool is_meta_class () const { return m_meta; } void doc_string (const std::string& txt) { m_doc_string = txt; } - std::string doc_string (void) const { return m_doc_string; } + std::string doc_string () const { return m_doc_string; } void file_name (const std::string& nm) { m_file_name = nm; } - std::string file_name (void) const { return m_file_name; } + std::string file_name () const { return m_file_name; } private: - OCTINTERP_API void load_all_methods (void); + OCTINTERP_API void load_all_methods (); OCTINTERP_API void find_names (std::set& names, bool all); @@ -181,7 +181,7 @@ find_methods (std::map& meths, bool only_inherited, bool include_ctor = false); - cdef_class wrap (void) + cdef_class wrap () { m_count++; return cdef_class (this); @@ -237,7 +237,7 @@ // Create an invalid class object. - cdef_class (void) : cdef_meta_object () { } + cdef_class () : cdef_meta_object () { } cdef_class (const std::string& nm, const std::list& superclasses) @@ -264,7 +264,7 @@ return *this; } - ~cdef_class (void) = default; + ~cdef_class () = default; OCTINTERP_API cdef_method find_method (const std::string& nm, bool local = false); @@ -303,25 +303,25 @@ return get_rep ()->get_property_map (mode); } - string_vector get_names (void) { return get_rep ()->get_names (); } + string_vector get_names () { return get_rep ()->get_names (); } - bool is_abstract (void) const { return get_rep ()->is_abstract (); } + bool is_abstract () const { return get_rep ()->is_abstract (); } - bool is_sealed (void) const { return get_rep ()->is_sealed (); } + bool is_sealed () const { return get_rep ()->is_sealed (); } void set_directory (const std::string& dir) { get_rep ()->set_directory (dir); } - std::string get_directory (void) const + std::string get_directory () const { return get_rep ()->get_directory (); } - std::string get_name (void) const { return get_rep ()->get_name (); } + std::string get_name () const { return get_rep ()->get_name (); } - bool is_builtin (void) const { return get_directory ().empty (); } + bool is_builtin () const { return get_directory ().empty (); } void delete_object (const cdef_object& obj) { @@ -359,7 +359,7 @@ OCTINTERP_API octave_value get_method_function (const std::string& nm); - octave_value get_constructor_function (void) + octave_value get_constructor_function () { return get_method_function (get_name ()); } @@ -384,27 +384,27 @@ get_rep ()->run_constructor (obj, args); } - void mark_as_handle_class (void) + void mark_as_handle_class () { get_rep ()->mark_as_handle_class (); } - bool is_handle_class (void) const + bool is_handle_class () const { return get_rep ()->is_handle_class (); } - void mark_as_meta_class (void) { get_rep ()->mark_as_meta_class (); } + void mark_as_meta_class () { get_rep ()->mark_as_meta_class (); } - bool is_meta_class (void) const { return get_rep ()->is_meta_class (); } + bool is_meta_class () const { return get_rep ()->is_meta_class (); } void doc_string (const std::string& txt) { get_rep ()->doc_string (txt); } - std::string doc_string (void) const { return get_rep ()->doc_string (); } + std::string doc_string () const { return get_rep ()->doc_string (); } void file_name (const std::string& nm) { get_rep ()->file_name (nm); } - std::string file_name (void) const { return get_rep ()->file_name (); } + std::string file_name () const { return get_rep ()->file_name (); } public: @@ -417,12 +417,12 @@ private: - cdef_class_rep * get_rep (void) + cdef_class_rep * get_rep () { return dynamic_cast (cdef_object::get_rep ()); } - const cdef_class_rep * get_rep (void) const + const cdef_class_rep * get_rep () const { return dynamic_cast (cdef_object::get_rep ()); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/cdef-manager.h --- a/libinterp/octave-value/cdef-manager.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/cdef-manager.h Tue Jan 24 17:19:44 2023 -0800 @@ -53,7 +53,7 @@ cdef_manager& operator = (const cdef_manager&) = delete; - ~cdef_manager (void) = default; + ~cdef_manager () = default; OCTINTERP_API cdef_class find_class (const std::string& name, bool error_if_not_found = true, @@ -90,12 +90,12 @@ m_all_packages.erase (pkg.get_name ()); } - const cdef_class& meta_class (void) const { return m_meta_class; } - const cdef_class& meta_property (void) const { return m_meta_property; } - const cdef_class& meta_method (void) const { return m_meta_method; } - const cdef_class& meta_package (void) const { return m_meta_package; } + const cdef_class& meta_class () const { return m_meta_class; } + const cdef_class& meta_property () const { return m_meta_property; } + const cdef_class& meta_method () const { return m_meta_method; } + const cdef_class& meta_package () const { return m_meta_package; } - const cdef_package& meta (void) const { return m_meta; } + const cdef_package& meta () const { return m_meta; } OCTINTERP_API cdef_class make_class (const std::string& name, diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/cdef-method.cc --- a/libinterp/octave-value/cdef-method.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/cdef-method.cc Tue Jan 24 17:19:44 2023 -0800 @@ -68,7 +68,7 @@ } void -cdef_method::cdef_method_rep::check_method (void) +cdef_method::cdef_method_rep::check_method () { if (is_external ()) { @@ -179,7 +179,7 @@ } bool -cdef_method::cdef_method_rep::is_constructor (void) const +cdef_method::cdef_method_rep::is_constructor () const { if (m_function.is_function()) return m_function.function_value ()->is_classdef_constructor (); @@ -196,7 +196,7 @@ } std::string -cdef_method::cdef_method_rep::get_doc_string (void) +cdef_method::cdef_method_rep::get_doc_string () { check_method (); @@ -206,7 +206,7 @@ } bool -cdef_method::cdef_method_rep::check_access (void) const +cdef_method::cdef_method_rep::check_access () const { cdef_class cls (to_cdef (get ("DefiningClass"))); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/cdef-method.h --- a/libinterp/octave-value/cdef-method.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/cdef-method.h Tue Jan 24 17:19:44 2023 -0800 @@ -52,33 +52,33 @@ { public: - cdef_method_rep (void) + cdef_method_rep () : cdef_meta_object_rep (), m_function (), m_dispatch_type () { } cdef_method_rep& operator = (const cdef_method_rep& m) = delete; - ~cdef_method_rep (void) = default; + ~cdef_method_rep () = default; - cdef_object_rep * copy (void) const { return new cdef_method_rep(*this); } + cdef_object_rep * copy () const { return new cdef_method_rep(*this); } - bool is_method (void) const { return true; } + bool is_method () const { return true; } - std::string get_name (void) const { return get("Name").string_value (); } + std::string get_name () const { return get("Name").string_value (); } void set_name (const std::string& nm) { put ("Name", nm); } - bool is_static (void) const { return get("Static").bool_value (); } + bool is_static () const { return get("Static").bool_value (); } - octave_value get_function (void) const { return m_function; } + octave_value get_function () const { return m_function; } void set_function (const octave_value& fcn) { m_function = fcn; } - OCTINTERP_API std::string get_doc_string (void); + OCTINTERP_API std::string get_doc_string (); - OCTINTERP_API bool check_access (void) const; + OCTINTERP_API bool check_access () const; - bool is_external (void) const { return ! m_dispatch_type.empty (); } + bool is_external () const { return ! m_dispatch_type.empty (); } void mark_as_external (const std::string& dtype) { @@ -94,7 +94,7 @@ const octave_value_list& args, int nargout, bool do_check_access = true, const std::string& who = ""); - OCTINTERP_API bool is_constructor (void) const; + OCTINTERP_API bool is_constructor () const; OCTINTERP_API bool is_defined_in_class (const std::string& cname) const; @@ -114,9 +114,9 @@ m_dispatch_type (m.m_dispatch_type) { } - OCTINTERP_API void check_method (void); + OCTINTERP_API void check_method (); - cdef_method wrap (void) + cdef_method wrap () { m_count++; return cdef_method (this); @@ -132,7 +132,7 @@ public: - cdef_method (void) : cdef_meta_object () { } + cdef_method () : cdef_meta_object () { } cdef_method (const std::string& nm) : cdef_meta_object (new cdef_method_rep ()) @@ -158,7 +158,7 @@ return *this; } - ~cdef_method (void) = default; + ~cdef_method () = default; // normal invocation octave_value_list execute (const octave_value_list& args, int nargout, @@ -177,28 +177,28 @@ return get_rep ()->execute (obj, args, nargout, do_check_access, who); } - bool check_access (void) const { return get_rep ()->check_access (); } + bool check_access () const { return get_rep ()->check_access (); } - std::string get_name (void) const { return get_rep ()->get_name (); } + std::string get_name () const { return get_rep ()->get_name (); } - bool is_static (void) const { return get_rep ()->is_static (); } + bool is_static () const { return get_rep ()->is_static (); } void set_function (const octave_value& fcn) { get_rep ()->set_function (fcn); } - octave_value get_function (void) const + octave_value get_function () const { return get_rep ()->get_function (); } - std::string get_doc_string (void) + std::string get_doc_string () { return get_rep ()->get_doc_string (); } - bool is_constructor (void) const + bool is_constructor () const { return get_rep ()->is_constructor (); } @@ -208,7 +208,7 @@ return get_rep ()->is_defined_in_class (cname); } - bool is_external (void) const { return get_rep ()->is_external (); } + bool is_external () const { return get_rep ()->is_external (); } void mark_as_external (const std::string& dtype) { @@ -217,12 +217,12 @@ private: - cdef_method_rep * get_rep (void) + cdef_method_rep * get_rep () { return dynamic_cast (cdef_object::get_rep ()); } - const cdef_method_rep * get_rep (void) const + const cdef_method_rep * get_rep () const { return dynamic_cast (cdef_object::get_rep ()); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/cdef-object.cc --- a/libinterp/octave-value/cdef-object.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/cdef-object.cc Tue Jan 24 17:19:44 2023 -0800 @@ -111,19 +111,19 @@ } cdef_class -cdef_object_rep::get_class (void) const +cdef_object_rep::get_class () const { err_invalid_object ("get_class"); } std::string -cdef_object_rep::class_name (void) const +cdef_object_rep::class_name () const { return get_class ().get_name (); } string_vector -cdef_object_rep::map_keys (void) const +cdef_object_rep::map_keys () const { cdef_class cls = get_class (); @@ -134,7 +134,7 @@ } octave_map -cdef_object::map_value (void) const +cdef_object::map_value () const { octave_map retval; @@ -180,13 +180,13 @@ } cdef_class -cdef_object::get_class (void) const +cdef_object::get_class () const { return m_rep->get_class (); } cdef_class -cdef_object_base::get_class (void) const +cdef_object_base::get_class () const { return cdef_class (m_klass); } @@ -203,7 +203,7 @@ } cdef_object_rep * -cdef_object_base::make_array (void) const +cdef_object_base::make_array () const { cdef_object_rep *r = new cdef_object_array (); @@ -735,7 +735,7 @@ m_ctor_list.erase (cls); } -handle_cdef_object::~handle_cdef_object (void) +handle_cdef_object::~handle_cdef_object () { #if DEBUG_TRACE std::cerr << "deleting " << get_class ().get_name () @@ -743,7 +743,7 @@ #endif } -value_cdef_object::~value_cdef_object (void) +value_cdef_object::~value_cdef_object () { #if DEBUG_TRACE std::cerr << "deleting " << get_class ().get_name () diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/cdef-object.h --- a/libinterp/octave-value/cdef-object.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/cdef-object.h Tue Jan 24 17:19:44 2023 -0800 @@ -53,48 +53,48 @@ friend class cdef_object; - cdef_object_rep (void) : m_count (1) { } + cdef_object_rep () : m_count (1) { } cdef_object_rep& operator = (const cdef_object_rep&) = delete; - virtual ~cdef_object_rep (void) = default; + virtual ~cdef_object_rep () = default; - virtual cdef_class get_class (void) const; + virtual cdef_class get_class () const; virtual void set_class (const cdef_class&) { err_invalid_object ("set_class"); } - virtual cdef_object_rep * clone (void) const + virtual cdef_object_rep * clone () const { err_invalid_object ("clone"); } - virtual cdef_object_rep * empty_clone (void) const + virtual cdef_object_rep * empty_clone () const { err_invalid_object ("empty_clone"); } - virtual cdef_object_rep * copy (void) const + virtual cdef_object_rep * copy () const { err_invalid_object ("copy"); } - virtual cdef_object_rep * make_array (void) const + virtual cdef_object_rep * make_array () const { err_invalid_object ("make_array"); } - virtual bool is_array (void) const { return false; } + virtual bool is_array () const { return false; } - virtual bool is_value_object (void) const { return false; } + virtual bool is_value_object () const { return false; } - virtual bool is_handle_object (void) const { return false; } + virtual bool is_handle_object () const { return false; } - virtual bool is_meta_object (void) const { return false; } + virtual bool is_meta_object () const { return false; } - virtual Array array_value (void) const + virtual Array array_value () const { err_invalid_object ("array_value"); } @@ -137,11 +137,11 @@ err_invalid_object ("subsasgn"); } - virtual string_vector map_keys (void) const; + virtual string_vector map_keys () const; - virtual bool is_valid (void) const { return false; } + virtual bool is_valid () const { return false; } - OCTINTERP_API std::string class_name (void) const; + OCTINTERP_API std::string class_name () const; virtual void mark_for_construction (const cdef_class&) { @@ -158,7 +158,7 @@ err_invalid_object ("is_partially_constructed_for"); } - virtual void mark_as_constructed (void) + virtual void mark_as_constructed () { err_invalid_object ("mark_as_constructed"); } @@ -168,18 +168,18 @@ err_invalid_object ("mark_as_constructed"); } - virtual bool is_constructed (void) const + virtual bool is_constructed () const { err_invalid_object ("is_constructed"); } - virtual octave_idx_type static_count (void) const { return 0; } + virtual octave_idx_type static_count () const { return 0; } - virtual void destroy (void) { delete this; } + virtual void destroy () { delete this; } OCTINTERP_API void release (const cdef_object& obj); - virtual dim_vector dims (void) const { return dim_vector (); } + virtual dim_vector dims () const { return dim_vector (); } protected: @@ -205,14 +205,14 @@ public: // FIXME: use a null object? - cdef_object (void) : m_rep (new cdef_object_rep ()) { } + cdef_object () : m_rep (new cdef_object_rep ()) { } cdef_object (const cdef_object& obj) : m_rep (obj.m_rep) { m_rep->m_count++; } cdef_object (cdef_object_rep *r) : m_rep (r) { } - virtual ~cdef_object (void) { m_rep->release (*this); } + virtual ~cdef_object () { m_rep->release (*this); } cdef_object& operator = (const cdef_object& obj) { @@ -227,37 +227,37 @@ return *this; } - OCTINTERP_API cdef_class get_class (void) const; + OCTINTERP_API cdef_class get_class () const; void set_class (const cdef_class& cls) { m_rep->set_class (cls); } - std::string class_name (void) const { return m_rep->class_name (); } + std::string class_name () const { return m_rep->class_name (); } - cdef_object clone (void) const { return cdef_object (m_rep->clone ()); } + cdef_object clone () const { return cdef_object (m_rep->clone ()); } - cdef_object empty_clone (void) const + cdef_object empty_clone () const { return cdef_object (m_rep->empty_clone ()); } - dim_vector dims (void) const { return m_rep->dims (); } + dim_vector dims () const { return m_rep->dims (); } - cdef_object make_array (void) const + cdef_object make_array () const { return cdef_object (m_rep->make_array ()); } - cdef_object copy (void) const { return cdef_object (m_rep->copy ()); } + cdef_object copy () const { return cdef_object (m_rep->copy ()); } - bool is_array (void) const { return m_rep->is_array (); } + bool is_array () const { return m_rep->is_array (); } - bool is_value_object (void) const { return m_rep->is_value_object (); } + bool is_value_object () const { return m_rep->is_value_object (); } - bool is_handle_object (void) const { return m_rep->is_handle_object (); } + bool is_handle_object () const { return m_rep->is_handle_object (); } - bool is_meta_object (void) const { return m_rep->is_meta_object (); } + bool is_meta_object () const { return m_rep->is_meta_object (); } - Array array_value (void) const + Array array_value () const { return m_rep->array_value (); } void put (const std::string& pname, const octave_value& val) @@ -303,20 +303,20 @@ return m_rep->subsasgn (type, idx, rhs); } - string_vector map_keys (void) const { return m_rep->map_keys (); } + string_vector map_keys () const { return m_rep->map_keys (); } - OCTINTERP_API octave_map map_value (void) const; + OCTINTERP_API octave_map map_value () const; - const cdef_object_rep * get_rep (void) const { return m_rep; } + const cdef_object_rep * get_rep () const { return m_rep; } - bool ok (void) const { return m_rep->is_valid (); } + bool ok () const { return m_rep->is_valid (); } void mark_for_construction (const cdef_class& cls) { m_rep->mark_for_construction (cls); } - bool is_constructed (void) const { return m_rep->is_constructed (); } + bool is_constructed () const { return m_rep->is_constructed (); } bool is_constructed_for (const cdef_class& cls) const { @@ -328,7 +328,7 @@ return m_rep->is_partially_constructed_for (cls); } - void mark_as_constructed (void) { m_rep->mark_as_constructed (); } + void mark_as_constructed () { m_rep->mark_as_constructed (); } void mark_as_constructed (const cdef_class& cls) { m_rep->mark_as_constructed (cls); } @@ -337,7 +337,7 @@ protected: - cdef_object_rep * get_rep (void) { return m_rep; } + cdef_object_rep * get_rep () { return m_rep; } void make_unique (int ignore_copies) { @@ -356,24 +356,24 @@ { public: - cdef_object_base (void) + cdef_object_base () : cdef_object_rep (), m_klass () { } cdef_object_base& operator = (const cdef_object_base&) = delete; - ~cdef_object_base (void) { } + ~cdef_object_base () { } - OCTINTERP_API cdef_class get_class (void) const; + OCTINTERP_API cdef_class get_class () const; OCTINTERP_API void set_class (const cdef_class& cls); - cdef_object_rep * empty_clone (void) const + cdef_object_rep * empty_clone () const { return new cdef_object_base (*this); } - OCTINTERP_API cdef_object_rep * make_array (void) const; + OCTINTERP_API cdef_object_rep * make_array () const; protected: @@ -394,7 +394,7 @@ { public: - cdef_object_array (void) : cdef_object_base () { } + cdef_object_array () : cdef_object_base () { } cdef_object_array (const Array& a) : cdef_object_base (), m_array (a) @@ -402,20 +402,20 @@ cdef_object_array& operator = (const cdef_object_array&) = delete; - ~cdef_object_array (void) = default; + ~cdef_object_array () = default; - cdef_object_rep * clone (void) const + cdef_object_rep * clone () const { return new cdef_object_array (*this); } - dim_vector dims (void) const { return m_array.dims (); } + dim_vector dims () const { return m_array.dims (); } - bool is_valid (void) const { return true; } + bool is_valid () const { return true; } - bool is_array (void) const { return true; } + bool is_array () const { return true; } - Array array_value (void) const { return m_array; } + Array array_value () const { return m_array; } OCTINTERP_API octave_value_list subsref (const std::string& type, const std::list& idx, @@ -446,7 +446,7 @@ Array m_array; - void fill_empty_values (void) { fill_empty_values (m_array); } + void fill_empty_values () { fill_empty_values (m_array); } OCTINTERP_API void fill_empty_values (Array& arr); @@ -462,13 +462,13 @@ { public: - cdef_object_scalar (void) : cdef_object_base () { } + cdef_object_scalar () : cdef_object_base () { } cdef_object_scalar& operator = (const cdef_object_scalar&) = delete; - ~cdef_object_scalar (void) = default; + ~cdef_object_scalar () = default; - dim_vector dims (void) const { return dim_vector (1, 1); } + dim_vector dims () const { return dim_vector (1, 1); } void break_closure_cycles (const std::shared_ptr& frame); @@ -521,11 +521,11 @@ OCTINTERP_API bool is_partially_constructed_for (const cdef_class& cls) const; - void mark_as_constructed (void) { m_ctor_list.clear (); } + void mark_as_constructed () { m_ctor_list.clear (); } OCTINTERP_API void mark_as_constructed (const cdef_class& cls); - bool is_constructed (void) const { return m_ctor_list.empty (); } + bool is_constructed () const { return m_ctor_list.empty (); } protected: @@ -549,27 +549,27 @@ { public: - handle_cdef_object (void) : cdef_object_scalar () { } + handle_cdef_object () : cdef_object_scalar () { } handle_cdef_object& operator = (const handle_cdef_object&) = delete; - OCTINTERP_API ~handle_cdef_object (void); + OCTINTERP_API ~handle_cdef_object (); - cdef_object_rep * clone (void) const + cdef_object_rep * clone () const { handle_cdef_object *obj = const_cast (this); obj->m_count++; return obj; } - cdef_object_rep * copy (void) const + cdef_object_rep * copy () const { return new handle_cdef_object (*this); } - bool is_valid (void) const { return true; } + bool is_valid () const { return true; } - bool is_handle_object (void) const { return true; } + bool is_handle_object () const { return true; } protected: @@ -585,22 +585,22 @@ { public: - value_cdef_object (void) : cdef_object_scalar () { } + value_cdef_object () : cdef_object_scalar () { } value_cdef_object& operator = (const value_cdef_object&) = delete; - OCTINTERP_API ~value_cdef_object (void); + OCTINTERP_API ~value_cdef_object (); - cdef_object_rep * clone (void) const + cdef_object_rep * clone () const { return new value_cdef_object (*this); } - cdef_object_rep * copy (void) const { return clone (); } + cdef_object_rep * copy () const { return clone (); } - bool is_valid (void) const { return true; } + bool is_valid () const { return true; } - bool is_value_object (void) const { return true; } + bool is_value_object () const { return true; } private: @@ -616,24 +616,24 @@ { public: - cdef_meta_object_rep (void) : handle_cdef_object () { } + cdef_meta_object_rep () : handle_cdef_object () { } cdef_meta_object_rep& operator = (const cdef_meta_object_rep&) = delete; - ~cdef_meta_object_rep (void) = default; + ~cdef_meta_object_rep () = default; - cdef_object_rep * copy (void) const + cdef_object_rep * copy () const { return new cdef_meta_object_rep (*this); } - bool is_meta_object (void) const { return true; } + bool is_meta_object () const { return true; } - virtual bool is_class (void) const { return false; } + virtual bool is_class () const { return false; } - virtual bool is_property (void) const { return false; } + virtual bool is_property () const { return false; } - virtual bool is_method (void) const { return false; } + virtual bool is_method () const { return false; } - virtual bool is_package (void) const { return false; } + virtual bool is_package () const { return false; } virtual octave_value_list meta_subsref (const std::string& /* type */, @@ -643,7 +643,7 @@ error ("subsref: invalid meta object"); } - virtual void meta_release (void) { } + virtual void meta_release () { } virtual bool meta_accepts_postfix_index (char /* type */) const { @@ -664,7 +664,7 @@ { public: - cdef_meta_object (void) : cdef_object () { } + cdef_meta_object () : cdef_object () { } // Object consistency is checked in sub-classes. cdef_meta_object (const cdef_meta_object& obj) : cdef_object (obj) { } @@ -675,15 +675,15 @@ cdef_meta_object& operator = (const cdef_object&) = delete; - ~cdef_meta_object (void) = default; + ~cdef_meta_object () = default; - bool is_class (void) const { return get_rep ()->is_class (); } + bool is_class () const { return get_rep ()->is_class (); } - bool is_property (void) const { return get_rep ()->is_property (); } + bool is_property () const { return get_rep ()->is_property (); } - bool is_method (void) const { return get_rep ()->is_method (); } + bool is_method () const { return get_rep ()->is_method (); } - bool is_package (void) const { return get_rep ()->is_package (); } + bool is_package () const { return get_rep ()->is_package (); } octave_value_list meta_subsref (const std::string& type, @@ -692,7 +692,7 @@ return get_rep ()->meta_subsref (type, idx, nargout); } - void meta_release (void) { get_rep ()->meta_release (); } + void meta_release () { get_rep ()->meta_release (); } bool meta_accepts_postfix_index (char type) const { @@ -701,12 +701,12 @@ private: - cdef_meta_object_rep * get_rep (void) + cdef_meta_object_rep * get_rep () { return dynamic_cast (cdef_object::get_rep ()); } - const cdef_meta_object_rep * get_rep (void) const + const cdef_meta_object_rep * get_rep () const { return dynamic_cast (cdef_object::get_rep ()); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/cdef-package.cc --- a/libinterp/octave-value/cdef-package.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/cdef-package.cc Tue Jan 24 17:19:44 2023 -0800 @@ -91,19 +91,19 @@ } Cell -cdef_package::cdef_package_rep::get_classes (void) const +cdef_package::cdef_package_rep::get_classes () const { return map2Cell (m_class_map); } Cell -cdef_package::cdef_package_rep::get_functions (void) const +cdef_package::cdef_package_rep::get_functions () const { return map2Cell (m_function_map); } Cell -cdef_package::cdef_package_rep::get_packages (void) const +cdef_package::cdef_package_rep::get_packages () const { return map2Cell (m_package_map); } @@ -186,7 +186,7 @@ } void -cdef_package::cdef_package_rep::meta_release (void) +cdef_package::cdef_package_rep::meta_release () { // FIXME: Do we really want to unregister the package, as it // could still be referenced by classes or sub-packages? diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/cdef-package.h --- a/libinterp/octave-value/cdef-package.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/cdef-package.h Tue Jan 24 17:19:44 2023 -0800 @@ -55,18 +55,18 @@ { public: - cdef_package_rep (void) : cdef_meta_object_rep (), m_member_count (0) { } + cdef_package_rep () : cdef_meta_object_rep (), m_member_count (0) { } cdef_package_rep& operator = (const cdef_package_rep&) = delete; - ~cdef_package_rep (void) = default; + ~cdef_package_rep () = default; - cdef_object_rep * copy (void) const + cdef_object_rep * copy () const { return new cdef_package_rep (*this); } - bool is_package (void) const { return true; } + bool is_package () const { return true; } - std::string get_name (void) const { return get("Name").string_value (); } + std::string get_name () const { return get("Name").string_value (); } void set_name (const std::string& nm) { put ("Name", nm); } @@ -79,15 +79,15 @@ OCTINTERP_API void install_package (const cdef_package& pack, const std::string& nm); - OCTINTERP_API Cell get_classes (void) const; + OCTINTERP_API Cell get_classes () const; - OCTINTERP_API Cell get_functions (void) const; + OCTINTERP_API Cell get_functions () const; - OCTINTERP_API Cell get_packages (void) const; + OCTINTERP_API Cell get_packages () const; - octave_idx_type static_count (void) const { return m_member_count; } + octave_idx_type static_count () const { return m_member_count; } - void destroy (void) + void destroy () { if (m_member_count) { @@ -106,7 +106,7 @@ meta_subsref (const std::string& type, const std::list& idx, int nargout); - OCTINTERP_API void meta_release (void); + OCTINTERP_API void meta_release (); bool meta_accepts_postfix_index (char type) const { @@ -141,7 +141,7 @@ m_package_map (p.m_package_map), m_member_count (p.m_member_count) { } - cdef_package wrap (void) + cdef_package wrap () { m_count++; return cdef_package (this); @@ -150,7 +150,7 @@ public: - cdef_package (void) : cdef_meta_object () { } + cdef_package () : cdef_meta_object () { } cdef_package (const std::string& nm) : cdef_meta_object (new cdef_package_rep ()) @@ -176,7 +176,7 @@ return *this; } - ~cdef_package (void) = default; + ~cdef_package () = default; void install_class (const cdef_class& cls, const std::string& nm) { @@ -193,22 +193,22 @@ get_rep ()->install_package (pack, nm); } - Cell get_classes (void) const + Cell get_classes () const { return get_rep ()->get_classes (); } - Cell get_functions (void) const + Cell get_functions () const { return get_rep ()->get_functions (); } - Cell get_packages (void) const + Cell get_packages () const { return get_rep ()->get_packages (); } - std::string get_name (void) const { return get_rep ()->get_name (); } + std::string get_name () const { return get_rep ()->get_name (); } octave_value find (const std::string& nm) { @@ -217,12 +217,12 @@ private: - cdef_package_rep * get_rep (void) + cdef_package_rep * get_rep () { return dynamic_cast (cdef_object::get_rep ()); } - const cdef_package_rep * get_rep (void) const + const cdef_package_rep * get_rep () const { return dynamic_cast (cdef_object::get_rep ()); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/cdef-property.cc --- a/libinterp/octave-value/cdef-property.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/cdef-property.cc Tue Jan 24 17:19:44 2023 -0800 @@ -233,7 +233,7 @@ } bool -cdef_property::cdef_property_rep::check_get_access (void) const +cdef_property::cdef_property_rep::check_get_access () const { cdef_class cls (to_cdef (get ("DefiningClass"))); @@ -243,7 +243,7 @@ } bool -cdef_property::cdef_property_rep::check_set_access (void) const +cdef_property::cdef_property_rep::check_set_access () const { cdef_class cls (to_cdef (get ("DefiningClass"))); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/cdef-property.h --- a/libinterp/octave-value/cdef-property.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/cdef-property.h Tue Jan 24 17:19:44 2023 -0800 @@ -53,24 +53,24 @@ { public: - cdef_property_rep (void) : cdef_meta_object_rep () { } + cdef_property_rep () : cdef_meta_object_rep () { } cdef_property_rep& operator = (const cdef_property_rep& p) = delete; - ~cdef_property_rep (void) = default; + ~cdef_property_rep () = default; - cdef_object_rep * copy (void) const + cdef_object_rep * copy () const { return new cdef_property_rep (*this); } - bool is_property (void) const { return true; } + bool is_property () const { return true; } - std::string get_name (void) const { return get("Name").string_value (); } + std::string get_name () const { return get("Name").string_value (); } void set_name (const std::string& nm) { put ("Name", nm); } - bool is_constant (void) const { return get("Constant").bool_value (); } + bool is_constant () const { return get("Constant").bool_value (); } octave_value get_value (bool do_check_access = true, const std::string& who = "") const; @@ -83,9 +83,9 @@ bool do_check_access = true, const std::string& who = ""); - OCTINTERP_API bool check_get_access (void) const; + OCTINTERP_API bool check_get_access () const; - OCTINTERP_API bool check_set_access (void) const; + OCTINTERP_API bool check_set_access () const; private: cdef_property_rep (const cdef_property_rep& p) @@ -94,7 +94,7 @@ OCTINTERP_API bool is_recursive_set (const cdef_object& obj) const; - cdef_property wrap (void) + cdef_property wrap () { m_count++; return cdef_property (this); @@ -107,7 +107,7 @@ public: - cdef_property (void) : cdef_meta_object () { } + cdef_property () : cdef_meta_object () { } cdef_property (const std::string& nm) : cdef_meta_object (new cdef_property_rep ()) @@ -133,7 +133,7 @@ return *this; } - ~cdef_property (void) = default; + ~cdef_property () = default; octave_value get_value (const cdef_object& obj, bool do_check_access = true, const std::string& who = "") const @@ -154,28 +154,28 @@ get_rep ()->set_value (obj, val, do_check_access, who); } - bool check_get_access (void) const + bool check_get_access () const { return get_rep ()->check_get_access (); } - bool check_set_access (void) const + bool check_set_access () const { return get_rep ()->check_set_access (); } - std::string get_name (void) const { return get_rep ()->get_name (); } + std::string get_name () const { return get_rep ()->get_name (); } - bool is_constant (void) const { return get_rep ()->is_constant (); } + bool is_constant () const { return get_rep ()->is_constant (); } private: - cdef_property_rep * get_rep (void) + cdef_property_rep * get_rep () { return dynamic_cast (cdef_object::get_rep ()); } - const cdef_property_rep * get_rep (void) const + const cdef_property_rep * get_rep () const { return dynamic_cast (cdef_object::get_rep ()); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/cdef-utils.cc --- a/libinterp/octave-value/cdef-utils.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/cdef-utils.cc Tue Jan 24 17:19:44 2023 -0800 @@ -282,7 +282,7 @@ } cdef_class -get_class_context (void) +get_class_context () { std::string dummy_string; bool dummy_bool; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/cdef-utils.h --- a/libinterp/octave-value/cdef-utils.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/cdef-utils.h Tue Jan 24 17:19:44 2023 -0800 @@ -99,7 +99,7 @@ get_class_context (std::string& name, bool& in_constructor); extern OCTINTERP_API cdef_class -get_class_context (void); +get_class_context (); extern OCTINTERP_API bool check_access (const cdef_class& cls, const octave_value& acc, diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-base-diag.cc --- a/libinterp/octave-value/ov-base-diag.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-base-diag.cc Tue Jan 24 17:19:44 2023 -0800 @@ -279,7 +279,7 @@ // Return true if this matrix has all true elements (non-zero, not NA/NaN). template bool -octave_base_diag::is_true (void) const +octave_base_diag::is_true () const { if (dims ().numel () > 1) { @@ -473,7 +473,7 @@ template float_display_format -octave_base_diag::get_edit_display_format (void) const +octave_base_diag::get_edit_display_format () const { // FIXME return float_display_format (); @@ -551,7 +551,7 @@ template bool -octave_base_diag::print_as_scalar (void) const +octave_base_diag::print_as_scalar () const { dim_vector dv = dims (); @@ -657,7 +657,7 @@ template octave_value -octave_base_diag::to_dense (void) const +octave_base_diag::to_dense () const { if (! m_dense_cache.is_defined ()) m_dense_cache = MT (m_matrix); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-base-diag.h --- a/libinterp/octave-value/ov-base-diag.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-base-diag.h Tue Jan 24 17:19:44 2023 -0800 @@ -50,7 +50,7 @@ public: - octave_base_diag (void) + octave_base_diag () : octave_base_value (), m_matrix (), m_dense_cache () { } octave_base_diag (const DMT& m) @@ -60,13 +60,13 @@ octave_base_diag (const octave_base_diag& m) : octave_base_value (), m_matrix (m.m_matrix), m_dense_cache () { } - ~octave_base_diag (void) = default; + ~octave_base_diag () = default; - std::size_t byte_size (void) const { return m_matrix.byte_size (); } + std::size_t byte_size () const { return m_matrix.byte_size (); } - octave_value squeeze (void) const { return m_matrix; } + octave_value squeeze () const { return m_matrix; } - octave_value full_value (void) const { return to_dense (); } + octave_value full_value () const { return to_dense (); } // We don't need to override all three forms of subsref. The using // declaration will avoid warnings about partially-overloaded virtual @@ -87,9 +87,9 @@ subsasgn (const std::string& type, const std::list& idx, const octave_value& rhs); - dim_vector dims (void) const { return m_matrix.dims (); } + dim_vector dims () const { return m_matrix.dims (); } - octave_idx_type nnz (void) const { return diag ().nnz (); } + octave_idx_type nnz () const { return diag ().nnz (); } octave_value reshape (const dim_vector& new_dims) const { return to_dense ().reshape (new_dims); } @@ -110,7 +110,7 @@ octave_value all (int dim = 0) const { return MT (m_matrix).all (dim); } octave_value any (int dim = 0) const { return MT (m_matrix).any (dim); } - MatrixType matrix_type (void) const { return MatrixType::Diagonal; } + MatrixType matrix_type () const { return MatrixType::Diagonal; } MatrixType matrix_type (const MatrixType&) const { return matrix_type (); } @@ -136,17 +136,17 @@ sortmode is_sorted_rows (sortmode mode = UNSORTED) const { return to_dense ().is_sorted_rows (mode); } - bool is_matrix_type (void) const { return true; } + bool is_matrix_type () const { return true; } - bool isnumeric (void) const { return true; } + bool isnumeric () const { return true; } - bool is_defined (void) const { return true; } + bool is_defined () const { return true; } - bool is_constant (void) const { return true; } + bool is_constant () const { return true; } - OCTINTERP_API bool is_true (void) const; + OCTINTERP_API bool is_true () const; - bool is_diag_matrix (void) const { return true; } + bool is_diag_matrix () const { return true; } OCTINTERP_API double double_value (bool = false) const; @@ -190,28 +190,28 @@ sparse_complex_matrix_value (bool = false) const; int8NDArray - int8_array_value (void) const { return to_dense ().int8_array_value (); } + int8_array_value () const { return to_dense ().int8_array_value (); } int16NDArray - int16_array_value (void) const { return to_dense ().int16_array_value (); } + int16_array_value () const { return to_dense ().int16_array_value (); } int32NDArray - int32_array_value (void) const { return to_dense ().int32_array_value (); } + int32_array_value () const { return to_dense ().int32_array_value (); } int64NDArray - int64_array_value (void) const { return to_dense ().int64_array_value (); } + int64_array_value () const { return to_dense ().int64_array_value (); } uint8NDArray - uint8_array_value (void) const { return to_dense ().uint8_array_value (); } + uint8_array_value () const { return to_dense ().uint8_array_value (); } uint16NDArray - uint16_array_value (void) const { return to_dense ().uint16_array_value (); } + uint16_array_value () const { return to_dense ().uint16_array_value (); } uint32NDArray - uint32_array_value (void) const { return to_dense ().uint32_array_value (); } + uint32_array_value () const { return to_dense ().uint32_array_value (); } uint64NDArray - uint64_array_value (void) const { return to_dense ().uint64_array_value (); } + uint64_array_value () const { return to_dense ().uint64_array_value (); } OCTINTERP_API octave_value convert_to_str_internal (bool pad, bool force, char type) const; @@ -219,7 +219,7 @@ OCTINTERP_API void print_raw (std::ostream& os, bool pr_as_read_syntax = false) const; - OCTINTERP_API float_display_format get_edit_display_format (void) const; + OCTINTERP_API float_display_format get_edit_display_format () const; OCTINTERP_API std::string edit_display (const float_display_format& fmt, @@ -236,7 +236,7 @@ OCTINTERP_API mxArray * as_mxArray (bool interleaved) const; - OCTINTERP_API bool print_as_scalar (void) const; + OCTINTERP_API bool print_as_scalar () const; OCTINTERP_API void print (std::ostream& os, bool pr_as_read_syntax = false); @@ -251,7 +251,7 @@ DMT m_matrix; - OCTINTERP_API octave_value to_dense (void) const; + OCTINTERP_API octave_value to_dense () const; virtual bool chk_valid_scalar (const octave_value&, typename DMT::element_type&) const = 0; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-base-int.cc --- a/libinterp/octave-value/ov-base-int.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-base-int.cc Tue Jan 24 17:19:44 2023 -0800 @@ -144,7 +144,7 @@ template octave_base_value * -octave_base_int_matrix::try_narrowing_conversion (void) +octave_base_int_matrix::try_narrowing_conversion () { octave_base_value *retval = nullptr; @@ -205,70 +205,70 @@ template octave_value -octave_base_int_matrix::as_double (void) const +octave_base_int_matrix::as_double () const { return NDArray (this->m_matrix); } template octave_value -octave_base_int_matrix::as_single (void) const +octave_base_int_matrix::as_single () const { return FloatNDArray (this->m_matrix); } template octave_value -octave_base_int_matrix::as_int8 (void) const +octave_base_int_matrix::as_int8 () const { return int8NDArray (this->m_matrix); } template octave_value -octave_base_int_matrix::as_int16 (void) const +octave_base_int_matrix::as_int16 () const { return int16NDArray (this->m_matrix); } template octave_value -octave_base_int_matrix::as_int32 (void) const +octave_base_int_matrix::as_int32 () const { return int32NDArray (this->m_matrix); } template octave_value -octave_base_int_matrix::as_int64 (void) const +octave_base_int_matrix::as_int64 () const { return int64NDArray (this->m_matrix); } template octave_value -octave_base_int_matrix::as_uint8 (void) const +octave_base_int_matrix::as_uint8 () const { return uint8NDArray (this->m_matrix); } template octave_value -octave_base_int_matrix::as_uint16 (void) const +octave_base_int_matrix::as_uint16 () const { return uint16NDArray (this->m_matrix); } template octave_value -octave_base_int_matrix::as_uint32 (void) const +octave_base_int_matrix::as_uint32 () const { return uint32NDArray (this->m_matrix); } template octave_value -octave_base_int_matrix::as_uint64 (void) const +octave_base_int_matrix::as_uint64 () const { return uint64NDArray (this->m_matrix); } @@ -599,70 +599,70 @@ template octave_value -octave_base_int_scalar::as_double (void) const +octave_base_int_scalar::as_double () const { return static_cast (this->scalar); } template octave_value -octave_base_int_scalar::as_single (void) const +octave_base_int_scalar::as_single () const { return static_cast (this->scalar); } template octave_value -octave_base_int_scalar::as_int8 (void) const +octave_base_int_scalar::as_int8 () const { return octave_int8 (this->scalar); } template octave_value -octave_base_int_scalar::as_int16 (void) const +octave_base_int_scalar::as_int16 () const { return octave_int16 (this->scalar); } template octave_value -octave_base_int_scalar::as_int32 (void) const +octave_base_int_scalar::as_int32 () const { return octave_int32 (this->scalar); } template octave_value -octave_base_int_scalar::as_int64 (void) const +octave_base_int_scalar::as_int64 () const { return octave_int64 (this->scalar); } template octave_value -octave_base_int_scalar::as_uint8 (void) const +octave_base_int_scalar::as_uint8 () const { return octave_uint8 (this->scalar); } template octave_value -octave_base_int_scalar::as_uint16 (void) const +octave_base_int_scalar::as_uint16 () const { return octave_uint16 (this->scalar); } template octave_value -octave_base_int_scalar::as_uint32 (void) const +octave_base_int_scalar::as_uint32 () const { return octave_uint32 (this->scalar); } template octave_value -octave_base_int_scalar::as_uint64 (void) const +octave_base_int_scalar::as_uint64 () const { return octave_uint64 (this->scalar); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-base-int.h --- a/libinterp/octave-value/ov-base-int.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-base-int.h Tue Jan 24 17:19:44 2023 -0800 @@ -51,25 +51,25 @@ { public: - octave_base_int_matrix (void) : octave_base_matrix () { } + octave_base_int_matrix () : octave_base_matrix () { } octave_base_int_matrix (const T& nda) : octave_base_matrix (nda) { } - ~octave_base_int_matrix (void) = default; + ~octave_base_int_matrix () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_base_int_matrix (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_base_int_matrix (); } - OCTINTERP_API octave_base_value * try_narrowing_conversion (void); + OCTINTERP_API octave_base_value * try_narrowing_conversion (); - bool isreal (void) const { return true; } + bool isreal () const { return true; } - // void increment (void) { matrix += 1; } + // void increment () { matrix += 1; } - // void decrement (void) { matrix -= 1; } + // void decrement () { matrix -= 1; } OCTINTERP_API void print_raw (std::ostream& os, bool pr_as_read_syntax = false) const; @@ -77,18 +77,18 @@ OCTINTERP_API octave_value convert_to_str_internal (bool, bool, char type) const; - OCTINTERP_API octave_value as_double (void) const; - OCTINTERP_API octave_value as_single (void) const; + OCTINTERP_API octave_value as_double () const; + OCTINTERP_API octave_value as_single () const; - OCTINTERP_API octave_value as_int8 (void) const; - OCTINTERP_API octave_value as_int16 (void) const; - OCTINTERP_API octave_value as_int32 (void) const; - OCTINTERP_API octave_value as_int64 (void) const; + OCTINTERP_API octave_value as_int8 () const; + OCTINTERP_API octave_value as_int16 () const; + OCTINTERP_API octave_value as_int32 () const; + OCTINTERP_API octave_value as_int64 () const; - OCTINTERP_API octave_value as_uint8 (void) const; - OCTINTERP_API octave_value as_uint16 (void) const; - OCTINTERP_API octave_value as_uint32 (void) const; - OCTINTERP_API octave_value as_uint64 (void) const; + OCTINTERP_API octave_value as_uint8 () const; + OCTINTERP_API octave_value as_uint16 () const; + OCTINTERP_API octave_value as_uint32 () const; + OCTINTERP_API octave_value as_uint64 () const; OCTINTERP_API std::string edit_display (const float_display_format& fmt, @@ -123,42 +123,42 @@ { public: - octave_base_int_scalar (void) : octave_base_scalar () { } + octave_base_int_scalar () : octave_base_scalar () { } octave_base_int_scalar (const T& s) : octave_base_scalar (s) { } - ~octave_base_int_scalar (void) = default; + ~octave_base_int_scalar () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_base_int_scalar (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_base_int_scalar (); } - octave_base_value * try_narrowing_conversion (void) { return nullptr; } + octave_base_value * try_narrowing_conversion () { return nullptr; } - bool isreal (void) const { return true; } + bool isreal () const { return true; } - bool is_real_scalar (void) const { return true; } + bool is_real_scalar () const { return true; } - // void increment (void) { scalar += 1; } + // void increment () { scalar += 1; } - // void decrement (void) { scalar -= 1; } + // void decrement () { scalar -= 1; } OCTINTERP_API octave_value convert_to_str_internal (bool, bool, char type) const; - OCTINTERP_API octave_value as_double (void) const; - OCTINTERP_API octave_value as_single (void) const; + OCTINTERP_API octave_value as_double () const; + OCTINTERP_API octave_value as_single () const; - OCTINTERP_API octave_value as_int8 (void) const; - OCTINTERP_API octave_value as_int16 (void) const; - OCTINTERP_API octave_value as_int32 (void) const; - OCTINTERP_API octave_value as_int64 (void) const; + OCTINTERP_API octave_value as_int8 () const; + OCTINTERP_API octave_value as_int16 () const; + OCTINTERP_API octave_value as_int32 () const; + OCTINTERP_API octave_value as_int64 () const; - OCTINTERP_API octave_value as_uint8 (void) const; - OCTINTERP_API octave_value as_uint16 (void) const; - OCTINTERP_API octave_value as_uint32 (void) const; - OCTINTERP_API octave_value as_uint64 (void) const; + OCTINTERP_API octave_value as_uint8 () const; + OCTINTERP_API octave_value as_uint16 () const; + OCTINTERP_API octave_value as_uint32 () const; + OCTINTERP_API octave_value as_uint64 () const; OCTINTERP_API std::string edit_display (const float_display_format& fmt, diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-base-mat.cc --- a/libinterp/octave-value/ov-base-mat.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-base-mat.cc Tue Jan 24 17:19:44 2023 -0800 @@ -420,7 +420,7 @@ // Return true if this matrix has all true elements (non-zero, not NA/NaN). template bool -octave_base_matrix::is_true (void) const +octave_base_matrix::is_true () const { bool retval = false; dim_vector dv = m_matrix.dims (); @@ -446,7 +446,7 @@ template bool -octave_base_matrix::print_as_scalar (void) const +octave_base_matrix::print_as_scalar () const { dim_vector dv = dims (); @@ -523,7 +523,7 @@ template float_display_format -octave_base_matrix::get_edit_display_format (void) const +octave_base_matrix::get_edit_display_format () const { return make_format (m_matrix); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-base-mat.h --- a/libinterp/octave-value/ov-base-mat.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-base-mat.h Tue Jan 24 17:19:44 2023 -0800 @@ -53,7 +53,7 @@ typedef MT object_type; - octave_base_matrix (void) + octave_base_matrix () : octave_base_value (), m_matrix (), m_typ (), m_idx_cache () { } octave_base_matrix (const MT& m, const MatrixType& t = MatrixType ()) @@ -71,15 +71,15 @@ : nullptr) { } - ~octave_base_matrix (void) { clear_cached_info (); } + ~octave_base_matrix () { clear_cached_info (); } - std::size_t byte_size (void) const { return m_matrix.byte_size (); } + std::size_t byte_size () const { return m_matrix.byte_size (); } - octave_value squeeze (void) const { return MT (m_matrix.squeeze ()); } + octave_value squeeze () const { return MT (m_matrix.squeeze ()); } - octave_value full_value (void) const { return m_matrix; } + octave_value full_value () const { return m_matrix; } - void maybe_economize (void) { m_matrix.maybe_economize (); } + void maybe_economize () { m_matrix.maybe_economize (); } // We don't need to override all three forms of subsref. The using // declaration will avoid warnings about partially-overloaded virtual @@ -114,13 +114,13 @@ OCTINTERP_API void delete_elements (const octave_value_list& idx); - dim_vector dims (void) const { return m_matrix.dims (); } + dim_vector dims () const { return m_matrix.dims (); } - octave_idx_type numel (void) const { return m_matrix.numel (); } + octave_idx_type numel () const { return m_matrix.numel (); } - int ndims (void) const { return m_matrix.ndims (); } + int ndims () const { return m_matrix.ndims (); } - octave_idx_type nnz (void) const { return m_matrix.nnz (); } + octave_idx_type nnz () const { return m_matrix.nnz (); } octave_value reshape (const dim_vector& new_dims) const { return MT (m_matrix.reshape (new_dims)); } @@ -133,7 +133,7 @@ octave_value all (int dim = 0) const { return m_matrix.all (dim); } octave_value any (int dim = 0) const { return m_matrix.any (dim); } - MatrixType matrix_type (void) const { return m_typ ? *m_typ : MatrixType (); } + MatrixType matrix_type () const { return m_typ ? *m_typ : MatrixType (); } MatrixType matrix_type (const MatrixType& _typ) const; octave_value diag (octave_idx_type k = 0) const @@ -157,17 +157,17 @@ sortmode is_sorted_rows (sortmode mode = UNSORTED) const { return m_matrix.is_sorted_rows (mode); } - bool is_matrix_type (void) const { return true; } + bool is_matrix_type () const { return true; } - bool isnumeric (void) const { return true; } + bool isnumeric () const { return true; } - bool is_defined (void) const { return true; } + bool is_defined () const { return true; } - bool is_constant (void) const { return true; } + bool is_constant () const { return true; } - OCTINTERP_API bool is_true (void) const; + OCTINTERP_API bool is_true () const; - OCTINTERP_API bool print_as_scalar (void) const; + OCTINTERP_API bool print_as_scalar () const; OCTINTERP_API void print (std::ostream& os, bool pr_as_read_syntax = false); @@ -176,19 +176,19 @@ OCTINTERP_API void short_disp (std::ostream& os) const; - OCTINTERP_API float_display_format get_edit_display_format (void) const; + OCTINTERP_API float_display_format get_edit_display_format () const; OCTINTERP_API std::string edit_display (const float_display_format& fmt, octave_idx_type i, octave_idx_type j) const; - MT& matrix_ref (void) + MT& matrix_ref () { clear_cached_info (); return m_matrix; } - const MT& matrix_ref (void) const + const MT& matrix_ref () const { return m_matrix; } @@ -201,7 +201,7 @@ // This function exists to support the MEX interface. // You should not use it anywhere else. - const void * mex_get_data (void) const { return m_matrix.data (); } + const void * mex_get_data () const { return m_matrix.data (); } protected: @@ -214,7 +214,7 @@ return idx; } - void clear_cached_info (void) const + void clear_cached_info () const { delete m_typ; m_typ = nullptr; delete m_idx_cache; m_idx_cache = nullptr; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-base-scalar.cc --- a/libinterp/octave-value/ov-base-scalar.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-base-scalar.cc Tue Jan 24 17:19:44 2023 -0800 @@ -107,7 +107,7 @@ template dim_vector -octave_base_scalar::dims (void) const +octave_base_scalar::dims () const { static dim_vector dv (1, 1); return dv; @@ -143,7 +143,7 @@ template bool -octave_base_scalar::is_true (void) const +octave_base_scalar::is_true () const { if (octave::math::isnan (scalar)) octave::err_nan_to_logical_conversion (); @@ -194,7 +194,7 @@ template float_display_format -octave_base_scalar::get_edit_display_format (void) const +octave_base_scalar::get_edit_display_format () const { return make_format (scalar); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-base-scalar.h --- a/libinterp/octave-value/ov-base-scalar.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-base-scalar.h Tue Jan 24 17:19:44 2023 -0800 @@ -52,7 +52,7 @@ typedef ST scalar_type; - octave_base_scalar (void) + octave_base_scalar () : octave_base_value (), scalar () { } octave_base_scalar (const ST& s) @@ -61,11 +61,11 @@ octave_base_scalar (const octave_base_scalar& s) : octave_base_value (), scalar (s.scalar) { } - ~octave_base_scalar (void) = default; + ~octave_base_scalar () = default; - octave_value squeeze (void) const { return scalar; } + octave_value squeeze () const { return scalar; } - octave_value full_value (void) const { return scalar; } + octave_value full_value () const { return scalar; } // We don't need to override all three forms of subsref. The using // declaration will avoid warnings about partially-overloaded virtual @@ -83,23 +83,23 @@ subsasgn (const std::string& type, const std::list& idx, const octave_value& rhs); - bool is_constant (void) const { return true; } + bool is_constant () const { return true; } - bool is_defined (void) const { return true; } + bool is_defined () const { return true; } - OCTINTERP_API dim_vector dims (void) const; + OCTINTERP_API dim_vector dims () const; - octave_idx_type numel (void) const { return 1; } + octave_idx_type numel () const { return 1; } - int ndims (void) const { return 2; } + int ndims () const { return 2; } - octave_idx_type nnz (void) const { return (scalar != ST () ? 1 : 0); } + octave_idx_type nnz () const { return (scalar != ST () ? 1 : 0); } OCTINTERP_API octave_value permute (const Array&, bool = false) const; OCTINTERP_API octave_value reshape (const dim_vector& new_dims) const; - std::size_t byte_size (void) const { return sizeof (ST); } + std::size_t byte_size () const { return sizeof (ST); } octave_value all (int = 0) const { return (scalar != ST ()); } @@ -131,15 +131,15 @@ sortmode is_sorted_rows (sortmode mode = UNSORTED) const { return mode == UNSORTED ? ASCENDING : mode; } - MatrixType matrix_type (void) const { return MatrixType::Diagonal; } + MatrixType matrix_type () const { return MatrixType::Diagonal; } MatrixType matrix_type (const MatrixType&) const { return matrix_type (); } - bool is_scalar_type (void) const { return true; } + bool is_scalar_type () const { return true; } - bool isnumeric (void) const { return true; } + bool isnumeric () const { return true; } - OCTINTERP_API bool is_true (void) const; + OCTINTERP_API bool is_true () const; OCTINTERP_API void print (std::ostream& os, bool pr_as_read_syntax = false); @@ -151,7 +151,7 @@ OCTINTERP_API void short_disp (std::ostream& os) const; - OCTINTERP_API float_display_format get_edit_display_format (void) const; + OCTINTERP_API float_display_format get_edit_display_format () const; OCTINTERP_API std::string edit_display (const float_display_format& fmt, @@ -159,11 +159,11 @@ // This function exists to support the MEX interface. // You should not use it anywhere else. - const void * mex_get_data (void) const { return &scalar; } + const void * mex_get_data () const { return &scalar; } - const ST& scalar_ref (void) const { return scalar; } + const ST& scalar_ref () const { return scalar; } - ST& scalar_ref (void) { return scalar; } + ST& scalar_ref () { return scalar; } OCTINTERP_API octave_value fast_elem_extract (octave_idx_type n) const; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-base-sparse.cc --- a/libinterp/octave-value/ov-base-sparse.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-base-sparse.cc Tue Jan 24 17:19:44 2023 -0800 @@ -242,7 +242,7 @@ template bool -octave_base_sparse::is_true (void) const +octave_base_sparse::is_true () const { bool retval = false; dim_vector dv = matrix.dims (); @@ -272,7 +272,7 @@ template bool -octave_base_sparse::print_as_scalar (void) const +octave_base_sparse::print_as_scalar () const { dim_vector dv = dims (); @@ -379,7 +379,7 @@ template float_display_format -octave_base_sparse::get_edit_display_format (void) const +octave_base_sparse::get_edit_display_format () const { return float_display_format (); // return make_format (this->matrix); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-base-sparse.h --- a/libinterp/octave-value/ov-base-sparse.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-base-sparse.h Tue Jan 24 17:19:44 2023 -0800 @@ -52,7 +52,7 @@ { public: - octave_base_sparse (void) + octave_base_sparse () : octave_base_value (), matrix (), typ (MatrixType ()) { } @@ -73,19 +73,19 @@ octave_base_sparse (const octave_base_sparse& a) : octave_base_value (), matrix (a.matrix), typ (a.typ) { } - ~octave_base_sparse (void) = default; + ~octave_base_sparse () = default; - octave_idx_type numel (void) const { return dims ().safe_numel (); } + octave_idx_type numel () const { return dims ().safe_numel (); } - octave_idx_type nnz (void) const { return matrix.nnz (); } + octave_idx_type nnz () const { return matrix.nnz (); } - octave_idx_type nzmax (void) const { return matrix.nzmax (); } + octave_idx_type nzmax () const { return matrix.nzmax (); } - std::size_t byte_size (void) const { return matrix.byte_size (); } + std::size_t byte_size () const { return matrix.byte_size (); } - octave_value squeeze (void) const { return matrix.squeeze (); } + octave_value squeeze () const { return matrix.squeeze (); } - octave_value full_value (void) const { return matrix.matrix_value (); } + octave_value full_value () const { return matrix.matrix_value (); } // We don't need to override all three forms of subsref. The using // declaration will avoid warnings about partially-overloaded virtual @@ -163,7 +163,7 @@ OCTINTERP_API void delete_elements (const octave_value_list& idx); - dim_vector dims (void) const { return matrix.dims (); } + dim_vector dims () const { return matrix.dims (); } OCTINTERP_API octave_value do_index_op (const octave_value_list& idx, bool resize_ok = false); @@ -196,23 +196,23 @@ sortmode issorted (sortmode mode = UNSORTED) const { return full_value ().issorted (mode); } - MatrixType matrix_type (void) const { return typ; } + MatrixType matrix_type () const { return typ; } MatrixType matrix_type (const MatrixType& _typ) const { MatrixType ret = typ; typ = _typ; return ret; } - bool is_matrix_type (void) const { return true; } + bool is_matrix_type () const { return true; } - bool isnumeric (void) const { return true; } + bool isnumeric () const { return true; } - bool issparse (void) const { return true; } + bool issparse () const { return true; } - bool is_defined (void) const { return true; } + bool is_defined () const { return true; } - bool is_constant (void) const { return true; } + bool is_constant () const { return true; } - OCTINTERP_API bool is_true (void) const; + OCTINTERP_API bool is_true () const; - OCTINTERP_API bool print_as_scalar (void) const; + OCTINTERP_API bool print_as_scalar () const; OCTINTERP_API void print (std::ostream& os, bool pr_as_read_syntax = false); @@ -226,7 +226,7 @@ OCTINTERP_API bool load_ascii (std::istream& is); - OCTINTERP_API float_display_format get_edit_display_format (void) const; + OCTINTERP_API float_display_format get_edit_display_format () const; OCTINTERP_API std::string edit_display (const float_display_format& fmt, @@ -234,11 +234,11 @@ // These functions exists to support the MEX interface. // You should not use them anywhere else. - const void * mex_get_data (void) const { return matrix.data (); } + const void * mex_get_data () const { return matrix.data (); } - const octave_idx_type * mex_get_ir (void) const { return matrix.ridx (); } + const octave_idx_type * mex_get_ir () const { return matrix.ridx (); } - const octave_idx_type * mex_get_jc (void) const { return matrix.cidx (); } + const octave_idx_type * mex_get_jc () const { return matrix.cidx (); } OCTINTERP_API octave_value fast_elem_extract (octave_idx_type n) const; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-base.cc --- a/libinterp/octave-value/ov-base.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-base.cc Tue Jan 24 17:19:44 2023 -0800 @@ -102,86 +102,86 @@ bool Vsparse_auto_mutate = false; octave_base_value * -octave_base_value::empty_clone (void) const +octave_base_value::empty_clone () const { return resize (dim_vector ()).clone (); } octave_value -octave_base_value::squeeze (void) const +octave_base_value::squeeze () const { std::string nm = type_name (); error ("squeeze: invalid operation for %s type", nm.c_str ()); } octave_value -octave_base_value::full_value (void) const +octave_base_value::full_value () const { err_wrong_type_arg ("full: invalid operation for %s type", type_name ()); } octave_value -octave_base_value::as_double (void) const +octave_base_value::as_double () const { err_invalid_conversion (type_name (), "double"); } octave_value -octave_base_value::as_single (void) const +octave_base_value::as_single () const { err_invalid_conversion (type_name (), "single"); } octave_value -octave_base_value::as_int8 (void) const +octave_base_value::as_int8 () const { err_invalid_conversion (type_name (), "int8"); } octave_value -octave_base_value::as_int16 (void) const +octave_base_value::as_int16 () const { err_invalid_conversion (type_name (), "int16"); } octave_value -octave_base_value::as_int32 (void) const +octave_base_value::as_int32 () const { err_invalid_conversion (type_name (), "int32"); } octave_value -octave_base_value::as_int64 (void) const +octave_base_value::as_int64 () const { err_invalid_conversion (type_name (), "int64"); } octave_value -octave_base_value::as_uint8 (void) const +octave_base_value::as_uint8 () const { err_invalid_conversion (type_name (), "uint8"); } octave_value -octave_base_value::as_uint16 (void) const +octave_base_value::as_uint16 () const { err_invalid_conversion (type_name (), "uint16"); } octave_value -octave_base_value::as_uint32 (void) const +octave_base_value::as_uint32 () const { err_invalid_conversion (type_name (), "uint32"); } octave_value -octave_base_value::as_uint64 (void) const +octave_base_value::as_uint64 () const { err_invalid_conversion (type_name (), "uint64"); } Matrix -octave_base_value::size (void) +octave_base_value::size () { const dim_vector dv = dims (); Matrix mdv (1, dv.ndims ()); @@ -313,19 +313,19 @@ } octave_idx_type -octave_base_value::nnz (void) const +octave_base_value::nnz () const { err_wrong_type_arg ("octave_base_value::nnz ()", type_name ()); } octave_idx_type -octave_base_value::nzmax (void) const +octave_base_value::nzmax () const { return numel (); } octave_idx_type -octave_base_value::nfields (void) const +octave_base_value::nfields () const { err_wrong_type_arg ("octave_base_value::nfields ()", type_name ()); } @@ -349,7 +349,7 @@ } MatrixType -octave_base_value::matrix_type (void) const +octave_base_value::matrix_type () const { err_wrong_type_arg ("octave_base_value::matrix_type ()", type_name ()); } @@ -392,7 +392,7 @@ } void -octave_base_value::convert_to_row_or_column_vector (void) +octave_base_value::convert_to_row_or_column_vector () { err_wrong_type_arg ("octave_base_value::convert_to_row_or_column_vector ()", type_name ()); @@ -445,7 +445,7 @@ } float_display_format -octave_base_value::get_edit_display_format (void) const +octave_base_value::get_edit_display_format () const { return float_display_format (); } @@ -681,103 +681,103 @@ } PermMatrix -octave_base_value::perm_matrix_value (void) const +octave_base_value::perm_matrix_value () const { err_wrong_type_arg ("octave_base_value::perm_matrix_value()", type_name ()); } octave_int8 -octave_base_value::int8_scalar_value (void) const +octave_base_value::int8_scalar_value () const { err_wrong_type_arg ("octave_base_value::int8_scalar_value()", type_name ()); } octave_int16 -octave_base_value::int16_scalar_value (void) const +octave_base_value::int16_scalar_value () const { err_wrong_type_arg ("octave_base_value::int16_scalar_value()", type_name ()); } octave_int32 -octave_base_value::int32_scalar_value (void) const +octave_base_value::int32_scalar_value () const { err_wrong_type_arg ("octave_base_value::int32_scalar_value()", type_name ()); } octave_int64 -octave_base_value::int64_scalar_value (void) const +octave_base_value::int64_scalar_value () const { err_wrong_type_arg ("octave_base_value::int64_scalar_value()", type_name ()); } octave_uint8 -octave_base_value::uint8_scalar_value (void) const +octave_base_value::uint8_scalar_value () const { err_wrong_type_arg ("octave_base_value::uint8_scalar_value()", type_name ()); } octave_uint16 -octave_base_value::uint16_scalar_value (void) const +octave_base_value::uint16_scalar_value () const { err_wrong_type_arg ("octave_base_value::uint16_scalar_value()", type_name ()); } octave_uint32 -octave_base_value::uint32_scalar_value (void) const +octave_base_value::uint32_scalar_value () const { err_wrong_type_arg ("octave_base_value::uint32_scalar_value()", type_name ()); } octave_uint64 -octave_base_value::uint64_scalar_value (void) const +octave_base_value::uint64_scalar_value () const { err_wrong_type_arg ("octave_base_value::uint64_scalar_value()", type_name ()); } int8NDArray -octave_base_value::int8_array_value (void) const +octave_base_value::int8_array_value () const { err_wrong_type_arg ("octave_base_value::int8_array_value()", type_name ()); } int16NDArray -octave_base_value::int16_array_value (void) const +octave_base_value::int16_array_value () const { err_wrong_type_arg ("octave_base_value::int16_array_value()", type_name ()); } int32NDArray -octave_base_value::int32_array_value (void) const +octave_base_value::int32_array_value () const { err_wrong_type_arg ("octave_base_value::int32_array_value()", type_name ()); } int64NDArray -octave_base_value::int64_array_value (void) const +octave_base_value::int64_array_value () const { err_wrong_type_arg ("octave_base_value::int64_array_value()", type_name ()); } uint8NDArray -octave_base_value::uint8_array_value (void) const +octave_base_value::uint8_array_value () const { err_wrong_type_arg ("octave_base_value::uint8_array_value()", type_name ()); } uint16NDArray -octave_base_value::uint16_array_value (void) const +octave_base_value::uint16_array_value () const { err_wrong_type_arg ("octave_base_value::uint16_array_value()", type_name ()); } uint32NDArray -octave_base_value::uint32_array_value (void) const +octave_base_value::uint32_array_value () const { err_wrong_type_arg ("octave_base_value::uint32_array_value()", type_name ()); } uint64NDArray -octave_base_value::uint64_array_value (void) const +octave_base_value::uint64_array_value () const { err_wrong_type_arg ("octave_base_value::uint64_array_value()", type_name ()); } @@ -799,7 +799,7 @@ } std::string -octave_base_value::xstring_value (void) const +octave_base_value::xstring_value () const { wrong_type_arg_error (); @@ -807,13 +807,13 @@ } Array -octave_base_value::cellstr_value (void) const +octave_base_value::cellstr_value () const { err_wrong_type_arg ("octave_base_value::cellstr_value()", type_name ()); } octave::range -octave_base_value::range_value (void) const +octave_base_value::range_value () const { err_wrong_type_arg ("octave_base_value::range_value()", type_name ()); } @@ -823,55 +823,55 @@ #if 0 octave::range -octave_base_value::float_range_value (void) const +octave_base_value::float_range_value () const { err_wrong_type_arg ("octave_base_value::float_range_value()", type_name ()); } octave::range -octave_base_value::int8_range_value (void) const +octave_base_value::int8_range_value () const { err_wrong_type_arg ("octave_base_value::int8_range_value()", type_name ()); } octave::range -octave_base_value::int16_range_value (void) const +octave_base_value::int16_range_value () const { err_wrong_type_arg ("octave_base_value::int16_range_value()", type_name ()); } octave::range -octave_base_value::int32_range_value (void) const +octave_base_value::int32_range_value () const { err_wrong_type_arg ("octave_base_value::int32_range_value()", type_name ()); } octave::range -octave_base_value::int64_range_value (void) const +octave_base_value::int64_range_value () const { err_wrong_type_arg ("octave_base_value::int64_range_value()", type_name ()); } octave::range -octave_base_value::uint8_range_value (void) const +octave_base_value::uint8_range_value () const { err_wrong_type_arg ("octave_base_value::uint8_range_value()", type_name ()); } octave::range -octave_base_value::uint16_range_value (void) const +octave_base_value::uint16_range_value () const { err_wrong_type_arg ("octave_base_value::uint16_range_value()", type_name ()); } octave::range -octave_base_value::uint32_range_value (void) const +octave_base_value::uint32_range_value () const { err_wrong_type_arg ("octave_base_value::uint32_range_value()", type_name ()); } octave::range -octave_base_value::uint64_range_value (void) const +octave_base_value::uint64_range_value () const { err_wrong_type_arg ("octave_base_value::uint64_range_value()", type_name ()); } @@ -879,13 +879,13 @@ #endif octave_map -octave_base_value::map_value (void) const +octave_base_value::map_value () const { err_wrong_type_arg ("octave_base_value::map_value()", type_name ()); } octave_scalar_map -octave_base_value::scalar_map_value (void) const +octave_base_value::scalar_map_value () const { octave_map tmp = map_value (); @@ -896,7 +896,7 @@ } string_vector -octave_base_value::map_keys (void) const +octave_base_value::map_keys () const { err_wrong_type_arg ("octave_base_value::map_keys()", type_name ()); } @@ -908,20 +908,20 @@ } std::size_t -octave_base_value::nparents (void) const +octave_base_value::nparents () const { err_wrong_type_arg ("octave_base_value::nparents()", type_name ()); } std::list -octave_base_value::parent_class_name_list (void) const +octave_base_value::parent_class_name_list () const { err_wrong_type_arg ("octave_base_value::parent_class_name_list()", type_name ()); } string_vector -octave_base_value::parent_class_names (void) const +octave_base_value::parent_class_names () const { err_wrong_type_arg ("octave_base_value::parent_class_names()", type_name ()); } @@ -982,7 +982,7 @@ } octave_value_list -octave_base_value::list_value (void) const +octave_base_value::list_value () const { err_wrong_type_arg ("octave_base_value::list_value()", type_name ()); } @@ -1172,7 +1172,7 @@ } void -octave_base_value::wrong_type_arg_error (void) const +octave_base_value::wrong_type_arg_error () const { err_wrong_type_arg (type_name ()); } @@ -1184,19 +1184,19 @@ } void -octave_base_value::lock (void) +octave_base_value::lock () { err_wrong_type_arg ("octave_base_value::lock ()", type_name ()); } void -octave_base_value::unlock (void) +octave_base_value::unlock () { err_wrong_type_arg ("octave_base_value::unlock ()", type_name ()); } octave_value -octave_base_value::dump (void) const +octave_base_value::dump () const { std::map m = {{ "class", this->class_name () }, @@ -1395,7 +1395,7 @@ // For resetting print state. void -octave_base_value::reset (void) const +octave_base_value::reset () const { s_beginning_of_line = true; s_curr_print_indent_level = 0; @@ -1521,7 +1521,7 @@ } bool -called_from_builtin (void) +called_from_builtin () { octave::tree_evaluator& tw = octave::__get_evaluator__ (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-base.h --- a/libinterp/octave-value/ov-base.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-base.h Tue Jan 24 17:19:44 2023 -0800 @@ -55,7 +55,7 @@ // object is required to load a user-defined octave_value object, // maybe this function should be declared in a public header file? -extern OCTINTERP_API type_info& __get_type_info__ (void); +extern OCTINTERP_API type_info& __get_type_info__ (); // For now just preserve the old interface and don't mark it as deprecated. // This function is currently an internal, private function. Additional @@ -186,13 +186,13 @@ #define DECLARE_OV_TYPEID_FUNCTIONS_AND_DATA2(VIRTUAL) \ public: \ - VIRTUAL int type_id (void) const { return t_id; } \ - VIRTUAL std::string type_name (void) const { return t_name; } \ - VIRTUAL std::string class_name (void) const { return c_name; } \ - static int static_type_id (void) { return t_id; } \ - static std::string static_type_name (void) { return t_name; } \ - static std::string static_class_name (void) { return c_name; } \ - static void register_type (void); \ + VIRTUAL int type_id () const { return t_id; } \ + VIRTUAL std::string type_name () const { return t_name; } \ + VIRTUAL std::string class_name () const { return c_name; } \ + static int static_type_id () { return t_id; } \ + static std::string static_type_name () { return t_name; } \ + static std::string static_class_name () { return c_name; } \ + static void register_type (); \ static void register_type (octave::type_info&); \ \ private: \ @@ -201,7 +201,7 @@ static const std::string c_name; #define DECLARE_TEMPLATE_OV_TYPEID_SPECIALIZATIONS(cls, type) \ - template <> void cls::register_type (void); \ + template <> void cls::register_type (); \ template <> void cls::register_type (octave::type_info&); \ template <> int cls::t_id; \ template <> const std::string cls::t_name; \ @@ -211,7 +211,7 @@ tspec int t::t_id (-1); \ tspec const std::string t::t_name (n); \ tspec const std::string t::c_name (c); \ - tspec void t::register_type (void) \ + tspec void t::register_type () \ { \ octave::type_info& type_info = octave::__get_type_info__ (); \ \ @@ -248,12 +248,12 @@ type_conv_info (type_conv_fcn f = nullptr, int t = -1) : m_fcn (f), m_type_id (t) { } - operator type_conv_fcn (void) const { return m_fcn; } + operator type_conv_fcn () const { return m_fcn; } octave_base_value * operator () (const octave_base_value& v) const { return (*m_fcn) (v); } - int type_id (void) const { return m_type_id; } + int type_id () const { return m_type_id; } private: type_conv_fcn m_fcn; @@ -262,59 +262,59 @@ friend class octave_value; - octave_base_value (void) : count (1) { } + octave_base_value () : count (1) { } octave_base_value (const octave_base_value&) : count (1) { } - virtual ~octave_base_value (void) = default; + virtual ~octave_base_value () = default; // Unconditional clone. Always clones. virtual octave_base_value * - clone (void) const { return new octave_base_value (*this); } + clone () const { return new octave_base_value (*this); } // Empty clone. virtual octave_base_value * - empty_clone (void) const; + empty_clone () const; // Unique clone. Usually clones, but may be overridden to fake the // cloning when sharing copies is to be controlled from within an // instance (see octave_class). virtual octave_base_value * - unique_clone (void) { return clone (); } + unique_clone () { return clone (); } virtual void break_closure_cycles (const std::shared_ptr&) { } virtual type_conv_info - numeric_conversion_function (void) const + numeric_conversion_function () const { return type_conv_info (); } virtual type_conv_info - numeric_demotion_function (void) const + numeric_demotion_function () const { return type_conv_info (); } - virtual octave_value squeeze (void) const; + virtual octave_value squeeze () const; - virtual octave_value full_value (void) const; + virtual octave_value full_value () const; - virtual octave_value as_double (void) const; - virtual octave_value as_single (void) const; + virtual octave_value as_double () const; + virtual octave_value as_single () const; - virtual octave_value as_int8 (void) const; - virtual octave_value as_int16 (void) const; - virtual octave_value as_int32 (void) const; - virtual octave_value as_int64 (void) const; + virtual octave_value as_int8 () const; + virtual octave_value as_int16 () const; + virtual octave_value as_int32 () const; + virtual octave_value as_int64 () const; - virtual octave_value as_uint8 (void) const; - virtual octave_value as_uint16 (void) const; - virtual octave_value as_uint32 (void) const; - virtual octave_value as_uint64 (void) const; + virtual octave_value as_uint8 () const; + virtual octave_value as_uint16 () const; + virtual octave_value as_uint32 () const; + virtual octave_value as_uint64 () const; - virtual octave_base_value * try_narrowing_conversion (void) + virtual octave_base_value * try_narrowing_conversion () { return nullptr; } - virtual void maybe_economize (void) { } + virtual void maybe_economize () { } - virtual Matrix size (void); + virtual Matrix size (); virtual octave_idx_type xnumel (const octave_value_list&); @@ -351,34 +351,34 @@ virtual octave::idx_vector index_vector (bool require_integers = false) const; - virtual dim_vector dims (void) const { return dim_vector (); } + virtual dim_vector dims () const { return dim_vector (); } - octave_idx_type rows (void) const + octave_idx_type rows () const { const dim_vector dv = dims (); return dv(0); } - octave_idx_type columns (void) const + octave_idx_type columns () const { const dim_vector dv = dims (); return dv(1); } - virtual int ndims (void) const + virtual int ndims () const { return dims ().ndims (); } - virtual octave_idx_type numel (void) const { return dims ().numel (); } + virtual octave_idx_type numel () const { return dims ().numel (); } - virtual std::size_t byte_size (void) const { return 0; } + virtual std::size_t byte_size () const { return 0; } - virtual octave_idx_type nnz (void) const; + virtual octave_idx_type nnz () const; - virtual octave_idx_type nzmax (void) const; + virtual octave_idx_type nzmax () const; - virtual octave_idx_type nfields (void) const; + virtual octave_idx_type nfields () const; virtual octave_value reshape (const dim_vector&) const; @@ -386,143 +386,143 @@ virtual octave_value resize (const dim_vector&, bool fill = false) const; - virtual MatrixType matrix_type (void) const; + virtual MatrixType matrix_type () const; virtual MatrixType matrix_type (const MatrixType& typ) const; - virtual bool is_defined (void) const { return false; } + virtual bool is_defined () const { return false; } - virtual bool is_storable (void) const { return true; } + virtual bool is_storable () const { return true; } - virtual bool is_legacy_object (void) const { return false; } + virtual bool is_legacy_object () const { return false; } - bool isempty (void) const { return (dims ().any_zero ()); } + bool isempty () const { return (dims ().any_zero ()); } - bool is_zero_by_zero (void) const { return dims().zero_by_zero (); } + bool is_zero_by_zero () const { return dims().zero_by_zero (); } - virtual bool iscell (void) const { return false; } + virtual bool iscell () const { return false; } - virtual bool iscellstr (void) const { return false; } + virtual bool iscellstr () const { return false; } - virtual bool is_real_scalar (void) const { return false; } + virtual bool is_real_scalar () const { return false; } - virtual bool is_real_matrix (void) const { return false; } + virtual bool is_real_matrix () const { return false; } - virtual bool is_complex_scalar (void) const { return false; } + virtual bool is_complex_scalar () const { return false; } - virtual bool is_complex_matrix (void) const { return false; } + virtual bool is_complex_matrix () const { return false; } - virtual bool is_bool_scalar (void) const { return false; } + virtual bool is_bool_scalar () const { return false; } - virtual bool is_bool_matrix (void) const { return false; } + virtual bool is_bool_matrix () const { return false; } - virtual bool is_char_matrix (void) const { return false; } + virtual bool is_char_matrix () const { return false; } - virtual bool is_diag_matrix (void) const { return false; } + virtual bool is_diag_matrix () const { return false; } - virtual bool is_perm_matrix (void) const { return false; } + virtual bool is_perm_matrix () const { return false; } - virtual bool is_string (void) const { return false; } + virtual bool is_string () const { return false; } - virtual bool is_sq_string (void) const { return false; } + virtual bool is_sq_string () const { return false; } - virtual bool is_range (void) const { return false; } + virtual bool is_range () const { return false; } - virtual bool isstruct (void) const { return false; } + virtual bool isstruct () const { return false; } - virtual bool isobject (void) const { return false; } + virtual bool isobject () const { return false; } - virtual bool is_classdef_meta (void) const { return false; } + virtual bool is_classdef_meta () const { return false; } - virtual bool is_classdef_superclass_ref (void) const { return false; } + virtual bool is_classdef_superclass_ref () const { return false; } - virtual bool is_classdef_object (void) const { return false; } + virtual bool is_classdef_object () const { return false; } - virtual bool is_package (void) const { return false; } + virtual bool is_package () const { return false; } - virtual bool isjava (void) const { return false; } + virtual bool isjava () const { return false; } - virtual bool is_cs_list (void) const { return false; } + virtual bool is_cs_list () const { return false; } - virtual bool is_magic_colon (void) const { return false; } + virtual bool is_magic_colon () const { return false; } - virtual bool is_all_va_args (void) const { return false; } + virtual bool is_all_va_args () const { return false; } virtual octave_value all (int = 0) const; virtual octave_value any (int = 0) const; - virtual builtin_type_t builtin_type (void) const { return btyp_unknown; } + virtual builtin_type_t builtin_type () const { return btyp_unknown; } - virtual bool is_double_type (void) const { return false; } + virtual bool is_double_type () const { return false; } - virtual bool is_single_type (void) const { return false; } + virtual bool is_single_type () const { return false; } - virtual bool isfloat (void) const { return false; } + virtual bool isfloat () const { return false; } - virtual bool is_int8_type (void) const { return false; } + virtual bool is_int8_type () const { return false; } - virtual bool is_int16_type (void) const { return false; } + virtual bool is_int16_type () const { return false; } - virtual bool is_int32_type (void) const { return false; } + virtual bool is_int32_type () const { return false; } - virtual bool is_int64_type (void) const { return false; } + virtual bool is_int64_type () const { return false; } - virtual bool is_uint8_type (void) const { return false; } + virtual bool is_uint8_type () const { return false; } - virtual bool is_uint16_type (void) const { return false; } + virtual bool is_uint16_type () const { return false; } - virtual bool is_uint32_type (void) const { return false; } + virtual bool is_uint32_type () const { return false; } - virtual bool is_uint64_type (void) const { return false; } + virtual bool is_uint64_type () const { return false; } - virtual bool islogical (void) const { return false; } + virtual bool islogical () const { return false; } - virtual bool isinteger (void) const { return false; } + virtual bool isinteger () const { return false; } - virtual bool isreal (void) const { return false; } + virtual bool isreal () const { return false; } - virtual bool iscomplex (void) const { return false; } + virtual bool iscomplex () const { return false; } // Would be nice to get rid of the next four functions: - virtual bool is_scalar_type (void) const { return false; } + virtual bool is_scalar_type () const { return false; } - virtual bool is_matrix_type (void) const { return false; } + virtual bool is_matrix_type () const { return false; } - virtual bool isnumeric (void) const { return false; } + virtual bool isnumeric () const { return false; } - virtual bool issparse (void) const { return false; } + virtual bool issparse () const { return false; } - virtual bool is_true (void) const { return false; } + virtual bool is_true () const { return false; } - virtual bool is_magic_int (void) const { return false; } + virtual bool is_magic_int () const { return false; } - virtual bool isnull (void) const { return false; } + virtual bool isnull () const { return false; } - virtual bool is_constant (void) const { return false; } + virtual bool is_constant () const { return false; } - virtual bool is_function_handle (void) const { return false; } + virtual bool is_function_handle () const { return false; } - virtual bool is_anonymous_function (void) const { return false; } + virtual bool is_anonymous_function () const { return false; } - virtual bool is_inline_function (void) const { return false; } + virtual bool is_inline_function () const { return false; } - virtual bool is_function (void) const { return false; } + virtual bool is_function () const { return false; } - virtual bool is_user_script (void) const { return false; } + virtual bool is_user_script () const { return false; } - virtual bool is_user_function (void) const { return false; } + virtual bool is_user_function () const { return false; } - virtual bool is_user_code (void) const { return false; } + virtual bool is_user_code () const { return false; } - virtual bool is_builtin_function (void) const { return false; } + virtual bool is_builtin_function () const { return false; } - virtual bool is_dld_function (void) const { return false; } + virtual bool is_dld_function () const { return false; } - virtual bool is_mex_function (void) const { return false; } + virtual bool is_mex_function () const { return false; } - virtual void erase_subfunctions (void) { } + virtual void erase_subfunctions () { } virtual short int short_value (bool = false, bool = false) const; @@ -552,7 +552,7 @@ virtual float float_scalar_value (bool frc_str_conv = false) const { return float_value (frc_str_conv); } - virtual Cell cell_value (void) const; + virtual Cell cell_value () const; virtual Matrix matrix_value (bool = false) const; @@ -599,85 +599,85 @@ virtual FloatComplexDiagMatrix float_complex_diag_matrix_value (bool = false) const; - virtual PermMatrix perm_matrix_value (void) const; + virtual PermMatrix perm_matrix_value () const; - virtual octave_int8 int8_scalar_value (void) const; + virtual octave_int8 int8_scalar_value () const; - virtual octave_int16 int16_scalar_value (void) const; + virtual octave_int16 int16_scalar_value () const; - virtual octave_int32 int32_scalar_value (void) const; + virtual octave_int32 int32_scalar_value () const; - virtual octave_int64 int64_scalar_value (void) const; + virtual octave_int64 int64_scalar_value () const; - virtual octave_uint8 uint8_scalar_value (void) const; + virtual octave_uint8 uint8_scalar_value () const; - virtual octave_uint16 uint16_scalar_value (void) const; + virtual octave_uint16 uint16_scalar_value () const; - virtual octave_uint32 uint32_scalar_value (void) const; + virtual octave_uint32 uint32_scalar_value () const; - virtual octave_uint64 uint64_scalar_value (void) const; + virtual octave_uint64 uint64_scalar_value () const; - virtual int8NDArray int8_array_value (void) const; + virtual int8NDArray int8_array_value () const; - virtual int16NDArray int16_array_value (void) const; + virtual int16NDArray int16_array_value () const; - virtual int32NDArray int32_array_value (void) const; + virtual int32NDArray int32_array_value () const; - virtual int64NDArray int64_array_value (void) const; + virtual int64NDArray int64_array_value () const; - virtual uint8NDArray uint8_array_value (void) const; + virtual uint8NDArray uint8_array_value () const; - virtual uint16NDArray uint16_array_value (void) const; + virtual uint16NDArray uint16_array_value () const; - virtual uint32NDArray uint32_array_value (void) const; + virtual uint32NDArray uint32_array_value () const; - virtual uint64NDArray uint64_array_value (void) const; + virtual uint64NDArray uint64_array_value () const; virtual string_vector string_vector_value (bool pad = false) const; virtual std::string string_value (bool force = false) const; - virtual Array cellstr_value (void) const; + virtual Array cellstr_value () const; - virtual octave::range range_value (void) const; + virtual octave::range range_value () const; // For now, disable all but range. #if 0 - virtual octave::range float_range_value (void) const; + virtual octave::range float_range_value () const; - virtual octave::range int8_range_value (void) const; + virtual octave::range int8_range_value () const; - virtual octave::range int16_range_value (void) const; + virtual octave::range int16_range_value () const; - virtual octave::range int32_range_value (void) const; + virtual octave::range int32_range_value () const; - virtual octave::range int64_range_value (void) const; + virtual octave::range int64_range_value () const; - virtual octave::range uint8_range_value (void) const; + virtual octave::range uint8_range_value () const; - virtual octave::range uint16_range_value (void) const; + virtual octave::range uint16_range_value () const; - virtual octave::range uint32_range_value (void) const; + virtual octave::range uint32_range_value () const; - virtual octave::range uint64_range_value (void) const; + virtual octave::range uint64_range_value () const; #endif - virtual octave_map map_value (void) const; + virtual octave_map map_value () const; - virtual octave_scalar_map scalar_map_value (void) const; + virtual octave_scalar_map scalar_map_value () const; - virtual string_vector map_keys (void) const; + virtual string_vector map_keys () const; virtual bool isfield (const std::string&) const; - virtual std::size_t nparents (void) const; + virtual std::size_t nparents () const; - virtual std::list parent_class_name_list (void) const; + virtual std::list parent_class_name_list () const; - virtual string_vector parent_class_names (void) const; + virtual string_vector parent_class_names () const; virtual octave_base_value * find_parent_class (const std::string&) { return nullptr; } @@ -700,21 +700,21 @@ virtual octave_fcn_handle * fcn_handle_value (bool silent = false); - virtual octave_value_list list_value (void) const; + virtual octave_value_list list_value () const; virtual octave_value convert_to_str (bool pad = false, bool force = false, char type = '\'') const; virtual octave_value convert_to_str_internal (bool pad, bool force, char type) const; - virtual void convert_to_row_or_column_vector (void); + virtual void convert_to_row_or_column_vector (); // The following extractor functions don't perform any implicit type // conversions. virtual std::string xstring_value () const; - virtual bool print_as_scalar (void) const { return false; } + virtual bool print_as_scalar () const { return false; } virtual void print (std::ostream& os, bool pr_as_read_syntax = false); @@ -730,7 +730,7 @@ virtual void short_disp (std::ostream& os) const { os << "..."; } - virtual float_display_format get_edit_display_format (void) const; + virtual float_display_format get_edit_display_format () const; virtual std::string edit_display (const float_display_format&, octave_idx_type, octave_idx_type) const @@ -758,11 +758,11 @@ oct_data_conv::data_type output_type, int skip, octave::mach_info::float_format flt_fmt) const; - virtual const void * mex_get_data (void) const { return nullptr; } + virtual const void * mex_get_data () const { return nullptr; } - virtual const octave_idx_type * mex_get_ir (void) const { return nullptr; } + virtual const octave_idx_type * mex_get_ir () const { return nullptr; } - virtual const octave_idx_type * mex_get_jc (void) const { return nullptr; } + virtual const octave_idx_type * mex_get_jc () const { return nullptr; } virtual mxArray * as_mxArray (bool interleaved) const; @@ -783,15 +783,15 @@ virtual sortmode is_sorted_rows (sortmode mode = UNSORTED) const; - virtual void lock (void); + virtual void lock (); - virtual void unlock (void); + virtual void unlock (); - virtual bool islocked (void) const { return false; } + virtual bool islocked () const { return false; } - virtual void call_object_destructor (void) { } + virtual void call_object_destructor () { } - virtual octave_value dump (void) const; + virtual octave_value dump () const; // Standard mappers. Register new ones here. enum unary_mapper_t @@ -891,23 +891,23 @@ const std::list& idx, const octave_value& rhs); - void reset_indent_level (void) const + void reset_indent_level () const { s_curr_print_indent_level = 0; } - void increment_indent_level (void) const + void increment_indent_level () const { s_curr_print_indent_level += 2; } - void decrement_indent_level (void) const + void decrement_indent_level () const { s_curr_print_indent_level -= 2; } - int current_print_indent_level (void) const + int current_print_indent_level () const { return s_curr_print_indent_level; } OCTINTERP_API void indent (std::ostream& os) const; OCTINTERP_API void newline (std::ostream& os) const; - OCTINTERP_API void reset (void) const; + OCTINTERP_API void reset () const; // A reference count. // NOTE: the declaration is octave_idx_type because with 64-bit indexing, @@ -922,7 +922,7 @@ private: - OCTINTERP_API void wrong_type_arg_error (void) const; + OCTINTERP_API void wrong_type_arg_error () const; //-------- @@ -938,9 +938,9 @@ { public: - octave_base_dld_value (void) = default; + octave_base_dld_value () = default; - ~octave_base_dld_value (void) + ~octave_base_dld_value () { m_containing_dynamic_library.delete_later (); } @@ -965,6 +965,6 @@ // Tells whether some regular octave_value_base methods are being called from // within the "builtin" function. -extern OCTINTERP_API bool called_from_builtin (void); +extern OCTINTERP_API bool called_from_builtin (); #endif diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-bool-mat.cc --- a/libinterp/octave-value/ov-bool-mat.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-bool-mat.cc Tue Jan 24 17:19:44 2023 -0800 @@ -79,14 +79,14 @@ } octave_base_value::type_conv_info -octave_bool_matrix::numeric_conversion_function (void) const +octave_bool_matrix::numeric_conversion_function () const { return octave_base_value::type_conv_info (default_numeric_conversion_function, octave_matrix::static_type_id ()); } octave_base_value * -octave_bool_matrix::try_narrowing_conversion (void) +octave_bool_matrix::try_narrowing_conversion () { octave_base_value *retval = nullptr; @@ -167,61 +167,61 @@ } octave_value -octave_bool_matrix::as_double (void) const +octave_bool_matrix::as_double () const { return NDArray (m_matrix); } octave_value -octave_bool_matrix::as_single (void) const +octave_bool_matrix::as_single () const { return FloatNDArray (m_matrix); } octave_value -octave_bool_matrix::as_int8 (void) const +octave_bool_matrix::as_int8 () const { return int8NDArray (m_matrix); } octave_value -octave_bool_matrix::as_int16 (void) const +octave_bool_matrix::as_int16 () const { return int16NDArray (m_matrix); } octave_value -octave_bool_matrix::as_int32 (void) const +octave_bool_matrix::as_int32 () const { return int32NDArray (m_matrix); } octave_value -octave_bool_matrix::as_int64 (void) const +octave_bool_matrix::as_int64 () const { return int64NDArray (m_matrix); } octave_value -octave_bool_matrix::as_uint8 (void) const +octave_bool_matrix::as_uint8 () const { return uint8NDArray (m_matrix); } octave_value -octave_bool_matrix::as_uint16 (void) const +octave_bool_matrix::as_uint16 () const { return uint16NDArray (m_matrix); } octave_value -octave_bool_matrix::as_uint32 (void) const +octave_bool_matrix::as_uint32 () const { return uint32NDArray (m_matrix); } octave_value -octave_bool_matrix::as_uint64 (void) const +octave_bool_matrix::as_uint64 () const { return uint64NDArray (m_matrix); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-bool-mat.h --- a/libinterp/octave-value/ov-bool-mat.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-bool-mat.h Tue Jan 24 17:19:44 2023 -0800 @@ -53,7 +53,7 @@ { public: - octave_bool_matrix (void) + octave_bool_matrix () : octave_base_matrix () { } octave_bool_matrix (const boolNDArray& bnda) @@ -77,17 +77,17 @@ octave_bool_matrix (const octave_bool_matrix& bm) : octave_base_matrix (bm) { } - ~octave_bool_matrix (void) = default; + ~octave_bool_matrix () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_bool_matrix (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_bool_matrix (); } - type_conv_info numeric_conversion_function (void) const; + type_conv_info numeric_conversion_function () const; - octave_base_value * try_narrowing_conversion (void); + octave_base_value * try_narrowing_conversion (); octave::idx_vector index_vector (bool /* require_integers */ = false) const { @@ -95,39 +95,39 @@ : set_idx_cache (octave::idx_vector (m_matrix)); } - builtin_type_t builtin_type (void) const { return btyp_bool; } + builtin_type_t builtin_type () const { return btyp_bool; } - bool is_bool_matrix (void) const { return true; } + bool is_bool_matrix () const { return true; } - bool islogical (void) const { return true; } + bool islogical () const { return true; } - bool isreal (void) const { return true; } + bool isreal () const { return true; } - bool isnumeric (void) const { return false; } + bool isnumeric () const { return false; } int8NDArray - int8_array_value (void) const { return int8NDArray (m_matrix); } + int8_array_value () const { return int8NDArray (m_matrix); } int16NDArray - int16_array_value (void) const { return int16NDArray (m_matrix); } + int16_array_value () const { return int16NDArray (m_matrix); } int32NDArray - int32_array_value (void) const { return int32NDArray (m_matrix); } + int32_array_value () const { return int32NDArray (m_matrix); } int64NDArray - int64_array_value (void) const { return int64NDArray (m_matrix); } + int64_array_value () const { return int64NDArray (m_matrix); } uint8NDArray - uint8_array_value (void) const { return uint8NDArray (m_matrix); } + uint8_array_value () const { return uint8NDArray (m_matrix); } uint16NDArray - uint16_array_value (void) const { return uint16NDArray (m_matrix); } + uint16_array_value () const { return uint16NDArray (m_matrix); } uint32NDArray - uint32_array_value (void) const { return uint32NDArray (m_matrix); } + uint32_array_value () const { return uint32NDArray (m_matrix); } uint64NDArray - uint64_array_value (void) const { return uint64NDArray (m_matrix); } + uint64_array_value () const { return uint64NDArray (m_matrix); } double double_value (bool = false) const; @@ -194,21 +194,21 @@ octave_value convert_to_str_internal (bool pad, bool force, char type) const; - octave_value as_double (void) const; - octave_value as_single (void) const; + octave_value as_double () const; + octave_value as_single () const; - octave_value as_int8 (void) const; - octave_value as_int16 (void) const; - octave_value as_int32 (void) const; - octave_value as_int64 (void) const; + octave_value as_int8 () const; + octave_value as_int16 () const; + octave_value as_int32 () const; + octave_value as_int64 () const; - octave_value as_uint8 (void) const; - octave_value as_uint16 (void) const; - octave_value as_uint32 (void) const; - octave_value as_uint64 (void) const; + octave_value as_uint8 () const; + octave_value as_uint16 () const; + octave_value as_uint32 () const; + octave_value as_uint64 () const; // Use matrix_ref here to clear index cache. - void invert (void) { matrix_ref ().invert (); } + void invert () { matrix_ref ().invert (); } void print_raw (std::ostream& os, bool pr_as_read_syntax = false) const; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-bool-sparse.cc --- a/libinterp/octave-value/ov-bool-sparse.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-bool-sparse.cc Tue Jan 24 17:19:44 2023 -0800 @@ -67,7 +67,7 @@ } octave_base_value::type_conv_info -octave_sparse_bool_matrix::numeric_conversion_function (void) const +octave_sparse_bool_matrix::numeric_conversion_function () const { return octave_base_value::type_conv_info (default_numeric_conversion_function, octave_sparse_matrix::static_type_id ()); @@ -172,7 +172,7 @@ } octave_value -octave_sparse_bool_matrix::as_double (void) const +octave_sparse_bool_matrix::as_double () const { return SparseMatrix (this->matrix); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-bool-sparse.h --- a/libinterp/octave-value/ov-bool-sparse.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-bool-sparse.h Tue Jan 24 17:19:44 2023 -0800 @@ -53,7 +53,7 @@ { public: - octave_sparse_bool_matrix (void) + octave_sparse_bool_matrix () : octave_base_sparse () { } octave_sparse_bool_matrix (const SparseBoolMatrix& bnda) @@ -75,14 +75,14 @@ octave_sparse_bool_matrix (const octave_sparse_bool_matrix& bm) : octave_base_sparse (bm) { } - ~octave_sparse_bool_matrix (void) = default; + ~octave_sparse_bool_matrix () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_sparse_bool_matrix (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_sparse_bool_matrix (); } - type_conv_info numeric_conversion_function (void) const; + type_conv_info numeric_conversion_function () const; // FIXME: Adapt idx_vector to allow sparse logical indexing without overflow! octave::idx_vector index_vector (bool /* require_integers */ = false) const @@ -90,15 +90,15 @@ return octave::idx_vector (matrix); } - builtin_type_t builtin_type (void) const { return btyp_bool; } + builtin_type_t builtin_type () const { return btyp_bool; } - bool is_bool_matrix (void) const { return true; } + bool is_bool_matrix () const { return true; } - bool islogical (void) const { return true; } + bool islogical () const { return true; } - bool isreal (void) const { return true; } + bool isreal () const { return true; } - bool isnumeric (void) const { return false; } + bool isnumeric () const { return false; } double double_value (bool = false) const; @@ -130,7 +130,7 @@ octave_value convert_to_str_internal (bool pad, bool force, char type) const; - octave_value as_double (void) const; + octave_value as_double () const; bool save_binary (std::ostream& os, bool save_as_floats); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-bool.cc --- a/libinterp/octave-value/ov-bool.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-bool.cc Tue Jan 24 17:19:44 2023 -0800 @@ -69,7 +69,7 @@ } octave_base_value::type_conv_info -octave_bool::numeric_conversion_function (void) const +octave_bool::numeric_conversion_function () const { return octave_base_value::type_conv_info (default_numeric_conversion_function, octave_scalar::static_type_id ()); @@ -95,61 +95,61 @@ } octave_value -octave_bool::as_double (void) const +octave_bool::as_double () const { return static_cast (scalar); } octave_value -octave_bool::as_single (void) const +octave_bool::as_single () const { return static_cast (scalar); } octave_value -octave_bool::as_int8 (void) const +octave_bool::as_int8 () const { return octave_int8 (scalar); } octave_value -octave_bool::as_int16 (void) const +octave_bool::as_int16 () const { return octave_int16 (scalar); } octave_value -octave_bool::as_int32 (void) const +octave_bool::as_int32 () const { return octave_int32 (scalar); } octave_value -octave_bool::as_int64 (void) const +octave_bool::as_int64 () const { return octave_int64 (scalar); } octave_value -octave_bool::as_uint8 (void) const +octave_bool::as_uint8 () const { return octave_uint8 (scalar); } octave_value -octave_bool::as_uint16 (void) const +octave_bool::as_uint16 () const { return octave_uint16 (scalar); } octave_value -octave_bool::as_uint32 (void) const +octave_bool::as_uint32 () const { return octave_uint32 (scalar); } octave_value -octave_bool::as_uint64 (void) const +octave_bool::as_uint64 () const { return octave_uint64 (scalar); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-bool.h --- a/libinterp/octave-value/ov-bool.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-bool.h Tue Jan 24 17:19:44 2023 -0800 @@ -54,7 +54,7 @@ { public: - octave_bool (void) + octave_bool () : octave_base_scalar (false) { } octave_bool (bool b) @@ -63,13 +63,13 @@ octave_bool (const octave_bool& s) : octave_base_scalar (s) { } - ~octave_bool (void) = default; + ~octave_bool () = default; - octave_base_value * clone (void) const { return new octave_bool (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * clone () const { return new octave_bool (*this); } + octave_base_value * empty_clone () const { return new octave_bool_matrix (); } - type_conv_info numeric_conversion_function (void) const; + type_conv_info numeric_conversion_function () const; octave_value do_index_op (const octave_value_list& idx, bool resize_ok = false); @@ -77,75 +77,75 @@ octave::idx_vector index_vector (bool /* require_integers */ = false) const { return octave::idx_vector (scalar); } - builtin_type_t builtin_type (void) const { return btyp_bool; } + builtin_type_t builtin_type () const { return btyp_bool; } - bool is_real_scalar (void) const { return true; } + bool is_real_scalar () const { return true; } - bool is_bool_scalar (void) const { return true; } + bool is_bool_scalar () const { return true; } - bool islogical (void) const { return true; } + bool islogical () const { return true; } - bool isreal (void) const { return true; } + bool isreal () const { return true; } - bool isnumeric (void) const { return false; } + bool isnumeric () const { return false; } - bool is_true (void) const { return scalar; } + bool is_true () const { return scalar; } int8NDArray - int8_array_value (void) const + int8_array_value () const { return int8NDArray (dim_vector (1, 1), scalar); } int16NDArray - int16_array_value (void) const + int16_array_value () const { return int16NDArray (dim_vector (1, 1), scalar); } int32NDArray - int32_array_value (void) const + int32_array_value () const { return int32NDArray (dim_vector (1, 1), scalar); } int64NDArray - int64_array_value (void) const + int64_array_value () const { return int64NDArray (dim_vector (1, 1), scalar); } uint8NDArray - uint8_array_value (void) const + uint8_array_value () const { return uint8NDArray (dim_vector (1, 1), scalar); } uint16NDArray - uint16_array_value (void) const + uint16_array_value () const { return uint16NDArray (dim_vector (1, 1), scalar); } uint32NDArray - uint32_array_value (void) const + uint32_array_value () const { return uint32NDArray (dim_vector (1, 1), scalar); } uint64NDArray - uint64_array_value (void) const + uint64_array_value () const { return uint64NDArray (dim_vector (1, 1), scalar); } octave_int8 - int8_scalar_value (void) const { return octave_int8 (scalar); } + int8_scalar_value () const { return octave_int8 (scalar); } octave_int16 - int16_scalar_value (void) const { return octave_int16 (scalar); } + int16_scalar_value () const { return octave_int16 (scalar); } octave_int32 - int32_scalar_value (void) const { return octave_int32 (scalar); } + int32_scalar_value () const { return octave_int32 (scalar); } octave_int64 - int64_scalar_value (void) const { return octave_int64 (scalar); } + int64_scalar_value () const { return octave_int64 (scalar); } octave_uint8 - uint8_scalar_value (void) const { return octave_uint8 (scalar); } + uint8_scalar_value () const { return octave_uint8 (scalar); } octave_uint16 - uint16_scalar_value (void) const { return octave_uint16 (scalar); } + uint16_scalar_value () const { return octave_uint16 (scalar); } octave_uint32 - uint32_scalar_value (void) const { return octave_uint32 (scalar); } + uint32_scalar_value () const { return octave_uint32 (scalar); } octave_uint64 - uint64_scalar_value (void) const { return octave_uint64 (scalar); } + uint64_scalar_value () const { return octave_uint64 (scalar); } double double_value (bool = false) const { return scalar; } @@ -209,18 +209,18 @@ boolNDArray bool_array_value (bool = false) const { return boolNDArray (dim_vector (1, 1), scalar); } - octave_value as_double (void) const; - octave_value as_single (void) const; + octave_value as_double () const; + octave_value as_single () const; - octave_value as_int8 (void) const; - octave_value as_int16 (void) const; - octave_value as_int32 (void) const; - octave_value as_int64 (void) const; + octave_value as_int8 () const; + octave_value as_int16 () const; + octave_value as_int32 () const; + octave_value as_int64 () const; - octave_value as_uint8 (void) const; - octave_value as_uint16 (void) const; - octave_value as_uint32 (void) const; - octave_value as_uint64 (void) const; + octave_value as_uint8 () const; + octave_value as_uint16 () const; + octave_value as_uint32 () const; + octave_value as_uint64 () const; octave_value resize (const dim_vector& dv, bool fill = false) const; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-builtin.cc --- a/libinterp/octave-value/ov-builtin.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-builtin.cc Tue Jan 24 17:19:44 2023 -0800 @@ -50,13 +50,13 @@ } octave_builtin::fcn -octave_builtin::function (void) const +octave_builtin::function () const { return m_fcn; } octave_builtin::meth -octave_builtin::method (void) const +octave_builtin::method () const { return m_meth; } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-builtin.h --- a/libinterp/octave-value/ov-builtin.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-builtin.h Tue Jan 24 17:19:44 2023 -0800 @@ -53,7 +53,7 @@ { public: - octave_builtin (void) + octave_builtin () : octave_function (), m_fcn (nullptr), m_meth (nullptr), m_file () { } @@ -88,21 +88,21 @@ octave_builtin& operator = (const octave_builtin& ob) = delete; - ~octave_builtin (void) = default; + ~octave_builtin () = default; - std::string src_file_name (void) const { return m_file; } + std::string src_file_name () const { return m_file; } octave_function * function_value (bool = false) { return this; } - bool is_builtin_function (void) const { return true; } + bool is_builtin_function () const { return true; } octave_value_list execute (octave::tree_evaluator& tw, int nargout = 0, const octave_value_list& args = octave_value_list ()); - fcn function (void) const; + fcn function () const; - meth method (void) const; + meth method () const; void push_dispatch_class (const std::string& dispatch_type); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-cell.cc --- a/libinterp/octave-value/ov-cell.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-cell.cc Tue Jan 24 17:19:44 2023 -0800 @@ -428,7 +428,7 @@ } bool -octave_cell::iscellstr (void) const +octave_cell::iscellstr () const { bool retval; if (m_cellstr_cache.get ()) @@ -466,7 +466,7 @@ } std::size_t -octave_cell::byte_size (void) const +octave_cell::byte_size () const { std::size_t retval = 0; @@ -559,13 +559,13 @@ } bool -octave_cell::is_true (void) const +octave_cell::is_true () const { error ("invalid conversion from cell array to logical value"); } octave_value_list -octave_cell::list_value (void) const +octave_cell::list_value () const { return octave_value_list (m_matrix); } @@ -633,7 +633,7 @@ } Array -octave_cell::cellstr_value (void) const +octave_cell::cellstr_value () const { if (! iscellstr ()) error ("invalid conversion from cell array to array of strings"); @@ -645,7 +645,7 @@ } bool -octave_cell::print_as_scalar (void) const +octave_cell::print_as_scalar () const { return true; } @@ -995,7 +995,7 @@ } const void * -octave_cell::mex_get_data (void) const +octave_cell::mex_get_data () const { clear_cellstr_cache (); return m_matrix.data (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-cell.h --- a/libinterp/octave-value/ov-cell.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-cell.h Tue Jan 24 17:19:44 2023 -0800 @@ -51,7 +51,7 @@ { public: - octave_cell (void) + octave_cell () : octave_base_matrix (), m_cellstr_cache () { } octave_cell (const Cell& c) @@ -64,15 +64,15 @@ octave_cell (const octave_cell& c) : octave_base_matrix (c), m_cellstr_cache () { } - ~octave_cell (void) = default; + ~octave_cell () = default; - octave_base_value * clone (void) const { return new octave_cell (*this); } - octave_base_value * empty_clone (void) const { return new octave_cell (); } + octave_base_value * clone () const { return new octave_cell (*this); } + octave_base_value * empty_clone () const { return new octave_cell (); } void break_closure_cycles (const std::shared_ptr& frame); #if 0 - octave_base_value * try_narrowing_conversion (void); + octave_base_value * try_narrowing_conversion (); #endif octave_value subsref (const std::string& type, @@ -107,7 +107,7 @@ void delete_elements (const octave_value_list& idx); - std::size_t byte_size (void) const; + std::size_t byte_size () const; octave_value sort (octave_idx_type dim = 0, sortmode mode = ASCENDING) const; @@ -120,36 +120,36 @@ sortmode is_sorted_rows (sortmode mode = UNSORTED) const; - bool is_matrix_type (void) const { return false; } + bool is_matrix_type () const { return false; } - bool isnumeric (void) const { return false; } + bool isnumeric () const { return false; } - bool is_defined (void) const { return true; } + bool is_defined () const { return true; } - bool is_constant (void) const { return true; } + bool is_constant () const { return true; } - bool iscell (void) const { return true; } + bool iscell () const { return true; } - builtin_type_t builtin_type (void) const { return btyp_cell; } + builtin_type_t builtin_type () const { return btyp_cell; } - bool iscellstr (void) const; + bool iscellstr () const; - bool is_true (void) const; + bool is_true () const; - Cell cell_value (void) const { return m_matrix; } + Cell cell_value () const { return m_matrix; } - octave_value_list list_value (void) const; + octave_value_list list_value () const; octave_value convert_to_str_internal (bool pad, bool, char type) const { return octave_value (string_vector_value (pad), type); } string_vector string_vector_value (bool pad = false) const; - Array cellstr_value (void) const; + Array cellstr_value () const; Array cellstr_value (const char *fmt, ...) const; - bool print_as_scalar (void) const; + bool print_as_scalar () const; void print (std::ostream& os, bool pr_as_read_syntax = false); @@ -178,11 +178,11 @@ // This function exists to support the MEX interface. // You should not use it anywhere else. - const void * mex_get_data (void) const; + const void * mex_get_data () const; private: - void clear_cellstr_cache (void) const + void clear_cellstr_cache () const { m_cellstr_cache.reset (); } //-------- diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-ch-mat.cc --- a/libinterp/octave-value/ov-ch-mat.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-ch-mat.cc Tue Jan 24 17:19:44 2023 -0800 @@ -154,61 +154,61 @@ } octave_value -octave_char_matrix::as_double (void) const +octave_char_matrix::as_double () const { return NDArray (m_matrix); } octave_value -octave_char_matrix::as_single (void) const +octave_char_matrix::as_single () const { return FloatNDArray (m_matrix); } octave_value -octave_char_matrix::as_int8 (void) const +octave_char_matrix::as_int8 () const { return int8NDArray (m_matrix); } octave_value -octave_char_matrix::as_int16 (void) const +octave_char_matrix::as_int16 () const { return int16NDArray (m_matrix); } octave_value -octave_char_matrix::as_int32 (void) const +octave_char_matrix::as_int32 () const { return int32NDArray (m_matrix); } octave_value -octave_char_matrix::as_int64 (void) const +octave_char_matrix::as_int64 () const { return int64NDArray (m_matrix); } octave_value -octave_char_matrix::as_uint8 (void) const +octave_char_matrix::as_uint8 () const { return uint8NDArray (m_matrix); } octave_value -octave_char_matrix::as_uint16 (void) const +octave_char_matrix::as_uint16 () const { return uint16NDArray (m_matrix); } octave_value -octave_char_matrix::as_uint32 (void) const +octave_char_matrix::as_uint32 () const { return uint32NDArray (m_matrix); } octave_value -octave_char_matrix::as_uint64 (void) const +octave_char_matrix::as_uint64 () const { return uint64NDArray (m_matrix); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-ch-mat.h --- a/libinterp/octave-value/ov-ch-mat.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-ch-mat.h Tue Jan 24 17:19:44 2023 -0800 @@ -53,7 +53,7 @@ { protected: - octave_char_matrix (void) + octave_char_matrix () : octave_base_matrix () { } octave_char_matrix (const charMatrix& chm) @@ -82,21 +82,21 @@ public: - ~octave_char_matrix (void) = default; + ~octave_char_matrix () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_char_matrix (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_char_matrix (); } octave::idx_vector index_vector (bool require_integers = false) const; - builtin_type_t builtin_type (void) const { return btyp_char; } + builtin_type_t builtin_type () const { return btyp_char; } - bool is_char_matrix (void) const { return true; } - bool is_real_matrix (void) const { return true; } + bool is_char_matrix () const { return true; } + bool is_real_matrix () const { return true; } - bool isreal (void) const { return true; } + bool isreal () const { return true; } double double_value (bool = false) const; @@ -148,18 +148,18 @@ octave_value convert_to_str_internal (bool, bool, char type) const { return octave_value (m_matrix, type); } - octave_value as_double (void) const; - octave_value as_single (void) const; + octave_value as_double () const; + octave_value as_single () const; - octave_value as_int8 (void) const; - octave_value as_int16 (void) const; - octave_value as_int32 (void) const; - octave_value as_int64 (void) const; + octave_value as_int8 () const; + octave_value as_int16 () const; + octave_value as_int32 () const; + octave_value as_int64 () const; - octave_value as_uint8 (void) const; - octave_value as_uint16 (void) const; - octave_value as_uint32 (void) const; - octave_value as_uint64 (void) const; + octave_value as_uint8 () const; + octave_value as_uint16 () const; + octave_value as_uint32 () const; + octave_value as_uint64 () const; void print_raw (std::ostream& os, bool pr_as_read_syntax = false) const; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-class.cc --- a/libinterp/octave-value/ov-class.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-class.cc Tue Jan 24 17:19:44 2023 -0800 @@ -205,7 +205,7 @@ } octave_base_value * -octave_class::unique_clone (void) +octave_class::unique_clone () { if (count == m_obsolete_copies) { @@ -224,7 +224,7 @@ } std::string -octave_class::get_current_method_class (void) +octave_class::get_current_method_class () { std::string retval = class_name (); @@ -245,14 +245,14 @@ OCTAVE_NORETURN static void -err_invalid_index1 (void) +err_invalid_index1 () { error ("invalid index for class"); } OCTAVE_NORETURN static void -err_invalid_index_for_assignment (void) +err_invalid_index_for_assignment () { error ("invalid index for class assignment"); } @@ -304,7 +304,7 @@ } Matrix -octave_class::size (void) +octave_class::size () { if (in_class_method () || called_from_builtin ()) return octave_base_value::size (); @@ -857,7 +857,7 @@ } std::size_t -octave_class::byte_size (void) const +octave_class::byte_size () const { // Neglect the size of the fieldnames. @@ -876,7 +876,7 @@ } bool -octave_class::is_true (void) const +octave_class::is_true () const { bool retval = false; @@ -898,7 +898,7 @@ } string_vector -octave_class::map_keys (void) const +octave_class::map_keys () const { err_wrong_type_arg ("octave_class::map_keys()", type_name ()); } @@ -1043,7 +1043,7 @@ // If we don't have one, we attempt to create one by calling the constructor // with no arguments. bool -octave_class::reconstruct_exemplar (void) +octave_class::reconstruct_exemplar () { bool retval = false; @@ -1109,7 +1109,7 @@ } void -octave_class::clear_exemplar_map (void) +octave_class::clear_exemplar_map () { exemplar_map.clear (); } @@ -1122,7 +1122,7 @@ // class structure here so the user's loadobj method has a chance // to do its magic. bool -octave_class::reconstruct_parents (void) +octave_class::reconstruct_parents () { bool retval = true; bool might_have_inheritance = false; @@ -1670,7 +1670,7 @@ } bool -octave_class::in_class_method (void) +octave_class::in_class_method () { octave::tree_evaluator& tw = octave::__get_evaluator__ (); @@ -2090,7 +2090,7 @@ octave_inline_fcn& operator = (const octave_inline_fcn& ob) = delete; - ~octave_inline_fcn (void) = default; + ~octave_inline_fcn () = default; // Override default call method because we ultimately use feval to // execute the inline function and that will push a stack frame. @@ -2115,7 +2115,7 @@ // to eliminate the octave_inline class below and replace the // octave_value::is_inline_function method with // -// bool octave_value::is_inline_function (void) const +// bool octave_value::is_inline_function () const // { // return class_name () == "inline"; // } @@ -2131,16 +2131,16 @@ octave_inline (const octave_inline&) = default; - ~octave_inline (void) = default; - - octave_base_value * clone (void) const { return new octave_inline (*this); } - - octave_base_value * empty_clone (void) const + ~octave_inline () = default; + + octave_base_value * clone () const { return new octave_inline (*this); } + + octave_base_value * empty_clone () const { return new octave_inline (octave_map (map_keys ())); } - bool is_inline_function (void) const { return true; } + bool is_inline_function () const { return true; } octave_function * function_value (bool) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-class.h --- a/libinterp/octave-value/ov-class.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-class.h Tue Jan 24 17:19:44 2023 -0800 @@ -55,7 +55,7 @@ { public: - octave_class (void) + octave_class () : octave_base_value (), m_map (), c_name (), m_parent_list (), m_obsolete_copies (0) { } @@ -78,13 +78,13 @@ : octave_base_value (s), m_map (s.m_map), c_name (s.c_name), m_parent_list (s.m_parent_list), m_obsolete_copies (0) { } - ~octave_class (void) = default; + ~octave_class () = default; - octave_base_value * clone (void) const { return new octave_class (*this); } + octave_base_value * clone () const { return new octave_class (*this); } - OCTINTERP_API octave_base_value * unique_clone (void); + OCTINTERP_API octave_base_value * unique_clone (); - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_class (octave_map (m_map.keys ()), c_name, m_parent_list); } @@ -93,7 +93,7 @@ OCTINTERP_API Cell dotref (const octave_value_list& idx); - OCTINTERP_API Matrix size (void); + OCTINTERP_API Matrix size (); OCTINTERP_API octave_idx_type xnumel (const octave_value_list&); @@ -131,21 +131,21 @@ OCTINTERP_API octave::idx_vector index_vector (bool require_integers = false) const; - dim_vector dims (void) const { return m_map.dims (); } + dim_vector dims () const { return m_map.dims (); } - OCTINTERP_API std::size_t byte_size (void) const; + OCTINTERP_API std::size_t byte_size () const; // This is the number of elements in each field. The total number // of elements is numel () * nfields (). - octave_idx_type numel (void) const + octave_idx_type numel () const { dim_vector dv = dims (); return dv.numel (); } - octave_idx_type nfields (void) const { return m_map.nfields (); } + octave_idx_type nfields () const { return m_map.nfields (); } - std::size_t nparents (void) const { return m_parent_list.size (); } + std::size_t nparents () const { return m_parent_list.size (); } octave_value reshape (const dim_vector& new_dims) const { @@ -161,22 +161,22 @@ return octave_value (new octave_class (retval)); } - bool is_defined (void) const { return true; } + bool is_defined () const { return true; } - bool isstruct (void) const { return false; } + bool isstruct () const { return false; } - bool isobject (void) const { return true; } + bool isobject () const { return true; } - OCTINTERP_API bool is_true (void) const; + OCTINTERP_API bool is_true () const; - octave_map map_value (void) const { return m_map; } + octave_map map_value () const { return m_map; } - OCTINTERP_API string_vector map_keys (void) const; + OCTINTERP_API string_vector map_keys () const; - std::list parent_class_name_list (void) const + std::list parent_class_name_list () const { return m_parent_list; } - string_vector parent_class_names (void) const + string_vector parent_class_names () const { return string_vector (m_parent_list); } OCTINTERP_API octave_base_value * find_parent_class (const std::string&); @@ -192,11 +192,11 @@ OCTINTERP_API void print_raw (std::ostream& os, bool pr_as_read_syntax = false) const; - OCTINTERP_API bool reconstruct_exemplar (void); + OCTINTERP_API bool reconstruct_exemplar (); - OCTINTERP_API static void clear_exemplar_map (void); + OCTINTERP_API static void clear_exemplar_map (); - OCTINTERP_API bool reconstruct_parents (void); + OCTINTERP_API bool reconstruct_parents (); OCTINTERP_API bool save_ascii (std::ostream& os); @@ -220,13 +220,13 @@ octave_map m_map; public: - int type_id (void) const { return t_id; } - std::string type_name (void) const { return t_name; } - std::string class_name (void) const { return c_name; } + int type_id () const { return t_id; } + std::string type_name () const { return t_name; } + std::string class_name () const { return c_name; } - static int static_type_id (void) { return t_id; } - static std::string static_type_name (void) { return t_name; } - static std::string static_class_name (void) { return ""; } + static int static_type_id () { return t_id; } + static std::string static_type_name () { return t_name; } + static std::string static_class_name () { return ""; } static OCTINTERP_API void register_type (octave::type_info&); private: @@ -236,8 +236,8 @@ std::string c_name; std::list m_parent_list; - OCTINTERP_API bool in_class_method (void); - OCTINTERP_API std::string get_current_method_class (void); + OCTINTERP_API bool in_class_method (); + OCTINTERP_API std::string get_current_method_class (); OCTINTERP_API octave_value subsasgn_common (const octave_value& obj, const std::string& type, @@ -253,7 +253,7 @@ { public: - exemplar_info (void) : m_field_names (), m_parent_class_names () { } + exemplar_info () : m_field_names (), m_parent_class_names () { } OCTINTERP_API exemplar_info (const octave_value& obj); @@ -271,13 +271,13 @@ return *this; } - octave_idx_type nfields (void) const { return m_field_names.numel (); } + octave_idx_type nfields () const { return m_field_names.numel (); } - std::size_t nparents (void) const { return m_parent_class_names.size (); } + std::size_t nparents () const { return m_parent_class_names.size (); } - string_vector fields (void) const { return m_field_names; } + string_vector fields () const { return m_field_names; } - std::list parents (void) const { return m_parent_class_names; } + std::list parents () const { return m_parent_class_names; } OCTINTERP_API bool compare (const octave_value& obj) const; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-classdef.cc --- a/libinterp/octave-value/ov-classdef.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-classdef.cc Tue Jan 24 17:19:44 2023 -0800 @@ -228,7 +228,7 @@ } Matrix -octave_classdef::size (void) +octave_classdef::size () { octave::cdef_class cls = m_object.get_class (); @@ -480,7 +480,7 @@ return ""; } -std::string octave_classdef_meta::file_name (void) const +std::string octave_classdef_meta::file_name () const { if (m_object.is_class ()) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-classdef.h --- a/libinterp/octave-value/ov-classdef.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-classdef.h Tue Jan 24 17:19:44 2023 -0800 @@ -48,7 +48,7 @@ { public: - octave_classdef (void) + octave_classdef () : octave_base_value (), m_object () { } octave_classdef (const octave::cdef_object& obj) @@ -58,31 +58,31 @@ octave_classdef& operator = (const octave_classdef&) = delete; - ~octave_classdef (void) = default; + ~octave_classdef () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_classdef (m_object.clone ()); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_classdef (m_object.empty_clone ()); } octave_classdef * classdef_object_value (bool = false) { return this; } - octave::cdef_object get_object (void) const { return m_object; } + octave::cdef_object get_object () const { return m_object; } - octave::cdef_object& get_object_ref (void) { return m_object; } + octave::cdef_object& get_object_ref () { return m_object; } - bool is_defined (void) const { return true; } + bool is_defined () const { return true; } - bool isstruct (void) const { return false; } + bool isstruct () const { return false; } - bool isobject (void) const { return true; } + bool isobject () const { return true; } - bool is_classdef_object (void) const { return true; } + bool is_classdef_object () const { return true; } OCTINTERP_API void print (std::ostream& os, bool pr_as_read_syntax = false); @@ -120,15 +120,15 @@ const std::list& idx, const octave_value& rhs); - OCTINTERP_API Matrix size (void); + OCTINTERP_API Matrix size (); OCTINTERP_API octave_idx_type xnumel (const octave_value_list&); - string_vector map_keys (void) const { return m_object.map_keys (); } + string_vector map_keys () const { return m_object.map_keys (); } - octave_map map_value (void) const { return m_object.map_value (); } + octave_map map_value () const { return m_object.map_value (); } - dim_vector dims (void) const { return m_object.dims (); } + dim_vector dims () const { return m_object.dims (); } void set_property (octave_idx_type idx, const std::string& name, const octave_value& pval) @@ -149,13 +149,13 @@ public: - int type_id (void) const { return t_id; } - std::string type_name (void) const { return t_name; } - std::string class_name (void) const { return m_object.class_name (); } + int type_id () const { return t_id; } + std::string type_name () const { return t_name; } + std::string class_name () const { return m_object.class_name (); } - static int static_type_id (void) { return t_id; } - static std::string static_type_name (void) { return t_name; } - static std::string static_class_name (void) { return ""; } + static int static_type_id () { return t_id; } + static std::string static_type_name () { return t_name; } + static std::string static_class_name () { return ""; } static OCTINTERP_API void register_type (octave::type_info&); private: @@ -181,11 +181,11 @@ octave_classdef_meta& operator = (const octave_classdef_meta&) = delete; - ~octave_classdef_meta (void) { m_object.meta_release (); } + ~octave_classdef_meta () { m_object.meta_release (); } - bool is_classdef_meta (void) const { return true; } + bool is_classdef_meta () const { return true; } - bool is_package (void) const { return m_object.is_package(); } + bool is_package () const { return m_object.is_package(); } octave_function * function_value (bool = false) { return this; } @@ -232,7 +232,7 @@ OCTINTERP_API std::string doc_string (const std::string& meth_name) const; - OCTINTERP_API std::string file_name (void) const; + OCTINTERP_API std::string file_name () const; private: @@ -242,7 +242,7 @@ class octave_classdef_superclass_ref : public octave_function { public: - octave_classdef_superclass_ref (void) = delete; + octave_classdef_superclass_ref () = delete; octave_classdef_superclass_ref (const std::string& meth, const std::string& cls) @@ -253,9 +253,9 @@ octave_classdef_superclass_ref& operator = (const octave_classdef_superclass_ref&) = delete; - ~octave_classdef_superclass_ref (void) = default; + ~octave_classdef_superclass_ref () = default; - bool is_classdef_superclass_ref (void) const { return true; } + bool is_classdef_superclass_ref () const { return true; } octave_function * function_value (bool = false) { return this; } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-colon.h --- a/libinterp/octave-value/ov-colon.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-colon.h Tue Jan 24 17:19:44 2023 -0800 @@ -49,27 +49,27 @@ { public: - octave_magic_colon (void) + octave_magic_colon () : octave_base_value () { } octave_magic_colon (const octave_magic_colon&) : octave_base_value () { } - ~octave_magic_colon (void) = default; + ~octave_magic_colon () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_magic_colon (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_magic_colon (); } octave::idx_vector index_vector (bool /* require_integers */ = false) const { return octave::idx_vector (':'); } - bool is_defined (void) const { return true; } + bool is_defined () const { return true; } - bool is_constant (void) const { return true; } + bool is_constant () const { return true; } - bool is_magic_colon (void) const { return true; } + bool is_magic_colon () const { return true; } OCTINTERP_API void print (std::ostream& os, bool pr_as_read_syntax = false); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-complex.cc --- a/libinterp/octave-value/ov-complex.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-complex.cc Tue Jan 24 17:19:44 2023 -0800 @@ -80,16 +80,16 @@ update_message (); } - ~complex_index_exception (void) = default; + ~complex_index_exception () = default; - void update_message (void) + void update_message () { set_message (expression () + ": subscripts must be real (forgot to initialize i or j?)"); } // ID of error to throw. - const char * err_id (void) const + const char * err_id () const { return "Octave:invalid-index"; } @@ -106,7 +106,7 @@ } octave_base_value::type_conv_info -octave_complex::numeric_demotion_function (void) const +octave_complex::numeric_demotion_function () const { return octave_base_value::type_conv_info (default_numeric_demotion_function, @@ -114,7 +114,7 @@ } octave_base_value * -octave_complex::try_narrowing_conversion (void) +octave_complex::try_narrowing_conversion () { octave_base_value *retval = nullptr; @@ -292,13 +292,13 @@ } octave_value -octave_complex::as_double (void) const +octave_complex::as_double () const { return scalar; } octave_value -octave_complex::as_single (void) const +octave_complex::as_single () const { return FloatComplex (scalar); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-complex.h --- a/libinterp/octave-value/ov-complex.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-complex.h Tue Jan 24 17:19:44 2023 -0800 @@ -54,7 +54,7 @@ { public: - octave_complex (void) + octave_complex () : octave_base_scalar () { } octave_complex (const Complex& c) @@ -63,20 +63,20 @@ octave_complex (const octave_complex& c) : octave_base_scalar (c) { } - ~octave_complex (void) = default; + ~octave_complex () = default; - octave_base_value * clone (void) const { return new octave_complex (*this); } + octave_base_value * clone () const { return new octave_complex (*this); } // We return an octave_complex_matrix object here instead of an // octave_complex object so that in expressions like A(2,2,2) = 2 // (for A previously undefined), A will be empty instead of a 1x1 // object. - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_complex_matrix (); } - type_conv_info numeric_demotion_function (void) const; + type_conv_info numeric_demotion_function () const; - octave_base_value * try_narrowing_conversion (void); + octave_base_value * try_narrowing_conversion (); octave_value do_index_op (const octave_value_list& idx, bool resize_ok = false); @@ -91,15 +91,15 @@ || lo_ieee_isnan (scalar.imag ()))); } - builtin_type_t builtin_type (void) const { return btyp_complex; } + builtin_type_t builtin_type () const { return btyp_complex; } - bool is_complex_scalar (void) const { return true; } + bool is_complex_scalar () const { return true; } - bool iscomplex (void) const { return true; } + bool iscomplex () const { return true; } - bool is_double_type (void) const { return true; } + bool is_double_type () const { return true; } - bool isfloat (void) const { return true; } + bool isfloat () const { return true; } OCTINTERP_API double double_value (bool = false) const; @@ -162,8 +162,8 @@ return boolNDArray (dim_vector (1, 1), scalar != 0.0); } - OCTINTERP_API octave_value as_double (void) const; - OCTINTERP_API octave_value as_single (void) const; + OCTINTERP_API octave_value as_double () const; + OCTINTERP_API octave_value as_single () const; // We don't need to override both forms of the diag method. The using // declaration will avoid warnings about partially-overloaded virtual @@ -172,9 +172,9 @@ OCTINTERP_API octave_value diag (octave_idx_type m, octave_idx_type n) const; - void increment (void) { scalar += 1.0; } + void increment () { scalar += 1.0; } - void decrement (void) { scalar -= 1.0; } + void decrement () { scalar -= 1.0; } OCTINTERP_API bool save_ascii (std::ostream& os); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-cs-list.h --- a/libinterp/octave-value/ov-cs-list.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-cs-list.h Tue Jan 24 17:19:44 2023 -0800 @@ -48,7 +48,7 @@ { public: - octave_cs_list (void) + octave_cs_list () : octave_base_value (), m_list () { } octave_cs_list (const octave_value_list& l) @@ -59,20 +59,20 @@ octave_cs_list (const octave_cs_list& l) : octave_base_value (), m_list (l.m_list) { } - ~octave_cs_list (void) = default; + ~octave_cs_list () = default; - octave_base_value * clone (void) const { return new octave_cs_list (*this); } - octave_base_value * empty_clone (void) const { return new octave_cs_list (); } + octave_base_value * clone () const { return new octave_cs_list (*this); } + octave_base_value * empty_clone () const { return new octave_cs_list (); } - dim_vector dims (void) const { return dim_vector (1, m_list.length ()); } + dim_vector dims () const { return dim_vector (1, m_list.length ()); } - bool is_defined (void) const { return true; } + bool is_defined () const { return true; } - bool is_constant (void) const { return true; } + bool is_constant () const { return true; } - bool is_cs_list (void) const { return true; } + bool is_cs_list () const { return true; } - octave_value_list list_value (void) const { return m_list; } + octave_value_list list_value () const { return m_list; } // We don't need to override all three forms of subsref. The using // declaration will avoid warnings about partially-overloaded virtual diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-cx-diag.cc --- a/libinterp/octave-value/ov-cx-diag.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-cx-diag.cc Tue Jan 24 17:19:44 2023 -0800 @@ -53,7 +53,7 @@ } octave_base_value::type_conv_info -octave_complex_diag_matrix::numeric_conversion_function (void) const +octave_complex_diag_matrix::numeric_conversion_function () const { return octave_base_value::type_conv_info (default_numeric_conversion_function, @@ -71,7 +71,7 @@ } octave_base_value::type_conv_info -octave_complex_diag_matrix::numeric_demotion_function (void) const +octave_complex_diag_matrix::numeric_demotion_function () const { return octave_base_value::type_conv_info (default_numeric_demotion_function, @@ -79,7 +79,7 @@ } octave_base_value * -octave_complex_diag_matrix::try_narrowing_conversion (void) +octave_complex_diag_matrix::try_narrowing_conversion () { octave_base_value *retval = nullptr; @@ -142,13 +142,13 @@ } octave_value -octave_complex_diag_matrix::as_double (void) const +octave_complex_diag_matrix::as_double () const { return m_matrix; } octave_value -octave_complex_diag_matrix::as_single (void) const +octave_complex_diag_matrix::as_single () const { return FloatComplexDiagMatrix (m_matrix); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-cx-diag.h --- a/libinterp/octave-value/ov-cx-diag.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-cx-diag.h Tue Jan 24 17:19:44 2023 -0800 @@ -41,7 +41,7 @@ { public: - octave_complex_diag_matrix (void) + octave_complex_diag_matrix () : octave_base_diag () { } octave_complex_diag_matrix (const ComplexDiagMatrix& m) @@ -50,28 +50,28 @@ octave_complex_diag_matrix (const octave_complex_diag_matrix& m) : octave_base_diag (m) { } - ~octave_complex_diag_matrix (void) = default; + ~octave_complex_diag_matrix () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_complex_diag_matrix (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_complex_diag_matrix (); } - OCTINTERP_API type_conv_info numeric_conversion_function (void) const; + OCTINTERP_API type_conv_info numeric_conversion_function () const; - OCTINTERP_API type_conv_info numeric_demotion_function (void) const; + OCTINTERP_API type_conv_info numeric_demotion_function () const; - OCTINTERP_API octave_base_value * try_narrowing_conversion (void); + OCTINTERP_API octave_base_value * try_narrowing_conversion (); - builtin_type_t builtin_type (void) const { return btyp_complex; } + builtin_type_t builtin_type () const { return btyp_complex; } - bool is_complex_matrix (void) const { return true; } + bool is_complex_matrix () const { return true; } - bool iscomplex (void) const { return true; } + bool iscomplex () const { return true; } - bool is_double_type (void) const { return true; } + bool is_double_type () const { return true; } - bool isfloat (void) const { return true; } + bool isfloat () const { return true; } OCTINTERP_API DiagMatrix diag_matrix_value (bool = false) const; @@ -83,8 +83,8 @@ OCTINTERP_API FloatComplexDiagMatrix float_complex_diag_matrix_value (bool = false) const; - OCTINTERP_API octave_value as_double (void) const; - OCTINTERP_API octave_value as_single (void) const; + OCTINTERP_API octave_value as_double () const; + OCTINTERP_API octave_value as_single () const; OCTINTERP_API bool save_binary (std::ostream& os, bool save_as_floats); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-cx-mat.cc --- a/libinterp/octave-value/ov-cx-mat.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-cx-mat.cc Tue Jan 24 17:19:44 2023 -0800 @@ -79,7 +79,7 @@ } octave_base_value::type_conv_info -octave_complex_matrix::numeric_demotion_function (void) const +octave_complex_matrix::numeric_demotion_function () const { return octave_base_value::type_conv_info (default_numeric_demotion_function, @@ -87,7 +87,7 @@ } octave_base_value * -octave_complex_matrix::try_narrowing_conversion (void) +octave_complex_matrix::try_narrowing_conversion () { octave_base_value *retval = nullptr; @@ -281,13 +281,13 @@ } octave_value -octave_complex_matrix::as_double (void) const +octave_complex_matrix::as_double () const { return m_matrix; } octave_value -octave_complex_matrix::as_single (void) const +octave_complex_matrix::as_single () const { return FloatComplexNDArray (m_matrix); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-cx-mat.h --- a/libinterp/octave-value/ov-cx-mat.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-cx-mat.h Tue Jan 24 17:19:44 2023 -0800 @@ -54,7 +54,7 @@ { public: - octave_complex_matrix (void) + octave_complex_matrix () : octave_base_matrix () { } octave_complex_matrix (const ComplexNDArray& m) @@ -81,26 +81,26 @@ octave_complex_matrix (const octave_complex_matrix& cm) : octave_base_matrix (cm) { } - ~octave_complex_matrix (void) = default; + ~octave_complex_matrix () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_complex_matrix (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_complex_matrix (); } - type_conv_info numeric_demotion_function (void) const; + type_conv_info numeric_demotion_function () const; - octave_base_value * try_narrowing_conversion (void); + octave_base_value * try_narrowing_conversion (); - builtin_type_t builtin_type (void) const { return btyp_complex; } + builtin_type_t builtin_type () const { return btyp_complex; } - bool is_complex_matrix (void) const { return true; } + bool is_complex_matrix () const { return true; } - bool iscomplex (void) const { return true; } + bool iscomplex () const { return true; } - bool is_double_type (void) const { return true; } + bool is_double_type () const { return true; } - bool isfloat (void) const { return true; } + bool isfloat () const { return true; } double double_value (bool = false) const; @@ -138,18 +138,18 @@ SparseComplexMatrix sparse_complex_matrix_value (bool = false) const; - octave_value as_double (void) const; - octave_value as_single (void) const; + octave_value as_double () const; + octave_value as_single () const; octave_value diag (octave_idx_type k = 0) const; octave_value diag (octave_idx_type m, octave_idx_type n) const; - void increment (void) { m_matrix += Complex (1.0); } + void increment () { m_matrix += Complex (1.0); } - void decrement (void) { m_matrix -= Complex (1.0); } + void decrement () { m_matrix -= Complex (1.0); } - void changesign (void) { m_matrix.changesign (); } + void changesign () { m_matrix.changesign (); } bool save_ascii (std::ostream& os); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-cx-sparse.cc --- a/libinterp/octave-value/ov-cx-sparse.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-cx-sparse.cc Tue Jan 24 17:19:44 2023 -0800 @@ -58,7 +58,7 @@ "sparse complex matrix", "double"); octave_base_value * -octave_sparse_complex_matrix::try_narrowing_conversion (void) +octave_sparse_complex_matrix::try_narrowing_conversion () { return (matrix.all_elements_are_real () ? new octave_sparse_matrix (::real (matrix)) : nullptr); @@ -173,7 +173,7 @@ } octave_value -octave_sparse_complex_matrix::as_double (void) const +octave_sparse_complex_matrix::as_double () const { return this->matrix; } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-cx-sparse.h --- a/libinterp/octave-value/ov-cx-sparse.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-cx-sparse.h Tue Jan 24 17:19:44 2023 -0800 @@ -53,7 +53,7 @@ { public: - octave_sparse_complex_matrix (void) + octave_sparse_complex_matrix () : octave_base_sparse () { } octave_sparse_complex_matrix (const ComplexNDArray& m) @@ -86,24 +86,24 @@ octave_sparse_complex_matrix (const octave_sparse_complex_matrix& cm) : octave_base_sparse (cm) { } - ~octave_sparse_complex_matrix (void) = default; + ~octave_sparse_complex_matrix () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_sparse_complex_matrix (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_sparse_complex_matrix (); } - octave_base_value * try_narrowing_conversion (void); + octave_base_value * try_narrowing_conversion (); - builtin_type_t builtin_type (void) const { return btyp_complex; } + builtin_type_t builtin_type () const { return btyp_complex; } - bool is_complex_matrix (void) const { return true; } + bool is_complex_matrix () const { return true; } - bool iscomplex (void) const { return true; } + bool iscomplex () const { return true; } - bool is_double_type (void) const { return true; } + bool is_double_type () const { return true; } - bool isfloat (void) const { return true; } + bool isfloat () const { return true; } double double_value (bool = false) const; @@ -127,7 +127,7 @@ SparseBoolMatrix sparse_bool_matrix_value (bool warn = false) const; - octave_value as_double (void) const; + octave_value as_double () const; #if 0 int write (octave::stream& os, int block_size, diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-dld-fcn.cc --- a/libinterp/octave-value/ov-dld-fcn.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-dld-fcn.cc Tue Jan 24 17:19:44 2023 -0800 @@ -83,7 +83,7 @@ && oct_file_dir == file_name.substr (0, oct_file_dir.length ())); } -octave_dld_function::~octave_dld_function (void) +octave_dld_function::~octave_dld_function () { octave::dynamic_loader& dyn_loader = octave::__get_dynamic_loader__ (); @@ -91,13 +91,13 @@ } std::string -octave_dld_function::fcn_file_name (void) const +octave_dld_function::fcn_file_name () const { return m_sh_lib.file_name (); } octave::sys::time -octave_dld_function::time_parsed (void) const +octave_dld_function::time_parsed () const { return m_sh_lib.time_loaded (); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-dld-fcn.h --- a/libinterp/octave-value/ov-dld-fcn.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-dld-fcn.h Tue Jan 24 17:19:44 2023 -0800 @@ -47,7 +47,7 @@ { public: - octave_dld_function (void) + octave_dld_function () : m_sh_lib (), m_time_checked (), m_system_fcn_file () { } @@ -67,22 +67,22 @@ octave_dld_function& operator = (const octave_dld_function& fcn) = delete; - ~octave_dld_function (void); + ~octave_dld_function (); void mark_fcn_file_up_to_date (const octave::sys::time& t) { m_time_checked = t; } - std::string fcn_file_name (void) const; + std::string fcn_file_name () const; - octave::sys::time time_parsed (void) const; + octave::sys::time time_parsed () const; - octave::sys::time time_checked (void) const { return m_time_checked; } + octave::sys::time time_checked () const { return m_time_checked; } - bool is_system_fcn_file (void) const { return m_system_fcn_file; } + bool is_system_fcn_file () const { return m_system_fcn_file; } - bool is_builtin_function (void) const { return false; } + bool is_builtin_function () const { return false; } - bool is_dld_function (void) const { return true; } + bool is_dld_function () const { return true; } static octave_dld_function * create (octave_builtin::fcn ff, const octave::dynamic_library& shl, @@ -94,7 +94,7 @@ const std::string& nm = "", const std::string& ds = ""); - octave::dynamic_library get_shlib (void) const + octave::dynamic_library get_shlib () const { return m_sh_lib; } private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-fcn-handle.cc --- a/libinterp/octave-value/ov-fcn-handle.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-fcn-handle.cc Tue Jan 24 17:19:44 2023 -0800 @@ -90,18 +90,18 @@ { public: - invalid_fcn_handle (void) : base_fcn_handle ("") { } + invalid_fcn_handle () : base_fcn_handle ("") { } invalid_fcn_handle (const invalid_fcn_handle&) = default; - ~invalid_fcn_handle (void) = default; - - invalid_fcn_handle * clone (void) const + ~invalid_fcn_handle () = default; + + invalid_fcn_handle * clone () const { return new invalid_fcn_handle (*this); } - std::string type (void) const { return ""; } + std::string type () const { return ""; } octave_value_list call (int nargout, const octave_value_list& args); }; @@ -120,16 +120,16 @@ internal_fcn_handle (const internal_fcn_handle&) = default; - ~internal_fcn_handle (void) = default; - - internal_fcn_handle * clone (void) const + ~internal_fcn_handle () = default; + + internal_fcn_handle * clone () const { return new internal_fcn_handle (*this); } - std::string type (void) const { return ""; } - - bool is_internal (void) const { return true; } + std::string type () const { return ""; } + + bool is_internal () const { return true; } octave_value_list call (int nargout, const octave_value_list& args); @@ -145,10 +145,10 @@ return m_fcn.user_function_value (); } - octave_value fcn_val (void) { return m_fcn; } + octave_value fcn_val () { return m_fcn; } // Should be const. - octave_scalar_map info (void); + octave_scalar_map info (); friend bool is_equal_to (const internal_fcn_handle& fh1, const internal_fcn_handle& fh2); @@ -185,16 +185,16 @@ simple_fcn_handle (const simple_fcn_handle&) = default; - ~simple_fcn_handle (void) = default; - - simple_fcn_handle * clone (void) const + ~simple_fcn_handle () = default; + + simple_fcn_handle * clone () const { return new simple_fcn_handle (*this); } - std::string type (void) const { return "simple"; } - - bool is_simple (void) const { return true; } + std::string type () const { return "simple"; } + + bool is_simple () const { return true; } octave_value_list call (int nargout, const octave_value_list& args); @@ -204,10 +204,10 @@ octave_user_function * user_function_value (bool); - octave_value fcn_val (void); + octave_value fcn_val (); // Should be const. - octave_scalar_map info (void); + octave_scalar_map info (); bool save_ascii (std::ostream& os); @@ -252,16 +252,16 @@ scoped_fcn_handle (const scoped_fcn_handle&) = default; - ~scoped_fcn_handle (void) = default; - - scoped_fcn_handle * clone (void) const + ~scoped_fcn_handle () = default; + + scoped_fcn_handle * clone () const { return new scoped_fcn_handle (*this); } - std::string type (void) const { return "scopedfunction"; } - - bool is_scoped (void) const { return true; } + std::string type () const { return "scopedfunction"; } + + bool is_scoped () const { return true; } octave_value_list call (int nargout, const octave_value_list& args); @@ -277,10 +277,10 @@ return m_fcn.user_function_value (); } - octave_value fcn_val (void) { return m_fcn; } + octave_value fcn_val () { return m_fcn; } // Should be const. - octave_scalar_map info (void); + octave_scalar_map info (); bool save_ascii (std::ostream& os); @@ -304,7 +304,7 @@ protected: - void find_function (void); + void find_function (); // The function we are handling. octave_value m_fcn; @@ -331,11 +331,11 @@ : base_fcn_handle (name), m_fcn (fcn) { } - std::string type (void) const { return "nested"; } + std::string type () const { return "nested"; } using base_fcn_handle::is_nested; - bool is_nested (void) const { return true; } + bool is_nested () const { return true; } // FIXME: These must go away. They don't do the right thing for // scoping or overloads. @@ -349,12 +349,12 @@ return m_fcn.user_function_value (); } - octave_value fcn_val (void) { return m_fcn; } - - virtual octave_value workspace (void) const = 0; + octave_value fcn_val () { return m_fcn; } + + virtual octave_value workspace () const = 0; // Should be const. - octave_scalar_map info (void); + octave_scalar_map info (); bool save_ascii (std::ostream& os); @@ -402,7 +402,7 @@ nested_fcn_handle (const nested_fcn_handle&) = default; - ~nested_fcn_handle (void) = default; + ~nested_fcn_handle () = default; using base_nested_fcn_handle::is_nested; @@ -411,21 +411,21 @@ return frame == m_stack_context; } - nested_fcn_handle * clone (void) const + nested_fcn_handle * clone () const { return new nested_fcn_handle (*this); } - octave_value make_weak_nested_handle (void) const; + octave_value make_weak_nested_handle () const; octave_value_list call (int nargout, const octave_value_list& args); - octave_value workspace (void) const; + octave_value workspace () const; friend bool is_equal_to (const nested_fcn_handle& fh1, const nested_fcn_handle& fh2); - std::shared_ptr stack_context (void) const + std::shared_ptr stack_context () const { return m_stack_context; } @@ -446,18 +446,18 @@ weak_nested_fcn_handle (const weak_nested_fcn_handle&) = default; - ~weak_nested_fcn_handle (void) = default; - - weak_nested_fcn_handle * clone (void) const + ~weak_nested_fcn_handle () = default; + + weak_nested_fcn_handle * clone () const { return new weak_nested_fcn_handle (*this); } - bool is_weak_nested (void) const { return true; } + bool is_weak_nested () const { return true; } octave_value_list call (int nargout, const octave_value_list& args); - octave_value workspace (void) const; + octave_value workspace () const; friend bool is_equal_to (const weak_nested_fcn_handle& fh1, const weak_nested_fcn_handle& fh2); @@ -497,16 +497,16 @@ class_simple_fcn_handle (const class_simple_fcn_handle&) = default; - ~class_simple_fcn_handle (void) = default; - - class_simple_fcn_handle * clone (void) const + ~class_simple_fcn_handle () = default; + + class_simple_fcn_handle * clone () const { return new class_simple_fcn_handle (*this); } - std::string type (void) const { return "classsimple"; } - - bool is_class_simple (void) const { return true; } + std::string type () const { return "classsimple"; } + + bool is_class_simple () const { return true; } octave_value_list call (int nargout, const octave_value_list& args); @@ -540,12 +540,12 @@ return m_fcn.user_function_value (); } - octave_value fcn_val (void) { return m_fcn; } + octave_value fcn_val () { return m_fcn; } // Should be const. - octave_scalar_map info (void); - - std::string dispatch_class (void) const { return m_dispatch_class; } + octave_scalar_map info (); + + std::string dispatch_class () const { return m_dispatch_class; } bool save_ascii (std::ostream& os); @@ -627,11 +627,11 @@ base_anonymous_fcn_handle (const base_anonymous_fcn_handle&) = default; - ~base_anonymous_fcn_handle (void) = default; - - std::string type (void) const { return "anonymous"; } - - bool is_anonymous (void) const { return true; } + ~base_anonymous_fcn_handle () = default; + + std::string type () const { return "anonymous"; } + + bool is_anonymous () const { return true; } // FIXME: These must go away. They don't do the right thing for // scoping or overloads. @@ -645,12 +645,12 @@ return m_fcn.user_function_value (); } - octave_value fcn_val (void) { return m_fcn; } - - virtual octave_value workspace (void) const = 0; + octave_value fcn_val () { return m_fcn; } + + virtual octave_value workspace () const = 0; // Should be const. - octave_scalar_map info (void); + octave_scalar_map info (); bool save_ascii (std::ostream& os); @@ -670,7 +670,7 @@ int current_print_indent_level) const; // Anonymous function handles are printed without a newline. - bool print_as_scalar (void) const { return false; } + bool print_as_scalar () const { return false; } bool parse (const std::string& fcn_text); @@ -704,23 +704,23 @@ anonymous_fcn_handle (const anonymous_fcn_handle&) = default; - ~anonymous_fcn_handle (void) = default; - - anonymous_fcn_handle * clone (void) const + ~anonymous_fcn_handle () = default; + + anonymous_fcn_handle * clone () const { return new anonymous_fcn_handle (*this); } - octave_value make_weak_anonymous_handle (void) const; + octave_value make_weak_anonymous_handle () const; octave_value_list call (int nargout, const octave_value_list& args); - octave_value workspace (void) const; + octave_value workspace () const; friend bool is_equal_to (const anonymous_fcn_handle& fh1, const anonymous_fcn_handle& fh2); - std::shared_ptr stack_context (void) const + std::shared_ptr stack_context () const { return m_stack_context; } @@ -743,18 +743,18 @@ weak_anonymous_fcn_handle (const weak_anonymous_fcn_handle&) = default; - ~weak_anonymous_fcn_handle (void) = default; - - weak_anonymous_fcn_handle * clone (void) const + ~weak_anonymous_fcn_handle () = default; + + weak_anonymous_fcn_handle * clone () const { return new weak_anonymous_fcn_handle (*this); } - bool is_weak_anonymous (void) const { return true; } + bool is_weak_anonymous () const { return true; } octave_value_list call (int nargout, const octave_value_list& args); - octave_value workspace (void) const; + octave_value workspace () const; friend bool is_equal_to (const weak_anonymous_fcn_handle& fh1, const weak_anonymous_fcn_handle& fh2); @@ -774,14 +774,14 @@ name.c_str ()); } -octave_value base_fcn_handle::make_weak_nested_handle (void) const +octave_value base_fcn_handle::make_weak_nested_handle () const { std::string type_str = type (); error ("invalid conversion from %s handle to weak nestead handle", type_str.c_str ()); } -octave_value base_fcn_handle::make_weak_anonymous_handle (void) const +octave_value base_fcn_handle::make_weak_anonymous_handle () const { std::string type_str = type (); error ("invalid conversion from %s handle to weak anonymous handle", @@ -921,7 +921,7 @@ return interp.feval (m_fcn, args, nargout); } -octave_scalar_map internal_fcn_handle::info (void) +octave_scalar_map internal_fcn_handle::info () { octave_scalar_map m; @@ -1166,7 +1166,7 @@ return m_fcn.is_defined () ? m_fcn.user_function_value () : nullptr; } -octave_value simple_fcn_handle::fcn_val (void) +octave_value simple_fcn_handle::fcn_val () { if (m_fcn.is_defined ()) return m_fcn; @@ -1182,7 +1182,7 @@ return m_fcn; } -octave_scalar_map simple_fcn_handle::info (void) +octave_scalar_map simple_fcn_handle::info () { octave_scalar_map m; @@ -1476,7 +1476,7 @@ return interp.feval (m_fcn, args, nargout); } -octave_scalar_map scoped_fcn_handle::info (void) +octave_scalar_map scoped_fcn_handle::info () { octave_scalar_map m; @@ -1631,7 +1631,7 @@ return false; } -void scoped_fcn_handle::find_function (void) +void scoped_fcn_handle::find_function () { // Since a scoped function is not visible by itself, try to load the // file named in m_file then find and define the scoped function. @@ -1688,7 +1688,7 @@ } } -octave_scalar_map base_nested_fcn_handle::info (void) +octave_scalar_map base_nested_fcn_handle::info () { octave_scalar_map m; @@ -1807,7 +1807,7 @@ current_print_indent_level); } -octave_value nested_fcn_handle::make_weak_nested_handle (void) const +octave_value nested_fcn_handle::make_weak_nested_handle () const { return octave_value (new octave_fcn_handle (new weak_nested_fcn_handle (*this))); @@ -1827,7 +1827,7 @@ return oct_usr_fcn->execute (tw, nargout, args); } -octave_value nested_fcn_handle::workspace (void) const +octave_value nested_fcn_handle::workspace () const { return m_stack_context->workspace (); } @@ -1857,7 +1857,7 @@ return oct_usr_fcn->execute (tw, nargout, args); } -octave_value weak_nested_fcn_handle::workspace (void) const +octave_value weak_nested_fcn_handle::workspace () const { std::shared_ptr frames = m_stack_context.lock (); @@ -1925,7 +1925,7 @@ return interp.feval (fcn_name (), args, nargout); } -octave_scalar_map class_simple_fcn_handle::info (void) +octave_scalar_map class_simple_fcn_handle::info () { octave_scalar_map m; @@ -2054,7 +2054,7 @@ const std::string base_anonymous_fcn_handle::anonymous ("@"); -octave_scalar_map base_anonymous_fcn_handle::info (void) +octave_scalar_map base_anonymous_fcn_handle::info () { octave_scalar_map m; @@ -2694,7 +2694,7 @@ m_stack_context->mark_closure_context (); } -octave_value anonymous_fcn_handle::make_weak_anonymous_handle (void) const +octave_value anonymous_fcn_handle::make_weak_anonymous_handle () const { return octave_value (new octave_fcn_handle (new weak_anonymous_fcn_handle (*this))); @@ -2714,7 +2714,7 @@ return oct_usr_fcn->execute (tw, nargout, args); } -octave_value anonymous_fcn_handle::workspace (void) const +octave_value anonymous_fcn_handle::workspace () const { octave_scalar_map local_vars_map; @@ -2768,7 +2768,7 @@ return oct_usr_fcn->execute (tw, nargout, args); } -octave_value weak_anonymous_fcn_handle::workspace (void) const +octave_value weak_anonymous_fcn_handle::workspace () const { octave_scalar_map local_vars_map; @@ -2813,7 +2813,7 @@ OCTAVE_END_NAMESPACE(octave) -octave_fcn_handle::octave_fcn_handle (void) +octave_fcn_handle::octave_fcn_handle () : octave_base_value (), m_rep (new octave::invalid_fcn_handle ()) { } @@ -2883,7 +2883,7 @@ } dim_vector -octave_fcn_handle::dims (void) const +octave_fcn_handle::dims () const { static dim_vector dv (1, 1); return dv; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-fcn-handle.h --- a/libinterp/octave-value/ov-fcn-handle.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-fcn-handle.h Tue Jan 24 17:19:44 2023 -0800 @@ -58,40 +58,40 @@ base_fcn_handle (const base_fcn_handle&) = default; - virtual ~base_fcn_handle (void) = default; + virtual ~base_fcn_handle () = default; - virtual base_fcn_handle * clone (void) const = 0; + virtual base_fcn_handle * clone () const = 0; - virtual std::string type (void) const = 0; + virtual std::string type () const = 0; - virtual bool is_internal (void) const { return false; } + virtual bool is_internal () const { return false; } - virtual bool is_simple (void) const { return false; } + virtual bool is_simple () const { return false; } - virtual bool is_scoped (void) const { return false; } + virtual bool is_scoped () const { return false; } - virtual bool is_nested (void) const { return false; } + virtual bool is_nested () const { return false; } virtual bool is_nested (const std::shared_ptr&) const { return false; } - virtual bool is_weak_nested (void) const { return false; } + virtual bool is_weak_nested () const { return false; } - virtual bool is_class_simple (void) const { return false; } + virtual bool is_class_simple () const { return false; } - virtual bool is_anonymous (void) const { return false; } + virtual bool is_anonymous () const { return false; } - virtual bool is_weak_anonymous (void) const { return false; } + virtual bool is_weak_anonymous () const { return false; } - virtual octave_value make_weak_nested_handle (void) const; + virtual octave_value make_weak_nested_handle () const; - virtual octave_value make_weak_anonymous_handle (void) const; + virtual octave_value make_weak_anonymous_handle () const; - std::string fcn_name (void) const { return m_name; } + std::string fcn_name () const { return m_name; } - std::string file (void) const { return m_file; } + std::string file () const { return m_file; } octave_value_list subsref (const std::string& type, const std::list& idx, @@ -112,16 +112,16 @@ return nullptr; } - virtual octave_value fcn_val (void) { return octave_value (); } + virtual octave_value fcn_val () { return octave_value (); } - virtual octave_value workspace (void) const { return octave_value (); } + virtual octave_value workspace () const { return octave_value (); } // Should be const. - virtual octave_scalar_map info (void) { return octave_scalar_map (); } + virtual octave_scalar_map info () { return octave_scalar_map (); } virtual void set_dispatch_class (const std::string& /*class_name*/) { } - virtual std::string get_dispatch_class (void) const { return ""; } + virtual std::string get_dispatch_class () const { return ""; } octave_value convert_to_str_internal (bool pad, bool force, char type) const; @@ -146,7 +146,7 @@ { } // Function handles are printed without a newline by default. - virtual bool print_as_scalar (void) const { return true; } + virtual bool print_as_scalar () const { return true; } virtual bool set_fcn (const std::string& /*octaveroot*/, const std::string& /*fpath*/) @@ -182,7 +182,7 @@ // Creates an invalid function handle. Used to create generic // function handle objects when loading function handles. Further // dispatch happens in the octave_fcn_handle load/save functions. - octave_fcn_handle (void); + octave_fcn_handle (); // Create a handle to a built-in or internal function. octave_fcn_handle (const octave_value& fcn); @@ -225,14 +225,14 @@ octave_fcn_handle (const octave_fcn_handle& fh); - ~octave_fcn_handle (void) = default; + ~octave_fcn_handle () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_fcn_handle (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_fcn_handle (); } @@ -258,44 +258,44 @@ octave_value_list call (int nargout, const octave_value_list& args); - bool is_defined (void) const { return true; } + bool is_defined () const { return true; } - builtin_type_t builtin_type (void) const { return btyp_func_handle; } + builtin_type_t builtin_type () const { return btyp_func_handle; } - bool is_function_handle (void) const { return true; } + bool is_function_handle () const { return true; } - bool is_internal (void) const { return m_rep->is_internal (); } + bool is_internal () const { return m_rep->is_internal (); } - bool is_simple (void) const { return m_rep->is_simple (); } + bool is_simple () const { return m_rep->is_simple (); } - bool is_scoped (void) const { return m_rep->is_scoped (); } + bool is_scoped () const { return m_rep->is_scoped (); } - bool is_nested (void) const { return m_rep->is_nested (); } + bool is_nested () const { return m_rep->is_nested (); } bool is_nested (const std::shared_ptr& frame) const { return m_rep->is_nested (frame); } - bool is_weak_nested (void) const { return m_rep->is_weak_nested (); } + bool is_weak_nested () const { return m_rep->is_weak_nested (); } - bool is_class_simple (void) const { return m_rep->is_class_simple (); } + bool is_class_simple () const { return m_rep->is_class_simple (); } - bool is_anonymous (void) const { return m_rep->is_anonymous (); } + bool is_anonymous () const { return m_rep->is_anonymous (); } - bool is_weak_anonymous (void) const { return m_rep->is_weak_anonymous (); } + bool is_weak_anonymous () const { return m_rep->is_weak_anonymous (); } - octave_value make_weak_nested_handle (void) const + octave_value make_weak_nested_handle () const { return m_rep->make_weak_nested_handle (); } - octave_value make_weak_anonymous_handle (void) const + octave_value make_weak_anonymous_handle () const { return m_rep->make_weak_anonymous_handle (); } - dim_vector dims (void) const; + dim_vector dims () const; // FIXME: These must go away. They don't do the right thing for // scoping or overloads. @@ -311,24 +311,24 @@ octave_fcn_handle * fcn_handle_value (bool = false) { return this; } - octave_value fcn_val (void) { return m_rep->fcn_val (); } + octave_value fcn_val () { return m_rep->fcn_val (); } // FCN_NAME should be eliminated. - std::string fcn_name (void) const { return m_rep->fcn_name (); } + std::string fcn_name () const { return m_rep->fcn_name (); } - octave_value workspace (void) const + octave_value workspace () const { return m_rep->workspace (); } - octave_scalar_map info (void) { return m_rep->info (); } + octave_scalar_map info () { return m_rep->info (); } void set_dispatch_class (const std::string& class_name) { m_rep->set_dispatch_class (class_name); } - std::string get_dispatch_class (void) const + std::string get_dispatch_class () const { return m_rep->get_dispatch_class (); } @@ -356,7 +356,7 @@ void print_raw (std::ostream& os, bool pr_as_read_syntax = false) const; // Simple function handles are printed without a newline. - bool print_as_scalar (void) const { return m_rep->print_as_scalar (); } + bool print_as_scalar () const { return m_rep->print_as_scalar (); } friend bool is_equal_to (const octave_fcn_handle& fh1, const octave_fcn_handle& fh2); @@ -365,7 +365,7 @@ std::shared_ptr m_rep; - octave::base_fcn_handle * get_rep (void) const { return m_rep.get (); } + octave::base_fcn_handle * get_rep () const { return m_rep.get (); } DECLARE_OV_TYPEID_FUNCTIONS_AND_DATA }; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-fcn.cc --- a/libinterp/octave-value/ov-fcn.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-fcn.cc Tue Jan 24 17:19:44 2023 -0800 @@ -35,13 +35,13 @@ #include "pt-eval.h" octave_base_value * -octave_function::clone (void) const +octave_function::clone () const { panic_impossible (); } octave_base_value * -octave_function::empty_clone (void) const +octave_function::empty_clone () const { panic_impossible (); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-fcn.h --- a/libinterp/octave-value/ov-fcn.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-fcn.h Tue Jan 24 17:19:44 2023 -0800 @@ -54,7 +54,7 @@ { public: - octave_function (void) + octave_function () : m_relative (false), m_locked (false), m_private (false), m_dispatch_class (), m_package_name (), m_name (), m_dir_name (), m_doc () { } @@ -65,49 +65,49 @@ octave_function& operator = (const octave_function& f) = delete; - ~octave_function (void) = default; + ~octave_function () = default; - octave_base_value * clone (void) const; - octave_base_value * empty_clone (void) const; + octave_base_value * clone () const; + octave_base_value * empty_clone () const; - bool is_defined (void) const { return true; } + bool is_defined () const { return true; } - bool is_function (void) const { return true; } + bool is_function () const { return true; } - virtual bool is_system_fcn_file (void) const { return false; } + virtual bool is_system_fcn_file () const { return false; } - virtual std::string fcn_file_name (void) const { return ""; } + virtual std::string fcn_file_name () const { return ""; } - virtual std::string src_file_name (void) const { return ""; } + virtual std::string src_file_name () const { return ""; } // The name to show in the profiler (also used as map-key). - virtual std::string profiler_name (void) const { return name (); } + virtual std::string profiler_name () const { return name (); } - virtual std::string parent_fcn_name (void) const { return ""; } + virtual std::string parent_fcn_name () const { return ""; } - virtual octave::symbol_scope parent_fcn_scope (void) const + virtual octave::symbol_scope parent_fcn_scope () const { return octave::symbol_scope (); } - virtual std::list parent_fcn_names (void) const + virtual std::list parent_fcn_names () const { return std::list (); } virtual void mark_fcn_file_up_to_date (const octave::sys::time&) { } - virtual octave::symbol_scope scope (void) { return octave::symbol_scope (); } + virtual octave::symbol_scope scope () { return octave::symbol_scope (); } - virtual octave::sys::time time_parsed (void) const + virtual octave::sys::time time_parsed () const { return octave::sys::time (static_cast (0)); } - virtual octave::sys::time time_checked (void) const + virtual octave::sys::time time_checked () const { return octave::sys::time (static_cast (0)); } - virtual int call_depth (void) const { return 0; } + virtual int call_depth () const { return 0; } - virtual bool is_nested_function (void) const { return false; } + virtual bool is_nested_function () const { return false; } - virtual bool is_parent_function (void) const { return false; } + virtual bool is_parent_function () const { return false; } - virtual bool is_subfunction (void) const { return false; } + virtual bool is_subfunction () const { return false; } bool is_class_constructor (const std::string& cname = "") const { @@ -133,9 +133,9 @@ virtual bool is_classdef_method (const std::string& = "") const { return false; } - virtual bool takes_varargs (void) const { return false; } + virtual bool takes_varargs () const { return false; } - virtual bool takes_var_return (void) const { return false; } + virtual bool takes_var_return () const { return false; } // The next two functions are for dispatching to built-in // functions given built-in classes. @@ -147,11 +147,11 @@ void stash_dispatch_class (const std::string& nm) { m_dispatch_class = nm; } - std::string dispatch_class (void) const { return m_dispatch_class; } + std::string dispatch_class () const { return m_dispatch_class; } void stash_package_name (const std::string& pack) { m_package_name = pack; } - std::string package_name (void) const { return m_package_name; } + std::string package_name () const { return m_package_name; } virtual void mark_as_private_function (const std::string& cname = "") @@ -160,7 +160,7 @@ m_dispatch_class = cname; } - bool is_private_function (void) const { return m_private; } + bool is_private_function () const { return m_private; } bool is_private_function_of_class (const std::string& nm) const { return m_private && m_dispatch_class == nm; } @@ -169,45 +169,45 @@ is_anonymous_function_of_class (const std::string& = "") const { return false; } - std::string dir_name (void) const { return m_dir_name; } + std::string dir_name () const { return m_dir_name; } void stash_dir_name (const std::string& dir) { m_dir_name = dir; } - void lock (void) + void lock () { this->lock_subfunctions (); m_locked = true; } - void unlock (void) + void unlock () { this->unlock_subfunctions (); m_locked = false; } - bool islocked (void) const { return m_locked; } + bool islocked () const { return m_locked; } - virtual void lock_subfunctions (void) { } + virtual void lock_subfunctions () { } - virtual void unlock_subfunctions (void) { } + virtual void unlock_subfunctions () { } - virtual void maybe_relocate_end (void) { } + virtual void maybe_relocate_end () { } // Not valid until after the function is completely parsed. - virtual bool has_subfunctions (void) const { return false; } + virtual bool has_subfunctions () const { return false; } virtual void stash_subfunction_names (const std::list&) { } - virtual std::list subfunction_names (void) const + virtual std::list subfunction_names () const { return std::list (); } - void mark_relative (void) { m_relative = true; } + void mark_relative () { m_relative = true; } - bool is_relative (void) const { return m_relative; } + bool is_relative () const { return m_relative; } - std::string name (void) const { return m_name; } + std::string name () const { return m_name; } - std::string canonical_name (void) const + std::string canonical_name () const { if (m_package_name.empty ()) return m_name; @@ -220,7 +220,7 @@ virtual std::string doc_string (const std::string& /*meth_name*/ = "") const { return m_doc; } - virtual void unload (void) { } + virtual void unload () { } virtual void accept (octave::tree_walker&) { } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-float.cc --- a/libinterp/octave-value/ov-float.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-float.cc Tue Jan 24 17:19:44 2023 -0800 @@ -106,61 +106,61 @@ } octave_value -octave_float_scalar::as_double (void) const +octave_float_scalar::as_double () const { return static_cast (scalar); } octave_value -octave_float_scalar::as_single (void) const +octave_float_scalar::as_single () const { return scalar; } octave_value -octave_float_scalar::as_int8 (void) const +octave_float_scalar::as_int8 () const { return octave_int8 (scalar); } octave_value -octave_float_scalar::as_int16 (void) const +octave_float_scalar::as_int16 () const { return octave_int16 (scalar); } octave_value -octave_float_scalar::as_int32 (void) const +octave_float_scalar::as_int32 () const { return octave_int32 (scalar); } octave_value -octave_float_scalar::as_int64 (void) const +octave_float_scalar::as_int64 () const { return octave_int64 (scalar); } octave_value -octave_float_scalar::as_uint8 (void) const +octave_float_scalar::as_uint8 () const { return octave_uint8 (scalar); } octave_value -octave_float_scalar::as_uint16 (void) const +octave_float_scalar::as_uint16 () const { return octave_uint16 (scalar); } octave_value -octave_float_scalar::as_uint32 (void) const +octave_float_scalar::as_uint32 () const { return octave_uint32 (scalar); } octave_value -octave_float_scalar::as_uint64 (void) const +octave_float_scalar::as_uint64 () const { return octave_uint64 (scalar); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-float.h --- a/libinterp/octave-value/ov-float.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-float.h Tue Jan 24 17:19:44 2023 -0800 @@ -56,7 +56,7 @@ { public: - octave_float_scalar (void) + octave_float_scalar () : octave_base_scalar (0.0) { } octave_float_scalar (float d) @@ -65,15 +65,15 @@ octave_float_scalar (const octave_float_scalar& s) : octave_base_scalar (s) { } - ~octave_float_scalar (void) = default; + ~octave_float_scalar () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_float_scalar (*this); } // We return an octave_matrix here instead of an octave_float_scalar so // that in expressions like A(2,2,2) = 2 (for A previously // undefined), A will be empty instead of a 1x1 object. - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_float_matrix (); } octave_value do_index_op (const octave_value_list& idx, @@ -85,51 +85,51 @@ octave_value any (int = 0) const { return (scalar != 0 && ! lo_ieee_isnan (scalar)); } - builtin_type_t builtin_type (void) const { return btyp_float; } + builtin_type_t builtin_type () const { return btyp_float; } - bool is_real_scalar (void) const { return true; } + bool is_real_scalar () const { return true; } - bool isreal (void) const { return true; } + bool isreal () const { return true; } - bool is_single_type (void) const { return true; } + bool is_single_type () const { return true; } - bool isfloat (void) const { return true; } + bool isfloat () const { return true; } int8NDArray - int8_array_value (void) const + int8_array_value () const { return int8NDArray (dim_vector (1, 1), scalar); } int16NDArray - int16_array_value (void) const + int16_array_value () const { return int16NDArray (dim_vector (1, 1), scalar); } int32NDArray - int32_array_value (void) const + int32_array_value () const { return int32NDArray (dim_vector (1, 1), scalar); } int64NDArray - int64_array_value (void) const + int64_array_value () const { return int64NDArray (dim_vector (1, 1), scalar); } uint8NDArray - uint8_array_value (void) const + uint8_array_value () const { return uint8NDArray (dim_vector (1, 1), scalar); } uint16NDArray - uint16_array_value (void) const + uint16_array_value () const { return uint16NDArray (dim_vector (1, 1), scalar); } uint32NDArray - uint32_array_value (void) const + uint32_array_value () const { return uint32NDArray (dim_vector (1, 1), scalar); } uint64NDArray - uint64_array_value (void) const + uint64_array_value () const { return uint64NDArray (dim_vector (1, 1), scalar); } #define DEFINE_INT_SCALAR_VALUE(TYPE) \ octave_ ## TYPE \ - TYPE ## _scalar_value (void) const \ + TYPE ## _scalar_value () const \ { \ return octave_ ## TYPE (scalar); \ } @@ -220,18 +220,18 @@ return boolNDArray (dim_vector (1, 1), scalar); } - octave_value as_double (void) const; - octave_value as_single (void) const; + octave_value as_double () const; + octave_value as_single () const; - octave_value as_int8 (void) const; - octave_value as_int16 (void) const; - octave_value as_int32 (void) const; - octave_value as_int64 (void) const; + octave_value as_int8 () const; + octave_value as_int16 () const; + octave_value as_int32 () const; + octave_value as_int64 () const; - octave_value as_uint8 (void) const; - octave_value as_uint16 (void) const; - octave_value as_uint32 (void) const; - octave_value as_uint64 (void) const; + octave_value as_uint8 () const; + octave_value as_uint16 () const; + octave_value as_uint32 () const; + octave_value as_uint64 () const; // We don't need to override both forms of the diag method. The using // declaration will avoid warnings about partially-overloaded virtual @@ -242,9 +242,9 @@ octave_value convert_to_str_internal (bool pad, bool force, char type) const; - void increment (void) { ++scalar; } + void increment () { ++scalar; } - void decrement (void) { --scalar; } + void decrement () { --scalar; } bool save_ascii (std::ostream& os); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-flt-complex.cc --- a/libinterp/octave-value/ov-flt-complex.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-flt-complex.cc Tue Jan 24 17:19:44 2023 -0800 @@ -64,7 +64,7 @@ "float complex scalar", "single"); octave_base_value * -octave_float_complex::try_narrowing_conversion (void) +octave_float_complex::try_narrowing_conversion () { octave_base_value *retval = nullptr; @@ -230,13 +230,13 @@ } octave_value -octave_float_complex::as_double (void) const +octave_float_complex::as_double () const { return Complex (scalar); } octave_value -octave_float_complex::as_single (void) const +octave_float_complex::as_single () const { return scalar; } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-flt-complex.h --- a/libinterp/octave-value/ov-flt-complex.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-flt-complex.h Tue Jan 24 17:19:44 2023 -0800 @@ -54,7 +54,7 @@ { public: - octave_float_complex (void) + octave_float_complex () : octave_base_scalar () { } octave_float_complex (const FloatComplex& c) @@ -63,19 +63,19 @@ octave_float_complex (const octave_float_complex& c) : octave_base_scalar (c) { } - ~octave_float_complex (void) = default; + ~octave_float_complex () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_float_complex (*this); } // We return an octave_float_complex_matrix object here instead of an // octave_float_complex object so that in expressions like A(2,2,2) = 2 // (for A previously undefined), A will be empty instead of a 1x1 // object. - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_float_complex_matrix (); } - octave_base_value * try_narrowing_conversion (void); + octave_base_value * try_narrowing_conversion (); octave_value do_index_op (const octave_value_list& idx, bool resize_ok = false); @@ -87,15 +87,15 @@ || lo_ieee_isnan (scalar.imag ()))); } - builtin_type_t builtin_type (void) const { return btyp_float_complex; } + builtin_type_t builtin_type () const { return btyp_float_complex; } - bool is_complex_scalar (void) const { return true; } + bool is_complex_scalar () const { return true; } - bool iscomplex (void) const { return true; } + bool iscomplex () const { return true; } - bool is_single_type (void) const { return true; } + bool is_single_type () const { return true; } - bool isfloat (void) const { return true; } + bool isfloat () const { return true; } double double_value (bool = false) const; @@ -155,8 +155,8 @@ return boolNDArray (dim_vector (1, 1), scalar != 1.0f); } - octave_value as_double (void) const; - octave_value as_single (void) const; + octave_value as_double () const; + octave_value as_single () const; // We don't need to override both forms of the diag method. The using // declaration will avoid warnings about partially-overloaded virtual @@ -165,9 +165,9 @@ octave_value diag (octave_idx_type m, octave_idx_type n) const; - void increment (void) { scalar += 1.0; } + void increment () { scalar += 1.0; } - void decrement (void) { scalar -= 1.0; } + void decrement () { scalar -= 1.0; } bool save_ascii (std::ostream& os); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-flt-cx-diag.cc --- a/libinterp/octave-value/ov-flt-cx-diag.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-flt-cx-diag.cc Tue Jan 24 17:19:44 2023 -0800 @@ -52,14 +52,14 @@ } octave_base_value::type_conv_info -octave_float_complex_diag_matrix::numeric_conversion_function (void) const +octave_float_complex_diag_matrix::numeric_conversion_function () const { return octave_base_value::type_conv_info (default_numeric_conversion_function, octave_float_complex_matrix::static_type_id ()); } octave_base_value * -octave_float_complex_diag_matrix::try_narrowing_conversion (void) +octave_float_complex_diag_matrix::try_narrowing_conversion () { octave_base_value *retval = nullptr; @@ -122,13 +122,13 @@ } octave_value -octave_float_complex_diag_matrix::as_double (void) const +octave_float_complex_diag_matrix::as_double () const { return ComplexDiagMatrix (m_matrix); } octave_value -octave_float_complex_diag_matrix::as_single (void) const +octave_float_complex_diag_matrix::as_single () const { return m_matrix; } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-flt-cx-diag.h --- a/libinterp/octave-value/ov-flt-cx-diag.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-flt-cx-diag.h Tue Jan 24 17:19:44 2023 -0800 @@ -42,7 +42,7 @@ { public: - octave_float_complex_diag_matrix (void) + octave_float_complex_diag_matrix () : octave_base_diag () { } octave_float_complex_diag_matrix (const FloatComplexDiagMatrix& m) @@ -51,26 +51,26 @@ octave_float_complex_diag_matrix (const octave_float_complex_diag_matrix& m) : octave_base_diag (m) { } - ~octave_float_complex_diag_matrix (void) = default; + ~octave_float_complex_diag_matrix () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_float_complex_diag_matrix (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_float_complex_diag_matrix (); } - type_conv_info numeric_conversion_function (void) const; + type_conv_info numeric_conversion_function () const; - octave_base_value * try_narrowing_conversion (void); + octave_base_value * try_narrowing_conversion (); - builtin_type_t builtin_type (void) const { return btyp_float_complex; } + builtin_type_t builtin_type () const { return btyp_float_complex; } - bool is_complex_matrix (void) const { return true; } + bool is_complex_matrix () const { return true; } - bool iscomplex (void) const { return true; } + bool iscomplex () const { return true; } - bool is_single_type (void) const { return true; } + bool is_single_type () const { return true; } - bool isfloat (void) const { return true; } + bool isfloat () const { return true; } DiagMatrix diag_matrix_value (bool = false) const; @@ -80,8 +80,8 @@ FloatComplexDiagMatrix float_complex_diag_matrix_value (bool = false) const; - octave_value as_double (void) const; - octave_value as_single (void) const; + octave_value as_double () const; + octave_value as_single () const; bool save_binary (std::ostream& os, bool save_as_floats); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-flt-cx-mat.cc --- a/libinterp/octave-value/ov-flt-cx-mat.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-flt-cx-mat.cc Tue Jan 24 17:19:44 2023 -0800 @@ -75,7 +75,7 @@ "float complex matrix", "single"); octave_base_value * -octave_float_complex_matrix::try_narrowing_conversion (void) +octave_float_complex_matrix::try_narrowing_conversion () { octave_base_value *retval = nullptr; @@ -255,13 +255,13 @@ } octave_value -octave_float_complex_matrix::as_double (void) const +octave_float_complex_matrix::as_double () const { return ComplexNDArray (m_matrix); } octave_value -octave_float_complex_matrix::as_single (void) const +octave_float_complex_matrix::as_single () const { return m_matrix; } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-flt-cx-mat.h --- a/libinterp/octave-value/ov-flt-cx-mat.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-flt-cx-mat.h Tue Jan 24 17:19:44 2023 -0800 @@ -54,7 +54,7 @@ { public: - octave_float_complex_matrix (void) + octave_float_complex_matrix () : octave_base_matrix () { } octave_float_complex_matrix (const FloatComplexNDArray& m) @@ -81,24 +81,24 @@ octave_float_complex_matrix (const octave_float_complex_matrix& cm) : octave_base_matrix (cm) { } - ~octave_float_complex_matrix (void) = default; + ~octave_float_complex_matrix () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_float_complex_matrix (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_float_complex_matrix (); } - octave_base_value * try_narrowing_conversion (void); + octave_base_value * try_narrowing_conversion (); - builtin_type_t builtin_type (void) const { return btyp_float_complex; } + builtin_type_t builtin_type () const { return btyp_float_complex; } - bool is_complex_matrix (void) const { return true; } + bool is_complex_matrix () const { return true; } - bool iscomplex (void) const { return true; } + bool iscomplex () const { return true; } - bool is_single_type (void) const { return true; } + bool is_single_type () const { return true; } - bool isfloat (void) const { return true; } + bool isfloat () const { return true; } double double_value (bool = false) const; @@ -134,18 +134,18 @@ SparseComplexMatrix sparse_complex_matrix_value (bool = false) const; - octave_value as_double (void) const; - octave_value as_single (void) const; + octave_value as_double () const; + octave_value as_single () const; octave_value diag (octave_idx_type k = 0) const; octave_value diag (octave_idx_type m, octave_idx_type n) const; - void increment (void) { m_matrix += FloatComplex (1.0); } + void increment () { m_matrix += FloatComplex (1.0); } - void decrement (void) { m_matrix -= FloatComplex (1.0); } + void decrement () { m_matrix -= FloatComplex (1.0); } - void changesign (void) { m_matrix.changesign (); } + void changesign () { m_matrix.changesign (); } bool save_ascii (std::ostream& os); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-flt-re-diag.cc --- a/libinterp/octave-value/ov-flt-re-diag.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-flt-re-diag.cc Tue Jan 24 17:19:44 2023 -0800 @@ -51,14 +51,14 @@ } octave_base_value::type_conv_info -octave_float_diag_matrix::numeric_conversion_function (void) const +octave_float_diag_matrix::numeric_conversion_function () const { return octave_base_value::type_conv_info (default_numeric_conversion_function, octave_float_matrix::static_type_id ()); } octave_base_value * -octave_float_diag_matrix::try_narrowing_conversion (void) +octave_float_diag_matrix::try_narrowing_conversion () { octave_base_value *retval = nullptr; @@ -93,61 +93,61 @@ } octave_value -octave_float_diag_matrix::as_double (void) const +octave_float_diag_matrix::as_double () const { return DiagMatrix (m_matrix); } octave_value -octave_float_diag_matrix::as_single (void) const +octave_float_diag_matrix::as_single () const { return m_matrix; } octave_value -octave_float_diag_matrix::as_int8 (void) const +octave_float_diag_matrix::as_int8 () const { return int8_array_value (); } octave_value -octave_float_diag_matrix::as_int16 (void) const +octave_float_diag_matrix::as_int16 () const { return int16_array_value (); } octave_value -octave_float_diag_matrix::as_int32 (void) const +octave_float_diag_matrix::as_int32 () const { return int32_array_value (); } octave_value -octave_float_diag_matrix::as_int64 (void) const +octave_float_diag_matrix::as_int64 () const { return int64_array_value (); } octave_value -octave_float_diag_matrix::as_uint8 (void) const +octave_float_diag_matrix::as_uint8 () const { return uint8_array_value (); } octave_value -octave_float_diag_matrix::as_uint16 (void) const +octave_float_diag_matrix::as_uint16 () const { return uint16_array_value (); } octave_value -octave_float_diag_matrix::as_uint32 (void) const +octave_float_diag_matrix::as_uint32 () const { return uint32_array_value (); } octave_value -octave_float_diag_matrix::as_uint64 (void) const +octave_float_diag_matrix::as_uint64 () const { return uint64_array_value (); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-flt-re-diag.h --- a/libinterp/octave-value/ov-flt-re-diag.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-flt-re-diag.h Tue Jan 24 17:19:44 2023 -0800 @@ -42,7 +42,7 @@ { public: - octave_float_diag_matrix (void) + octave_float_diag_matrix () : octave_base_diag () { } octave_float_diag_matrix (const FloatDiagMatrix& m) @@ -51,26 +51,26 @@ octave_float_diag_matrix (const octave_float_diag_matrix& m) : octave_base_diag (m) { } - ~octave_float_diag_matrix (void) = default; + ~octave_float_diag_matrix () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_float_diag_matrix (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_float_diag_matrix (); } - type_conv_info numeric_conversion_function (void) const; + type_conv_info numeric_conversion_function () const; - octave_base_value * try_narrowing_conversion (void); + octave_base_value * try_narrowing_conversion (); - builtin_type_t builtin_type (void) const { return btyp_float; } + builtin_type_t builtin_type () const { return btyp_float; } - bool is_real_matrix (void) const { return true; } + bool is_real_matrix () const { return true; } - bool isreal (void) const { return true; } + bool isreal () const { return true; } - bool is_single_type (void) const { return true; } + bool is_single_type () const { return true; } - bool isfloat (void) const { return true; } + bool isfloat () const { return true; } DiagMatrix diag_matrix_value (bool = false) const; @@ -80,18 +80,18 @@ FloatComplexDiagMatrix float_complex_diag_matrix_value (bool = false) const; - octave_value as_double (void) const; - octave_value as_single (void) const; + octave_value as_double () const; + octave_value as_single () const; - octave_value as_int8 (void) const; - octave_value as_int16 (void) const; - octave_value as_int32 (void) const; - octave_value as_int64 (void) const; + octave_value as_int8 () const; + octave_value as_int16 () const; + octave_value as_int32 () const; + octave_value as_int64 () const; - octave_value as_uint8 (void) const; - octave_value as_uint16 (void) const; - octave_value as_uint32 (void) const; - octave_value as_uint64 (void) const; + octave_value as_uint8 () const; + octave_value as_uint16 () const; + octave_value as_uint32 () const; + octave_value as_uint64 () const; bool save_binary (std::ostream& os, bool save_as_floats); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-flt-re-mat.cc --- a/libinterp/octave-value/ov-flt-re-mat.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-flt-re-mat.cc Tue Jan 24 17:19:44 2023 -0800 @@ -90,7 +90,7 @@ "single"); octave_base_value * -octave_float_matrix::try_narrowing_conversion (void) +octave_float_matrix::try_narrowing_conversion () { octave_base_value *retval = nullptr; @@ -240,61 +240,61 @@ } octave_value -octave_float_matrix::as_double (void) const +octave_float_matrix::as_double () const { return NDArray (m_matrix); } octave_value -octave_float_matrix::as_single (void) const +octave_float_matrix::as_single () const { return FloatNDArray (m_matrix); } octave_value -octave_float_matrix::as_int8 (void) const +octave_float_matrix::as_int8 () const { return int8NDArray (m_matrix); } octave_value -octave_float_matrix::as_int16 (void) const +octave_float_matrix::as_int16 () const { return int16NDArray (m_matrix); } octave_value -octave_float_matrix::as_int32 (void) const +octave_float_matrix::as_int32 () const { return int32NDArray (m_matrix); } octave_value -octave_float_matrix::as_int64 (void) const +octave_float_matrix::as_int64 () const { return int64NDArray (m_matrix); } octave_value -octave_float_matrix::as_uint8 (void) const +octave_float_matrix::as_uint8 () const { return uint8NDArray (m_matrix); } octave_value -octave_float_matrix::as_uint16 (void) const +octave_float_matrix::as_uint16 () const { return uint16NDArray (m_matrix); } octave_value -octave_float_matrix::as_uint32 (void) const +octave_float_matrix::as_uint32 () const { return uint32NDArray (m_matrix); } octave_value -octave_float_matrix::as_uint64 (void) const +octave_float_matrix::as_uint64 () const { return uint64NDArray (m_matrix); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-flt-re-mat.h --- a/libinterp/octave-value/ov-flt-re-mat.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-flt-re-mat.h Tue Jan 24 17:19:44 2023 -0800 @@ -54,7 +54,7 @@ { public: - octave_float_matrix (void) + octave_float_matrix () : octave_base_matrix () { } octave_float_matrix (const FloatMatrix& m) @@ -81,14 +81,14 @@ octave_float_matrix (const octave_float_matrix& m) : octave_base_matrix (m) { } - ~octave_float_matrix (void) = default; + ~octave_float_matrix () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_float_matrix (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_float_matrix (); } - octave_base_value * try_narrowing_conversion (void); + octave_base_value * try_narrowing_conversion (); octave::idx_vector index_vector (bool /* require_integers */ = false) const { @@ -96,39 +96,39 @@ : set_idx_cache (octave::idx_vector (m_matrix)); } - builtin_type_t builtin_type (void) const { return btyp_float; } + builtin_type_t builtin_type () const { return btyp_float; } - bool is_real_matrix (void) const { return true; } + bool is_real_matrix () const { return true; } - bool isreal (void) const { return true; } + bool isreal () const { return true; } - bool is_single_type (void) const { return true; } + bool is_single_type () const { return true; } - bool isfloat (void) const { return true; } + bool isfloat () const { return true; } int8NDArray - int8_array_value (void) const { return int8NDArray (m_matrix); } + int8_array_value () const { return int8NDArray (m_matrix); } int16NDArray - int16_array_value (void) const { return int16NDArray (m_matrix); } + int16_array_value () const { return int16NDArray (m_matrix); } int32NDArray - int32_array_value (void) const { return int32NDArray (m_matrix); } + int32_array_value () const { return int32NDArray (m_matrix); } int64NDArray - int64_array_value (void) const { return int64NDArray (m_matrix); } + int64_array_value () const { return int64NDArray (m_matrix); } uint8NDArray - uint8_array_value (void) const { return uint8NDArray (m_matrix); } + uint8_array_value () const { return uint8NDArray (m_matrix); } uint16NDArray - uint16_array_value (void) const { return uint16NDArray (m_matrix); } + uint16_array_value () const { return uint16NDArray (m_matrix); } uint32NDArray - uint32_array_value (void) const { return uint32NDArray (m_matrix); } + uint32_array_value () const { return uint32NDArray (m_matrix); } uint64NDArray - uint64_array_value (void) const { return uint64NDArray (m_matrix); } + uint64_array_value () const { return uint64NDArray (m_matrix); } double double_value (bool = false) const; @@ -168,29 +168,29 @@ SparseComplexMatrix sparse_complex_matrix_value (bool = false) const; - octave_value as_double (void) const; - octave_value as_single (void) const; + octave_value as_double () const; + octave_value as_single () const; - octave_value as_int8 (void) const; - octave_value as_int16 (void) const; - octave_value as_int32 (void) const; - octave_value as_int64 (void) const; + octave_value as_int8 () const; + octave_value as_int16 () const; + octave_value as_int32 () const; + octave_value as_int64 () const; - octave_value as_uint8 (void) const; - octave_value as_uint16 (void) const; - octave_value as_uint32 (void) const; - octave_value as_uint64 (void) const; + octave_value as_uint8 () const; + octave_value as_uint16 () const; + octave_value as_uint32 () const; + octave_value as_uint64 () const; octave_value diag (octave_idx_type k = 0) const; octave_value diag (octave_idx_type m, octave_idx_type n) const; // Use matrix_ref here to clear index cache. - void increment (void) { matrix_ref () += 1.0; } + void increment () { matrix_ref () += 1.0; } - void decrement (void) { matrix_ref () -= 1.0; } + void decrement () { matrix_ref () -= 1.0; } - void changesign (void) { matrix_ref ().changesign (); } + void changesign () { matrix_ref ().changesign (); } octave_value convert_to_str_internal (bool pad, bool force, char type) const; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-intx.h --- a/libinterp/octave-value/ov-intx.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-intx.h Tue Jan 24 17:19:44 2023 -0800 @@ -56,7 +56,7 @@ { public: - OCTAVE_VALUE_INT_MATRIX_T (void) + OCTAVE_VALUE_INT_MATRIX_T () : octave_base_int_matrix> () { } OCTAVE_VALUE_INT_MATRIX_T (const intNDArray& nda) @@ -66,45 +66,45 @@ : octave_base_int_matrix> (intNDArray (nda)) { } - ~OCTAVE_VALUE_INT_MATRIX_T (void) = default; + ~OCTAVE_VALUE_INT_MATRIX_T () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new OCTAVE_VALUE_INT_MATRIX_T (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new OCTAVE_VALUE_INT_MATRIX_T (); } - bool OCTAVE_TYPE_PREDICATE_FUNCTION (void) const { return true; } + bool OCTAVE_TYPE_PREDICATE_FUNCTION () const { return true; } - bool isinteger (void) const { return true; } + bool isinteger () const { return true; } - builtin_type_t builtin_type (void) const { return OCTAVE_INT_BTYP; } + builtin_type_t builtin_type () const { return OCTAVE_INT_BTYP; } public: int8NDArray - int8_array_value (void) const { return int8NDArray (m_matrix); } + int8_array_value () const { return int8NDArray (m_matrix); } int16NDArray - int16_array_value (void) const { return int16NDArray (m_matrix); } + int16_array_value () const { return int16NDArray (m_matrix); } int32NDArray - int32_array_value (void) const { return int32NDArray (m_matrix); } + int32_array_value () const { return int32NDArray (m_matrix); } int64NDArray - int64_array_value (void) const { return int64NDArray (m_matrix); } + int64_array_value () const { return int64NDArray (m_matrix); } uint8NDArray - uint8_array_value (void) const { return uint8NDArray (m_matrix); } + uint8_array_value () const { return uint8NDArray (m_matrix); } uint16NDArray - uint16_array_value (void) const { return uint16NDArray (m_matrix); } + uint16_array_value () const { return uint16NDArray (m_matrix); } uint32NDArray - uint32_array_value (void) const { return uint32NDArray (m_matrix); } + uint32_array_value () const { return uint32NDArray (m_matrix); } uint64NDArray - uint64_array_value (void) const { return uint64NDArray (m_matrix); } + uint64_array_value () const { return uint64NDArray (m_matrix); } double double_value (bool = false) const @@ -286,17 +286,17 @@ } // Use matrix_ref here to clear index cache. - void increment (void) + void increment () { matrix_ref () += OCTAVE_INT_T (1); } - void decrement (void) + void decrement () { matrix_ref () -= OCTAVE_INT_T (1); } - void changesign (void) + void changesign () { matrix_ref ().changesign (); } @@ -393,18 +393,18 @@ { public: - OCTAVE_VALUE_INT_SCALAR_T (void) + OCTAVE_VALUE_INT_SCALAR_T () : octave_base_int_scalar () { } OCTAVE_VALUE_INT_SCALAR_T (const OCTAVE_INT_T& nda) : octave_base_int_scalar (nda) { } - ~OCTAVE_VALUE_INT_SCALAR_T (void) = default; + ~OCTAVE_VALUE_INT_SCALAR_T () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new OCTAVE_VALUE_INT_SCALAR_T (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new OCTAVE_VALUE_INT_MATRIX_T (); } octave_value do_index_op (const octave_value_list& idx, @@ -427,68 +427,68 @@ return tmp.index_op (idx, resize_ok); } - bool OCTAVE_TYPE_PREDICATE_FUNCTION (void) const { return true; } + bool OCTAVE_TYPE_PREDICATE_FUNCTION () const { return true; } - bool isinteger (void) const { return true; } + bool isinteger () const { return true; } - builtin_type_t builtin_type (void) const { return OCTAVE_INT_BTYP; } + builtin_type_t builtin_type () const { return OCTAVE_INT_BTYP; } public: octave_int8 - int8_scalar_value (void) const { return octave_int8 (scalar); } + int8_scalar_value () const { return octave_int8 (scalar); } octave_int16 - int16_scalar_value (void) const { return octave_int16 (scalar); } + int16_scalar_value () const { return octave_int16 (scalar); } octave_int32 - int32_scalar_value (void) const { return octave_int32 (scalar); } + int32_scalar_value () const { return octave_int32 (scalar); } octave_int64 - int64_scalar_value (void) const { return octave_int64 (scalar); } + int64_scalar_value () const { return octave_int64 (scalar); } octave_uint8 - uint8_scalar_value (void) const { return octave_uint8 (scalar); } + uint8_scalar_value () const { return octave_uint8 (scalar); } octave_uint16 - uint16_scalar_value (void) const { return octave_uint16 (scalar); } + uint16_scalar_value () const { return octave_uint16 (scalar); } octave_uint32 - uint32_scalar_value (void) const { return octave_uint32 (scalar); } + uint32_scalar_value () const { return octave_uint32 (scalar); } octave_uint64 - uint64_scalar_value (void) const { return octave_uint64 (scalar); } + uint64_scalar_value () const { return octave_uint64 (scalar); } int8NDArray - int8_array_value (void) const + int8_array_value () const { return int8NDArray (dim_vector (1, 1), int8_scalar_value ()); } int16NDArray - int16_array_value (void) const + int16_array_value () const { return int16NDArray (dim_vector (1, 1), int16_scalar_value ()); } int32NDArray - int32_array_value (void) const + int32_array_value () const { return int32NDArray (dim_vector (1, 1), int32_scalar_value ()); } int64NDArray - int64_array_value (void) const + int64_array_value () const { return int64NDArray (dim_vector (1, 1), int64_scalar_value ()); } uint8NDArray - uint8_array_value (void) const + uint8_array_value () const { return uint8NDArray (dim_vector (1, 1), uint8_scalar_value ()); } uint16NDArray - uint16_array_value (void) const + uint16_array_value () const { return uint16NDArray (dim_vector (1, 1), uint16_scalar_value ()); } uint32NDArray - uint32_array_value (void) const + uint32_array_value () const { return uint32NDArray (dim_vector (1, 1), uint32_scalar_value ()); } uint64NDArray - uint64_array_value (void) const + uint64_array_value () const { return uint64NDArray (dim_vector (1, 1), uint64_scalar_value ()); } octave_value resize (const dim_vector& dv, bool fill = false) const @@ -611,12 +611,12 @@ return retval; } - void increment (void) + void increment () { scalar += OCTAVE_INT_T (1); } - void decrement (void) + void decrement () { scalar -= OCTAVE_INT_T (1); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-java.cc --- a/libinterp/octave-value/ov-java.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-java.cc Tue Jan 24 17:19:44 2023 -0800 @@ -229,7 +229,7 @@ { public: - JVMArgs (void) + JVMArgs () { m_vm_args.version = JNI_VERSION_1_6; m_vm_args.nOptions = 0; @@ -237,7 +237,7 @@ m_vm_args.ignoreUnrecognized = false; } - ~JVMArgs (void) + ~JVMArgs () { clean (); } @@ -275,7 +275,7 @@ private: - void clean (void) + void clean () { if (m_vm_args.options != nullptr) { @@ -289,7 +289,7 @@ } } - void update (void) + void update () { clean (); @@ -340,7 +340,7 @@ //! the options given by @c java.opts. static std::string -initial_java_dir (void) +initial_java_dir () { static std::string java_dir; @@ -419,7 +419,7 @@ //! @returns The initial classpath. static std::string -initial_class_path (void) +initial_class_path () { std::string java_dir = initial_java_dir (); @@ -667,7 +667,7 @@ //! @see #terminate_jvm() static void -initialize_jvm (void) +initialize_jvm () { // Most of the time JVM already exists and has been initialized. // Also it seems, as if jvm is set, the jvm is already attached. @@ -829,7 +829,7 @@ //! @see #initialize_jvm() static void -terminate_jvm (void) +terminate_jvm () { // There is nothing to do if jvm is not set (= nullptr). if (jvm) @@ -893,7 +893,7 @@ //! @returns A reference to jni, if #jvm is present, otherwise @c nullptr. static inline JNIEnv * -thread_jni_env (void) +thread_jni_env () { JNIEnv *env = nullptr; @@ -906,7 +906,7 @@ #endif bool -octave_java::is_java_string (void) const +octave_java::is_java_string () const { #if defined (HAVE_JAVA) @@ -1978,7 +1978,7 @@ //! @returns 0 in any case for good reason. static int -java_event_hook (void) +java_event_hook () { JNIEnv *current_env = thread_jni_env (); @@ -2005,7 +2005,7 @@ //! @c __java_get__, @c __java_set__, and @c __java2mat__. static void -initialize_java (void) +initialize_java () { if (! jvm) { @@ -2119,7 +2119,7 @@ //! Ctor. -octave_java::octave_java (void) +octave_java::octave_java () : octave_base_value (), m_java_object (nullptr), m_java_class (nullptr) { #if ! defined (HAVE_JAVA) @@ -2166,7 +2166,7 @@ } dim_vector -octave_java::dims (void) const +octave_java::dims () const { #if defined (HAVE_JAVA) @@ -2343,7 +2343,7 @@ } string_vector -octave_java::map_keys (void) const +octave_java::map_keys () const { #if defined (HAVE_JAVA) @@ -3007,7 +3007,7 @@ } void -octave_java::release (void) +octave_java::release () { #if defined (HAVE_JAVA) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-java.h --- a/libinterp/octave-value/ov-java.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-java.h Tue Jan 24 17:19:44 2023 -0800 @@ -43,7 +43,7 @@ { public: - octave_java (void); + octave_java (); octave_java (const voidptr& obj, void *cls = nullptr); @@ -53,29 +53,29 @@ init (jobj.m_java_object, jobj.m_java_class); } - ~octave_java (void) { release (); } + ~octave_java () { release (); } - void * to_java (void) const { return m_java_object; } - void * to_class (void) const { return m_java_class; } + void * to_java () const { return m_java_object; } + void * to_class () const { return m_java_class; } - std::string java_class_name (void) const { return m_java_classname; } + std::string java_class_name () const { return m_java_classname; } - octave_base_value * clone (void) const { return new octave_java (*this); } - octave_base_value * empty_clone (void) const { return new octave_java (); } + octave_base_value * clone () const { return new octave_java (*this); } + octave_base_value * empty_clone () const { return new octave_java (); } bool is_instance_of (const std::string&) const; - bool is_defined (void) const { return true; } + bool is_defined () const { return true; } - bool is_constant (void) const { return true; } + bool is_constant () const { return true; } - bool isstruct (void) const { return false; } + bool isstruct () const { return false; } - bool isjava (void) const { return true; } + bool isjava () const { return true; } - string_vector map_keys (void) const; + string_vector map_keys () const; - dim_vector dims (void) const; + dim_vector dims () const; void print (std::ostream& os, bool pr_as_read_syntax = false); @@ -117,7 +117,7 @@ octave_value convert_to_str_internal (bool pad, bool force, char type) const; - bool is_java_string (void) const; + bool is_java_string () const; octave_value do_javaMethod (void *jni_env, const std::string& name, const octave_value_list& args); @@ -168,7 +168,7 @@ void init (void *jobj, void *jcls); - void release (void); + void release (); private: @@ -180,13 +180,13 @@ public: - int type_id (void) const { return t_id; } - std::string type_name (void) const { return t_name; } - std::string class_name (void) const { return m_java_classname; } + int type_id () const { return t_id; } + std::string type_name () const { return t_name; } + std::string class_name () const { return m_java_classname; } - static int static_type_id (void) { return t_id; } - static std::string static_type_name (void) { return t_name; } - static std::string static_class_name (void) { return ""; } + static int static_type_id () { return t_id; } + static std::string static_type_name () { return t_name; } + static std::string static_class_name () { return ""; } static void register_type (octave::type_info&); private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-lazy-idx.cc --- a/libinterp/octave-value/ov-lazy-idx.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-lazy-idx.cc Tue Jan 24 17:19:44 2023 -0800 @@ -44,14 +44,14 @@ } octave_base_value::type_conv_info -octave_lazy_index::numeric_conversion_function (void) const +octave_lazy_index::numeric_conversion_function () const { return octave_base_value::type_conv_info (default_numeric_conversion_function, octave_matrix::static_type_id ()); } octave_base_value * -octave_lazy_index::try_narrowing_conversion (void) +octave_lazy_index::try_narrowing_conversion () { octave_base_value *retval = nullptr; @@ -97,7 +97,7 @@ } octave_value -octave_lazy_index::squeeze (void) const +octave_lazy_index::squeeze () const { return octave::idx_vector (m_index.as_array ().squeeze (), m_index.extent (0)); @@ -161,61 +161,61 @@ } octave_value -octave_lazy_index::as_double (void) const +octave_lazy_index::as_double () const { return array_value (); } octave_value -octave_lazy_index::as_single (void) const +octave_lazy_index::as_single () const { return float_array_value (); } octave_value -octave_lazy_index::as_int8 (void) const +octave_lazy_index::as_int8 () const { return int8_array_value (); } octave_value -octave_lazy_index::as_int16 (void) const +octave_lazy_index::as_int16 () const { return int16_array_value (); } octave_value -octave_lazy_index::as_int32 (void) const +octave_lazy_index::as_int32 () const { return int32_array_value (); } octave_value -octave_lazy_index::as_int64 (void) const +octave_lazy_index::as_int64 () const { return int64_array_value (); } octave_value -octave_lazy_index::as_uint8 (void) const +octave_lazy_index::as_uint8 () const { return uint8_array_value (); } octave_value -octave_lazy_index::as_uint16 (void) const +octave_lazy_index::as_uint16 () const { return uint16_array_value (); } octave_value -octave_lazy_index::as_uint32 (void) const +octave_lazy_index::as_uint32 () const { return uint32_array_value (); } octave_value -octave_lazy_index::as_uint64 (void) const +octave_lazy_index::as_uint64 () const { return uint64_array_value (); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-lazy-idx.h --- a/libinterp/octave-value/ov-lazy-idx.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-lazy-idx.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,7 +39,7 @@ { public: - octave_lazy_index (void) + octave_lazy_index () : octave_base_value (), m_index (), m_value () { } octave_lazy_index (const octave::idx_vector& idx) @@ -48,37 +48,37 @@ octave_lazy_index (const octave_lazy_index& i) : octave_base_value (), m_index (i.m_index), m_value (i.m_value) { } - ~octave_lazy_index (void) = default; + ~octave_lazy_index () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_lazy_index (*this); } - octave_base_value * empty_clone (void) const { return new octave_matrix (); } + octave_base_value * empty_clone () const { return new octave_matrix (); } - type_conv_info numeric_conversion_function (void) const; + type_conv_info numeric_conversion_function () const; - octave_base_value * try_narrowing_conversion (void); + octave_base_value * try_narrowing_conversion (); octave_value fast_elem_extract (octave_idx_type n) const; - std::size_t byte_size (void) const + std::size_t byte_size () const { return numel () * sizeof (octave_idx_type); } - octave_value squeeze (void) const; + octave_value squeeze () const; - octave_value full_value (void) const { return make_value (); } + octave_value full_value () const { return make_value (); } octave::idx_vector index_vector (bool /* require_integers */ = false) const { return m_index; } - builtin_type_t builtin_type (void) const { return btyp_double; } + builtin_type_t builtin_type () const { return btyp_double; } - bool is_real_matrix (void) const { return true; } + bool is_real_matrix () const { return true; } - bool isreal (void) const { return true; } + bool isreal () const { return true; } - bool is_double_type (void) const { return true; } + bool is_double_type () const { return true; } - bool isfloat (void) const { return true; } + bool isfloat () const { return true; } // We don't need to override all three forms of subsref. The using // declaration will avoid warnings about partially-overloaded virtual @@ -97,11 +97,11 @@ bool resize_ok = false) { return make_value ().index_op (idx, resize_ok); } - dim_vector dims (void) const { return m_index.orig_dimensions (); } + dim_vector dims () const { return m_index.orig_dimensions (); } - octave_idx_type numel (void) const { return m_index.length (0); } + octave_idx_type numel () const { return m_index.length (0); } - octave_idx_type nnz (void) const { return numel (); } + octave_idx_type nnz () const { return numel (); } octave_value reshape (const dim_vector& new_dims) const; @@ -113,7 +113,7 @@ octave_value all (int dim = 0) const { return make_value ().all (dim); } octave_value any (int dim = 0) const { return make_value ().any (dim); } - MatrixType matrix_type (void) const { return make_value ().matrix_type (); } + MatrixType matrix_type () const { return make_value ().matrix_type (); } MatrixType matrix_type (const MatrixType& _typ) const { return make_value ().matrix_type (_typ); } @@ -128,18 +128,18 @@ sortmode is_sorted_rows (sortmode mode = UNSORTED) const; - bool is_matrix_type (void) const { return true; } + bool is_matrix_type () const { return true; } - bool isnumeric (void) const { return true; } + bool isnumeric () const { return true; } - bool is_defined (void) const { return true; } + bool is_defined () const { return true; } - bool is_constant (void) const { return true; } + bool is_constant () const { return true; } - bool is_true (void) const + bool is_true () const { return make_value ().is_true (); } - bool print_as_scalar (void) const + bool print_as_scalar () const { return make_value ().print_as_scalar (); } void print (std::ostream& os, bool pr_as_read_syntax = false) @@ -149,7 +149,7 @@ { make_value ().print_info (os, prefix); } #define FORWARD_VALUE_QUERY(TYPE, NAME) \ - TYPE NAME (void) const \ + TYPE NAME () const \ { \ return make_value ().NAME (); \ } @@ -202,18 +202,18 @@ return make_value ().convert_to_str_internal (pad, force, type); } - octave_value as_double (void) const; - octave_value as_single (void) const; + octave_value as_double () const; + octave_value as_single () const; - octave_value as_int8 (void) const; - octave_value as_int16 (void) const; - octave_value as_int32 (void) const; - octave_value as_int64 (void) const; + octave_value as_int8 () const; + octave_value as_int16 () const; + octave_value as_int32 () const; + octave_value as_int64 () const; - octave_value as_uint8 (void) const; - octave_value as_uint16 (void) const; - octave_value as_uint32 (void) const; - octave_value as_uint64 (void) const; + octave_value as_uint8 () const; + octave_value as_uint16 () const; + octave_value as_uint32 () const; + octave_value as_uint64 () const; void print_raw (std::ostream& os, bool pr_as_read_syntax = false) const { @@ -238,7 +238,7 @@ // This function exists to support the MEX interface. // You should not use it anywhere else. - const void * mex_get_data (void) const + const void * mex_get_data () const { return make_value ().mex_get_data (); } @@ -255,7 +255,7 @@ private: - const octave_value& make_value (void) const + const octave_value& make_value () const { if (m_value.is_undefined ()) m_value = octave_value (m_index, false); @@ -263,7 +263,7 @@ return m_value; } - octave_value& make_value (void) + octave_value& make_value () { if (m_value.is_undefined ()) m_value = octave_value (m_index, false); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-legacy-range.cc --- a/libinterp/octave-value/ov-legacy-range.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-legacy-range.cc Tue Jan 24 17:19:44 2023 -0800 @@ -55,7 +55,7 @@ { public: - Range (void) + Range () : m_base (0), m_limit (0), m_inc (0), m_numel (0) { } @@ -73,7 +73,7 @@ Range& operator = (const Range& r) = default; - ~Range (void) = default; + ~Range () = default; Range (double b, double l) : m_base (b), m_limit (l), m_inc (1), m_numel (numel_internal ()) @@ -90,24 +90,24 @@ } // The range has a finite number of elements. - bool ok (void) const + bool ok () const { return (octave::math::isfinite (m_limit) && (m_numel >= 0 || m_numel == -2)); } - double base (void) const { return m_base; } - double limit (void) const { return m_limit; } - double increment (void) const { return m_inc; } + double base () const { return m_base; } + double limit () const { return m_limit; } + double increment () const { return m_inc; } - octave_idx_type numel (void) const { return m_numel; } + octave_idx_type numel () const { return m_numel; } - bool all_elements_are_ints (void) const; + bool all_elements_are_ints () const; - Matrix matrix_value (void) const; + Matrix matrix_value () const; - double min (void) const; - double max (void) const; + double min () const; + double max () const; private: @@ -117,15 +117,15 @@ octave_idx_type m_numel; - octave_idx_type numel_internal (void) const; + octave_idx_type numel_internal () const; - double limit_internal (void) const; + double limit_internal () const; - void init (void); + void init (); }; bool -Range::all_elements_are_ints (void) const +Range::all_elements_are_ints () const { // If the base and increment are ints, the final value in the range will also // be an integer, even if the limit is not. If there is one or fewer @@ -137,7 +137,7 @@ } Matrix -Range::matrix_value (void) const +Range::matrix_value () const { Matrix retval (1, m_numel); @@ -162,7 +162,7 @@ // do_minmax_body() in max.cc avoids calling Range::min/max if numel == 0. double -Range::min (void) const +Range::min () const { double retval = 0.0; if (m_numel > 0) @@ -183,7 +183,7 @@ } double -Range::max (void) const +Range::max () const { double retval = 0.0; if (m_numel > 0) @@ -281,7 +281,7 @@ } octave_idx_type -Range::numel_internal (void) const +Range::numel_internal () const { octave_idx_type retval = -1; @@ -332,7 +332,7 @@ } double -Range::limit_internal (void) const +Range::limit_internal () const { double new_limit = m_inc > 0 ? max () : min (); @@ -344,7 +344,7 @@ } void -Range::init (void) +Range::init () { m_numel = numel_internal (); @@ -354,7 +354,7 @@ DEFINE_OV_TYPEID_FUNCTIONS_AND_DATA (octave_legacy_range, "range", "double"); -octave_legacy_range::octave_legacy_range (void) +octave_legacy_range::octave_legacy_range () : octave_base_value (), m_range (new Range ()) { } octave_legacy_range::octave_legacy_range (const Range& r) @@ -379,14 +379,14 @@ } octave_base_value::type_conv_info -octave_legacy_range::numeric_conversion_function (void) const +octave_legacy_range::numeric_conversion_function () const { return octave_base_value::type_conv_info (default_numeric_conversion_function, octave_matrix::static_type_id ()); } octave_base_value * -octave_legacy_range::try_narrowing_conversion (void) +octave_legacy_range::try_narrowing_conversion () { octave_base_value *retval = nullptr; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-legacy-range.h --- a/libinterp/octave-value/ov-legacy-range.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-legacy-range.h Tue Jan 24 17:19:44 2023 -0800 @@ -62,7 +62,7 @@ { public: - octave_legacy_range (void); + octave_legacy_range (); octave_legacy_range (const Range& r); @@ -72,9 +72,9 @@ octave_legacy_range& operator = (const octave_legacy_range&) = delete; - ~octave_legacy_range (void) = default; + ~octave_legacy_range () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_legacy_range (*this); } @@ -82,17 +82,17 @@ // A range is really just a special kind of real matrix object. In // the places where we need to call empty_clone, it makes more sense // to create an empty matrix (0x0) instead of an empty range (1x0). - octave_base_value * empty_clone (void) const { return new octave_matrix (); } + octave_base_value * empty_clone () const { return new octave_matrix (); } - type_conv_info numeric_conversion_function (void) const; + type_conv_info numeric_conversion_function () const; - octave_base_value * try_narrowing_conversion (void); + octave_base_value * try_narrowing_conversion (); - bool is_defined (void) const { return true; } + bool is_defined () const { return true; } - bool is_legacy_object (void) const { return true; } + bool is_legacy_object () const { return true; } - bool is_constant (void) const { return true; } + bool is_constant () const { return true; } bool load_ascii (std::istream& is); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-magic-int.cc --- a/libinterp/octave-value/ov-magic-int.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-magic-int.cc Tue Jan 24 17:19:44 2023 -0800 @@ -104,70 +104,70 @@ template octave_value -octave_base_magic_int::as_double (void) const +octave_base_magic_int::as_double () const { return static_cast (scalar_ref ()); } template octave_value -octave_base_magic_int::as_single (void) const +octave_base_magic_int::as_single () const { return static_cast (scalar_ref ()); } template octave_value -octave_base_magic_int::as_int8 (void) const +octave_base_magic_int::as_int8 () const { return octave_int8 (scalar_ref ()); } template octave_value -octave_base_magic_int::as_int16 (void) const +octave_base_magic_int::as_int16 () const { return octave_int16 (scalar_ref ()); } template octave_value -octave_base_magic_int::as_int32 (void) const +octave_base_magic_int::as_int32 () const { return octave_int32 (scalar_ref ()); } template octave_value -octave_base_magic_int::as_int64 (void) const +octave_base_magic_int::as_int64 () const { return octave_int64 (scalar_ref ()); } template octave_value -octave_base_magic_int::as_uint8 (void) const +octave_base_magic_int::as_uint8 () const { return octave_uint8 (scalar_ref ()); } template octave_value -octave_base_magic_int::as_uint16 (void) const +octave_base_magic_int::as_uint16 () const { return octave_uint16 (scalar_ref ()); } template octave_value -octave_base_magic_int::as_uint32 (void) const +octave_base_magic_int::as_uint32 () const { return octave_uint32 (scalar_ref ()); } template octave_value -octave_base_magic_int::as_uint64 (void) const +octave_base_magic_int::as_uint64 () const { return octave_uint64 (scalar_ref ()); } @@ -306,7 +306,7 @@ "double"); octave_base_value::type_conv_info -octave_magic_uint::numeric_conversion_function (void) const +octave_magic_uint::numeric_conversion_function () const { return octave_base_value::type_conv_info (default_numeric_conv_fcn, octave_scalar::static_type_id ()); @@ -316,7 +316,7 @@ "double"); octave_base_value::type_conv_info -octave_magic_int::numeric_conversion_function (void) const +octave_magic_int::numeric_conversion_function () const { return octave_base_value::type_conv_info (default_numeric_conv_fcn, octave_scalar::static_type_id ()); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-magic-int.h --- a/libinterp/octave-value/ov-magic-int.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-magic-int.h Tue Jan 24 17:19:44 2023 -0800 @@ -52,26 +52,26 @@ { public: - octave_base_magic_int (void) + octave_base_magic_int () : octave_base_scalar (0) { } octave_base_magic_int (const T& val) : octave_base_scalar (val) { } - ~octave_base_magic_int (void) = default; + ~octave_base_magic_int () = default; // We return an octave_matrix here instead of an octave_scalar so // that in expressions like A(2,2,2) = 2 (for A previously // undefined), A will be empty instead of a 1x1 object. - octave_base_value * empty_clone (void) const { return new octave_matrix (); } + octave_base_value * empty_clone () const { return new octave_matrix (); } // Although SCALAR is a protected member of the base class, it is not // directly visible here without the explicit octave_base_slalar:: // qualification. Why not? - const T& scalar_ref (void) const { return octave_base_scalar::scalar; } + const T& scalar_ref () const { return octave_base_scalar::scalar; } - T& scalar_ref (void) { return octave_base_scalar::scalar; } + T& scalar_ref () { return octave_base_scalar::scalar; } octave_value do_index_op (const octave_value_list& idx, bool resize_ok = false); @@ -80,66 +80,66 @@ octave_value any (int = 0) const { return scalar_ref () != T (0); } - builtin_type_t builtin_type (void) const { return btyp_double; } + builtin_type_t builtin_type () const { return btyp_double; } - bool is_storable (void) const { return false; } + bool is_storable () const { return false; } - bool is_magic_int (void) const { return true; } + bool is_magic_int () const { return true; } - bool is_real_scalar (void) const { return true; } + bool is_real_scalar () const { return true; } - bool isreal (void) const { return true; } + bool isreal () const { return true; } - bool is_double_type (void) const { return true; } + bool is_double_type () const { return true; } - bool isfloat (void) const { return true; } + bool isfloat () const { return true; } - int8NDArray int8_array_value (void) const + int8NDArray int8_array_value () const { return int8NDArray (dim_vector (1, 1), double_value ()); } - int16NDArray int16_array_value (void) const + int16NDArray int16_array_value () const { return int16NDArray (dim_vector (1, 1), double_value ()); } - int32NDArray int32_array_value (void) const + int32NDArray int32_array_value () const { return int32NDArray (dim_vector (1, 1), double_value ()); } - int64NDArray int64_array_value (void) const + int64NDArray int64_array_value () const { return int64NDArray (dim_vector (1, 1), double_value ()); } - uint8NDArray uint8_array_value (void) const + uint8NDArray uint8_array_value () const { return uint8NDArray (dim_vector (1, 1), double_value ()); } - uint16NDArray uint16_array_value (void) const + uint16NDArray uint16_array_value () const { return uint16NDArray (dim_vector (1, 1), double_value ()); } - uint32NDArray uint32_array_value (void) const + uint32NDArray uint32_array_value () const { return uint32NDArray (dim_vector (1, 1), double_value ()); } - uint64NDArray uint64_array_value (void) const + uint64NDArray uint64_array_value () const { return uint64NDArray (dim_vector (1, 1), double_value ()); } - octave_int8 int8_scalar_value (void) const + octave_int8 int8_scalar_value () const { return octave_int8 (double_value ()); } - octave_int16 int16_scalar_value (void) const + octave_int16 int16_scalar_value () const { return octave_int16 (double_value ()); } - octave_int32 int32_scalar_value (void) const + octave_int32 int32_scalar_value () const { return octave_int32 (double_value ()); } - octave_int64 int64_scalar_value (void) const + octave_int64 int64_scalar_value () const { return octave_int64 (double_value ()); } - octave_uint8 uint8_scalar_value (void) const + octave_uint8 uint8_scalar_value () const { return octave_uint8 (double_value ()); } - octave_uint16 uint16_scalar_value (void) const + octave_uint16 uint16_scalar_value () const { return octave_uint16 (double_value ()); } - octave_uint32 uint32_scalar_value (void) const + octave_uint32 uint32_scalar_value () const { return octave_uint32 (double_value ()); } - octave_uint64 uint64_scalar_value (void) const + octave_uint64 uint64_scalar_value () const { return octave_uint64 (double_value ()); } double double_value (bool = false) const @@ -221,18 +221,18 @@ return boolNDArray (dim_vector (1, 1), double_value ()); } - octave_value as_double (void) const; - octave_value as_single (void) const; + octave_value as_double () const; + octave_value as_single () const; - octave_value as_int8 (void) const; - octave_value as_int16 (void) const; - octave_value as_int32 (void) const; - octave_value as_int64 (void) const; + octave_value as_int8 () const; + octave_value as_int16 () const; + octave_value as_int32 () const; + octave_value as_int64 () const; - octave_value as_uint8 (void) const; - octave_value as_uint16 (void) const; - octave_value as_uint32 (void) const; - octave_value as_uint64 (void) const; + octave_value as_uint8 () const; + octave_value as_uint16 () const; + octave_value as_uint32 () const; + octave_value as_uint64 () const; // We don't need to override both forms of the diag method. The using // declaration will avoid warnings about partially-overloaded virtual @@ -243,9 +243,9 @@ octave_value convert_to_str_internal (bool pad, bool force, char type) const; - void increment (void) { scalar_ref () += T (1); } + void increment () { scalar_ref () += T (1); } - void decrement (void) { scalar_ref () -= T (1); } + void decrement () { scalar_ref () -= T (1); } bool save_ascii (std::ostream& os); @@ -279,20 +279,20 @@ { public: - octave_magic_uint (void) + octave_magic_uint () : octave_base_magic_int (0) { } octave_magic_uint (const octave_uint64& val) : octave_base_magic_int (val) { } - ~octave_magic_uint (void) = default; + ~octave_magic_uint () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_magic_uint (*this); } - type_conv_info numeric_conversion_function (void) const; + type_conv_info numeric_conversion_function () const; private: @@ -305,20 +305,20 @@ { public: - octave_magic_int (void) + octave_magic_int () : octave_base_magic_int (0) { } octave_magic_int (const octave_int64& val) : octave_base_magic_int (val) { } - ~octave_magic_int (void) = default; + ~octave_magic_int () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_magic_int (*this); } - type_conv_info numeric_conversion_function (void) const; + type_conv_info numeric_conversion_function () const; private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-mex-fcn.cc --- a/libinterp/octave-value/ov-mex-fcn.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-mex-fcn.cc Tue Jan 24 17:19:44 2023 -0800 @@ -68,7 +68,7 @@ && oct_file_dir == file_name.substr (0, oct_file_dir.length ())); } -octave_mex_function::~octave_mex_function (void) +octave_mex_function::~octave_mex_function () { if (m_exit_fcn_ptr) (*m_exit_fcn_ptr) (); @@ -79,13 +79,13 @@ } std::string -octave_mex_function::fcn_file_name (void) const +octave_mex_function::fcn_file_name () const { return m_sh_lib.file_name (); } octave::sys::time -octave_mex_function::time_parsed (void) const +octave_mex_function::time_parsed () const { return m_sh_lib.time_loaded (); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-mex-fcn.h --- a/libinterp/octave-value/ov-mex-fcn.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-mex-fcn.h Tue Jan 24 17:19:44 2023 -0800 @@ -52,7 +52,7 @@ { public: - octave_mex_function (void) + octave_mex_function () : m_mex_fcn_ptr (nullptr), m_exit_fcn_ptr (nullptr), m_sh_lib (), m_time_checked (), m_interleaved (false), m_is_fmex (false), m_is_system_fcn_file (false) @@ -68,7 +68,7 @@ octave_mex_function& operator = (const octave_mex_function& fcn) = delete; - ~octave_mex_function (void); + ~octave_mex_function (); octave_function * function_value (bool = false) { return this; } @@ -79,37 +79,37 @@ m_time_checked = t; } - std::string fcn_file_name (void) const; + std::string fcn_file_name () const; - octave::sys::time time_parsed (void) const; + octave::sys::time time_parsed () const; - octave::sys::time time_checked (void) const { return m_time_checked; } + octave::sys::time time_checked () const { return m_time_checked; } - bool is_system_fcn_file (void) const { return m_is_system_fcn_file; } + bool is_system_fcn_file () const { return m_is_system_fcn_file; } - bool is_builtin_function (void) const { return false; } + bool is_builtin_function () const { return false; } - bool is_mex_function (void) const { return true; } + bool is_mex_function () const { return true; } - bool use_interleaved_complex (void) const { return m_interleaved; } + bool use_interleaved_complex () const { return m_interleaved; } octave_value_list execute (octave::tree_evaluator& tw, int nargout = 0, const octave_value_list& args = octave_value_list ()); - void atexit (void (*fcn) (void)) { m_exit_fcn_ptr = fcn; } + void atexit (void (*fcn) ()) { m_exit_fcn_ptr = fcn; } - octave::dynamic_library get_shlib (void) const { return m_sh_lib; } + octave::dynamic_library get_shlib () const { return m_sh_lib; } - void * mex_fcn_ptr (void) const { return m_mex_fcn_ptr; } + void * mex_fcn_ptr () const { return m_mex_fcn_ptr; } - bool is_fmex (void) const { return m_is_fmex; } + bool is_fmex () const { return m_is_fmex; } private: void *m_mex_fcn_ptr; - void (*m_exit_fcn_ptr) (void); + void (*m_exit_fcn_ptr) (); octave::dynamic_library m_sh_lib; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-null-mat.cc --- a/libinterp/octave-value/ov-null-mat.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-null-mat.cc Tue Jan 24 17:19:44 2023 -0800 @@ -46,7 +46,7 @@ } octave_base_value::type_conv_info -octave_null_matrix::numeric_conversion_function (void) const +octave_null_matrix::numeric_conversion_function () const { return octave_base_value::type_conv_info (default_null_matrix_numeric_conversion_function, @@ -67,7 +67,7 @@ } octave_base_value::type_conv_info -octave_null_str::numeric_conversion_function (void) const +octave_null_str::numeric_conversion_function () const { return octave_base_value::type_conv_info (default_null_str_numeric_conversion_function, @@ -89,7 +89,7 @@ } octave_base_value::type_conv_info -octave_null_sq_str::numeric_conversion_function (void) const +octave_null_sq_str::numeric_conversion_function () const { return octave_base_value::type_conv_info (default_null_sq_str_numeric_conversion_function, diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-null-mat.h --- a/libinterp/octave-value/ov-null-mat.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-null-mat.h Tue Jan 24 17:19:44 2023 -0800 @@ -45,15 +45,15 @@ OCTINTERP_API octave_null_matrix : public octave_matrix { - octave_null_matrix (void) : octave_matrix () { } + octave_null_matrix () : octave_matrix () { } public: static const octave_value instance; - bool isnull (void) const { return true; } + bool isnull () const { return true; } - type_conv_info numeric_conversion_function (void) const; + type_conv_info numeric_conversion_function () const; private: @@ -66,17 +66,17 @@ OCTINTERP_API octave_null_str : public octave_char_matrix_str { - octave_null_str (void) : octave_char_matrix_str () { } + octave_null_str () : octave_char_matrix_str () { } public: static const octave_value instance; - bool is_storable (void) const { return false; } + bool is_storable () const { return false; } - bool isnull (void) const { return true; } + bool isnull () const { return true; } - type_conv_info numeric_conversion_function (void) const; + type_conv_info numeric_conversion_function () const; private: @@ -89,17 +89,17 @@ OCTINTERP_API octave_null_sq_str : public octave_char_matrix_sq_str { - octave_null_sq_str (void) : octave_char_matrix_sq_str () { } + octave_null_sq_str () : octave_char_matrix_sq_str () { } public: static const octave_value instance; - bool is_storable (void) const { return false; } + bool is_storable () const { return false; } - bool isnull (void) const { return true; } + bool isnull () const { return true; } - type_conv_info numeric_conversion_function (void) const; + type_conv_info numeric_conversion_function () const; private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-oncleanup.cc --- a/libinterp/octave-value/ov-oncleanup.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-oncleanup.cc Tue Jan 24 17:19:44 2023 -0800 @@ -65,13 +65,13 @@ } } -octave_oncleanup::~octave_oncleanup (void) +octave_oncleanup::~octave_oncleanup () { call_object_destructor (); } octave_scalar_map -octave_oncleanup::scalar_map_value (void) const +octave_oncleanup::scalar_map_value () const { octave_scalar_map retval; retval.setfield ("task", m_fcn); @@ -145,7 +145,7 @@ } void -octave_oncleanup::call_object_destructor (void) +octave_oncleanup::call_object_destructor () { if (m_fcn.is_undefined ()) return; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-oncleanup.h --- a/libinterp/octave-value/ov-oncleanup.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-oncleanup.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,11 +39,11 @@ { public: - octave_oncleanup (void) = default; + octave_oncleanup () = default; octave_oncleanup (const octave_value& m_fcn); - octave_base_value * clone (void) const + octave_base_value * clone () const { if (m_fcn.is_defined ()) error ("onCleanup: internal error: cloning nonempty object"); @@ -51,22 +51,22 @@ return empty_clone (); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_oncleanup (); } - ~octave_oncleanup (void); + ~octave_oncleanup (); - bool is_defined (void) const { return true; } + bool is_defined () const { return true; } - bool isobject (void) const { return true; } // do we want this? + bool isobject () const { return true; } // do we want this? - octave_map map_value (void) const { return scalar_map_value (); } + octave_map map_value () const { return scalar_map_value (); } - octave_scalar_map scalar_map_value (void) const; + octave_scalar_map scalar_map_value () const; - dim_vector dims (void) const + dim_vector dims () const { static dim_vector dv (1, 1); return dv; @@ -89,7 +89,7 @@ void print_raw (std::ostream& os, bool pr_as_read_syntax = false) const; - void call_object_destructor (void); + void call_object_destructor (); private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-perm.cc --- a/libinterp/octave-value/ov-perm.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-perm.cc Tue Jan 24 17:19:44 2023 -0800 @@ -137,7 +137,7 @@ // Return true if this matrix has all true elements (non-zero, not NaN/NA). // A permutation cannot have NaN/NA. bool -octave_perm_matrix::is_true (void) const +octave_perm_matrix::is_true () const { if (dims ().numel () > 1) { @@ -254,67 +254,67 @@ } octave_value -octave_perm_matrix::as_double (void) const +octave_perm_matrix::as_double () const { return m_matrix; } octave_value -octave_perm_matrix::as_single (void) const +octave_perm_matrix::as_single () const { return float_array_value (); } octave_value -octave_perm_matrix::as_int8 (void) const +octave_perm_matrix::as_int8 () const { return int8_array_value (); } octave_value -octave_perm_matrix::as_int16 (void) const +octave_perm_matrix::as_int16 () const { return int16_array_value (); } octave_value -octave_perm_matrix::as_int32 (void) const +octave_perm_matrix::as_int32 () const { return int32_array_value (); } octave_value -octave_perm_matrix::as_int64 (void) const +octave_perm_matrix::as_int64 () const { return int64_array_value (); } octave_value -octave_perm_matrix::as_uint8 (void) const +octave_perm_matrix::as_uint8 () const { return uint8_array_value (); } octave_value -octave_perm_matrix::as_uint16 (void) const +octave_perm_matrix::as_uint16 () const { return uint16_array_value (); } octave_value -octave_perm_matrix::as_uint32 (void) const +octave_perm_matrix::as_uint32 () const { return uint32_array_value (); } octave_value -octave_perm_matrix::as_uint64 (void) const +octave_perm_matrix::as_uint64 () const { return uint64_array_value (); } float_display_format -octave_perm_matrix::get_edit_display_format (void) const +octave_perm_matrix::get_edit_display_format () const { return float_display_format (float_format (1, 0, 0)); } @@ -440,7 +440,7 @@ } bool -octave_perm_matrix::print_as_scalar (void) const +octave_perm_matrix::print_as_scalar () const { dim_vector dv = dims (); @@ -470,7 +470,7 @@ } octave_value -octave_perm_matrix::to_dense (void) const +octave_perm_matrix::to_dense () const { if (! m_dense_cache.is_defined ()) m_dense_cache = Matrix (m_matrix); @@ -490,7 +490,7 @@ } octave_base_value::type_conv_info -octave_perm_matrix::numeric_conversion_function (void) const +octave_perm_matrix::numeric_conversion_function () const { return octave_base_value::type_conv_info (default_numeric_conversion_function, octave_matrix::static_type_id ()); @@ -552,7 +552,7 @@ } octave_base_value * -octave_perm_matrix::try_narrowing_conversion (void) +octave_perm_matrix::try_narrowing_conversion () { octave_base_value *retval = nullptr; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-perm.h --- a/libinterp/octave-value/ov-perm.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-perm.h Tue Jan 24 17:19:44 2023 -0800 @@ -40,24 +40,24 @@ octave_perm_matrix : public octave_base_value { public: - octave_perm_matrix (void) : m_matrix (), m_dense_cache () { } + octave_perm_matrix () : m_matrix (), m_dense_cache () { } octave_perm_matrix (const PermMatrix& p) : m_matrix (p), m_dense_cache () { } - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_perm_matrix (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_perm_matrix (); } - type_conv_info numeric_conversion_function (void) const; + type_conv_info numeric_conversion_function () const; - octave_base_value * try_narrowing_conversion (void); + octave_base_value * try_narrowing_conversion (); - std::size_t byte_size (void) const { return m_matrix.byte_size (); } + std::size_t byte_size () const { return m_matrix.byte_size (); } - octave_value squeeze (void) const { return m_matrix; } + octave_value squeeze () const { return m_matrix; } - octave_value full_value (void) const { return to_dense (); } + octave_value full_value () const { return to_dense (); } // We don't need to override all three forms of subsref. The using // declaration will avoid warnings about partially-overloaded virtual @@ -74,9 +74,9 @@ octave_value do_index_op (const octave_value_list& idx, bool resize_ok = false); - dim_vector dims (void) const { return m_matrix.dims (); } + dim_vector dims () const { return m_matrix.dims (); } - octave_idx_type nnz (void) const { return m_matrix.rows (); } + octave_idx_type nnz () const { return m_matrix.rows (); } octave_value reshape (const dim_vector& new_dims) const { return to_dense ().reshape (new_dims); } @@ -90,7 +90,7 @@ octave_value all (int dim = 0) const { return to_dense ().all (dim); } octave_value any (int dim = 0) const { return to_dense ().any (dim); } - MatrixType matrix_type (void) const { return MatrixType::Permuted_Diagonal; } + MatrixType matrix_type () const { return MatrixType::Permuted_Diagonal; } MatrixType matrix_type (const MatrixType&) const { return matrix_type (); } @@ -117,27 +117,27 @@ sortmode is_sorted_rows (sortmode mode = UNSORTED) const { return to_dense ().is_sorted_rows (mode); } - builtin_type_t builtin_type (void) const { return btyp_double; } + builtin_type_t builtin_type () const { return btyp_double; } - bool is_perm_matrix (void) const { return true; } + bool is_perm_matrix () const { return true; } - bool is_matrix_type (void) const { return true; } + bool is_matrix_type () const { return true; } - bool isnumeric (void) const { return true; } + bool isnumeric () const { return true; } - bool is_defined (void) const { return true; } + bool is_defined () const { return true; } - bool is_constant (void) const { return true; } + bool is_constant () const { return true; } - bool is_real_matrix (void) const { return true; } + bool is_real_matrix () const { return true; } - bool isreal (void) const { return true; } + bool isreal () const { return true; } - bool is_double_type (void) const { return true; } + bool is_double_type () const { return true; } - bool isfloat (void) const { return true; } + bool isfloat () const { return true; } - bool is_true (void) const; + bool is_true () const; double double_value (bool = false) const; @@ -148,7 +148,7 @@ octave::idx_vector index_vector (bool require_integers = false) const; - PermMatrix perm_matrix_value (void) const + PermMatrix perm_matrix_value () const { return m_matrix; } Matrix matrix_value (bool = false) const; @@ -182,47 +182,47 @@ SparseComplexMatrix sparse_complex_matrix_value (bool = false) const; int8NDArray - int8_array_value (void) const { return to_dense ().int8_array_value (); } + int8_array_value () const { return to_dense ().int8_array_value (); } int16NDArray - int16_array_value (void) const { return to_dense ().int16_array_value (); } + int16_array_value () const { return to_dense ().int16_array_value (); } int32NDArray - int32_array_value (void) const { return to_dense ().int32_array_value (); } + int32_array_value () const { return to_dense ().int32_array_value (); } int64NDArray - int64_array_value (void) const { return to_dense ().int64_array_value (); } + int64_array_value () const { return to_dense ().int64_array_value (); } uint8NDArray - uint8_array_value (void) const { return to_dense ().uint8_array_value (); } + uint8_array_value () const { return to_dense ().uint8_array_value (); } uint16NDArray - uint16_array_value (void) const { return to_dense ().uint16_array_value (); } + uint16_array_value () const { return to_dense ().uint16_array_value (); } uint32NDArray - uint32_array_value (void) const { return to_dense ().uint32_array_value (); } + uint32_array_value () const { return to_dense ().uint32_array_value (); } uint64NDArray - uint64_array_value (void) const { return to_dense ().uint64_array_value (); } + uint64_array_value () const { return to_dense ().uint64_array_value (); } octave_value convert_to_str_internal (bool pad, bool force, char type) const; - octave_value as_double (void) const; - octave_value as_single (void) const; + octave_value as_double () const; + octave_value as_single () const; - octave_value as_int8 (void) const; - octave_value as_int16 (void) const; - octave_value as_int32 (void) const; - octave_value as_int64 (void) const; + octave_value as_int8 () const; + octave_value as_int16 () const; + octave_value as_int32 () const; + octave_value as_int64 () const; - octave_value as_uint8 (void) const; - octave_value as_uint16 (void) const; - octave_value as_uint32 (void) const; - octave_value as_uint64 (void) const; + octave_value as_uint8 () const; + octave_value as_uint16 () const; + octave_value as_uint32 () const; + octave_value as_uint64 () const; void print_raw (std::ostream& os, bool pr_as_read_syntax = false) const; - float_display_format get_edit_display_format (void) const; + float_display_format get_edit_display_format () const; std::string edit_display (const float_display_format& fmt, octave_idx_type i, octave_idx_type j) const; @@ -242,7 +242,7 @@ mxArray * as_mxArray (bool interleaved) const; - bool print_as_scalar (void) const; + bool print_as_scalar () const; void print (std::ostream& os, bool pr_as_read_syntax = false); @@ -259,7 +259,7 @@ PermMatrix m_matrix; - virtual octave_value to_dense (void) const; + virtual octave_value to_dense () const; mutable octave_value m_dense_cache; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-range.cc --- a/libinterp/octave-value/ov-range.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-range.cc Tue Jan 24 17:19:44 2023 -0800 @@ -191,7 +191,7 @@ template octave_base_value::type_conv_info -ov_range::numeric_conversion_function (void) const +ov_range::numeric_conversion_function () const { typedef typename octave_value_range_traits::matrix_type ov_mx_type; @@ -201,7 +201,7 @@ template octave_base_value * -ov_range::try_narrowing_conversion (void) +ov_range::try_narrowing_conversion () { octave_base_value *retval = nullptr; @@ -414,7 +414,7 @@ template octave::range -ov_range::range_value (void) const +ov_range::range_value () const { err_wrong_type_arg ("ov_range::range_value()", type_name ()); } @@ -425,63 +425,63 @@ template octave::range -ov_range::float_range_value (void) const +ov_range::float_range_value () const { err_wrong_type_arg ("ov_range::float_range_value ()", type_name ()); } template octave::range -ov_range::int8_range_value (void) const +ov_range::int8_range_value () const { err_wrong_type_arg ("ov_range::int8_range_value ()", type_name ()); } template octave::range -ov_range::int16_range_value (void) const +ov_range::int16_range_value () const { err_wrong_type_arg ("ov_range::int16_range_value ()", type_name ()); } template octave::range -ov_range::int32_range_value (void) const +ov_range::int32_range_value () const { err_wrong_type_arg ("ov_range::int32_range_value ()", type_name ()); } template octave::range -ov_range::int64_range_value (void) const +ov_range::int64_range_value () const { err_wrong_type_arg ("ov_range::int64_range_value ()", type_name ()); } template octave::range -ov_range::uint8_range_value (void) const +ov_range::uint8_range_value () const { err_wrong_type_arg ("ov_range::uint8_range_value ()", type_name ()); } template octave::range -ov_range::uint16_range_value (void) const +ov_range::uint16_range_value () const { err_wrong_type_arg ("ov_range::uint16_range_value ()", type_name ()); } template octave::range -ov_range::uint32_range_value (void) const +ov_range::uint32_range_value () const { err_wrong_type_arg ("ov_range::uint32_range_value ()", type_name ()); } template octave::range -ov_range::uint64_range_value (void) const +ov_range::uint64_range_value () const { err_wrong_type_arg ("ov_range::uint64_range_value ()", type_name ()); } @@ -500,70 +500,70 @@ template octave_value -ov_range::as_double (void) const +ov_range::as_double () const { return NDArray (raw_array_value ()); } template octave_value -ov_range::as_single (void) const +ov_range::as_single () const { return FloatMatrix (raw_array_value ()); } template octave_value -ov_range::as_int8 (void) const +ov_range::as_int8 () const { return int8NDArray (raw_array_value ()); } template octave_value -ov_range::as_int16 (void) const +ov_range::as_int16 () const { return int16NDArray (raw_array_value ()); } template octave_value -ov_range::as_int32 (void) const +ov_range::as_int32 () const { return int32NDArray (raw_array_value ()); } template octave_value -ov_range::as_int64 (void) const +ov_range::as_int64 () const { return int64NDArray (raw_array_value ()); } template octave_value -ov_range::as_uint8 (void) const +ov_range::as_uint8 () const { return uint8NDArray (raw_array_value ()); } template octave_value -ov_range::as_uint16 (void) const +ov_range::as_uint16 () const { return uint16NDArray (raw_array_value ()); } template octave_value -ov_range::as_uint32 (void) const +ov_range::as_uint32 () const { return uint32NDArray (raw_array_value ()); } template octave_value -ov_range::as_uint64 (void) const +ov_range::as_uint64 () const { return uint64NDArray (raw_array_value ()); } @@ -655,7 +655,7 @@ template float_display_format -ov_range::get_edit_display_format (void) const +ov_range::get_edit_display_format () const { return make_format (m_range); } @@ -1428,7 +1428,7 @@ template <> octave::range -ov_range::range_value (void) const +ov_range::range_value () const { return m_range; } @@ -1439,63 +1439,63 @@ template <> octave::range -ov_range::float_range_value (void) const +ov_range::float_range_value () const { return m_range; } template <> octave::range -ov_range::int8_range_value (void) const +ov_range::int8_range_value () const { return m_range; } template <> octave::range -ov_range::int16_range_value (void) const +ov_range::int16_range_value () const { return m_range; } template <> octave::range -ov_range::int32_range_value (void) const +ov_range::int32_range_value () const { return m_range; } template <> octave::range -ov_range::int64_range_value (void) const +ov_range::int64_range_value () const { return m_range; } template <> octave::range -ov_range::uint8_range_value (void) const +ov_range::uint8_range_value () const { return m_range; } template <> octave::range -ov_range::uint16_range_value (void) const +ov_range::uint16_range_value () const { return m_range; } template <> octave::range -ov_range::uint32_range_value (void) const +ov_range::uint32_range_value () const { return m_range; } template <> octave::range -ov_range::uint64_range_value (void) const +ov_range::uint64_range_value () const { return m_range; } @@ -1520,7 +1520,7 @@ template <> octave_idx_type -ov_range::nnz (void) const +ov_range::nnz () const { return m_range.nnz (); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-range.h --- a/libinterp/octave-value/ov-range.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-range.h Tue Jan 24 17:19:44 2023 -0800 @@ -60,7 +60,7 @@ { public: - ov_range (void) + ov_range () : octave_base_value (), m_range (), m_idx_cache () { } ov_range (const octave::range& r) @@ -85,9 +85,9 @@ // No assignment. ov_range& operator = (const ov_range&) = delete; - ~ov_range (void) { clear_cached_info (); } + ~ov_range () { clear_cached_info (); } - octave_base_value * clone (void) const + octave_base_value * clone () const { return new ov_range (*this); } @@ -96,16 +96,16 @@ // the places where we need to call empty_clone, it makes more sense // to create an empty matrix (0x0) instead of an empty range (1x0). - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new typename octave_value_range_traits::matrix_type (); } - OCTINTERP_API type_conv_info numeric_conversion_function (void) const; + OCTINTERP_API type_conv_info numeric_conversion_function () const; - OCTINTERP_API octave_base_value * try_narrowing_conversion (void); + OCTINTERP_API octave_base_value * try_narrowing_conversion (); - builtin_type_t builtin_type (void) const { return class_to_btyp::btyp; } + builtin_type_t builtin_type () const { return class_to_btyp::btyp; } // We don't need to override all three forms of subsref. The using // declaration will avoid warnings about partially-overloaded virtual @@ -124,15 +124,15 @@ OCTINTERP_API octave::idx_vector index_vector (bool require_integers = false) const; - dim_vector dims (void) const + dim_vector dims () const { octave_idx_type n = numel (); return dim_vector (n > 0, n); } - octave_idx_type numel (void) const { return m_range.numel (); } + octave_idx_type numel () const { return m_range.numel (); } - octave_idx_type nnz (void) const + octave_idx_type nnz () const { // FIXME: this is a potential waste of memory. @@ -143,7 +143,7 @@ OCTINTERP_API octave_value resize (const dim_vector& dv, bool fill = false) const; - std::size_t byte_size (void) const { return 3 * sizeof (T); } + std::size_t byte_size () const { return 3 * sizeof (T); } octave_value reshape (const dim_vector& new_dims) const { @@ -155,53 +155,53 @@ return raw_array_value ().permute (vec, inv); } - octave_value squeeze (void) const { return m_range; } + octave_value squeeze () const { return m_range; } - octave_value full_value (void) const { return raw_array_value (); } + octave_value full_value () const { return raw_array_value (); } - bool is_defined (void) const { return true; } + bool is_defined () const { return true; } - bool is_storable (void) const { return m_range.is_storable (); } + bool is_storable () const { return m_range.is_storable (); } - bool is_constant (void) const { return true; } + bool is_constant () const { return true; } - bool is_range (void) const { return true; } + bool is_range () const { return true; } - bool is_double_type (void) const { return builtin_type () == btyp_double; } + bool is_double_type () const { return builtin_type () == btyp_double; } - bool is_single_type (void) const { return builtin_type () == btyp_float; } + bool is_single_type () const { return builtin_type () == btyp_float; } - bool isfloat (void) const { return btyp_isfloat (builtin_type ()); } + bool isfloat () const { return btyp_isfloat (builtin_type ()); } - bool is_int8_type (void) const { return builtin_type () == btyp_int8; } + bool is_int8_type () const { return builtin_type () == btyp_int8; } - bool is_int16_type (void) const { return builtin_type () == btyp_int16; } + bool is_int16_type () const { return builtin_type () == btyp_int16; } - bool is_int32_type (void) const { return builtin_type () == btyp_int32; } + bool is_int32_type () const { return builtin_type () == btyp_int32; } - bool is_int64_type (void) const { return builtin_type () == btyp_int64; } + bool is_int64_type () const { return builtin_type () == btyp_int64; } - bool is_uint8_type (void) const { return builtin_type () == btyp_uint8; } + bool is_uint8_type () const { return builtin_type () == btyp_uint8; } - bool is_uint16_type (void) const { return builtin_type () == btyp_uint16; } + bool is_uint16_type () const { return builtin_type () == btyp_uint16; } - bool is_uint32_type (void) const { return builtin_type () == btyp_uint32; } + bool is_uint32_type () const { return builtin_type () == btyp_uint32; } - bool is_uint64_type (void) const { return builtin_type () == btyp_uint64; } + bool is_uint64_type () const { return builtin_type () == btyp_uint64; } - bool isinteger (void) const + bool isinteger () const { return btyp_isinteger (builtin_type ()); } - bool isreal (void) const { return true; } + bool isreal () const { return true; } - bool isnumeric (void) const + bool isnumeric () const { return btyp_isnumeric (builtin_type ()); } - bool is_true (void) const { return nnz () == numel (); } + bool is_true () const { return nnz () == numel (); } octave_value all (int dim = 0) const { @@ -268,7 +268,7 @@ return (mode == UNSORTED) ? ASCENDING : mode; } - Array raw_array_value (void) const { return m_range.array_value (); } + Array raw_array_value () const { return m_range.array_value (); } OCTINTERP_API double double_value (bool = false) const; @@ -310,42 +310,42 @@ // functions to avoid the intermediate conversion to a matrix // object. - int8NDArray int8_array_value (void) const + int8NDArray int8_array_value () const { return raw_array_value (); } - int16NDArray int16_array_value (void) const + int16NDArray int16_array_value () const { return raw_array_value (); } - int32NDArray int32_array_value (void) const + int32NDArray int32_array_value () const { return raw_array_value (); } - int64NDArray int64_array_value (void) const + int64NDArray int64_array_value () const { return raw_array_value (); } - uint8NDArray uint8_array_value (void) const + uint8NDArray uint8_array_value () const { return raw_array_value (); } - uint16NDArray uint16_array_value (void) const + uint16NDArray uint16_array_value () const { return raw_array_value (); } - uint32NDArray uint32_array_value (void) const + uint32NDArray uint32_array_value () const { return raw_array_value (); } - uint64NDArray uint64_array_value (void) const + uint64NDArray uint64_array_value () const { return raw_array_value (); } @@ -386,47 +386,47 @@ return raw_array_value (); } - OCTINTERP_API octave::range range_value (void) const; + OCTINTERP_API octave::range range_value () const; // For now, disable all but ov_range. #if 0 - OCTINTERP_API octave::range float_range_value (void) const; + OCTINTERP_API octave::range float_range_value () const; - OCTINTERP_API octave::range int8_range_value (void) const; + OCTINTERP_API octave::range int8_range_value () const; - OCTINTERP_API octave::range int16_range_value (void) const; + OCTINTERP_API octave::range int16_range_value () const; - OCTINTERP_API octave::range int32_range_value (void) const; + OCTINTERP_API octave::range int32_range_value () const; - OCTINTERP_API octave::range int64_range_value (void) const; + OCTINTERP_API octave::range int64_range_value () const; - OCTINTERP_API octave::range uint8_range_value (void) const; + OCTINTERP_API octave::range uint8_range_value () const; - OCTINTERP_API octave::range uint16_range_value (void) const; + OCTINTERP_API octave::range uint16_range_value () const; - OCTINTERP_API octave::range uint32_range_value (void) const; + OCTINTERP_API octave::range uint32_range_value () const; - OCTINTERP_API octave::range uint64_range_value (void) const; + OCTINTERP_API octave::range uint64_range_value () const; #endif OCTINTERP_API octave_value convert_to_str_internal (bool pad, bool force, char type) const; - OCTINTERP_API octave_value as_double (void) const; - OCTINTERP_API octave_value as_single (void) const; + OCTINTERP_API octave_value as_double () const; + OCTINTERP_API octave_value as_single () const; - OCTINTERP_API octave_value as_int8 (void) const; - OCTINTERP_API octave_value as_int16 (void) const; - OCTINTERP_API octave_value as_int32 (void) const; - OCTINTERP_API octave_value as_int64 (void) const; + OCTINTERP_API octave_value as_int8 () const; + OCTINTERP_API octave_value as_int16 () const; + OCTINTERP_API octave_value as_int32 () const; + OCTINTERP_API octave_value as_int64 () const; - OCTINTERP_API octave_value as_uint8 (void) const; - OCTINTERP_API octave_value as_uint16 (void) const; - OCTINTERP_API octave_value as_uint32 (void) const; - OCTINTERP_API octave_value as_uint64 (void) const; + OCTINTERP_API octave_value as_uint8 () const; + OCTINTERP_API octave_value as_uint16 () const; + OCTINTERP_API octave_value as_uint32 () const; + OCTINTERP_API octave_value as_uint64 () const; OCTINTERP_API void print (std::ostream& os, bool pr_as_read_syntax = false); @@ -438,7 +438,7 @@ OCTINTERP_API void short_disp (std::ostream& os) const; - OCTINTERP_API float_display_format get_edit_display_format (void) const; + OCTINTERP_API float_display_format get_edit_display_format () const; OCTINTERP_API std::string edit_display (const float_display_format& fmt, @@ -490,7 +490,7 @@ return idx; } - void clear_cached_info (void) const + void clear_cached_info () const { delete m_idx_cache; m_idx_cache = nullptr; } @@ -524,7 +524,7 @@ template <> OCTINTERP_API octave::range -ov_range::range_value (void) const; +ov_range::range_value () const; // For now, disable all but ov_range. @@ -532,39 +532,39 @@ template <> OCTINTERP_API octave::range -ov_range::float_range_value (void) const; +ov_range::float_range_value () const; template <> OCTINTERP_API octave::range -ov_range::int8_range_value (void) const; +ov_range::int8_range_value () const; template <> OCTINTERP_API octave::range -ov_range::int16_range_value (void) const; +ov_range::int16_range_value () const; template <> OCTINTERP_API octave::range -ov_range::int32_range_value (void) const; +ov_range::int32_range_value () const; template <> OCTINTERP_API octave::range -ov_range::int64_range_value (void) const; +ov_range::int64_range_value () const; template <> OCTINTERP_API octave::range -ov_range::uint8_range_value (void) const; +ov_range::uint8_range_value () const; template <> OCTINTERP_API octave::range -ov_range::uint16_range_value (void) const; +ov_range::uint16_range_value () const; template <> OCTINTERP_API octave::range -ov_range::uint32_range_value (void) const; +ov_range::uint32_range_value () const; template <> OCTINTERP_API octave::range -ov_range::uint64_range_value (void) const; +ov_range::uint64_range_value () const; #endif @@ -577,7 +577,7 @@ template <> OCTINTERP_API octave_idx_type -ov_range::nnz (void) const; +ov_range::nnz () const; // The following specialization is also historical baggage. For double // ranges, we can produce special double-valued diagnoal matrix objects diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-re-diag.cc --- a/libinterp/octave-value/ov-re-diag.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-re-diag.cc Tue Jan 24 17:19:44 2023 -0800 @@ -51,7 +51,7 @@ } octave_base_value::type_conv_info -octave_diag_matrix::numeric_conversion_function (void) const +octave_diag_matrix::numeric_conversion_function () const { return octave_base_value::type_conv_info (default_numeric_conversion_function, octave_matrix::static_type_id ()); @@ -66,7 +66,7 @@ } octave_base_value::type_conv_info -octave_diag_matrix::numeric_demotion_function (void) const +octave_diag_matrix::numeric_demotion_function () const { return octave_base_value::type_conv_info (default_numeric_demotion_function, @@ -74,7 +74,7 @@ } octave_base_value * -octave_diag_matrix::try_narrowing_conversion (void) +octave_diag_matrix::try_narrowing_conversion () { octave_base_value *retval = nullptr; @@ -161,61 +161,61 @@ } octave_value -octave_diag_matrix::as_double (void) const +octave_diag_matrix::as_double () const { return m_matrix; } octave_value -octave_diag_matrix::as_single (void) const +octave_diag_matrix::as_single () const { return FloatDiagMatrix (m_matrix); } octave_value -octave_diag_matrix::as_int8 (void) const +octave_diag_matrix::as_int8 () const { return int8_array_value (); } octave_value -octave_diag_matrix::as_int16 (void) const +octave_diag_matrix::as_int16 () const { return int16_array_value (); } octave_value -octave_diag_matrix::as_int32 (void) const +octave_diag_matrix::as_int32 () const { return int32_array_value (); } octave_value -octave_diag_matrix::as_int64 (void) const +octave_diag_matrix::as_int64 () const { return int64_array_value (); } octave_value -octave_diag_matrix::as_uint8 (void) const +octave_diag_matrix::as_uint8 () const { return uint8_array_value (); } octave_value -octave_diag_matrix::as_uint16 (void) const +octave_diag_matrix::as_uint16 () const { return uint16_array_value (); } octave_value -octave_diag_matrix::as_uint32 (void) const +octave_diag_matrix::as_uint32 () const { return uint32_array_value (); } octave_value -octave_diag_matrix::as_uint64 (void) const +octave_diag_matrix::as_uint64 () const { return uint64_array_value (); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-re-diag.h --- a/libinterp/octave-value/ov-re-diag.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-re-diag.h Tue Jan 24 17:19:44 2023 -0800 @@ -42,7 +42,7 @@ { public: - octave_diag_matrix (void) + octave_diag_matrix () : octave_base_diag () { } octave_diag_matrix (const DiagMatrix& m) @@ -51,31 +51,31 @@ octave_diag_matrix (const octave_diag_matrix& m) : octave_base_diag (m) { } - ~octave_diag_matrix (void) = default; + ~octave_diag_matrix () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_diag_matrix (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_diag_matrix (); } - type_conv_info numeric_conversion_function (void) const; + type_conv_info numeric_conversion_function () const; - type_conv_info numeric_demotion_function (void) const; + type_conv_info numeric_demotion_function () const; - octave_base_value * try_narrowing_conversion (void); + octave_base_value * try_narrowing_conversion (); octave_value do_index_op (const octave_value_list& idx, bool resize_ok = false); - builtin_type_t builtin_type (void) const { return btyp_double; } + builtin_type_t builtin_type () const { return btyp_double; } - bool is_real_matrix (void) const { return true; } + bool is_real_matrix () const { return true; } - bool isreal (void) const { return true; } + bool isreal () const { return true; } - bool is_double_type (void) const { return true; } + bool is_double_type () const { return true; } - bool isfloat (void) const { return true; } + bool isfloat () const { return true; } DiagMatrix diag_matrix_value (bool = false) const; @@ -85,18 +85,18 @@ FloatComplexDiagMatrix float_complex_diag_matrix_value (bool = false) const; - octave_value as_double (void) const; - octave_value as_single (void) const; + octave_value as_double () const; + octave_value as_single () const; - octave_value as_int8 (void) const; - octave_value as_int16 (void) const; - octave_value as_int32 (void) const; - octave_value as_int64 (void) const; + octave_value as_int8 () const; + octave_value as_int16 () const; + octave_value as_int32 () const; + octave_value as_int64 () const; - octave_value as_uint8 (void) const; - octave_value as_uint16 (void) const; - octave_value as_uint32 (void) const; - octave_value as_uint64 (void) const; + octave_value as_uint8 () const; + octave_value as_uint16 () const; + octave_value as_uint32 () const; + octave_value as_uint64 () const; bool save_binary (std::ostream& os, bool save_as_floats); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-re-mat.cc --- a/libinterp/octave-value/ov-re-mat.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-re-mat.cc Tue Jan 24 17:19:44 2023 -0800 @@ -98,7 +98,7 @@ } octave_base_value::type_conv_info -octave_matrix::numeric_demotion_function (void) const +octave_matrix::numeric_demotion_function () const { return octave_base_value::type_conv_info (default_numeric_demotion_function, @@ -106,7 +106,7 @@ } octave_base_value * -octave_matrix::try_narrowing_conversion (void) +octave_matrix::try_narrowing_conversion () { octave_base_value *retval = nullptr; @@ -250,61 +250,61 @@ } octave_value -octave_matrix::as_double (void) const +octave_matrix::as_double () const { return NDArray (m_matrix); } octave_value -octave_matrix::as_single (void) const +octave_matrix::as_single () const { return FloatNDArray (m_matrix); } octave_value -octave_matrix::as_int8 (void) const +octave_matrix::as_int8 () const { return int8NDArray (m_matrix); } octave_value -octave_matrix::as_int16 (void) const +octave_matrix::as_int16 () const { return int16NDArray (m_matrix); } octave_value -octave_matrix::as_int32 (void) const +octave_matrix::as_int32 () const { return int32NDArray (m_matrix); } octave_value -octave_matrix::as_int64 (void) const +octave_matrix::as_int64 () const { return int64NDArray (m_matrix); } octave_value -octave_matrix::as_uint8 (void) const +octave_matrix::as_uint8 () const { return uint8NDArray (m_matrix); } octave_value -octave_matrix::as_uint16 (void) const +octave_matrix::as_uint16 () const { return uint16NDArray (m_matrix); } octave_value -octave_matrix::as_uint32 (void) const +octave_matrix::as_uint32 () const { return uint32NDArray (m_matrix); } octave_value -octave_matrix::as_uint64 (void) const +octave_matrix::as_uint64 () const { return uint64NDArray (m_matrix); } @@ -350,7 +350,7 @@ } octave_value -octave_matrix::squeeze (void) const +octave_matrix::squeeze () const { if (m_idx_cache) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-re-mat.h --- a/libinterp/octave-value/ov-re-mat.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-re-mat.h Tue Jan 24 17:19:44 2023 -0800 @@ -54,7 +54,7 @@ { public: - octave_matrix (void) + octave_matrix () : octave_base_matrix () { } octave_matrix (const Matrix& m) @@ -96,14 +96,14 @@ set_idx_cache (cache); } - ~octave_matrix (void) = default; + ~octave_matrix () = default; - octave_base_value * clone (void) const { return new octave_matrix (*this); } - octave_base_value * empty_clone (void) const { return new octave_matrix (); } + octave_base_value * clone () const { return new octave_matrix (*this); } + octave_base_value * empty_clone () const { return new octave_matrix (); } - type_conv_info numeric_demotion_function (void) const; + type_conv_info numeric_demotion_function () const; - octave_base_value * try_narrowing_conversion (void); + octave_base_value * try_narrowing_conversion (); octave::idx_vector index_vector (bool /* require_integers */ = false) const { @@ -111,39 +111,39 @@ : set_idx_cache (octave::idx_vector (m_matrix)); } - builtin_type_t builtin_type (void) const { return btyp_double; } + builtin_type_t builtin_type () const { return btyp_double; } - bool is_real_matrix (void) const { return true; } + bool is_real_matrix () const { return true; } - bool isreal (void) const { return true; } + bool isreal () const { return true; } - bool is_double_type (void) const { return true; } + bool is_double_type () const { return true; } - bool isfloat (void) const { return true; } + bool isfloat () const { return true; } int8NDArray - int8_array_value (void) const { return int8NDArray (m_matrix); } + int8_array_value () const { return int8NDArray (m_matrix); } int16NDArray - int16_array_value (void) const { return int16NDArray (m_matrix); } + int16_array_value () const { return int16NDArray (m_matrix); } int32NDArray - int32_array_value (void) const { return int32NDArray (m_matrix); } + int32_array_value () const { return int32NDArray (m_matrix); } int64NDArray - int64_array_value (void) const { return int64NDArray (m_matrix); } + int64_array_value () const { return int64NDArray (m_matrix); } uint8NDArray - uint8_array_value (void) const { return uint8NDArray (m_matrix); } + uint8_array_value () const { return uint8NDArray (m_matrix); } uint16NDArray - uint16_array_value (void) const { return uint16NDArray (m_matrix); } + uint16_array_value () const { return uint16NDArray (m_matrix); } uint32NDArray - uint32_array_value (void) const { return uint32NDArray (m_matrix); } + uint32_array_value () const { return uint32NDArray (m_matrix); } uint64NDArray - uint64_array_value (void) const { return uint64NDArray (m_matrix); } + uint64_array_value () const { return uint64NDArray (m_matrix); } double double_value (bool = false) const; @@ -180,18 +180,18 @@ SparseComplexMatrix sparse_complex_matrix_value (bool = false) const; - octave_value as_double (void) const; - octave_value as_single (void) const; + octave_value as_double () const; + octave_value as_single () const; - octave_value as_int8 (void) const; - octave_value as_int16 (void) const; - octave_value as_int32 (void) const; - octave_value as_int64 (void) const; + octave_value as_int8 () const; + octave_value as_int16 () const; + octave_value as_int32 () const; + octave_value as_int64 () const; - octave_value as_uint8 (void) const; - octave_value as_uint16 (void) const; - octave_value as_uint32 (void) const; - octave_value as_uint64 (void) const; + octave_value as_uint8 () const; + octave_value as_uint16 () const; + octave_value as_uint32 () const; + octave_value as_uint64 () const; octave_value diag (octave_idx_type k = 0) const; @@ -199,7 +199,7 @@ octave_value reshape (const dim_vector& new_dims) const; - octave_value squeeze (void) const; + octave_value squeeze () const; octave_value sort (octave_idx_type dim = 0, sortmode mode = ASCENDING) const; octave_value sort (Array& sidx, octave_idx_type dim = 0, @@ -212,11 +212,11 @@ sortmode is_sorted_rows (sortmode mode = UNSORTED) const; // Use matrix_ref here to clear index cache. - void increment (void) { matrix_ref () += 1.0; } + void increment () { matrix_ref () += 1.0; } - void decrement (void) { matrix_ref () -= 1.0; } + void decrement () { matrix_ref () -= 1.0; } - void changesign (void) { matrix_ref ().changesign (); } + void changesign () { matrix_ref ().changesign (); } octave_value convert_to_str_internal (bool pad, bool force, char type) const; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-re-sparse.cc --- a/libinterp/octave-value/ov-re-sparse.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-re-sparse.cc Tue Jan 24 17:19:44 2023 -0800 @@ -214,7 +214,7 @@ } octave_value -octave_sparse_matrix::as_double (void) const +octave_sparse_matrix::as_double () const { return this->matrix; } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-re-sparse.h --- a/libinterp/octave-value/ov-re-sparse.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-re-sparse.h Tue Jan 24 17:19:44 2023 -0800 @@ -54,7 +54,7 @@ { public: - octave_sparse_matrix (void) + octave_sparse_matrix () : octave_base_sparse () { } octave_sparse_matrix (const Matrix& m) @@ -84,24 +84,24 @@ octave_sparse_matrix (const octave_sparse_matrix& m) : octave_base_sparse (m) { } - ~octave_sparse_matrix (void) = default; + ~octave_sparse_matrix () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_sparse_matrix (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_sparse_matrix (); } octave::idx_vector index_vector (bool require_integers = false) const; - builtin_type_t builtin_type (void) const { return btyp_double; } + builtin_type_t builtin_type () const { return btyp_double; } - bool is_real_matrix (void) const { return true; } + bool is_real_matrix () const { return true; } - bool isreal (void) const { return true; } + bool isreal () const { return true; } - bool is_double_type (void) const { return true; } + bool is_double_type () const { return true; } - bool isfloat (void) const { return true; } + bool isfloat () const { return true; } double double_value (bool = false) const; @@ -132,7 +132,7 @@ octave_value convert_to_str_internal (bool pad, bool force, char type) const; - octave_value as_double (void) const; + octave_value as_double () const; #if 0 int write (octave::stream& os, int block_size, diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-scalar.cc --- a/libinterp/octave-value/ov-scalar.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-scalar.cc Tue Jan 24 17:19:44 2023 -0800 @@ -76,7 +76,7 @@ } octave_base_value::type_conv_info -octave_scalar::numeric_demotion_function (void) const +octave_scalar::numeric_demotion_function () const { return octave_base_value::type_conv_info (default_numeric_demotion_function, @@ -125,61 +125,61 @@ } octave_value -octave_scalar::as_double (void) const +octave_scalar::as_double () const { return scalar; } octave_value -octave_scalar::as_single (void) const +octave_scalar::as_single () const { return static_cast (scalar); } octave_value -octave_scalar::as_int8 (void) const +octave_scalar::as_int8 () const { return octave_int8 (scalar); } octave_value -octave_scalar::as_int16 (void) const +octave_scalar::as_int16 () const { return octave_int16 (scalar); } octave_value -octave_scalar::as_int32 (void) const +octave_scalar::as_int32 () const { return octave_int32 (scalar); } octave_value -octave_scalar::as_int64 (void) const +octave_scalar::as_int64 () const { return octave_int64 (scalar); } octave_value -octave_scalar::as_uint8 (void) const +octave_scalar::as_uint8 () const { return octave_uint8 (scalar); } octave_value -octave_scalar::as_uint16 (void) const +octave_scalar::as_uint16 () const { return octave_uint16 (scalar); } octave_value -octave_scalar::as_uint32 (void) const +octave_scalar::as_uint32 () const { return octave_uint32 (scalar); } octave_value -octave_scalar::as_uint64 (void) const +octave_scalar::as_uint64 () const { return octave_uint64 (scalar); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-scalar.h --- a/libinterp/octave-value/ov-scalar.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-scalar.h Tue Jan 24 17:19:44 2023 -0800 @@ -55,7 +55,7 @@ { public: - octave_scalar (void) + octave_scalar () : octave_base_scalar (0.0) { } octave_scalar (double d) @@ -64,19 +64,19 @@ octave_scalar (const octave_scalar& s) : octave_base_scalar (s) { } - ~octave_scalar (void) = default; + ~octave_scalar () = default; - octave_base_value * clone (void) const { return new octave_scalar (*this); } + octave_base_value * clone () const { return new octave_scalar (*this); } // We return an octave_matrix here instead of an octave_scalar so // that in expressions like A(2,2,2) = 2 (for A previously // undefined), A will be empty instead of a 1x1 object. - octave_base_value * empty_clone (void) const { return new octave_matrix (); } + octave_base_value * empty_clone () const { return new octave_matrix (); } octave_value do_index_op (const octave_value_list& idx, bool resize_ok = false); - type_conv_info numeric_demotion_function (void) const; + type_conv_info numeric_demotion_function () const; octave::idx_vector index_vector (bool /* require_integers */ = false) const { return octave::idx_vector (scalar); } @@ -84,51 +84,51 @@ octave_value any (int = 0) const { return (scalar != 0 && ! lo_ieee_isnan (scalar)); } - builtin_type_t builtin_type (void) const { return btyp_double; } + builtin_type_t builtin_type () const { return btyp_double; } - bool is_real_scalar (void) const { return true; } + bool is_real_scalar () const { return true; } - bool isreal (void) const { return true; } + bool isreal () const { return true; } - bool is_double_type (void) const { return true; } + bool is_double_type () const { return true; } - bool isfloat (void) const { return true; } + bool isfloat () const { return true; } int8NDArray - int8_array_value (void) const + int8_array_value () const { return int8NDArray (dim_vector (1, 1), scalar); } int16NDArray - int16_array_value (void) const + int16_array_value () const { return int16NDArray (dim_vector (1, 1), scalar); } int32NDArray - int32_array_value (void) const + int32_array_value () const { return int32NDArray (dim_vector (1, 1), scalar); } int64NDArray - int64_array_value (void) const + int64_array_value () const { return int64NDArray (dim_vector (1, 1), scalar); } uint8NDArray - uint8_array_value (void) const + uint8_array_value () const { return uint8NDArray (dim_vector (1, 1), scalar); } uint16NDArray - uint16_array_value (void) const + uint16_array_value () const { return uint16NDArray (dim_vector (1, 1), scalar); } uint32NDArray - uint32_array_value (void) const + uint32_array_value () const { return uint32NDArray (dim_vector (1, 1), scalar); } uint64NDArray - uint64_array_value (void) const + uint64_array_value () const { return uint64NDArray (dim_vector (1, 1), scalar); } #define DEFINE_INT_SCALAR_VALUE(TYPE) \ octave_ ## TYPE \ - TYPE ## _scalar_value (void) const \ + TYPE ## _scalar_value () const \ { \ return octave_ ## TYPE (scalar); \ } @@ -223,18 +223,18 @@ return boolNDArray (dim_vector (1, 1), scalar); } - octave_value as_double (void) const; - octave_value as_single (void) const; + octave_value as_double () const; + octave_value as_single () const; - octave_value as_int8 (void) const; - octave_value as_int16 (void) const; - octave_value as_int32 (void) const; - octave_value as_int64 (void) const; + octave_value as_int8 () const; + octave_value as_int16 () const; + octave_value as_int32 () const; + octave_value as_int64 () const; - octave_value as_uint8 (void) const; - octave_value as_uint16 (void) const; - octave_value as_uint32 (void) const; - octave_value as_uint64 (void) const; + octave_value as_uint8 () const; + octave_value as_uint16 () const; + octave_value as_uint32 () const; + octave_value as_uint64 () const; // We don't need to override both forms of the diag method. The using // declaration will avoid warnings about partially-overloaded virtual @@ -245,9 +245,9 @@ octave_value convert_to_str_internal (bool pad, bool force, char type) const; - void increment (void) { ++scalar; } + void increment () { ++scalar; } - void decrement (void) { --scalar; } + void decrement () { --scalar; } bool save_ascii (std::ostream& os); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-str-mat.cc --- a/libinterp/octave-value/ov-str-mat.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-str-mat.cc Tue Jan 24 17:19:44 2023 -0800 @@ -80,7 +80,7 @@ } octave_base_value::type_conv_info -octave_char_matrix_str::numeric_conversion_function (void) const +octave_char_matrix_str::numeric_conversion_function () const { return octave_base_value::type_conv_info (default_numeric_conversion_function, octave_matrix::static_type_id ()); @@ -252,7 +252,7 @@ */ Array -octave_char_matrix_str::cellstr_value (void) const +octave_char_matrix_str::cellstr_value () const { Array retval; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-str-mat.h --- a/libinterp/octave-value/ov-str-mat.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-str-mat.h Tue Jan 24 17:19:44 2023 -0800 @@ -54,7 +54,7 @@ { public: - octave_char_matrix_str (void) + octave_char_matrix_str () : octave_char_matrix () { } octave_char_matrix_str (const charMatrix& chm) @@ -84,20 +84,20 @@ octave_char_matrix_str (const octave_char_matrix_str& chms) : octave_char_matrix (chms) { } - ~octave_char_matrix_str (void) = default; + ~octave_char_matrix_str () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_char_matrix_str (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_char_matrix_str (); } - type_conv_info numeric_conversion_function (void) const; + type_conv_info numeric_conversion_function () const; octave_value do_index_op (const octave_value_list& idx, bool resize_ok = false) { return do_index_op_internal (idx, resize_ok); } - octave_value squeeze (void) const + octave_value squeeze () const { return octave_value (charNDArray (m_matrix.squeeze ())); } octave_value reshape (const dim_vector& new_dims) const @@ -116,9 +116,9 @@ octave_value diag (octave_idx_type k = 0) const { return octave_value (m_matrix.diag (k)); } - bool is_string (void) const { return true; } + bool is_string () const { return true; } - bool isnumeric (void) const { return false; } + bool isnumeric () const { return false; } double double_value (bool = false) const; @@ -136,9 +136,9 @@ std::string string_value (bool force = false) const; - std::string xstring_value (void) const { return string_value (); } + std::string xstring_value () const { return string_value (); } - Array cellstr_value (void) const; + Array cellstr_value () const; octave_value sort (octave_idx_type dim = 0, sortmode mode = ASCENDING) const { return octave_value (m_matrix.sort (dim, mode)); } @@ -147,7 +147,7 @@ sortmode mode = ASCENDING) const { return octave_value (m_matrix.sort (sidx, dim, mode)); } - bool print_as_scalar (void) const { return (rows () <= 1); } + bool print_as_scalar () const { return (rows () <= 1); } void print_raw (std::ostream& os, bool pr_as_read_syntax = false) const; @@ -191,7 +191,7 @@ { public: - octave_char_matrix_sq_str (void) + octave_char_matrix_sq_str () : octave_char_matrix_str () { } octave_char_matrix_sq_str (const charMatrix& chm) @@ -221,14 +221,14 @@ octave_char_matrix_sq_str (const octave_char_matrix_sq_str& chms) : octave_char_matrix_str (chms) { } - ~octave_char_matrix_sq_str (void) = default; + ~octave_char_matrix_sq_str () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_char_matrix_sq_str (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_char_matrix_sq_str (); } - octave_value squeeze (void) const + octave_value squeeze () const { return octave_value (charNDArray (m_matrix.squeeze ()), '\''); } octave_value reshape (const dim_vector& new_dims) const @@ -252,7 +252,7 @@ octave_value diag (octave_idx_type k = 0) const { return octave_value (m_matrix.diag (k), '\''); } - bool is_sq_string (void) const { return true; } + bool is_sq_string () const { return true; } octave_value do_index_op (const octave_value_list& idx, bool resize_ok = false) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-struct.cc --- a/libinterp/octave-value/ov-struct.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-struct.cc Tue Jan 24 17:19:44 2023 -0800 @@ -76,7 +76,7 @@ } octave_base_value * -octave_struct::try_narrowing_conversion (void) +octave_struct::try_narrowing_conversion () { octave_base_value *retval = nullptr; @@ -109,7 +109,7 @@ } static void -err_invalid_index_for_assignment (void) +err_invalid_index_for_assignment () { error ("invalid index for structure array assignment"); } @@ -571,7 +571,7 @@ } std::size_t -octave_struct::byte_size (void) const +octave_struct::byte_size () const { // Neglect the size of the fieldnames. @@ -1292,7 +1292,7 @@ } std::size_t -octave_scalar_struct::byte_size (void) const +octave_scalar_struct::byte_size () const { // Neglect the size of the fieldnames. @@ -1694,7 +1694,7 @@ } octave_value -octave_scalar_struct::to_array (void) +octave_scalar_struct::to_array () { return new octave_struct (octave_map (m_map)); } @@ -2019,7 +2019,7 @@ OCTAVE_NORETURN static void -invalid_cell2struct_fields_error (void) +invalid_cell2struct_fields_error () { error ("cell2struct: FIELDS must be a cell array of strings or a scalar string"); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-struct.h --- a/libinterp/octave-value/ov-struct.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-struct.h Tue Jan 24 17:19:44 2023 -0800 @@ -50,7 +50,7 @@ { public: - octave_struct (void) + octave_struct () : octave_base_value (), m_map () { } octave_struct (const octave_map& m) @@ -59,14 +59,14 @@ octave_struct (const octave_struct& s) : octave_base_value (), m_map (s.m_map) { } - ~octave_struct (void) = default; + ~octave_struct () = default; - octave_base_value * clone (void) const { return new octave_struct (*this); } - octave_base_value * empty_clone (void) const { return new octave_struct (); } + octave_base_value * clone () const { return new octave_struct (*this); } + octave_base_value * empty_clone () const { return new octave_struct (); } void break_closure_cycles (const std::shared_ptr& frame); - octave_base_value * try_narrowing_conversion (void); + octave_base_value * try_narrowing_conversion (); Cell dotref (const octave_value_list& idx, bool auto_add = false); @@ -91,7 +91,7 @@ const std::list& idx, const octave_value& rhs); - octave_value squeeze (void) const { return m_map.squeeze (); } + octave_value squeeze () const { return m_map.squeeze (); } octave_value permute (const Array& vec, bool inv = false) const { return m_map.permute (vec, inv); } @@ -99,18 +99,18 @@ octave_value do_index_op (const octave_value_list& idx, bool resize_ok = false); - dim_vector dims (void) const { return m_map.dims (); } + dim_vector dims () const { return m_map.dims (); } - std::size_t byte_size (void) const; + std::size_t byte_size () const; // This is the number of elements in each field. The total number // of elements is numel () * nfields (). - octave_idx_type numel (void) const + octave_idx_type numel () const { return m_map.numel (); } - octave_idx_type nfields (void) const { return m_map.nfields (); } + octave_idx_type nfields () const { return m_map.nfields (); } octave_value reshape (const dim_vector& new_dims) const { return m_map.reshape (new_dims); } @@ -118,17 +118,17 @@ octave_value resize (const dim_vector& dv, bool fill = false) const { octave_map tmap = m_map; tmap.resize (dv, fill); return tmap; } - bool is_defined (void) const { return true; } + bool is_defined () const { return true; } - bool is_constant (void) const { return true; } + bool is_constant () const { return true; } - bool isstruct (void) const { return true; } + bool isstruct () const { return true; } - builtin_type_t builtin_type (void) const { return btyp_struct; } + builtin_type_t builtin_type () const { return btyp_struct; } - octave_map map_value (void) const { return m_map; } + octave_map map_value () const { return m_map; } - string_vector map_keys (void) const { return m_map.fieldnames (); } + string_vector map_keys () const { return m_map.fieldnames (); } bool isfield (const std::string& field_name) const { return m_map.isfield (field_name); } @@ -178,7 +178,7 @@ { public: - octave_scalar_struct (void) + octave_scalar_struct () : octave_base_value (), m_map () { } octave_scalar_struct (const octave_scalar_map& m) @@ -190,11 +190,11 @@ octave_scalar_struct (const octave_scalar_struct& s) : octave_base_value (), m_map (s.m_map) { } - ~octave_scalar_struct (void) = default; + ~octave_scalar_struct () = default; - octave_base_value * clone (void) const + octave_base_value * clone () const { return new octave_scalar_struct (*this); } - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return new octave_scalar_struct (); } void break_closure_cycles (const std::shared_ptr& frame); @@ -218,7 +218,7 @@ const std::list& idx, const octave_value& rhs); - octave_value squeeze (void) const { return m_map; } + octave_value squeeze () const { return m_map; } octave_value permute (const Array& vec, bool inv = false) const { return octave_map (m_map).permute (vec, inv); } @@ -226,18 +226,18 @@ octave_value do_index_op (const octave_value_list& idx, bool resize_ok = false); - dim_vector dims (void) const { static dim_vector dv (1, 1); return dv; } + dim_vector dims () const { static dim_vector dv (1, 1); return dv; } - std::size_t byte_size (void) const; + std::size_t byte_size () const; // This is the number of elements in each field. The total number // of elements is numel () * nfields (). - octave_idx_type numel (void) const + octave_idx_type numel () const { return 1; } - octave_idx_type nfields (void) const { return m_map.nfields (); } + octave_idx_type nfields () const { return m_map.nfields (); } octave_value reshape (const dim_vector& new_dims) const { return octave_map (m_map).reshape (new_dims); } @@ -245,19 +245,19 @@ octave_value resize (const dim_vector& dv, bool fill = false) const { octave_map tmap = m_map; tmap.resize (dv, fill); return tmap; } - bool is_defined (void) const { return true; } + bool is_defined () const { return true; } - bool is_constant (void) const { return true; } + bool is_constant () const { return true; } - bool isstruct (void) const { return true; } + bool isstruct () const { return true; } - builtin_type_t builtin_type (void) const { return btyp_struct; } + builtin_type_t builtin_type () const { return btyp_struct; } - octave_map map_value (void) const { return m_map; } + octave_map map_value () const { return m_map; } - octave_scalar_map scalar_map_value (void) const { return m_map; } + octave_scalar_map scalar_map_value () const { return m_map; } - string_vector map_keys (void) const { return m_map.fieldnames (); } + string_vector map_keys () const { return m_map.fieldnames (); } bool isfield (const std::string& field_name) const { return m_map.isfield (field_name); } @@ -295,7 +295,7 @@ private: - octave_value to_array (void); + octave_value to_array (); DECLARE_OV_TYPEID_FUNCTIONS_AND_DATA }; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-typeinfo.cc --- a/libinterp/octave-value/ov-typeinfo.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-typeinfo.cc Tue Jan 24 17:19:44 2023 -0800 @@ -581,7 +581,7 @@ } string_vector -type_info::installed_type_names (void) const +type_info::installed_type_names () const { string_vector retval (m_num_types); @@ -592,7 +592,7 @@ } octave_scalar_map -type_info::unary_ops_map (void) const +type_info::unary_ops_map () const { octave_scalar_map retval; @@ -617,7 +617,7 @@ } octave_scalar_map -type_info::non_const_unary_ops_map (void) const +type_info::non_const_unary_ops_map () const { octave_scalar_map retval; @@ -642,7 +642,7 @@ } octave_scalar_map -type_info::binary_ops_map (void) const +type_info::binary_ops_map () const { octave_scalar_map retval; @@ -668,7 +668,7 @@ } octave_scalar_map -type_info::compound_binary_ops_map (void) const +type_info::compound_binary_ops_map () const { octave_scalar_map retval; @@ -695,7 +695,7 @@ } octave_scalar_map -type_info::assign_ops_map (void) const +type_info::assign_ops_map () const { octave_scalar_map retval; @@ -721,7 +721,7 @@ } octave_scalar_map -type_info::assignany_ops_map (void) const +type_info::assignany_ops_map () const { octave_scalar_map retval; @@ -746,7 +746,7 @@ } octave_scalar_map -type_info::installed_type_info (void) const +type_info::installed_type_info () const { octave_scalar_map retval; @@ -875,14 +875,14 @@ return type_info.lookup_widening_op (t, t_result); } -string_vector installed_type_names (void) +string_vector installed_type_names () { octave::type_info& type_info = octave::__get_type_info__ (); return type_info.installed_type_names (); } -octave_scalar_map installed_type_info (void) +octave_scalar_map installed_type_info () { octave::type_info& type_info = octave::__get_type_info__ (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-typeinfo.h --- a/libinterp/octave-value/ov-typeinfo.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-typeinfo.h Tue Jan 24 17:19:44 2023 -0800 @@ -75,7 +75,7 @@ type_info& operator = (const type_info&) = delete; - ~type_info (void) = default; + ~type_info () = default; // It is intentional that there is no install_type function. @@ -219,21 +219,21 @@ octave_base_value::type_conv_fcn lookup_widening_op (int, int); - string_vector installed_type_names (void) const; + string_vector installed_type_names () const; - octave_scalar_map installed_type_info (void) const; + octave_scalar_map installed_type_info () const; - octave_scalar_map unary_ops_map (void) const; + octave_scalar_map unary_ops_map () const; - octave_scalar_map non_const_unary_ops_map (void) const; + octave_scalar_map non_const_unary_ops_map () const; - octave_scalar_map binary_ops_map (void) const; + octave_scalar_map binary_ops_map () const; - octave_scalar_map compound_binary_ops_map (void) const; + octave_scalar_map compound_binary_ops_map () const; - octave_scalar_map assign_ops_map (void) const; + octave_scalar_map assign_ops_map () const; - octave_scalar_map assignany_ops_map (void) const; + octave_scalar_map assignany_ops_map () const; private: @@ -328,9 +328,9 @@ extern OCTINTERP_API octave_base_value::type_conv_fcn lookup_widening_op (int t, int t_result); -extern OCTINTERP_API string_vector installed_type_names (void); +extern OCTINTERP_API string_vector installed_type_names (); -extern OCTINTERP_API octave_scalar_map installed_type_info (void); +extern OCTINTERP_API octave_scalar_map installed_type_info (); OCTAVE_END_NAMESPACE(octave_value_typeinfo) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-usr-fcn.cc --- a/libinterp/octave-value/ov-usr-fcn.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-usr-fcn.cc Tue Jan 24 17:19:44 2023 -0800 @@ -64,7 +64,7 @@ // Whether to optimize subsasgn method calls. static bool Voptimize_subsasgn_calls = true; -octave_user_code::~octave_user_code (void) +octave_user_code::~octave_user_code () { // This function is no longer valid, so remove the pointer to it from // the corresponding scope. @@ -85,7 +85,7 @@ } void -octave_user_code::get_file_info (void) +octave_user_code::get_file_info () { m_file_info = new octave::file_info (m_file_name); @@ -128,13 +128,13 @@ } std::map -octave_user_code::subfunctions (void) const +octave_user_code::subfunctions () const { return std::map (); } octave_value -octave_user_code::dump (void) const +octave_user_code::dump () const { std::map m = {{ "scope_info", m_scope ? m_scope.dump () : "0x0" }, @@ -153,7 +153,7 @@ "user-defined script", "user-defined script"); -octave_user_script::octave_user_script (void) +octave_user_script::octave_user_script () : octave_user_code () { } @@ -228,7 +228,7 @@ m_cmd_list->mark_as_function_body (); } -octave_user_function::~octave_user_function (void) +octave_user_function::~octave_user_function () { delete m_param_list; delete m_ret_list; @@ -253,7 +253,7 @@ // information (yet). void -octave_user_function::maybe_relocate_end_internal (void) +octave_user_function::maybe_relocate_end_internal () { if (m_cmd_list && ! m_cmd_list->empty ()) { @@ -289,7 +289,7 @@ } void -octave_user_function::maybe_relocate_end (void) +octave_user_function::maybe_relocate_end () { std::map fcns = subfunctions (); @@ -314,7 +314,7 @@ } std::string -octave_user_function::profiler_name (void) const +octave_user_function::profiler_name () const { std::ostringstream result; @@ -337,7 +337,7 @@ } void -octave_user_function::mark_as_system_fcn_file (void) +octave_user_function::mark_as_system_fcn_file () { if (! m_file_name.empty ()) { @@ -367,19 +367,19 @@ } void -octave_user_function::erase_subfunctions (void) +octave_user_function::erase_subfunctions () { m_scope.erase_subfunctions (); } bool -octave_user_function::takes_varargs (void) const +octave_user_function::takes_varargs () const { return (m_param_list && m_param_list->takes_varargs ()); } bool -octave_user_function::takes_var_return (void) const +octave_user_function::takes_var_return () const { return (m_ret_list && m_ret_list->takes_varargs ()); } @@ -393,19 +393,19 @@ } void -octave_user_function::lock_subfunctions (void) +octave_user_function::lock_subfunctions () { m_scope.lock_subfunctions (); } void -octave_user_function::unlock_subfunctions (void) +octave_user_function::unlock_subfunctions () { m_scope.unlock_subfunctions (); } std::map -octave_user_function::subfunctions (void) const +octave_user_function::subfunctions () const { return m_scope.subfunctions (); } @@ -442,7 +442,7 @@ } bool -octave_user_function::has_subfunctions (void) const +octave_user_function::has_subfunctions () const { return m_scope.has_subfunctions (); } @@ -454,7 +454,7 @@ } std::list -octave_user_function::subfunction_names (void) const +octave_user_function::subfunction_names () const { return m_scope.subfunction_names (); } @@ -502,7 +502,7 @@ } octave::tree_expression * -octave_user_function::special_expr (void) +octave_user_function::special_expr () { panic_unless (is_special_expr ()); panic_if (m_cmd_list->length () != 1); @@ -512,7 +512,7 @@ } bool -octave_user_function::subsasgn_optimization_ok (void) +octave_user_function::subsasgn_optimization_ok () { bool retval = false; if (Voptimize_subsasgn_calls @@ -529,7 +529,7 @@ } std::string -octave_user_function::ctor_type_str (void) const +octave_user_function::ctor_type_str () const { std::string retval; @@ -556,7 +556,7 @@ } std::string -octave_user_function::method_type_str (void) const +octave_user_function::method_type_str () const { std::string retval; @@ -583,7 +583,7 @@ } octave_value -octave_user_function::dump (void) const +octave_user_function::dump () const { std::map m = {{ "user_code", octave_user_code::dump () }, @@ -621,7 +621,7 @@ } void -octave_user_function::restore_warning_states (void) +octave_user_function::restore_warning_states () { octave::interpreter& interp = octave::__get_interpreter__ (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov-usr-fcn.h --- a/libinterp/octave-value/ov-usr-fcn.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov-usr-fcn.h Tue Jan 24 17:19:44 2023 -0800 @@ -79,9 +79,9 @@ octave_user_code& operator = (const octave_user_code& f) = delete; - ~octave_user_code (void); + ~octave_user_code (); - bool is_user_code (void) const { return true; } + bool is_user_code () const { return true; } std::string get_code_line (std::size_t line); @@ -91,7 +91,7 @@ void cache_function_text (const std::string& text, const octave::sys::time& timestamp); - octave::symbol_scope scope (void) { return m_scope; } + octave::symbol_scope scope () { return m_scope; } void stash_fcn_file_name (const std::string& nm) { m_file_name = nm; } @@ -104,26 +104,26 @@ mark_fcn_file_up_to_date (t); } - std::string fcn_file_name (void) const { return m_file_name; } + std::string fcn_file_name () const { return m_file_name; } - octave::sys::time time_parsed (void) const { return m_t_parsed; } + octave::sys::time time_parsed () const { return m_t_parsed; } - octave::sys::time time_checked (void) const { return m_t_checked; } + octave::sys::time time_checked () const { return m_t_checked; } virtual octave_value find_subfunction (const std::string&) const { return octave_value (); } - virtual std::map subfunctions (void) const; + virtual std::map subfunctions () const; - octave::tree_statement_list * body (void) { return m_cmd_list; } + octave::tree_statement_list * body () { return m_cmd_list; } - octave_value dump (void) const; + octave_value dump () const; protected: - void get_file_info (void); + void get_file_info (); // Our symbol table scope. octave::symbol_scope m_scope; @@ -153,7 +153,7 @@ { public: - octave_user_script (void); + octave_user_script (); octave_user_script (const std::string& fnm, const std::string& nm, const octave::symbol_scope& scope = octave::symbol_scope (), @@ -170,7 +170,7 @@ octave_user_script& operator = (const octave_user_script& f) = delete; - ~octave_user_script (void) = default; + ~octave_user_script () = default; octave_function * function_value (bool = false) { return this; } @@ -181,7 +181,7 @@ // Scripts and user functions are both considered "scripts" because // they are written in Octave's scripting language. - bool is_user_script (void) const { return true; } + bool is_user_script () const { return true; } // We must overload the call method so that we call the proper // push_stack_frame method, which is overloaded for pointers to @@ -221,7 +221,7 @@ octave_user_function& operator = (const octave_user_function& fcn) = delete; - ~octave_user_function (void); + ~octave_user_function (); octave_function * function_value (bool = false) { return this; } @@ -239,8 +239,8 @@ m_location_column = col; } - int beginning_line (void) const { return m_location_line; } - int beginning_column (void) const { return m_location_column; } + int beginning_line () const { return m_location_line; } + int beginning_column () const { return m_location_column; } void stash_fcn_end_location (int line, int col) { @@ -248,10 +248,10 @@ m_end_location_column = col; } - int ending_line (void) const { return m_end_location_line; } - int ending_column (void) const { return m_end_location_column; } + int ending_line () const { return m_end_location_line; } + int ending_column () const { return m_end_location_column; } - void maybe_relocate_end (void); + void maybe_relocate_end (); void stash_parent_fcn_scope (const octave::symbol_scope& ps); @@ -259,68 +259,68 @@ void stash_trailing_comment (octave::comment_list *tc) { m_trail_comm = tc; } - std::string profiler_name (void) const; + std::string profiler_name () const; - std::string parent_fcn_name (void) const + std::string parent_fcn_name () const { octave::symbol_scope pscope = parent_fcn_scope (); return pscope.fcn_name (); } - octave::symbol_scope parent_fcn_scope (void) const + octave::symbol_scope parent_fcn_scope () const { return m_scope.parent_scope (); } - std::list parent_fcn_names (void) const + std::list parent_fcn_names () const { return m_scope.parent_fcn_names (); } - void mark_as_system_fcn_file (void); + void mark_as_system_fcn_file (); - bool is_system_fcn_file (void) const { return m_system_fcn_file; } + bool is_system_fcn_file () const { return m_system_fcn_file; } - bool is_user_function (void) const { return true; } + bool is_user_function () const { return true; } - void erase_subfunctions (void); + void erase_subfunctions (); - bool takes_varargs (void) const; + bool takes_varargs () const; - bool takes_var_return (void) const; + bool takes_var_return () const; void mark_as_private_function (const std::string& cname = ""); - void lock_subfunctions (void); + void lock_subfunctions (); - void unlock_subfunctions (void); + void unlock_subfunctions (); - std::map subfunctions (void) const; + std::map subfunctions () const; octave_value find_subfunction (const std::string& subfuns) const; - bool has_subfunctions (void) const; + bool has_subfunctions () const; void stash_subfunction_names (const std::list& names); - std::list subfunction_names (void) const; + std::list subfunction_names () const; octave_value_list all_va_args (const octave_value_list& args); void stash_function_name (const std::string& s) { m_name = s; } - void mark_as_subfunction (void) { m_subfunction = true; } + void mark_as_subfunction () { m_subfunction = true; } - bool is_subfunction (void) const { return m_subfunction; } + bool is_subfunction () const { return m_subfunction; } - void mark_as_inline_function (void) { m_inline_function = true; } + void mark_as_inline_function () { m_inline_function = true; } - bool is_inline_function (void) const { return m_inline_function; } + bool is_inline_function () const { return m_inline_function; } - void mark_as_anonymous_function (void) { m_anonymous_function = true; } + void mark_as_anonymous_function () { m_anonymous_function = true; } - bool is_anonymous_function (void) const { return m_anonymous_function; } + bool is_anonymous_function () const { return m_anonymous_function; } bool is_anonymous_function_of_class (const std::string& cname = "") const @@ -335,18 +335,18 @@ // If we are a special expression, then the function body consists of exactly // one expression. The expression's result is the return value of the // function. - bool is_special_expr (void) const + bool is_special_expr () const { return is_inline_function () || is_anonymous_function (); } - void mark_as_nested_function (void) { m_nested_function = true; } + void mark_as_nested_function () { m_nested_function = true; } - bool is_nested_function (void) const { return m_nested_function; } + bool is_nested_function () const { return m_nested_function; } - bool is_parent_function (void) const { return m_scope.is_parent (); } + bool is_parent_function () const { return m_scope.is_parent (); } - void mark_as_legacy_constructor (void) { m_class_constructor = legacy; } + void mark_as_legacy_constructor () { m_class_constructor = legacy; } bool is_legacy_constructor (const std::string& cname = "") const { @@ -354,7 +354,7 @@ ? (cname.empty () ? true : cname == dispatch_class ()) : false); } - void mark_as_classdef_constructor (void) { m_class_constructor = classdef; } + void mark_as_classdef_constructor () { m_class_constructor = classdef; } bool is_classdef_constructor (const std::string& cname = "") const { @@ -362,7 +362,7 @@ ? (cname.empty () ? true : cname == dispatch_class ()) : false); } - void mark_as_legacy_method (void) { m_class_method = legacy; } + void mark_as_legacy_method () { m_class_method = legacy; } bool is_legacy_method (const std::string& cname = "") const { @@ -370,7 +370,7 @@ ? (cname.empty () ? true : cname == dispatch_class ()) : false); } - void mark_as_classdef_method (void) { m_class_method = classdef; } + void mark_as_classdef_method () { m_class_method = classdef; } bool is_classdef_method (const std::string& cname = "") const { @@ -391,23 +391,23 @@ execute (octave::tree_evaluator& tw, int nargout = 0, const octave_value_list& args = octave_value_list ()); - octave::tree_parameter_list * parameter_list (void) { return m_param_list; } + octave::tree_parameter_list * parameter_list () { return m_param_list; } - octave::tree_parameter_list * return_list (void) { return m_ret_list; } + octave::tree_parameter_list * return_list () { return m_ret_list; } - octave::comment_list * leading_comment (void) { return m_lead_comm; } + octave::comment_list * leading_comment () { return m_lead_comm; } - octave::comment_list * trailing_comment (void) { return m_trail_comm; } + octave::comment_list * trailing_comment () { return m_trail_comm; } // If is_special_expr is true, retrieve the sigular expression that forms the // body. May be null (even if is_special_expr is true). - octave::tree_expression * special_expr (void); + octave::tree_expression * special_expr (); - bool subsasgn_optimization_ok (void); + bool subsasgn_optimization_ok (); void accept (octave::tree_walker& tw); - octave_value dump (void) const; + octave_value dump () const; private: @@ -418,8 +418,8 @@ classdef }; - std::string ctor_type_str (void) const; - std::string method_type_str (void) const; + std::string ctor_type_str () const; + std::string method_type_str () const; // List of arguments for this function. These are local variables. octave::tree_parameter_list *m_param_list; @@ -466,7 +466,7 @@ // Enum describing whether this function is a method for a class. class_method_type m_class_method; - void maybe_relocate_end_internal (void); + void maybe_relocate_end_internal (); void print_code_function_header (const std::string& prefix); @@ -475,7 +475,7 @@ // XXX FIXME (public) public: - void restore_warning_states (void); + void restore_warning_states (); DECLARE_OV_TYPEID_FUNCTIONS_AND_DATA }; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov.cc --- a/libinterp/octave-value/ov.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov.cc Tue Jan 24 17:19:44 2023 -0800 @@ -118,7 +118,7 @@ // Octave's value type. octave_base_value * -octave_value::nil_rep (void) +octave_value::nil_rep () { static octave_base_value nr; return &nr; @@ -1226,7 +1226,7 @@ } octave_base_value * -octave_value::clone (void) const +octave_value::clone () const { return m_rep->clone (); } @@ -1259,7 +1259,7 @@ } void -octave_value::maybe_mutate (void) +octave_value::maybe_mutate () { octave_base_value *tmp = m_rep->try_narrowing_conversion (); @@ -1694,7 +1694,7 @@ // unresolved const issues that prevent that solution from working. std::string -octave_value::get_dims_str (void) const +octave_value::get_dims_str () const { octave_value tmp = *this; @@ -1709,7 +1709,7 @@ } octave_idx_type -octave_value::length (void) const +octave_value::length () const { octave_idx_type retval = 0; @@ -1773,19 +1773,19 @@ } Cell -octave_value::cell_value (void) const +octave_value::cell_value () const { return m_rep->cell_value (); } octave_map -octave_value::map_value (void) const +octave_value::map_value () const { return m_rep->map_value (); } octave_scalar_map -octave_value::scalar_map_value (void) const +octave_value::scalar_map_value () const { return m_rep->scalar_map_value (); } @@ -1827,7 +1827,7 @@ } octave_value_list -octave_value::list_value (void) const +octave_value::list_value () const { return m_rep->list_value (); } @@ -2267,7 +2267,7 @@ #undef XVALUE_EXTRACTOR octave_value -octave_value::storable_value (void) const +octave_value::storable_value () const { octave_value retval = *this; if (isnull ()) @@ -2283,7 +2283,7 @@ } void -octave_value::make_storable_value (void) +octave_value::make_storable_value () { if (isnull ()) { @@ -2306,7 +2306,7 @@ } float_display_format -octave_value::get_edit_display_format (void) const +octave_value::get_edit_display_format () const { return m_rep->get_edit_display_format (); } @@ -2918,7 +2918,7 @@ } OCTAVE_NORETURN static void - err_cat_op_conv (void) + err_cat_op_conv () { error ("type conversion failed for concatenation operator"); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ov.h --- a/libinterp/octave-value/ov.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ov.h Tue Jan 24 17:19:44 2023 -0800 @@ -166,7 +166,7 @@ enum magic_colon { magic_colon_t }; - octave_value (void) + octave_value () : m_rep (nil_rep ()) { m_rep->count++; @@ -357,14 +357,14 @@ // This should only be called for derived types. - OCTINTERP_API octave_base_value * clone (void) const; + OCTINTERP_API octave_base_value * clone () const; - octave_base_value * empty_clone (void) const + octave_base_value * empty_clone () const { return m_rep->empty_clone (); } // Delete the representation of this constant if the count drops to zero. - ~octave_value (void) + ~octave_value () { // Because we define a move constructor and a move assignment // operator, rep may be a nullptr here. We should only need to @@ -374,7 +374,7 @@ delete m_rep; } - void make_unique (void) + void make_unique () { if (m_rep->count > 1) { @@ -443,43 +443,43 @@ return *this; } - octave_idx_type get_count (void) const { return m_rep->count; } + octave_idx_type get_count () const { return m_rep->count; } - octave_base_value::type_conv_info numeric_conversion_function (void) const + octave_base_value::type_conv_info numeric_conversion_function () const { return m_rep->numeric_conversion_function (); } - octave_base_value::type_conv_info numeric_demotion_function (void) const + octave_base_value::type_conv_info numeric_demotion_function () const { return m_rep->numeric_demotion_function (); } - OCTINTERP_API void maybe_mutate (void); + OCTINTERP_API void maybe_mutate (); - octave_value squeeze (void) const + octave_value squeeze () const { return m_rep->squeeze (); } // The result of full(). - octave_value full_value (void) const + octave_value full_value () const { return m_rep->full_value (); } // Type conversions. - octave_value as_double (void) const { return m_rep->as_double (); } - octave_value as_single (void) const { return m_rep->as_single (); } + octave_value as_double () const { return m_rep->as_double (); } + octave_value as_single () const { return m_rep->as_single (); } - octave_value as_int8 (void) const { return m_rep->as_int8 (); } - octave_value as_int16 (void) const { return m_rep->as_int16 (); } - octave_value as_int32 (void) const { return m_rep->as_int32 (); } - octave_value as_int64 (void) const { return m_rep->as_int64 (); } + octave_value as_int8 () const { return m_rep->as_int8 (); } + octave_value as_int16 () const { return m_rep->as_int16 (); } + octave_value as_int32 () const { return m_rep->as_int32 (); } + octave_value as_int64 () const { return m_rep->as_int64 (); } - octave_value as_uint8 (void) const { return m_rep->as_uint8 (); } - octave_value as_uint16 (void) const { return m_rep->as_uint16 (); } - octave_value as_uint32 (void) const { return m_rep->as_uint32 (); } - octave_value as_uint64 (void) const { return m_rep->as_uint64 (); } + octave_value as_uint8 () const { return m_rep->as_uint8 (); } + octave_value as_uint16 () const { return m_rep->as_uint16 (); } + octave_value as_uint32 () const { return m_rep->as_uint32 (); } + octave_value as_uint64 () const { return m_rep->as_uint64 (); } - octave_base_value * try_narrowing_conversion (void) + octave_base_value * try_narrowing_conversion () { return m_rep->try_narrowing_conversion (); } // Close to dims (), but can be overloaded for classes. - Matrix size (void) + Matrix size () { return m_rep->size (); } // FIXME: should this function be deprecated and removed? It supports @@ -545,35 +545,35 @@ // Size. - dim_vector dims (void) const { return m_rep->dims (); } + dim_vector dims () const { return m_rep->dims (); } - OCTINTERP_API std::string get_dims_str (void) const; + OCTINTERP_API std::string get_dims_str () const; - octave_idx_type rows (void) const { return m_rep->rows (); } + octave_idx_type rows () const { return m_rep->rows (); } - octave_idx_type columns (void) const { return m_rep->columns (); } + octave_idx_type columns () const { return m_rep->columns (); } - OCTINTERP_API octave_idx_type length (void) const; + OCTINTERP_API octave_idx_type length () const; - int ndims (void) const { return m_rep->ndims (); } + int ndims () const { return m_rep->ndims (); } - bool all_zero_dims (void) const { return dims ().all_zero (); } + bool all_zero_dims () const { return dims ().all_zero (); } // Are the dimensions of this constant zero by zero? - bool is_zero_by_zero (void) const + bool is_zero_by_zero () const { return (ndims () == 2 && rows () == 0 && columns () == 0); } - octave_idx_type numel (void) const + octave_idx_type numel () const { return m_rep->numel (); } - std::size_t byte_size (void) const + std::size_t byte_size () const { return m_rep->byte_size (); } - octave_idx_type nnz (void) const { return m_rep->nnz (); } + octave_idx_type nnz () const { return m_rep->nnz (); } - octave_idx_type nzmax (void) const { return m_rep->nzmax (); } + octave_idx_type nzmax () const { return m_rep->nzmax (); } - octave_idx_type nfields (void) const { return m_rep->nfields (); } + octave_idx_type nfields () const { return m_rep->nfields (); } octave_value reshape (const dim_vector& dv) const { return m_rep->reshape (dv); } @@ -587,7 +587,7 @@ octave_value resize (const dim_vector& dv, bool fill = false) const { return m_rep->resize (dv, fill);} - MatrixType matrix_type (void) const + MatrixType matrix_type () const { return m_rep->matrix_type (); } MatrixType matrix_type (const MatrixType& typ) const @@ -596,94 +596,94 @@ // Does this constant have a type? Both of these are provided since it is // sometimes more natural to write is_undefined() instead of ! is_defined(). - bool is_defined (void) const + bool is_defined () const { return m_rep->is_defined (); } - bool is_undefined (void) const + bool is_undefined () const { return ! is_defined (); } - bool is_legacy_object (void) const + bool is_legacy_object () const { return m_rep->is_legacy_object (); } - bool isempty (void) const + bool isempty () const { return m_rep->isempty (); } - bool iscell (void) const + bool iscell () const { return m_rep->iscell (); } - bool iscellstr (void) const + bool iscellstr () const { return m_rep->iscellstr (); } - bool is_real_scalar (void) const + bool is_real_scalar () const { return m_rep->is_real_scalar (); } - bool is_real_matrix (void) const + bool is_real_matrix () const { return m_rep->is_real_matrix (); } - bool is_complex_scalar (void) const + bool is_complex_scalar () const { return m_rep->is_complex_scalar (); } - bool is_complex_matrix (void) const + bool is_complex_matrix () const { return m_rep->is_complex_matrix (); } - bool is_bool_scalar (void) const + bool is_bool_scalar () const { return m_rep->is_bool_scalar (); } - bool is_bool_matrix (void) const + bool is_bool_matrix () const { return m_rep->is_bool_matrix (); } - bool is_char_matrix (void) const + bool is_char_matrix () const { return m_rep->is_char_matrix (); } - bool is_diag_matrix (void) const + bool is_diag_matrix () const { return m_rep->is_diag_matrix (); } - bool is_perm_matrix (void) const + bool is_perm_matrix () const { return m_rep->is_perm_matrix (); } - bool is_string (void) const + bool is_string () const { return m_rep->is_string (); } - bool is_sq_string (void) const + bool is_sq_string () const { return m_rep->is_sq_string (); } - bool is_dq_string (void) const + bool is_dq_string () const { return m_rep->is_string () && ! m_rep->is_sq_string (); } - bool is_range (void) const + bool is_range () const { return m_rep->is_range (); } - bool isstruct (void) const + bool isstruct () const { return m_rep->isstruct (); } - bool is_classdef_meta (void) const + bool is_classdef_meta () const { return m_rep->is_classdef_meta (); } - bool is_classdef_object (void) const + bool is_classdef_object () const { return m_rep->is_classdef_object (); } - bool is_classdef_superclass_ref (void) const + bool is_classdef_superclass_ref () const { return m_rep->is_classdef_superclass_ref (); } - bool is_package (void) const + bool is_package () const { return m_rep->is_package (); } - bool isobject (void) const + bool isobject () const { return m_rep->isobject (); } - bool isjava (void) const + bool isjava () const { return m_rep->isjava (); } - bool is_cs_list (void) const + bool is_cs_list () const { return m_rep->is_cs_list (); } - bool is_magic_colon (void) const + bool is_magic_colon () const { return m_rep->is_magic_colon (); } - bool is_magic_int (void) const + bool is_magic_int () const { return m_rep->is_magic_int (); } - bool isnull (void) const + bool isnull () const { return m_rep->isnull (); } // Are any or all of the elements in this constant nonzero? @@ -694,119 +694,119 @@ octave_value any (int dim = 0) const { return m_rep->any (dim); } - builtin_type_t builtin_type (void) const + builtin_type_t builtin_type () const { return m_rep->builtin_type (); } // Floating point types. - bool is_double_type (void) const + bool is_double_type () const { return m_rep->is_double_type (); } - bool is_single_type (void) const + bool is_single_type () const { return m_rep->is_single_type (); } - bool isfloat (void) const + bool isfloat () const { return m_rep->isfloat (); } // Integer types. - bool is_int8_type (void) const + bool is_int8_type () const { return m_rep->is_int8_type (); } - bool is_int16_type (void) const + bool is_int16_type () const { return m_rep->is_int16_type (); } - bool is_int32_type (void) const + bool is_int32_type () const { return m_rep->is_int32_type (); } - bool is_int64_type (void) const + bool is_int64_type () const { return m_rep->is_int64_type (); } - bool is_uint8_type (void) const + bool is_uint8_type () const { return m_rep->is_uint8_type (); } - bool is_uint16_type (void) const + bool is_uint16_type () const { return m_rep->is_uint16_type (); } - bool is_uint32_type (void) const + bool is_uint32_type () const { return m_rep->is_uint32_type (); } - bool is_uint64_type (void) const + bool is_uint64_type () const { return m_rep->is_uint64_type (); } - bool isinteger (void) const + bool isinteger () const { return m_rep->isinteger (); } // Other type stuff. - bool islogical (void) const + bool islogical () const { return m_rep->islogical (); } - bool isreal (void) const + bool isreal () const { return m_rep->isreal (); } - bool iscomplex (void) const + bool iscomplex () const { return m_rep->iscomplex (); } - bool is_scalar_type (void) const + bool is_scalar_type () const { return m_rep->is_scalar_type (); } - bool is_matrix_type (void) const + bool is_matrix_type () const { return m_rep->is_matrix_type (); } - bool isnumeric (void) const + bool isnumeric () const { return m_rep->isnumeric (); } - bool issparse (void) const + bool issparse () const { return m_rep->issparse (); } // Does this constant correspond to a truth value? - bool is_true (void) const + bool is_true () const { return m_rep->is_true (); } // Do two constants match (in a switch statement)? bool is_equal (const octave_value&) const; - bool is_constant (void) const + bool is_constant () const { return m_rep->is_constant (); } - bool is_function_handle (void) const + bool is_function_handle () const { return m_rep->is_function_handle (); } - bool is_anonymous_function (void) const + bool is_anonymous_function () const { return m_rep->is_anonymous_function (); } - bool is_inline_function (void) const + bool is_inline_function () const { return m_rep->is_inline_function (); } - bool is_function (void) const + bool is_function () const { return m_rep->is_function (); } - bool is_user_script (void) const + bool is_user_script () const { return m_rep->is_user_script (); } - bool is_user_function (void) const + bool is_user_function () const { return m_rep->is_user_function (); } - bool is_user_code (void) const + bool is_user_code () const { return m_rep->is_user_code (); } - bool is_builtin_function (void) const + bool is_builtin_function () const { return m_rep->is_builtin_function (); } - bool is_dld_function (void) const + bool is_dld_function () const { return m_rep->is_dld_function (); } - bool is_mex_function (void) const + bool is_mex_function () const { return m_rep->is_mex_function (); } - void erase_subfunctions (void) { m_rep->erase_subfunctions (); } + void erase_subfunctions () { m_rep->erase_subfunctions (); } // Values. - octave_value eval (void) { return *this; } + octave_value eval () { return *this; } short int short_value (bool req_int = false, bool frc_str_conv = false) const @@ -927,55 +927,55 @@ float_complex_diag_matrix_value (bool force = false) const { return m_rep->float_complex_diag_matrix_value (force); } - PermMatrix perm_matrix_value (void) const + PermMatrix perm_matrix_value () const { return m_rep->perm_matrix_value (); } - octave_int8 int8_scalar_value (void) const + octave_int8 int8_scalar_value () const { return m_rep->int8_scalar_value (); } - octave_int16 int16_scalar_value (void) const + octave_int16 int16_scalar_value () const { return m_rep->int16_scalar_value (); } - octave_int32 int32_scalar_value (void) const + octave_int32 int32_scalar_value () const { return m_rep->int32_scalar_value (); } - octave_int64 int64_scalar_value (void) const + octave_int64 int64_scalar_value () const { return m_rep->int64_scalar_value (); } - octave_uint8 uint8_scalar_value (void) const + octave_uint8 uint8_scalar_value () const { return m_rep->uint8_scalar_value (); } - octave_uint16 uint16_scalar_value (void) const + octave_uint16 uint16_scalar_value () const { return m_rep->uint16_scalar_value (); } - octave_uint32 uint32_scalar_value (void) const + octave_uint32 uint32_scalar_value () const { return m_rep->uint32_scalar_value (); } - octave_uint64 uint64_scalar_value (void) const + octave_uint64 uint64_scalar_value () const { return m_rep->uint64_scalar_value (); } - int8NDArray int8_array_value (void) const + int8NDArray int8_array_value () const { return m_rep->int8_array_value (); } - int16NDArray int16_array_value (void) const + int16NDArray int16_array_value () const { return m_rep->int16_array_value (); } - int32NDArray int32_array_value (void) const + int32NDArray int32_array_value () const { return m_rep->int32_array_value (); } - int64NDArray int64_array_value (void) const + int64NDArray int64_array_value () const { return m_rep->int64_array_value (); } - uint8NDArray uint8_array_value (void) const + uint8NDArray uint8_array_value () const { return m_rep->uint8_array_value (); } - uint16NDArray uint16_array_value (void) const + uint16NDArray uint16_array_value () const { return m_rep->uint16_array_value (); } - uint32NDArray uint32_array_value (void) const + uint32NDArray uint32_array_value () const { return m_rep->uint32_array_value (); } - uint64NDArray uint64_array_value (void) const + uint64NDArray uint64_array_value () const { return m_rep->uint64_array_value (); } std::string string_value (bool force = false) const @@ -984,64 +984,64 @@ string_vector string_vector_value (bool pad = false) const { return m_rep->string_vector_value (pad); } - Cell cell_value (void) const; + Cell cell_value () const; - Array cellstr_value (void) const + Array cellstr_value () const { return m_rep->cellstr_value (); } - octave::range range_value (void) const + octave::range range_value () const { return m_rep->range_value (); } // For now, disable all but range. #if 0 - octave::range float_range_value (void) const + octave::range float_range_value () const { return m_rep->float_range_value (); } - octave::range int8_range_value (void) const + octave::range int8_range_value () const { return m_rep->int8_range_value (); } - octave::range int16_range_value (void) const + octave::range int16_range_value () const { return m_rep->int16_range_value (); } - octave::range int32_range_value (void) const + octave::range int32_range_value () const { return m_rep->int32_range_value (); } - octave::range int64_range_value (void) const + octave::range int64_range_value () const { return m_rep->int64_range_value (); } - octave::range uint8_range_value (void) const + octave::range uint8_range_value () const { return m_rep->uint8_range_value (); } - octave::range uint16_range_value (void) const + octave::range uint16_range_value () const { return m_rep->uint16_range_value (); } - octave::range uint32_range_value (void) const + octave::range uint32_range_value () const { return m_rep->uint32_range_value (); } - octave::range uint64_range_value (void) const + octave::range uint64_range_value () const { return m_rep->uint64_range_value (); } #endif - OCTINTERP_API octave_map map_value (void) const; + OCTINTERP_API octave_map map_value () const; - OCTINTERP_API octave_scalar_map scalar_map_value (void) const; + OCTINTERP_API octave_scalar_map scalar_map_value () const; - string_vector map_keys (void) const + string_vector map_keys () const { return m_rep->map_keys (); } bool isfield (const std::string& field_name) const { return m_rep->isfield (field_name); } - std::size_t nparents (void) const + std::size_t nparents () const { return m_rep->nparents (); } - std::list parent_class_name_list (void) const + std::list parent_class_name_list () const { return m_rep->parent_class_name_list (); } - string_vector parent_class_names (void) const + string_vector parent_class_names () const { return m_rep->parent_class_names (); } octave_base_value * @@ -1068,7 +1068,7 @@ OCTINTERP_API octave_fcn_handle * fcn_handle_value (bool silent = false) const; - OCTINTERP_API octave_value_list list_value (void) const; + OCTINTERP_API octave_value_list list_value () const; OCTINTERP_API ColumnVector column_vector_value (bool frc_str_conv = false, @@ -1355,19 +1355,19 @@ // Possibly economize a lazy-indexed value. - void maybe_economize (void) + void maybe_economize () { m_rep->maybe_economize (); } // The following two hook conversions are called on any octave_value prior to // storing it to a "permanent" location, like a named variable, a cell or a // struct component, or a return value of a function. - OCTINTERP_API octave_value storable_value (void) const; + OCTINTERP_API octave_value storable_value () const; // Ditto, but in place, i.e., equivalent to *this = this->storable_value (), // but possibly more efficient. - OCTINTERP_API void make_storable_value (void); + OCTINTERP_API void make_storable_value (); // FIXME: These should probably be private. // Conversions. If a user of this class wants a certain kind of constant, @@ -1381,10 +1381,10 @@ convert_to_str_internal (bool pad, bool force, char type) const { return m_rep->convert_to_str_internal (pad, force, type); } - void convert_to_row_or_column_vector (void) + void convert_to_row_or_column_vector () { m_rep->convert_to_row_or_column_vector (); } - bool print_as_scalar (void) const + bool print_as_scalar () const { return m_rep->print_as_scalar (); } void print (std::ostream& os, bool pr_as_read_syntax = false) @@ -1401,7 +1401,7 @@ void short_disp (std::ostream& os) const { m_rep->short_disp (os); } - OCTINTERP_API float_display_format get_edit_display_format (void) const; + OCTINTERP_API float_display_format get_edit_display_format () const; std::string edit_display (const float_display_format& fmt, octave_idx_type i, octave_idx_type j) const @@ -1409,11 +1409,11 @@ return m_rep->edit_display (fmt, i, j); } - int type_id (void) const { return m_rep->type_id (); } + int type_id () const { return m_rep->type_id (); } - std::string type_name (void) const { return m_rep->type_name (); } + std::string type_name () const { return m_rep->type_name (); } - std::string class_name (void) const { return m_rep->class_name (); } + std::string class_name () const { return m_rep->class_name (); } // Unary operations that are member functions. There are also some // non-member functions for unary and binary operations declared @@ -1425,7 +1425,7 @@ non_const_unary_op (unary_op op, const std::string& type, const std::list& idx); - const octave_base_value& get_rep (void) const { return *m_rep; } + const octave_base_value& get_rep () const { return *m_rep; } bool is_copy_of (const octave_value& val) const { return m_rep == val.m_rep; } @@ -1453,7 +1453,7 @@ oct_data_conv::data_type output_type, int skip, octave::mach_info::float_format flt_fmt) const; - octave_base_value * internal_rep (void) const { return m_rep; } + octave_base_value * internal_rep () const { return m_rep; } // These functions exist to support the MEX interface. // You should not use them anywhere else. @@ -1462,13 +1462,13 @@ mex_get_data (mxClassID class_id = mxUNKNOWN_CLASS, mxComplexity complexity = mxREAL) const; - const octave_idx_type * mex_get_ir (void) const + const octave_idx_type * mex_get_ir () const { return m_rep->mex_get_ir (); } const octave_idx_type * - mex_get_jc (void) const + mex_get_jc () const { return m_rep->mex_get_jc (); } @@ -1497,18 +1497,18 @@ sortmode is_sorted_rows (sortmode mode = UNSORTED) const { return m_rep->is_sorted_rows (mode); } - void lock (void) { m_rep->lock (); } + void lock () { m_rep->lock (); } - void unlock (void) { m_rep->unlock (); } + void unlock () { m_rep->unlock (); } - bool islocked (void) const { return m_rep->islocked (); } + bool islocked () const { return m_rep->islocked (); } - void call_object_destructor (void) { return m_rep->call_object_destructor (); } + void call_object_destructor () { return m_rep->call_object_destructor (); } - octave_value dump (void) const { return m_rep->dump (); } + octave_value dump () const { return m_rep->dump (); } #define MAPPER_FORWARD(F) \ - octave_value F (void) const \ + octave_value F () const \ { \ return m_rep->map (octave_base_value::umap_ ## F); \ } @@ -1615,7 +1615,7 @@ private: - static OCTINTERP_API octave_base_value * nil_rep (void); + static OCTINTERP_API octave_base_value * nil_rep (); OCTINTERP_API assign_op unary_op_to_assign_op (unary_op op); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ovl.cc --- a/libinterp/octave-value/ovl.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ovl.cc Tue Jan 24 17:19:44 2023 -0800 @@ -121,7 +121,7 @@ } octave_value_list& -octave_value_list::reverse (void) +octave_value_list::reverse () { octave_idx_type n = length (); @@ -173,7 +173,7 @@ } bool -octave_value_list::all_strings_p (void) const +octave_value_list::all_strings_p () const { octave_idx_type n = length (); @@ -185,7 +185,7 @@ } bool -octave_value_list::all_scalars (void) const +octave_value_list::all_scalars () const { octave_idx_type n = length (); @@ -200,7 +200,7 @@ } bool -octave_value_list::any_cell (void) const +octave_value_list::any_cell () const { octave_idx_type n = length (); @@ -212,7 +212,7 @@ } bool -octave_value_list::has_magic_colon (void) const +octave_value_list::has_magic_colon () const { octave_idx_type n = length (); @@ -274,7 +274,7 @@ } void -octave_value_list::make_storable_values (void) +octave_value_list::make_storable_values () { octave_idx_type len = length (); const std::vector& cdata = m_data; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave-value/ovl.h --- a/libinterp/octave-value/ovl.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave-value/ovl.h Tue Jan 24 17:19:44 2023 -0800 @@ -44,7 +44,7 @@ { public: - octave_value_list (void) = default; + octave_value_list () = default; explicit octave_value_list (octave_idx_type n) : m_data (n), m_names () { } @@ -81,13 +81,13 @@ octave_value_list (const std::list&); octave_value_list (const std::list&); - ~octave_value_list (void) = default; + ~octave_value_list () = default; octave_value_list& operator = (const octave_value_list& obj) = default; octave_value_list& operator = (octave_value_list&& obj) = default; - Array array_value (void) const + Array array_value () const { Array retval; @@ -102,7 +102,7 @@ return retval; } - Cell cell_value (void) const { return array_value (); } + Cell cell_value () const { return array_value (); } // Assignment will resize on range errors. @@ -110,9 +110,9 @@ const octave_value& operator () (octave_idx_type n) const { return elem (n); } - octave_idx_type length (void) const { return m_data.size (); } + octave_idx_type length () const { return m_data.size (); } - bool empty (void) const { return length () == 0; } + bool empty () const { return length () == 0; } void resize (octave_idx_type n, const octave_value& rfv = octave_value ()) { @@ -125,7 +125,7 @@ octave_value_list& append (const octave_value_list& lst); - octave_value_list& reverse (void); + octave_value_list& reverse (); octave_value_list slice (octave_idx_type offset, octave_idx_type len, bool tags = false) const @@ -152,25 +152,25 @@ splice (octave_idx_type offset, octave_idx_type len, const octave_value_list& lst = octave_value_list ()) const; - bool all_strings_p (void) const; + bool all_strings_p () const; - bool all_scalars (void) const; + bool all_scalars () const; - bool any_cell (void) const; + bool any_cell () const; - bool has_magic_colon (void) const; + bool has_magic_colon () const; string_vector make_argv (const std::string& = "") const; void stash_name_tags (const string_vector& nm) { m_names = nm; } - string_vector name_tags (void) const { return m_names; } + string_vector name_tags () const { return m_names; } - void make_storable_values (void); + void make_storable_values (); octave_value& xelem (octave_idx_type i) { return m_data[i]; } - void clear (void) { m_data.clear (); } + void clear () { m_data.clear (); } private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave.cc --- a/libinterp/octave.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave.cc Tue Jan 24 17:19:44 2023 -0800 @@ -56,7 +56,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) -cmdline_options::cmdline_options (void) +cmdline_options::cmdline_options () { m_all_args.resize (1); m_all_args[0] = ""; @@ -239,7 +239,7 @@ argc-octave_optind_wrapper ()); } -octave_value cmdline_options::as_octave_value (void) const +octave_value cmdline_options::as_octave_value () const { octave_scalar_map m; @@ -295,7 +295,7 @@ // an explicit definition of the destructor here is much simpler than // including the full declaration of interpreter in the // octave.h header file. -application::~application (void) { } +application::~application () { } void application::set_program_names (const std::string& pname) @@ -324,25 +324,25 @@ } } -bool application::forced_interactive (void) +bool application::forced_interactive () { return s_instance ? s_instance->m_options.forced_interactive () : false; } // Provided for convenience. Will be removed once we eliminate the // old terminal widget. -bool application::experimental_terminal_widget (void) const +bool application::experimental_terminal_widget () const { return (s_instance ? s_instance->m_options.experimental_terminal_widget () : false); } -bool application::interpreter_initialized (void) +bool application::interpreter_initialized () { return m_interpreter ? m_interpreter->initialized () : false; } -interpreter& application::create_interpreter (void) +interpreter& application::create_interpreter () { if (! m_interpreter) m_interpreter = std::unique_ptr (new interpreter (this)); @@ -350,23 +350,23 @@ return *m_interpreter; } -void application::initialize_interpreter (void) +void application::initialize_interpreter () { if (m_interpreter) m_interpreter->initialize (); } -int application::execute_interpreter (void) +int application::execute_interpreter () { return m_interpreter ? m_interpreter->execute () : -1; } -void application::delete_interpreter (void) +void application::delete_interpreter () { m_interpreter.reset (); } -void application::init (void) +void application::init () { if (s_instance) throw std::runtime_error @@ -420,7 +420,7 @@ sysdep_init (); } -int cli_application::execute (void) +int cli_application::execute () { interpreter& interp = create_interpreter (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/octave.h --- a/libinterp/octave.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/octave.h Tue Jan 24 17:19:44 2023 -0800 @@ -44,7 +44,7 @@ { public: - cmdline_options (void); + cmdline_options (); cmdline_options (int argc, char **argv); @@ -52,41 +52,41 @@ cmdline_options& operator = (const cmdline_options&) = default; - int sys_argc (void) const { return m_all_args.numel (); } - char ** sys_argv (void) const { return m_all_args.c_str_vec (); } + int sys_argc () const { return m_all_args.numel (); } + char ** sys_argv () const { return m_all_args.c_str_vec (); } - bool echo_commands (void) const { return m_echo_commands; } + bool echo_commands () const { return m_echo_commands; } - bool experimental_terminal_widget (void) const + bool experimental_terminal_widget () const { return m_experimental_terminal_widget; } - bool forced_interactive (void) const { return m_forced_interactive; } - bool forced_line_editing (void) const { return m_forced_line_editing; } - bool gui (void) const { return m_gui; } - bool inhibit_startup_message (void) const + bool forced_interactive () const { return m_forced_interactive; } + bool forced_line_editing () const { return m_forced_line_editing; } + bool gui () const { return m_gui; } + bool inhibit_startup_message () const { return m_inhibit_startup_message; } - bool line_editing (void) const { return m_line_editing; } + bool line_editing () const { return m_line_editing; } - bool no_window_system (void) const { return m_no_window_system; } - bool persist (void) const { return m_persist; } - bool read_history_file (void) const { return m_read_history_file; } - bool read_init_files (void) const { return m_read_init_files; } - bool read_site_files (void) const { return m_read_site_files; } - bool server (void) const { return m_server; } - bool set_initial_path (void) const { return m_set_initial_path; } - bool traditional (void) const { return m_traditional; } - bool verbose_flag (void) const { return m_verbose_flag; } - std::string code_to_eval (void) const { return m_code_to_eval; } - std::list command_line_path (void) const + bool no_window_system () const { return m_no_window_system; } + bool persist () const { return m_persist; } + bool read_history_file () const { return m_read_history_file; } + bool read_init_files () const { return m_read_init_files; } + bool read_site_files () const { return m_read_site_files; } + bool server () const { return m_server; } + bool set_initial_path () const { return m_set_initial_path; } + bool traditional () const { return m_traditional; } + bool verbose_flag () const { return m_verbose_flag; } + std::string code_to_eval () const { return m_code_to_eval; } + std::list command_line_path () const { return m_command_line_path; } - std::string docstrings_file (void) const { return m_docstrings_file; } - std::string doc_cache_file (void) const { return m_doc_cache_file; } - std::string exec_path (void) const { return m_exec_path; } - std::string image_path (void) const { return m_image_path; } - std::string info_file (void) const { return m_info_file; } - std::string info_program (void) const { return m_info_program; } - std::string texi_macros_file (void) const {return m_texi_macros_file; } - string_vector all_args (void) const { return m_all_args; } - string_vector remaining_args (void) const { return m_remaining_args; } + std::string docstrings_file () const { return m_docstrings_file; } + std::string doc_cache_file () const { return m_doc_cache_file; } + std::string exec_path () const { return m_exec_path; } + std::string image_path () const { return m_image_path; } + std::string info_file () const { return m_info_file; } + std::string info_program () const { return m_info_program; } + std::string texi_macros_file () const {return m_texi_macros_file; } + string_vector all_args () const { return m_all_args; } + string_vector remaining_args () const { return m_remaining_args; } void echo_commands (bool arg) { m_echo_commands = arg; } @@ -120,7 +120,7 @@ void all_args (const string_vector& arg) { m_all_args = arg; } void remaining_args (const string_vector& arg) { m_remaining_args = arg; } - octave_value as_octave_value (void) const; + octave_value as_octave_value () const; private: @@ -255,36 +255,36 @@ application& operator = (const application&) = delete; - virtual ~application (void); + virtual ~application (); - int sys_argc (void) const { return m_options.sys_argc (); } - char ** sys_argv (void) const { return m_options.sys_argv (); } + int sys_argc () const { return m_options.sys_argc (); } + char ** sys_argv () const { return m_options.sys_argv (); } void set_program_names (const std::string& pname); void intern_argv (const string_vector& args); - cmdline_options options (void) const { return m_options; } + cmdline_options options () const { return m_options; } - bool have_eval_option_code (void) const { return m_have_eval_option_code; } + bool have_eval_option_code () const { return m_have_eval_option_code; } - bool have_script_file (void) const { return m_have_script_file; } + bool have_script_file () const { return m_have_script_file; } - bool is_octave_program (void) const { return m_is_octave_program; } + bool is_octave_program () const { return m_is_octave_program; } - bool interpreter_initialized (void); + bool interpreter_initialized (); - virtual interpreter& create_interpreter (void); + virtual interpreter& create_interpreter (); - virtual void initialize_interpreter (void); + virtual void initialize_interpreter (); - virtual int execute_interpreter (void); + virtual int execute_interpreter (); - virtual void delete_interpreter (void); + virtual void delete_interpreter (); - virtual int execute (void) = 0; + virtual int execute () = 0; - virtual bool gui_running (void) const { return false; } + virtual bool gui_running () const { return false; } virtual void gui_running (bool) { } void program_invocation_name (const std::string& nm) @@ -296,40 +296,40 @@ // Provided for convenience. Will be removed once we eliminate the // old terminal widget. - bool experimental_terminal_widget (void) const; + bool experimental_terminal_widget () const; - static application * app (void) { return s_instance; } + static application * app () { return s_instance; } - static std::string program_invocation_name (void) + static std::string program_invocation_name () { return s_instance ? s_instance->m_program_invocation_name : ""; } - static std::string program_name (void) + static std::string program_name () { return s_instance ? s_instance->m_program_name : ""; } - static string_vector argv (void) + static string_vector argv () { return s_instance ? s_instance->m_argv : string_vector (); } - static bool is_gui_running (void) + static bool is_gui_running () { return s_instance ? s_instance->gui_running () : false; } // Convenience functions. - static bool forced_interactive (void); + static bool forced_interactive (); private: // The application instance; There should be only one. static application *s_instance; - void init (void); + void init (); protected: @@ -380,9 +380,9 @@ cli_application& operator = (const cli_application&) = delete; - ~cli_application (void) = default; + ~cli_application () = default; - int execute (void); + int execute (); }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/anon-fcn-validator.h --- a/libinterp/parse-tree/anon-fcn-validator.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/anon-fcn-validator.h Tue Jan 24 17:19:44 2023 -0800 @@ -51,7 +51,7 @@ anon_fcn_validator& operator = (const anon_fcn_validator&) = delete; - ~anon_fcn_validator (void) = default; + ~anon_fcn_validator () = default; void visit_postfix_expression (tree_postfix_expression&); @@ -61,12 +61,12 @@ void visit_simple_assignment (tree_simple_assignment&); - bool ok (void) const { return m_ok; } + bool ok () const { return m_ok; } - int line (void) const { return m_line; } - int column (void) const { return m_column; } + int line () const { return m_line; } + int column () const { return m_column; } - std::string message (void) const { return m_message; } + std::string message () const { return m_message; } private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/bp-table.cc --- a/libinterp/parse-tree/bp-table.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/bp-table.cc Tue Jan 24 17:19:44 2023 -0800 @@ -96,12 +96,12 @@ m_ok = true; } - std::string file (void) const { return m_file; } - std::string dir (void) const { return m_fcn; } - std::string fcn (void) const { return m_fcn; } - std::string class_name (void) const { return m_class_name; } + std::string file () const { return m_file; } + std::string dir () const { return m_fcn; } + std::string fcn () const { return m_fcn; } + std::string class_name () const { return m_class_name; } - bool ok (void) const { return m_ok; } + bool ok () const { return m_ok; } private: @@ -114,7 +114,7 @@ // Clear all reasons to stop, other than breakpoints. -void bp_table::dbclear_all_signals (void) +void bp_table::dbclear_all_signals () { interpreter& interp = m_evaluator.get_interpreter (); error_system& es = interp.get_error_system (); @@ -941,7 +941,7 @@ return remove_all_breakpoints_from_function (info.fcn (), silent); } -void bp_table::remove_all_breakpoints (void) +void bp_table::remove_all_breakpoints () { // Odd loop structure required because delete will invalidate // m_bp_set iterators. diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/bp-table.h --- a/libinterp/parse-tree/bp-table.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/bp-table.h Tue Jan 24 17:19:44 2023 -0800 @@ -62,7 +62,7 @@ m_caught_that_stop (), m_warnings_that_stop () { } - ~bp_table (void) = default; + ~bp_table () = default; // Set of breakpoint lines. typedef std::set bp_lines; @@ -129,13 +129,13 @@ bool silent = false); // Remove all the breakpoints registered with octave. - void remove_all_breakpoints (void); + void remove_all_breakpoints (); // Return all breakpoints. Each element of the map is a vector // containing the breakpoints corresponding to a given function name. fname_bp_map get_breakpoint_list (const octave_value_list& fname_list); - bool have_breakpoints (void) { return (! m_bp_set.empty ()); } + bool have_breakpoints () { return (! m_bp_set.empty ()); } // Should we enter debugging for this particular error identifier? bool debug_on_err (const std::string& id) @@ -159,7 +159,7 @@ void dbstop_process_map_args (const octave_map& mv); - void dbclear_all_signals (void); + void dbclear_all_signals (); bool condition_valid (const std::string& cond); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/comment-list.cc --- a/libinterp/parse-tree/comment-list.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/comment-list.cc Tue Jan 24 17:19:44 2023 -0800 @@ -35,7 +35,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) comment_list * -comment_list::dup (void) const +comment_list::dup () const { comment_list *new_cl = new comment_list (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/comment-list.h --- a/libinterp/parse-tree/comment-list.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/comment-list.h Tue Jan 24 17:19:44 2023 -0800 @@ -34,9 +34,9 @@ OCTAVE_BEGIN_NAMESPACE(octave) -extern std::string get_comment_text (void); +extern std::string get_comment_text (); -extern char * get_comment_text_c_str (void); +extern char * get_comment_text_c_str (); extern void save_comment_text (const std::string& text); @@ -72,17 +72,17 @@ return *this; } - std::string text (void) const { return m_text; } + std::string text () const { return m_text; } - comment_type type (void) const { return m_type; } + comment_type type () const { return m_type; } - bool is_block (void) const { return m_type == block; } - bool is_full_line (void) const { return m_type == full_line; } - bool is_end_of_line (void) const { return m_type == end_of_line; } - bool is_doc_string (void) const { return m_type == doc_string; } - bool is_copyright (void) const { return m_type == copyright; } + bool is_block () const { return m_type == block; } + bool is_full_line () const { return m_type == full_line; } + bool is_end_of_line () const { return m_type == end_of_line; } + bool is_doc_string () const { return m_type == doc_string; } + bool is_copyright () const { return m_type == copyright; } - ~comment_elt (void) = default; + ~comment_elt () = default; private: @@ -98,7 +98,7 @@ { public: - comment_list (void) { } + comment_list () { } void append (const comment_elt& elt) { base_list::append (elt); } @@ -107,7 +107,7 @@ comment_elt::comment_type t = comment_elt::unknown) { append (comment_elt (s, t)); } - comment_list * dup (void) const; + comment_list * dup () const; }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/filepos.h --- a/libinterp/parse-tree/filepos.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/filepos.h Tue Jan 24 17:19:44 2023 -0800 @@ -34,7 +34,7 @@ { public: - filepos (void) : m_line (0), m_column (0) { } + filepos () : m_line (0), m_column (0) { } filepos (int l, int c) : m_line (l), m_column (c) { } @@ -42,15 +42,15 @@ filepos& operator = (const filepos&) = default; - ~filepos (void) = default; + ~filepos () = default; operator bool () { return m_line > 0 && m_column > 0; } void line (int l) { m_line = l; } void column (int c) { m_column = c; } - int line (void) const { return m_line; } - int column (void) const { return m_column; } + int line () const { return m_line; } + int column () const { return m_column; } void increment_line (int val = 1) { m_line += val; } void increment_column (int val = 1) { m_column += val; } @@ -58,7 +58,7 @@ void decrement_line (int val = 1) { m_line -= val; } void decrement_column (int val = 1) { m_column -= val; } - void next_line (void) + void next_line () { m_line++; m_column = 1; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/lex.h --- a/libinterp/parse-tree/lex.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/lex.h Tue Jan 24 17:19:44 2023 -0800 @@ -62,23 +62,23 @@ symbol_table_context (interpreter& interp) : m_interpreter (interp), m_frame_stack () { } - ~symbol_table_context (void) { clear (); } + ~symbol_table_context () { clear (); } - void clear (void); + void clear (); - bool empty (void) const { return m_frame_stack.empty (); } + bool empty () const { return m_frame_stack.empty (); } - std::size_t size (void) const { return m_frame_stack.size (); } + std::size_t size () const { return m_frame_stack.size (); } - void pop (void); + void pop (); void push (const symbol_scope& scope) { m_frame_stack.push_front (scope); } - symbol_scope curr_scope (void) const; - symbol_scope parent_scope (void) const; + symbol_scope curr_scope () const; + symbol_scope parent_scope () const; private: @@ -103,7 +103,7 @@ public: - bbp_nesting_level (void) : m_context () { } + bbp_nesting_level () : m_context () { } bbp_nesting_level (const bbp_nesting_level& nl) : m_context (nl.m_context) @@ -117,54 +117,54 @@ return *this; } - ~bbp_nesting_level (void) = default; + ~bbp_nesting_level () = default; // Alias for clear function. - void reset (void) { clear (); } + void reset () { clear (); } - void bracket (void) { m_context.push (BRACKET); } + void bracket () { m_context.push (BRACKET); } - bool is_bracket (void) + bool is_bracket () { return ! m_context.empty () && m_context.top () == BRACKET; } - void brace (void) { m_context.push (BRACE); } + void brace () { m_context.push (BRACE); } - bool is_brace (void) + bool is_brace () { return ! m_context.empty () && m_context.top () == BRACE; } - void paren (void) { m_context.push (PAREN); } + void paren () { m_context.push (PAREN); } - bool is_paren (void) + bool is_paren () { return ! m_context.empty () && m_context.top () == PAREN; } - void anon_fcn_body (void) { m_context.push (ANON_FCN_BODY); } + void anon_fcn_body () { m_context.push (ANON_FCN_BODY); } - bool is_anon_fcn_body (void) + bool is_anon_fcn_body () { return ! m_context.empty () && m_context.top () == ANON_FCN_BODY; } - bool is_bracket_or_brace (void) + bool is_bracket_or_brace () { return (! m_context.empty () && (m_context.top () == BRACKET || m_context.top () == BRACE)); } - bool none (void) { return m_context.empty (); } + bool none () { return m_context.empty (); } - void remove (void) + void remove () { if (! m_context.empty ()) m_context.pop (); } - void clear (void) + void clear () { while (! m_context.empty ()) m_context.pop (); @@ -191,7 +191,7 @@ // elements that it stores. Another reason is that it makes it // easier to change the implementation later if needed. - token_cache (void) : m_buffer () { } + token_cache () : m_buffer () { } // No copying! @@ -199,14 +199,14 @@ token_cache& operator = (const token_cache&) = delete; - ~token_cache (void) { clear (); } + ~token_cache () { clear (); } void push (token *tok) { m_buffer.push_front (tok); } - void pop (void) + void pop () { if (! empty ()) { @@ -227,32 +227,32 @@ } // Most recently pushed. - token * front (void) + token * front () { return empty () ? nullptr : m_buffer.front (); } - const token * front (void) const + const token * front () const { return empty () ? nullptr : m_buffer.front (); } - token * back (void) + token * back () { return empty () ? nullptr : m_buffer.back (); } - const token * back (void) const + const token * back () const { return empty () ? nullptr : m_buffer.back (); } // Number of elements currently in the buffer. - std::size_t size (void) const { return m_buffer.size (); } + std::size_t size () const { return m_buffer.size (); } - bool empty (void) const { return m_buffer.empty (); } + bool empty () const { return m_buffer.empty (); } - void clear (void) + void clear () { while (! empty ()) pop (); @@ -326,25 +326,25 @@ lexical_feedback& operator = (const lexical_feedback&) = delete; - ~lexical_feedback (void); + ~lexical_feedback (); - void init (void); + void init (); - void reset (void); + void reset (); - int previous_token_value (void) const; + int previous_token_value () const; bool previous_token_value_is (int tok_val) const; - void mark_previous_token_trailing_space (void); + void mark_previous_token_trailing_space (); - bool space_follows_previous_token (void) const; + bool space_follows_previous_token () const; - bool previous_token_is_binop (void) const; + bool previous_token_is_binop () const; - bool previous_token_is_keyword (void) const; + bool previous_token_is_keyword () const; - bool previous_token_may_be_command (void) const; + bool previous_token_may_be_command () const; void mark_as_variable (const std::string& nm); void mark_as_variables (const std::list& lst); @@ -539,7 +539,7 @@ { public: - input_buffer (void) + input_buffer () : m_buffer (), m_offset (0), m_chars_left (0), m_eof (false) { } @@ -548,9 +548,9 @@ // Copy at most max_size characters to buf. int copy_chunk (char *buf, std::size_t max_size, bool by_lines = false); - bool empty (void) const { return m_chars_left == 0; } + bool empty () const { return m_chars_left == 0; } - bool at_eof (void) const { return m_eof; } + bool at_eof () const { return m_eof; } private: @@ -567,9 +567,9 @@ { public: - comment_buffer (void) : m_comment_list (nullptr) { } + comment_buffer () : m_comment_list (nullptr) { } - ~comment_buffer (void) { delete m_comment_list; } + ~comment_buffer () { delete m_comment_list; } void append (const std::string& s, comment_elt::comment_type t) { @@ -581,7 +581,7 @@ // Caller is expected to delete the returned value. - comment_list * get_comment (void) + comment_list * get_comment () { comment_list *retval = m_comment_list; @@ -590,7 +590,7 @@ return retval; } - void reset (void) + void reset () { delete m_comment_list; @@ -615,31 +615,31 @@ base_lexer& operator = (const base_lexer&) = delete; - virtual ~base_lexer (void); + virtual ~base_lexer (); - void init (void); + void init (); - virtual bool is_push_lexer (void) const { return false; } + virtual bool is_push_lexer () const { return false; } - virtual void reset (void); + virtual void reset (); - void prep_for_file (void); + void prep_for_file (); void begin_string (int state); virtual int fill_flex_buffer (char *buf, unsigned int max_size) = 0; - bool at_end_of_buffer (void) const { return m_input_buf.empty (); } + bool at_end_of_buffer () const { return m_input_buf.empty (); } - bool at_end_of_file (void) const { return m_input_buf.at_eof (); } + bool at_end_of_file () const { return m_input_buf.at_eof (); } - int handle_end_of_input (void); + int handle_end_of_input (); - char * flex_yytext (void); + char * flex_yytext (); - int flex_yyleng (void); + int flex_yyleng (); - int text_yyinput (void); + int text_yyinput (); void xunput (char c, char *buf); @@ -647,37 +647,37 @@ void update_token_positions (int tok_len); - bool looking_at_space (void); + bool looking_at_space (); - bool inside_any_object_index (void); + bool inside_any_object_index (); int make_keyword_token (const std::string& s); bool fq_identifier_contains_keyword (const std::string& s); - bool whitespace_is_significant (void); + bool whitespace_is_significant (); // We only provide specializations with base equal to 2, 10, or 16. template - int handle_number (void); + int handle_number (); - void handle_continuation (void); + void handle_continuation (); void finish_comment (comment_elt::comment_type typ); - comment_list * get_comment (void) { return m_comment_buf.get_comment (); } + comment_list * get_comment () { return m_comment_buf.get_comment (); } int handle_close_bracket (int bracket_type); - bool looks_like_command_arg (void); + bool looks_like_command_arg (); - int handle_superclass_identifier (void); + int handle_superclass_identifier (); - int handle_meta_identifier (void); + int handle_meta_identifier (); - int handle_fq_identifier (void); + int handle_fq_identifier (); - int handle_identifier (void); + int handle_identifier (); void maybe_warn_separator_insert (char sep); @@ -685,7 +685,7 @@ void maybe_warn_language_extension_comment (char c); - void warn_language_extension_continuation (void); + void warn_language_extension_continuation (); void warn_language_extension_operator (const std::string& op); @@ -693,19 +693,19 @@ void push_token (token *); - token * current_token (void); + token * current_token (); - std::size_t pending_token_count (void) const; + std::size_t pending_token_count () const; void display_token (int tok); void fatal_error (const char *msg); - bool debug_flag (void) const; + bool debug_flag () const; - bool display_tokens (void) const; + bool display_tokens () const; - void increment_token_count (void); + void increment_token_count (); void lexer_debug (const char *pattern); @@ -718,31 +718,31 @@ // Object that collects comment text. comment_buffer m_comment_buf; - virtual std::string input_source (void) const { return "unknown"; } + virtual std::string input_source () const { return "unknown"; } - virtual bool input_from_terminal (void) const { return false; } + virtual bool input_from_terminal () const { return false; } - virtual bool input_from_file (void) const { return false; } + virtual bool input_from_file () const { return false; } - virtual bool input_from_eval_string (void) const { return false; } + virtual bool input_from_eval_string () const { return false; } - bool input_from_tmp_history_file (void); + bool input_from_tmp_history_file (); void push_start_state (int state); - void pop_start_state (void); + void pop_start_state (); - void clear_start_state (void); + void clear_start_state (); - int start_state (void) const { return start_state_stack.top (); } + int start_state () const { return start_state_stack.top (); } - void display_start_state (void) const; + void display_start_state () const; bool maybe_unput_comma_before_unary_op (int tok); int handle_op (int tok, bool bos = false, bool compat = true); - int finish_command_arg (void); + int finish_command_arg (); int handle_token (int tok, token *tok_val = nullptr); @@ -786,29 +786,29 @@ lexer& operator = (const lexer&) = delete; - void reset (void) + void reset () { m_initial_input = true; base_lexer::reset (); } - std::string input_source (void) const + std::string input_source () const { return m_reader.input_source (); } - bool input_from_terminal (void) const + bool input_from_terminal () const { return m_reader.input_from_terminal (); } - bool input_from_file (void) const + bool input_from_file () const { return m_reader.input_from_file (); } - bool input_from_eval_string (void) const + bool input_from_eval_string () const { return m_reader.input_from_eval_string (); } @@ -864,11 +864,11 @@ push_lexer& operator = (const push_lexer&) = delete; - bool is_push_lexer (void) const { return true; } + bool is_push_lexer () const { return true; } void append_input (const std::string& input, bool eof); - std::string input_source (void) const { return "push buffer"; } + std::string input_source () const { return "push buffer"; } int fill_flex_buffer (char *buf, unsigned int max_size); }; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/lex.ll --- a/libinterp/parse-tree/lex.ll Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/lex.ll Tue Jan 24 17:19:44 2023 -0800 @@ -2114,14 +2114,14 @@ */ void - lexical_feedback::symbol_table_context::clear (void) + lexical_feedback::symbol_table_context::clear () { while (! m_frame_stack.empty ()) m_frame_stack.pop_front (); } void - lexical_feedback::symbol_table_context::pop (void) + lexical_feedback::symbol_table_context::pop () { if (empty ()) panic_impossible (); @@ -2130,7 +2130,7 @@ } symbol_scope - lexical_feedback::symbol_table_context::curr_scope (void) const + lexical_feedback::symbol_table_context::curr_scope () const { if (empty ()) return m_interpreter.get_current_scope (); @@ -2139,7 +2139,7 @@ } symbol_scope - lexical_feedback::symbol_table_context::parent_scope (void) const + lexical_feedback::symbol_table_context::parent_scope () const { std::size_t sz = size (); @@ -2148,13 +2148,13 @@ : (sz == 1 ? m_frame_stack[0] : symbol_scope ())); } - lexical_feedback::~lexical_feedback (void) + lexical_feedback::~lexical_feedback () { m_tokens.clear (); } void - lexical_feedback::init (void) + lexical_feedback::init () { // The closest paren, brace, or bracket nesting is not an object // index. @@ -2162,7 +2162,7 @@ } void - lexical_feedback::reset (void) + lexical_feedback::reset () { m_end_of_input = false; m_allow_command_syntax = true; @@ -2222,7 +2222,7 @@ } int - lexical_feedback::previous_token_value (void) const + lexical_feedback::previous_token_value () const { const token *tok = m_tokens.front (); return tok ? tok->token_value () : 0; @@ -2236,7 +2236,7 @@ } void - lexical_feedback::mark_previous_token_trailing_space (void) + lexical_feedback::mark_previous_token_trailing_space () { token *tok = m_tokens.front (); if (tok && ! previous_token_value_is ('\n')) @@ -2244,14 +2244,14 @@ } bool - lexical_feedback::space_follows_previous_token (void) const + lexical_feedback::space_follows_previous_token () const { const token *tok = m_tokens.front (); return tok ? tok->space_follows_token () : false; } bool - lexical_feedback::previous_token_is_binop (void) const + lexical_feedback::previous_token_is_binop () const { int tok = previous_token_value (); @@ -2271,7 +2271,7 @@ } bool - lexical_feedback::previous_token_is_keyword (void) const + lexical_feedback::previous_token_is_keyword () const { const token *tok = m_tokens.front (); return tok ? tok->iskeyword () : false; @@ -2296,7 +2296,7 @@ } bool - lexical_feedback::previous_token_may_be_command (void) const + lexical_feedback::previous_token_may_be_command () const { if (! m_allow_command_syntax) return false; @@ -2392,13 +2392,13 @@ return len; } - base_lexer::~base_lexer (void) + base_lexer::~base_lexer () { yylex_destroy (m_scanner); } void - base_lexer::init (void) + base_lexer::init () { yylex_init (&m_scanner); @@ -2419,7 +2419,7 @@ struct yyguts_t *yyg = static_cast (m_scanner) void - base_lexer::reset (void) + base_lexer::reset () { // Start off on the right foot. clear_start_state (); @@ -2442,7 +2442,7 @@ } void - base_lexer::prep_for_file (void) + base_lexer::prep_for_file () { m_reading_script_file = true; @@ -2458,7 +2458,7 @@ } int - base_lexer::handle_end_of_input (void) + base_lexer::handle_end_of_input () { lexer_debug ("<>"); @@ -2483,19 +2483,19 @@ } char * - base_lexer::flex_yytext (void) + base_lexer::flex_yytext () { return yyget_text (m_scanner); } int - base_lexer::flex_yyleng (void) + base_lexer::flex_yyleng () { return yyget_leng (m_scanner); } int - base_lexer::text_yyinput (void) + base_lexer::text_yyinput () { int c = yyinput (m_scanner); @@ -2566,7 +2566,7 @@ } bool - base_lexer::looking_at_space (void) + base_lexer::looking_at_space () { int c = text_yyinput (); xunput (c); @@ -2574,7 +2574,7 @@ } bool - base_lexer::inside_any_object_index (void) + base_lexer::inside_any_object_index () { bool retval = false; @@ -2901,7 +2901,7 @@ } bool - base_lexer::whitespace_is_significant (void) + base_lexer::whitespace_is_significant () { return (m_nesting_level.is_bracket () || (m_nesting_level.is_brace () @@ -2972,7 +2972,7 @@ template <> int - base_lexer::handle_number<2> (void) + base_lexer::handle_number<2> () { // Skip 0[bB] prefix. std::string yytxt (flex_yytext () + 2); @@ -3058,14 +3058,14 @@ } static uint64_t - flintmax (void) + flintmax () { return (static_cast (1) << std::numeric_limits::digits); } template <> int - base_lexer::handle_number<10> (void) + base_lexer::handle_number<10> () { bool imag = false; bool digits_only = true; @@ -3180,7 +3180,7 @@ template <> int - base_lexer::handle_number<16> (void) + base_lexer::handle_number<16> () { // Skip 0[xX] prefix. std::string yytxt (flex_yytext () + 2); @@ -3256,7 +3256,7 @@ } void - base_lexer::handle_continuation (void) + base_lexer::handle_continuation () { char *yytxt = flex_yytext (); int yylng = flex_yyleng (); @@ -3359,7 +3359,7 @@ } bool - base_lexer::looks_like_command_arg (void) + base_lexer::looks_like_command_arg () { if (! m_allow_command_syntax) return false; @@ -3372,7 +3372,7 @@ } int - base_lexer::handle_superclass_identifier (void) + base_lexer::handle_superclass_identifier () { update_token_positions (flex_yyleng ()); @@ -3406,7 +3406,7 @@ } int - base_lexer::handle_meta_identifier (void) + base_lexer::handle_meta_identifier () { std::string txt = flex_yytext (); @@ -3437,7 +3437,7 @@ } int - base_lexer::handle_fq_identifier (void) + base_lexer::handle_fq_identifier () { std::string txt = flex_yytext (); @@ -3471,7 +3471,7 @@ // should be ignored. int - base_lexer::handle_identifier (void) + base_lexer::handle_identifier () { update_token_positions (flex_yyleng ()); @@ -3577,7 +3577,7 @@ } void - base_lexer::warn_language_extension_continuation (void) + base_lexer::warn_language_extension_continuation () { warn_language_extension ("\\ used as line continuation marker"); } @@ -3612,14 +3612,14 @@ } token * - base_lexer::current_token (void) + base_lexer::current_token () { YYSTYPE *lval = yyget_lval (m_scanner); return lval->tok_val; } std::size_t - base_lexer::pending_token_count (void) const + base_lexer::pending_token_count () const { return m_tokens.size (); } @@ -3759,21 +3759,21 @@ } bool - base_lexer::debug_flag (void) const + base_lexer::debug_flag () const { settings& stgs = m_interpreter.get_settings (); return stgs.lexer_debug_flag (); } bool - base_lexer::display_tokens (void) const + base_lexer::display_tokens () const { settings& stgs = m_interpreter.get_settings (); return stgs.display_tokens (); } void - base_lexer::increment_token_count (void) + base_lexer::increment_token_count () { settings& stgs = m_interpreter.get_settings (); stgs.increment_token_count (); @@ -3796,7 +3796,7 @@ } bool - base_lexer::input_from_tmp_history_file (void) + base_lexer::input_from_tmp_history_file () { history_system& history_sys = m_interpreter.get_history_system (); @@ -3814,7 +3814,7 @@ } void - base_lexer::pop_start_state (void) + base_lexer::pop_start_state () { OCTAVE_YYG; @@ -3824,7 +3824,7 @@ } void - base_lexer::clear_start_state (void) + base_lexer::clear_start_state () { while (! start_state_stack.empty ()) start_state_stack.pop (); @@ -3833,7 +3833,7 @@ } void - base_lexer::display_start_state (void) const + base_lexer::display_start_state () const { std::cerr << "S: "; @@ -3944,7 +3944,7 @@ // function call. int - base_lexer::finish_command_arg (void) + base_lexer::finish_command_arg () { int tok = SQ_STRING; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/oct-lvalue.cc --- a/libinterp/parse-tree/oct-lvalue.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/oct-lvalue.cc Tue Jan 24 17:19:44 2023 -0800 @@ -37,12 +37,12 @@ OCTAVE_BEGIN_NAMESPACE(octave) -bool octave_lvalue::is_defined (void) const +bool octave_lvalue::is_defined () const { return ! is_black_hole () && m_frame->is_defined (m_sym); } -bool octave_lvalue::is_undefined (void) const +bool octave_lvalue::is_undefined () const { return ! is_defined (); } @@ -59,7 +59,7 @@ m_frame->assign (op, m_sym, m_type, m_idx, rhs); } -octave_idx_type octave_lvalue::numel (void) const +octave_idx_type octave_lvalue::numel () const { // Return 1 if there is no index because without an index there // should be no way to have a cs-list here. Cs-lists may be passed @@ -178,7 +178,7 @@ m_idx = i; } -bool octave_lvalue::index_is_empty (void) const +bool octave_lvalue::index_is_empty () const { bool retval = false; @@ -192,7 +192,7 @@ return retval; } -bool octave_lvalue::index_is_colon (void) const +bool octave_lvalue::index_is_colon () const { bool retval = false; @@ -212,7 +212,7 @@ m_frame->non_const_unary_op (op, m_sym, m_type, m_idx); } -octave_value octave_lvalue::value (void) const +octave_value octave_lvalue::value () const { return (is_black_hole () ? octave_value () : m_frame->value (m_sym, m_type, m_idx)); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/oct-lvalue.h --- a/libinterp/parse-tree/oct-lvalue.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/oct-lvalue.h Tue Jan 24 17:19:44 2023 -0800 @@ -50,38 +50,38 @@ octave_lvalue& operator = (const octave_lvalue&) = delete; - ~octave_lvalue (void) = default; + ~octave_lvalue () = default; - bool is_black_hole (void) const { return m_black_hole; } + bool is_black_hole () const { return m_black_hole; } - void mark_black_hole (void) { m_black_hole = true; } + void mark_black_hole () { m_black_hole = true; } - bool is_defined (void) const; + bool is_defined () const; - bool is_undefined (void) const; + bool is_undefined () const; - bool isstruct (void) const { return value().isstruct (); } + bool isstruct () const { return value().isstruct (); } void define (const octave_value& v); void assign (octave_value::assign_op, const octave_value&); - octave_idx_type numel (void) const; + octave_idx_type numel () const; void set_index (const std::string& t, const std::list& i); - void clear_index (void) { m_type = ""; m_idx.clear (); } + void clear_index () { m_type = ""; m_idx.clear (); } - std::string index_type (void) const { return m_type; } + std::string index_type () const { return m_type; } - bool index_is_empty (void) const; + bool index_is_empty () const; - bool index_is_colon (void) const; + bool index_is_colon () const; void unary_op (octave_value::unary_op op); - octave_value value (void) const; + octave_value value () const; private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/oct-parse.yy --- a/libinterp/parse-tree/oct-parse.yy Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/oct-parse.yy Tue Jan 24 17:19:44 2023 -0800 @@ -2425,18 +2425,18 @@ parse_exception& operator = (const parse_exception&) = default; - ~parse_exception (void) = default; - - std::string message (void) const { return m_message; } + ~parse_exception () = default; + + std::string message () const { return m_message; } // Provided for std::exception interface. - const char * what (void) const noexcept { return m_message.c_str (); } - - std::string fcn_name (void) const { return m_fcn_name; } - std::string file_name (void) const { return m_file_name; } - - int line (void) const { return m_line; } - int column (void) const { return m_column; } + const char * what () const noexcept { return m_message.c_str (); } + + std::string fcn_name () const { return m_fcn_name; } + std::string file_name () const { return m_file_name; } + + int line () const { return m_line; } + int column () const { return m_column; } // virtual void display (std::ostream& os) const; @@ -2454,7 +2454,7 @@ { public: - parse_tree_validator (void) + parse_tree_validator () : m_scope (), m_error_list () { } @@ -2462,13 +2462,13 @@ parse_tree_validator& operator = (const parse_tree_validator&) = delete; - ~parse_tree_validator (void) = default; - - symbol_scope get_scope (void) const { return m_scope; } - - bool ok (void) const { return m_error_list.empty (); } - - std::list error_list (void) const + ~parse_tree_validator () = default; + + symbol_scope get_scope () const { return m_scope; } + + bool ok () const { return m_error_list.empty (); } + + std::list error_list () const { return m_error_list; } @@ -2542,7 +2542,7 @@ } std::size_t - base_parser::parent_scope_info::size (void) const + base_parser::parent_scope_info::size () const { return m_info.size (); } @@ -2560,7 +2560,7 @@ } void - base_parser::parent_scope_info::pop (void) + base_parser::parent_scope_info::pop () { m_info.pop_back (); } @@ -2616,18 +2616,18 @@ } symbol_scope - base_parser::parent_scope_info::parent_scope (void) const + base_parser::parent_scope_info::parent_scope () const { return size () > 1 ? m_info[size()-2].first : symbol_scope (); } std::string - base_parser::parent_scope_info::parent_name (void) const + base_parser::parent_scope_info::parent_name () const { return m_info[size()-2].second; } - void base_parser::parent_scope_info::clear (void) + void base_parser::parent_scope_info::clear () { m_info.clear (); m_all_names.clear (); @@ -2643,7 +2643,7 @@ m_stmt_list (), m_lexer (lxr), m_parser_state (yypstate_new ()) { } - base_parser::~base_parser (void) + base_parser::~base_parser () { delete &m_lexer; @@ -2659,7 +2659,7 @@ } void - base_parser::reset (void) + base_parser::reset () { m_endfunction_found = false; m_autoloading = false; @@ -2801,7 +2801,7 @@ } bool - base_parser::push_fcn_symtab (void) + base_parser::push_fcn_symtab () { m_curr_fcn_depth++; @@ -2893,7 +2893,7 @@ } tree_black_hole * - base_parser::make_black_hole (void) + base_parser::make_black_hole () { return new tree_black_hole (); } @@ -4302,7 +4302,7 @@ } void - base_parser::recover_from_parsing_function (void) + base_parser::recover_from_parsing_function () { m_lexer.m_symtab_context.pop (); @@ -5494,7 +5494,7 @@ } void - base_parser::disallow_command_syntax (void) + base_parser::disallow_command_syntax () { m_lexer.m_allow_command_syntax = false; } @@ -5615,7 +5615,7 @@ } int - parser::run (void) + parser::run () { int status = -1; @@ -5732,7 +5732,7 @@ } int - push_parser::run (void) + push_parser::run () { if (! m_reader) error ("push_parser::run requires valid input_reader"); @@ -5804,7 +5804,7 @@ return octave_value (); } - unwind_action act ([=] (void) { ::fclose (ffile); }); + unwind_action act ([=] () { ::fclose (ffile); }); // get the encoding for this folder input_system& input_sys = interp.get_input_system (); @@ -5898,7 +5898,7 @@ // Check script or function for semantic errors. bool - base_parser::validate_primary_fcn (void) + base_parser::validate_primary_fcn () { octave_user_code *code = m_primary_fcn.user_code_value (); @@ -6636,7 +6636,7 @@ // the eval, then the message is stored in the exception object and we // will display it later, after the buffers have been restored. - unwind_action act ([=] (void) + unwind_action act ([=] () { octave_stdout.rdbuf (old_out_buf); std::cerr.rdbuf (old_err_buf); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/parse.h --- a/libinterp/parse-tree/parse.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/parse.h Tue Jan 24 17:19:44 2023 -0800 @@ -122,7 +122,7 @@ typedef std::deque::reverse_iterator reverse_iterator; typedef std::deque::const_reverse_iterator const_reverse_iterator; - parent_scope_info (void) = delete; + parent_scope_info () = delete; parent_scope_info (base_parser& parser) : m_parser (parser), m_info (), m_all_names () @@ -134,25 +134,25 @@ parent_scope_info& operator = (const parent_scope_info&) = delete; - ~parent_scope_info (void) = default; + ~parent_scope_info () = default; - OCTINTERP_API std::size_t size (void) const; + OCTINTERP_API std::size_t size () const; OCTINTERP_API void push (const value_type& elt); OCTINTERP_API void push (const symbol_scope& id); - OCTINTERP_API void pop (void); + OCTINTERP_API void pop (); OCTINTERP_API bool name_ok (const std::string& name); OCTINTERP_API bool name_current_scope (const std::string& name); - OCTINTERP_API symbol_scope parent_scope (void) const; + OCTINTERP_API symbol_scope parent_scope () const; - OCTINTERP_API std::string parent_name (void) const; + OCTINTERP_API std::string parent_name () const; - OCTINTERP_API void clear (void); + OCTINTERP_API void clear (); private: @@ -171,27 +171,27 @@ base_parser& operator = (const base_parser&) = delete; - virtual ~base_parser (void); + virtual ~base_parser (); - base_lexer& get_lexer (void) const { return m_lexer; } + base_lexer& get_lexer () const { return m_lexer; } - bool at_end_of_input (void) const { return m_lexer.m_end_of_input; } + bool at_end_of_input () const { return m_lexer.m_end_of_input; } - OCTINTERP_API void reset (void); + OCTINTERP_API void reset (); void classdef_object (const std::shared_ptr& obj) { m_classdef_object = obj; } - std::shared_ptr classdef_object (void) const + std::shared_ptr classdef_object () const { return m_classdef_object; } OCTINTERP_API void statement_list (std::shared_ptr& lst); - std::shared_ptr statement_list (void) const + std::shared_ptr statement_list () const { return m_stmt_list; } @@ -201,7 +201,7 @@ m_parsing_subfunctions = flag; } - bool parsing_subfunctions (void) const + bool parsing_subfunctions () const { return m_parsing_subfunctions; } @@ -211,12 +211,12 @@ m_parsing_local_functions = flag; } - bool parsing_local_functions (void) const + bool parsing_local_functions () const { return m_parsing_local_functions; } - int curr_fcn_depth (void) const + int curr_fcn_depth () const { return m_curr_fcn_depth; } @@ -226,7 +226,7 @@ m_endfunction_found = flag; } - bool endfunction_found (void) const + bool endfunction_found () const { return m_endfunction_found; } @@ -239,12 +239,12 @@ OCTINTERP_API bool end_token_ok (token *tok, token::end_tok_type expected); // Handle pushing symbol table for new function scope. - OCTINTERP_API bool push_fcn_symtab (void); + OCTINTERP_API bool push_fcn_symtab (); // Build a constant. OCTINTERP_API tree_constant * make_constant (token *tok_val); - OCTINTERP_API tree_black_hole * make_black_hole (void); + OCTINTERP_API tree_black_hole * make_black_hole (); OCTINTERP_API tree_matrix * make_matrix (tree_argument_list *row); @@ -458,7 +458,7 @@ // Reset state after parsing function. OCTINTERP_API void - recover_from_parsing_function (void); + recover_from_parsing_function (); OCTINTERP_API tree_classdef * make_classdef (token *tok_val, tree_classdef_attribute_list *a, @@ -701,7 +701,7 @@ // Don't allow parsing command syntax. If the parser/lexer is // reset, this setting is also reset to the default (allow command // syntax). - OCTINTERP_API void disallow_command_syntax (void); + OCTINTERP_API void disallow_command_syntax (); // Generic error messages. OCTINTERP_API void bison_error (const std::string& s); @@ -723,11 +723,11 @@ // use a separate run method and completely separate input from // lexical analysis and parsing. - virtual int run (void) = 0; + virtual int run () = 0; // Check primary script or function generated by the parser for // semantic errors. - OCTINTERP_API bool validate_primary_fcn (void); + OCTINTERP_API bool validate_primary_fcn (); OCTINTERP_API bool finish_input (tree_statement_list *lst, bool at_eof = false); @@ -859,9 +859,9 @@ parser& operator = (const parser&) = delete; - ~parser (void) = default; + ~parser () = default; - OCTINTERP_API int run (void); + OCTINTERP_API int run (); }; class push_parser : public base_parser @@ -887,13 +887,13 @@ push_parser& operator = (const push_parser&) = delete; - ~push_parser (void) = default; + ~push_parser () = default; // Use the push parser in the same way as the pull parser. The // parser arranges for input through the M_READER object. See, for // example, interpreter::main_loop. - OCTINTERP_API int run (void); + OCTINTERP_API int run (); // Parse INPUT. M_READER is not used. The user is responsible for // collecting input. diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/profiler.cc --- a/libinterp/parse-tree/profiler.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/profiler.cc Tue Jan 24 17:19:44 2023 -0800 @@ -37,7 +37,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) -profiler::stats::stats (void) +profiler::stats::stats () : m_time (0.0), m_calls (0), m_recursive (false), m_parents (), m_children () { } @@ -172,13 +172,13 @@ return retval; } -profiler::profiler (void) +profiler::profiler () : m_known_functions (), m_fcn_index (), m_enabled (false), m_call_tree (new tree_node (nullptr, 0)), m_active_fcn (nullptr), m_last_time (-1.0) { } -profiler::~profiler (void) +profiler::~profiler () { delete m_call_tree; } @@ -253,7 +253,7 @@ } void -profiler::reset (void) +profiler::reset () { if (enabled ()) error ("profile: can't reset active profiler"); @@ -272,7 +272,7 @@ } octave_value -profiler::get_flat (void) const +profiler::get_flat () const { octave_value retval; @@ -334,7 +334,7 @@ } octave_value -profiler::get_hierarchical (void) const +profiler::get_hierarchical () const { octave_value retval; @@ -360,7 +360,7 @@ } double -profiler::query_time (void) const +profiler::query_time () const { sys::time now; @@ -372,7 +372,7 @@ } void -profiler::add_current_time (void) +profiler::add_current_time () { if (m_active_fcn) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/profiler.h --- a/libinterp/parse-tree/profiler.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/profiler.h Tue Jan 24 17:19:44 2023 -0800 @@ -82,14 +82,14 @@ enter& operator = (const enter&) = delete; - ~enter (void) + ~enter () { if (m_enabled) m_profiler.exit_function (m_fcn); } }; - profiler (void); + profiler (); // No copying! @@ -97,15 +97,15 @@ profiler& operator = (const profiler&) = delete; - virtual ~profiler (void); + virtual ~profiler (); - bool enabled (void) const { return m_enabled; } + bool enabled () const { return m_enabled; } void set_active (bool); - void reset (void); + void reset (); - octave_value get_flat (void) const; - octave_value get_hierarchical (void) const; + octave_value get_flat () const; + octave_value get_hierarchical () const; private: @@ -115,7 +115,7 @@ struct stats { public: - stats (void); + stats (); typedef std::set function_set; @@ -143,7 +143,7 @@ tree_node (tree_node *, octave_idx_type); - virtual ~tree_node (void); + virtual ~tree_node (); // No copying! @@ -212,12 +212,12 @@ // This is not static because in the future, maybe we want a flag // in the profiler or something to choose between cputime, wall-time, // user-time, system-time, ... - double query_time (void) const; + double query_time () const; // Add the time elapsed since last_time to the function we're currently in. // This is called from two different positions, thus it is useful to have // it as a separate function. - void add_current_time (void); + void add_current_time (); }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-anon-scopes.h --- a/libinterp/parse-tree/pt-anon-scopes.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-anon-scopes.h Tue Jan 24 17:19:44 2023 -0800 @@ -41,7 +41,7 @@ { public: - tree_anon_scopes (void) = delete; + tree_anon_scopes () = delete; tree_anon_scopes (tree_anon_fcn_handle& anon_fh); @@ -51,11 +51,11 @@ tree_anon_scopes& operator = (const tree_anon_scopes&) = delete; - ~tree_anon_scopes (void) = default; + ~tree_anon_scopes () = default; - std::set fcn_parameters (void) const { return m_params; } + std::set fcn_parameters () const { return m_params; } - std::set free_variables (void) const { return m_vars; } + std::set free_variables () const { return m_vars; } // The following methods, though public, don't belong to the // intended user interface of this class. diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-arg-list.cc --- a/libinterp/parse-tree/pt-arg-list.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-arg-list.cc Tue Jan 24 17:19:44 2023 -0800 @@ -43,7 +43,7 @@ // Argument lists. -tree_argument_list::~tree_argument_list (void) +tree_argument_list::~tree_argument_list () { while (! empty ()) { @@ -66,7 +66,7 @@ } bool -tree_argument_list::all_elements_are_constant (void) const +tree_argument_list::all_elements_are_constant () const { for (const tree_expression *elt : *this) { @@ -78,7 +78,7 @@ } bool -tree_argument_list::is_valid_lvalue_list (void) const +tree_argument_list::is_valid_lvalue_list () const { bool retval = true; @@ -98,7 +98,7 @@ } string_vector -tree_argument_list::get_arg_names (void) const +tree_argument_list::get_arg_names () const { int len = length (); @@ -113,7 +113,7 @@ } std::list -tree_argument_list::variable_names (void) const +tree_argument_list::variable_names () const { std::list retval; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-arg-list.h --- a/libinterp/parse-tree/pt-arg-list.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-arg-list.h Tue Jan 24 17:19:44 2023 -0800 @@ -53,7 +53,7 @@ typedef tree_expression *element_type; - tree_argument_list (void) + tree_argument_list () : m_list_includes_magic_tilde (false), m_simple_assign_lhs (false) { } @@ -67,19 +67,19 @@ tree_argument_list& operator = (const tree_argument_list&) = delete; - ~tree_argument_list (void); + ~tree_argument_list (); - bool has_magic_tilde (void) const + bool has_magic_tilde () const { return m_list_includes_magic_tilde; } - bool includes_magic_tilde (void) const + bool includes_magic_tilde () const { return m_list_includes_magic_tilde; } - tree_expression * remove_front (void) + tree_expression * remove_front () { auto p = begin (); tree_expression *retval = *p; @@ -89,17 +89,17 @@ void append (const element_type& s); - void mark_as_simple_assign_lhs (void) { m_simple_assign_lhs = true; } + void mark_as_simple_assign_lhs () { m_simple_assign_lhs = true; } - bool is_simple_assign_lhs (void) { return m_simple_assign_lhs; } + bool is_simple_assign_lhs () { return m_simple_assign_lhs; } - bool all_elements_are_constant (void) const; + bool all_elements_are_constant () const; - bool is_valid_lvalue_list (void) const; + bool is_valid_lvalue_list () const; - string_vector get_arg_names (void) const; + string_vector get_arg_names () const; - std::list variable_names (void) const; + std::list variable_names () const; tree_argument_list * dup (symbol_scope& scope) const; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-args-block.cc --- a/libinterp/parse-tree/pt-args-block.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-args-block.cc Tue Jan 24 17:19:44 2023 -0800 @@ -31,7 +31,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) -tree_args_block_validation_list::~tree_args_block_validation_list (void) +tree_args_block_validation_list::~tree_args_block_validation_list () { while (! empty ()) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-args-block.h --- a/libinterp/parse-tree/pt-args-block.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-args-block.h Tue Jan 24 17:19:44 2023 -0800 @@ -55,12 +55,12 @@ tree_arg_size_spec& operator = (const tree_arg_size_spec&) = delete; - ~tree_arg_size_spec (void) + ~tree_arg_size_spec () { delete m_size_args; } - tree_argument_list * size_args (void) { return m_size_args; } + tree_argument_list * size_args () { return m_size_args; } void accept (tree_walker& tw) { @@ -86,12 +86,12 @@ tree_arg_validation_fcns& operator = (const tree_arg_validation_fcns&) = delete; - ~tree_arg_validation_fcns (void) + ~tree_arg_validation_fcns () { delete m_fcn_args; } - tree_argument_list * fcn_args (void) { return m_fcn_args; } + tree_argument_list * fcn_args () { return m_fcn_args; } void accept (tree_walker& tw) { @@ -122,7 +122,7 @@ tree_arg_validation& operator = (const tree_arg_validation&) = delete; - ~tree_arg_validation (void) + ~tree_arg_validation () { delete m_arg_name; delete m_size_spec; @@ -136,17 +136,17 @@ m_arg_name = name; } - tree_expression * identifier_expression (void) { return m_arg_name; } + tree_expression * identifier_expression () { return m_arg_name; } - tree_arg_size_spec * size_spec (void) { return m_size_spec; } + tree_arg_size_spec * size_spec () { return m_size_spec; } - tree_identifier * class_name (void) { return m_class_name; } + tree_identifier * class_name () { return m_class_name; } tree_arg_validation_fcns * - validation_fcns (void) { return m_validation_fcns; } + validation_fcns () { return m_validation_fcns; } tree_expression * - initializer_expression (void) { return m_default_value; } + initializer_expression () { return m_default_value; } void accept (tree_walker& tw) { @@ -169,7 +169,7 @@ { public: - tree_args_block_validation_list (void) { } + tree_args_block_validation_list () { } tree_args_block_validation_list (tree_arg_validation *a) { append (a); } @@ -183,7 +183,7 @@ tree_args_block_validation_list& operator = (const tree_args_block_validation_list&) = delete; - ~tree_args_block_validation_list (void); + ~tree_args_block_validation_list (); void accept (tree_walker& tw) { @@ -208,12 +208,12 @@ tree_args_block_attribute_list& operator = (const tree_args_block_attribute_list&) = delete; - ~tree_args_block_attribute_list (void) + ~tree_args_block_attribute_list () { delete m_attr; } - tree_identifier * attribute (void) { return m_attr; } + tree_identifier * attribute () { return m_attr; } void accept (tree_walker& tw) { @@ -245,7 +245,7 @@ tree_arguments_block& operator = (const tree_arguments_block&) = delete; - ~tree_arguments_block (void) + ~tree_arguments_block () { delete m_attr_list; delete m_validation_list; @@ -254,19 +254,19 @@ delete m_trail_comm; } - tree_args_block_attribute_list * attribute_list (void) + tree_args_block_attribute_list * attribute_list () { return m_attr_list; } - tree_args_block_validation_list * validation_list (void) + tree_args_block_validation_list * validation_list () { return m_validation_list; } - comment_list * leading_comment (void) { return m_lead_comm; } + comment_list * leading_comment () { return m_lead_comm; } - comment_list * trailing_comment (void) { return m_trail_comm; } + comment_list * trailing_comment () { return m_trail_comm; } void accept (tree_walker& tw) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-array-list.cc --- a/libinterp/parse-tree/pt-array-list.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-array-list.cc Tue Jan 24 17:19:44 2023 -0800 @@ -34,7 +34,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) -tree_array_list::~tree_array_list (void) +tree_array_list::~tree_array_list () { while (! empty ()) { @@ -45,7 +45,7 @@ } bool -tree_array_list::all_elements_are_constant (void) const +tree_array_list::all_elements_are_constant () const { for (const tree_argument_list *elt : *this) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-array-list.h --- a/libinterp/parse-tree/pt-array-list.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-array-list.h Tue Jan 24 17:19:44 2023 -0800 @@ -64,9 +64,9 @@ tree_array_list& operator = (const tree_array_list&) = delete; - ~tree_array_list (void); + ~tree_array_list (); - bool all_elements_are_constant (void) const; + bool all_elements_are_constant () const; // FIXME: should we import the functions from the base class and // overload them here, or should we use a different name so we don't diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-assign.cc --- a/libinterp/parse-tree/pt-assign.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-assign.cc Tue Jan 24 17:19:44 2023 -0800 @@ -48,7 +48,7 @@ m_ans_assign (), m_etype (t) { } -tree_simple_assignment::~tree_simple_assignment (void) +tree_simple_assignment::~tree_simple_assignment () { if (! m_preserve) delete m_lhs; @@ -57,7 +57,7 @@ } std::string -tree_simple_assignment::oper (void) const +tree_simple_assignment::oper () const { return octave_value::assign_op_as_string (m_etype); } @@ -159,7 +159,7 @@ : tree_expression (l, c), m_lhs (lst), m_rhs (r), m_preserve (plhs) { } -tree_multi_assignment::~tree_multi_assignment (void) +tree_multi_assignment::~tree_multi_assignment () { if (! m_preserve) delete m_lhs; @@ -168,7 +168,7 @@ } std::string -tree_multi_assignment::oper (void) const +tree_multi_assignment::oper () const { return octave_value::assign_op_as_string (op_type ()); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-assign.h --- a/libinterp/parse-tree/pt-assign.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-assign.h Tue Jan 24 17:19:44 2023 -0800 @@ -66,17 +66,17 @@ tree_simple_assignment& operator = (const tree_simple_assignment&) = delete; - ~tree_simple_assignment (void); + ~tree_simple_assignment (); - bool rvalue_ok (void) const { return true; } + bool rvalue_ok () const { return true; } - bool is_assignment_expression (void) const { return true; } + bool is_assignment_expression () const { return true; } - std::string oper (void) const; + std::string oper () const; - tree_expression * left_hand_side (void) { return m_lhs; } + tree_expression * left_hand_side () { return m_lhs; } - tree_expression * right_hand_side (void) { return m_rhs; } + tree_expression * right_hand_side () { return m_rhs; } tree_expression * dup (symbol_scope& scope) const; @@ -92,7 +92,7 @@ tw.visit_simple_assignment (*this); } - octave_value::assign_op op_type (void) const { return m_etype; } + octave_value::assign_op op_type () const { return m_etype; } private: @@ -137,17 +137,17 @@ tree_multi_assignment& operator = (const tree_multi_assignment&) = delete; - ~tree_multi_assignment (void); + ~tree_multi_assignment (); - bool is_assignment_expression (void) const { return true; } + bool is_assignment_expression () const { return true; } - bool rvalue_ok (void) const { return true; } + bool rvalue_ok () const { return true; } - std::string oper (void) const; + std::string oper () const; - tree_argument_list * left_hand_side (void) { return m_lhs; } + tree_argument_list * left_hand_side () { return m_lhs; } - tree_expression * right_hand_side (void) { return m_rhs; } + tree_expression * right_hand_side () { return m_rhs; } tree_expression * dup (symbol_scope& scope) const; @@ -165,7 +165,7 @@ tw.visit_multi_assignment (*this); } - octave_value::assign_op op_type (void) const + octave_value::assign_op op_type () const { return octave_value::op_asn_eq; } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-binop.cc --- a/libinterp/parse-tree/pt-binop.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-binop.cc Tue Jan 24 17:19:44 2023 -0800 @@ -48,7 +48,7 @@ } std::string -tree_binary_expression::oper (void) const +tree_binary_expression::oper () const { return octave_value::binary_op_as_string (m_etype); } @@ -164,7 +164,7 @@ // Boolean expressions. std::string -tree_boolean_expression::oper (void) const +tree_boolean_expression::oper () const { std::string retval = ""; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-binop.h --- a/libinterp/parse-tree/pt-binop.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-binop.h Tue Jan 24 17:19:44 2023 -0800 @@ -68,7 +68,7 @@ tree_binary_expression& operator = (const tree_binary_expression&) = delete; - ~tree_binary_expression (void) + ~tree_binary_expression () { if (! m_preserve_operands) { @@ -77,18 +77,18 @@ } } - void preserve_operands (void) { m_preserve_operands = true; } + void preserve_operands () { m_preserve_operands = true; } - bool is_binary_expression (void) const { return true; } + bool is_binary_expression () const { return true; } - bool rvalue_ok (void) const { return true; } + bool rvalue_ok () const { return true; } - std::string oper (void) const; + std::string oper () const; - octave_value::binary_op op_type (void) const { return m_etype; } + octave_value::binary_op op_type () const { return m_etype; } - tree_expression * lhs (void) { return m_lhs; } - tree_expression * rhs (void) { return m_rhs; } + tree_expression * lhs () { return m_lhs; } + tree_expression * rhs () { return m_rhs; } tree_expression * dup (symbol_scope& scope) const; @@ -104,7 +104,7 @@ tw.visit_binary_expression (*this); } - std::string profiler_name (void) const { return "binary " + oper (); } + std::string profiler_name () const { return "binary " + oper (); } void matlab_style_short_circuit_warning (const char *op); @@ -143,7 +143,7 @@ tree_braindead_shortcircuit_binary_expression& operator = (const tree_braindead_shortcircuit_binary_expression&) = delete; - ~tree_braindead_shortcircuit_binary_expression (void) = default; + ~tree_braindead_shortcircuit_binary_expression () = default; tree_expression * dup (symbol_scope& scope) const; @@ -178,15 +178,15 @@ tree_boolean_expression& operator = (const tree_boolean_expression&) = delete; - ~tree_boolean_expression (void) = default; + ~tree_boolean_expression () = default; - bool is_boolean_expression (void) const { return true; } + bool is_boolean_expression () const { return true; } - bool rvalue_ok (void) const { return true; } + bool rvalue_ok () const { return true; } - std::string oper (void) const; + std::string oper () const; - type op_type (void) const { return m_etype; } + type op_type () const { return m_etype; } tree_expression * dup (symbol_scope& scope) const; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-bp.h --- a/libinterp/parse-tree/pt-bp.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-bp.h Tue Jan 24 17:19:44 2023 -0800 @@ -56,9 +56,9 @@ tree_breakpoint& operator = (const tree_breakpoint&) = delete; - ~tree_breakpoint (void) = default; + ~tree_breakpoint () = default; - bool success (void) const { return m_found; } + bool success () const { return m_found; } void visit_argument_list (tree_argument_list&); @@ -147,11 +147,11 @@ void visit_unwind_protect_command (tree_unwind_protect_command&); - octave_value_list get_list (void) { return m_bp_list; } + octave_value_list get_list () { return m_bp_list; } - octave_value_list get_cond_list (void) { return m_bp_cond_list; } + octave_value_list get_cond_list () { return m_bp_cond_list; } - int get_line (void) { return m_found ? m_line : 0; } + int get_line () { return m_found ? m_line : 0; } private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-cbinop.h --- a/libinterp/parse-tree/pt-cbinop.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-cbinop.h Tue Jan 24 17:19:44 2023 -0800 @@ -54,12 +54,12 @@ m_etype (ct) { } - octave_value::compound_binary_op cop_type (void) const { return m_etype; } + octave_value::compound_binary_op cop_type () const { return m_etype; } - bool rvalue_ok (void) const { return true; } + bool rvalue_ok () const { return true; } - tree_expression * clhs (void) { return m_lhs; } - tree_expression * crhs (void) { return m_rhs; } + tree_expression * clhs () { return m_lhs; } + tree_expression * crhs () { return m_rhs; } octave_value evaluate (tree_evaluator&, int nargout = 1); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-cell.h --- a/libinterp/parse-tree/pt-cell.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-cell.h Tue Jan 24 17:19:44 2023 -0800 @@ -57,11 +57,11 @@ tree_cell& operator = (const tree_cell&) = delete; - ~tree_cell (void) = default; + ~tree_cell () = default; - bool iscell (void) const { return true; } + bool iscell () const { return true; } - bool rvalue_ok (void) const { return true; } + bool rvalue_ok () const { return true; } tree_expression * dup (symbol_scope& scope) const; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-check.h --- a/libinterp/parse-tree/pt-check.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-check.h Tue Jan 24 17:19:44 2023 -0800 @@ -42,7 +42,7 @@ { public: - tree_checker (void) + tree_checker () : m_do_lvalue_check (false), m_file_name () { } // No copying! @@ -51,7 +51,7 @@ tree_checker& operator = (const tree_checker&) = delete; - ~tree_checker (void) = default; + ~tree_checker () = default; void visit_argument_list (tree_argument_list&); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-classdef.cc --- a/libinterp/parse-tree/pt-classdef.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-classdef.cc Tue Jan 24 17:19:44 2023 -0800 @@ -95,7 +95,7 @@ // Classdef attribute_list -tree_classdef_attribute_list::~tree_classdef_attribute_list (void) +tree_classdef_attribute_list::~tree_classdef_attribute_list () { while (! empty ()) { @@ -109,7 +109,7 @@ // Classdef superclass_list -tree_classdef_superclass_list::~tree_classdef_superclass_list (void) +tree_classdef_superclass_list::~tree_classdef_superclass_list () { while (! empty ()) { @@ -143,26 +143,26 @@ m_doc_string (check_for_doc_string (m_comments)) { } -tree_classdef_property::~tree_classdef_property (void) +tree_classdef_property::~tree_classdef_property () { delete m_av; } -tree_identifier *tree_classdef_property::ident (void) +tree_identifier *tree_classdef_property::ident () { tree_expression *id_expr = m_av->identifier_expression (); return dynamic_cast (id_expr); } -tree_expression *tree_classdef_property::expression (void) +tree_expression *tree_classdef_property::expression () { return m_av->initializer_expression (); } // Classdef property_list -tree_classdef_property_list::~tree_classdef_property_list (void) +tree_classdef_property_list::~tree_classdef_property_list () { while (! empty ()) { @@ -188,7 +188,7 @@ // Classdef events_list -tree_classdef_events_list::~tree_classdef_events_list (void) +tree_classdef_events_list::~tree_classdef_events_list () { while (! empty ()) { @@ -211,7 +211,7 @@ // Classdef enum_list -tree_classdef_enum_list::~tree_classdef_enum_list (void) +tree_classdef_enum_list::~tree_classdef_enum_list () { while (! empty ()) { @@ -225,7 +225,7 @@ // Classdef body -tree_classdef_body::tree_classdef_body (void) +tree_classdef_body::tree_classdef_body () : m_properties_lst (), m_methods_lst (), m_events_lst (), m_enum_lst () { } @@ -257,7 +257,7 @@ append (enb); } -tree_classdef_body::~tree_classdef_body (void) +tree_classdef_body::~tree_classdef_body () { while (! m_properties_lst.empty ()) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-classdef.h --- a/libinterp/parse-tree/pt-classdef.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-classdef.h Tue Jan 24 17:19:44 2023 -0800 @@ -50,7 +50,7 @@ { public: - tree_superclass_ref (void) = delete; + tree_superclass_ref () = delete; tree_superclass_ref (const std::string& meth, const std::string& cls, int l = -1, int c = -1) @@ -63,12 +63,12 @@ tree_superclass_ref& operator = (const tree_superclass_ref&) = delete; - std::string method_name (void) const + std::string method_name () const { return m_method_name; } - std::string class_name (void) const { return m_class_name; } + std::string class_name () const { return m_class_name; } tree_superclass_ref * dup (symbol_scope& scope) const; @@ -101,7 +101,7 @@ { public: - tree_metaclass_query (void) = delete; + tree_metaclass_query () = delete; tree_metaclass_query (const std::string& cls, int l = -1, int c = -1) : tree_expression (l, c), m_class_name (cls) @@ -113,7 +113,7 @@ tree_metaclass_query& operator = (const tree_metaclass_query&) = delete; - std::string class_name (void) const { return m_class_name; } + std::string class_name () const { return m_class_name; } tree_metaclass_query * dup (symbol_scope& scope) const; @@ -153,17 +153,17 @@ tree_classdef_attribute& operator = (const tree_classdef_attribute&) = delete; - ~tree_classdef_attribute (void) + ~tree_classdef_attribute () { delete m_id; delete m_expr; } - tree_identifier * ident (void) { return m_id; } + tree_identifier * ident () { return m_id; } - tree_expression * expression (void) { return m_expr; } + tree_expression * expression () { return m_expr; } - bool negate (void) { return m_neg; } + bool negate () { return m_neg; } void accept (tree_walker& tw) { @@ -181,7 +181,7 @@ { public: - tree_classdef_attribute_list (void) { } + tree_classdef_attribute_list () { } tree_classdef_attribute_list (tree_classdef_attribute *a) { append (a); } @@ -196,7 +196,7 @@ tree_classdef_attribute_list& operator = (const tree_classdef_attribute_list&) = delete; - ~tree_classdef_attribute_list (void); + ~tree_classdef_attribute_list (); void accept (tree_walker& tw) { @@ -219,9 +219,9 @@ tree_classdef_superclass& operator = (const tree_classdef_superclass&) = delete; - ~tree_classdef_superclass (void) = default; + ~tree_classdef_superclass () = default; - std::string class_name (void) { return m_cls_name; } + std::string class_name () { return m_cls_name; } void accept (tree_walker& tw) { @@ -238,7 +238,7 @@ { public: - tree_classdef_superclass_list (void) { } + tree_classdef_superclass_list () { } tree_classdef_superclass_list (tree_classdef_superclass *sc) { @@ -256,7 +256,7 @@ tree_classdef_superclass_list& operator = (const tree_classdef_superclass_list&) = delete; - ~tree_classdef_superclass_list (void); + ~tree_classdef_superclass_list (); void accept (tree_walker& tw) { @@ -282,7 +282,7 @@ tree_classdef_element& operator = (const tree_classdef_element&) = delete; - ~tree_classdef_element (void) + ~tree_classdef_element () { delete m_attr_list; delete m_elt_list; @@ -290,13 +290,13 @@ delete m_trail_comm; } - tree_classdef_attribute_list * attribute_list (void) { return m_attr_list; } + tree_classdef_attribute_list * attribute_list () { return m_attr_list; } - T * element_list (void) { return m_elt_list; } + T * element_list () { return m_elt_list; } - comment_list * leading_comment (void) { return m_lead_comm; } + comment_list * leading_comment () { return m_lead_comm; } - comment_list * trailing_comment (void) { return m_trail_comm; } + comment_list * trailing_comment () { return m_trail_comm; } void accept (tree_walker&) { } @@ -328,19 +328,19 @@ tree_classdef_property& operator = (const tree_classdef_property&) = delete; - ~tree_classdef_property (void); + ~tree_classdef_property (); - tree_identifier * ident (void); + tree_identifier * ident (); - tree_expression * expression (void); + tree_expression * expression (); - comment_list * comments (void) const { return m_comments; } + comment_list * comments () const { return m_comments; } void doc_string (const std::string& txt) { m_doc_string = txt; } - std::string doc_string (void) const { return m_doc_string; } + std::string doc_string () const { return m_doc_string; } - bool have_doc_string (void) const { return ! m_doc_string.empty (); } + bool have_doc_string () const { return ! m_doc_string.empty (); } void accept (tree_walker& tw) { @@ -358,7 +358,7 @@ { public: - tree_classdef_property_list (void) { } + tree_classdef_property_list () { } tree_classdef_property_list (tree_classdef_property *p) { append (p); } @@ -372,7 +372,7 @@ tree_classdef_property_list& operator = (const tree_classdef_property_list&) = delete; - ~tree_classdef_property_list (void); + ~tree_classdef_property_list (); void accept (tree_walker& tw) { @@ -399,7 +399,7 @@ tree_classdef_properties_block& operator = (const tree_classdef_properties_block&) = delete; - ~tree_classdef_properties_block (void) = default; + ~tree_classdef_properties_block () = default; void accept (tree_walker& tw) { @@ -411,7 +411,7 @@ { public: - tree_classdef_methods_list (void) { } + tree_classdef_methods_list () { } tree_classdef_methods_list (const octave_value& f) { append (f); } @@ -425,7 +425,7 @@ tree_classdef_methods_list& operator = (const tree_classdef_methods_list&) = delete; - ~tree_classdef_methods_list (void) = default; + ~tree_classdef_methods_list () = default; void accept (tree_walker& tw) { @@ -452,7 +452,7 @@ tree_classdef_methods_block& operator = (const tree_classdef_methods_block&) = delete; - ~tree_classdef_methods_block (void) = default; + ~tree_classdef_methods_block () = default; void accept (tree_walker& tw) { @@ -473,20 +473,20 @@ tree_classdef_event& operator = (const tree_classdef_event&) = delete; - ~tree_classdef_event (void) + ~tree_classdef_event () { delete m_id; } - tree_identifier * ident (void) { return m_id; } + tree_identifier * ident () { return m_id; } - comment_list * comments (void) const { return m_comments; } + comment_list * comments () const { return m_comments; } void doc_string (const std::string& txt) { m_doc_string = txt; } - std::string doc_string (void) const { return m_doc_string; } + std::string doc_string () const { return m_doc_string; } - bool have_doc_string (void) const { return ! m_doc_string.empty (); } + bool have_doc_string () const { return ! m_doc_string.empty (); } void accept (tree_walker& tw) { @@ -504,7 +504,7 @@ { public: - tree_classdef_events_list (void) { } + tree_classdef_events_list () { } tree_classdef_events_list (tree_classdef_event *e) { append (e); } @@ -519,7 +519,7 @@ tree_classdef_events_list& operator = (const tree_classdef_events_list&) = delete; - ~tree_classdef_events_list (void); + ~tree_classdef_events_list (); void accept (tree_walker& tw) { @@ -546,7 +546,7 @@ tree_classdef_events_block& operator = (const tree_classdef_events_block&) = delete; - ~tree_classdef_events_block (void) = default; + ~tree_classdef_events_block () = default; void accept (tree_walker& tw) { @@ -567,23 +567,23 @@ tree_classdef_enum& operator = (const tree_classdef_enum&) = delete; - ~tree_classdef_enum (void) + ~tree_classdef_enum () { delete m_id; delete m_expr; } - tree_identifier * ident (void) { return m_id; } + tree_identifier * ident () { return m_id; } - tree_expression * expression (void) { return m_expr; } + tree_expression * expression () { return m_expr; } - comment_list * comments (void) const { return m_comments; } + comment_list * comments () const { return m_comments; } void doc_string (const std::string& txt) { m_doc_string = txt; } - std::string doc_string (void) const { return m_doc_string; } + std::string doc_string () const { return m_doc_string; } - bool have_doc_string (void) const { return ! m_doc_string.empty (); } + bool have_doc_string () const { return ! m_doc_string.empty (); } void accept (tree_walker& tw) { @@ -602,7 +602,7 @@ { public: - tree_classdef_enum_list (void) { } + tree_classdef_enum_list () { } tree_classdef_enum_list (tree_classdef_enum *e) { append (e); } @@ -616,7 +616,7 @@ tree_classdef_enum_list& operator = (const tree_classdef_enum_list&) = delete; - ~tree_classdef_enum_list (void); + ~tree_classdef_enum_list (); void accept (tree_walker& tw) { @@ -643,7 +643,7 @@ tree_classdef_enum_block& operator = (const tree_classdef_enum_block&) = delete; - ~tree_classdef_enum_block (void) = default; + ~tree_classdef_enum_block () = default; void accept (tree_walker& tw) { @@ -673,7 +673,7 @@ typedef std::list::const_iterator enum_list_const_iterator; - tree_classdef_body (void); + tree_classdef_body (); tree_classdef_body (tree_classdef_properties_block *pb); @@ -689,7 +689,7 @@ tree_classdef_body& operator = (const tree_classdef_body&) = delete; - ~tree_classdef_body (void); + ~tree_classdef_body (); void append (tree_classdef_properties_block *pb) { @@ -711,31 +711,31 @@ m_enum_lst.push_back (enb); } - std::list properties_list (void) + std::list properties_list () { return m_properties_lst; } - std::list methods_list (void) + std::list methods_list () { return m_methods_lst; } - std::list events_list (void) + std::list events_list () { return m_events_lst; } - std::list enum_list (void) + std::list enum_list () { return m_enum_lst; } void doc_string (const std::string& txt) { m_doc_string = txt; } - std::string doc_string (void) const { return m_doc_string; } + std::string doc_string () const { return m_doc_string; } - bool have_doc_string (void) const { return ! m_doc_string.empty (); } + bool have_doc_string () const { return ! m_doc_string.empty (); } void accept (tree_walker& tw) { @@ -780,7 +780,7 @@ tree_classdef& operator = (const tree_classdef&) = delete; - ~tree_classdef (void) + ~tree_classdef () { delete m_attr_list; delete m_id; @@ -790,29 +790,29 @@ delete m_trail_comm; } - symbol_scope scope (void) { return m_scope; } + symbol_scope scope () { return m_scope; } tree_classdef_attribute_list * - attribute_list (void) { return m_attr_list; } + attribute_list () { return m_attr_list; } - tree_identifier * ident (void) { return m_id; } + tree_identifier * ident () { return m_id; } tree_classdef_superclass_list * - superclass_list (void) { return m_supclass_list; } + superclass_list () { return m_supclass_list; } - tree_classdef_body * body (void) { return m_element_list; } + tree_classdef_body * body () { return m_element_list; } - comment_list * leading_comment (void) { return m_lead_comm; } - comment_list * trailing_comment (void) { return m_trail_comm; } + comment_list * leading_comment () { return m_lead_comm; } + comment_list * trailing_comment () { return m_trail_comm; } - std::string package_name (void) const { return m_pack_name; } + std::string package_name () const { return m_pack_name; } - std::string file_name (void) const { return m_file_name; } + std::string file_name () const { return m_file_name; } octave_value make_meta_class (interpreter& interp, bool is_at_folder = false); - std::string doc_string (void) const + std::string doc_string () const { return m_element_list ? m_element_list->doc_string () : ""; } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-cmd.h --- a/libinterp/parse-tree/pt-cmd.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-cmd.h Tue Jan 24 17:19:44 2023 -0800 @@ -52,7 +52,7 @@ tree_command& operator = (const tree_command&) = delete; - virtual ~tree_command (void) = default; + virtual ~tree_command () = default; }; // No-op. @@ -71,21 +71,21 @@ tree_no_op_command& operator = (const tree_no_op_command&) = delete; - ~tree_no_op_command (void) = default; + ~tree_no_op_command () = default; void accept (tree_walker& tw) { tw.visit_no_op_command (*this); } - bool is_end_of_fcn_or_script (void) const + bool is_end_of_fcn_or_script () const { return (m_orig_cmd == "endfunction" || m_orig_cmd == "endscript"); } - bool is_end_of_file (void) const { return m_eof; } + bool is_end_of_file () const { return m_eof; } - std::string original_command (void) { return m_orig_cmd; } + std::string original_command () { return m_orig_cmd; } private: @@ -109,14 +109,14 @@ tree_function_def& operator = (const tree_function_def&) = delete; - ~tree_function_def (void) = default; + ~tree_function_def () = default; void accept (tree_walker& tw) { tw.visit_function_def (*this); } - octave_value function (void) { return m_fcn; } + octave_value function () { return m_fcn; } private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-colon.h --- a/libinterp/parse-tree/pt-colon.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-colon.h Tue Jan 24 17:19:44 2023 -0800 @@ -66,7 +66,7 @@ tree_colon_expression& operator = (const tree_colon_expression&) = delete; - ~tree_colon_expression (void) + ~tree_colon_expression () { if (! m_save_base) delete m_base; @@ -75,21 +75,21 @@ delete m_increment; } - void preserve_base (void) { m_save_base = true; } + void preserve_base () { m_save_base = true; } - bool rvalue_ok (void) const { return true; } + bool rvalue_ok () const { return true; } void eval_error (const std::string& s) const; - tree_expression * base (void) { return m_base; } + tree_expression * base () { return m_base; } - tree_expression * limit (void) { return m_limit; } + tree_expression * limit () { return m_limit; } - tree_expression * increment (void) { return m_increment; } + tree_expression * increment () { return m_increment; } tree_expression * dup (symbol_scope& scope) const; - bool is_colon_expression (void) const { return true; } + bool is_colon_expression () const { return true; } octave_value evaluate (tree_evaluator&, int nargout = 1); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-const.h --- a/libinterp/parse-tree/pt-const.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-const.h Tue Jan 24 17:19:44 2023 -0800 @@ -67,13 +67,13 @@ tree_constant& operator = (const tree_constant&) = delete; - ~tree_constant (void) = default; + ~tree_constant () = default; // Type. It would be nice to eliminate the need for this. - bool is_constant (void) const { return true; } + bool is_constant () const { return true; } - void maybe_mutate (void) { m_value.maybe_mutate (); } + void maybe_mutate () { m_value.maybe_mutate (); } void print (std::ostream& os, bool pr_as_read_syntax = false, bool pr_orig_txt = true); @@ -81,9 +81,9 @@ void print_raw (std::ostream& os, bool pr_as_read_syntax = false, bool pr_orig_txt = true); - bool rvalue_ok (void) const { return true; } + bool rvalue_ok () const { return true; } - octave_value value (void) { return m_value; } + octave_value value () { return m_value; } tree_expression * dup (symbol_scope& scope) const; @@ -97,7 +97,7 @@ void stash_original_text (const std::string& s) { m_orig_text = s; } - std::string original_text (void) const { return m_orig_text; } + std::string original_text () const { return m_orig_text; } octave_value evaluate (tree_evaluator&, int nargout = 1) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-decl.cc --- a/libinterp/parse-tree/pt-decl.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-decl.cc Tue Jan 24 17:19:44 2023 -0800 @@ -51,7 +51,7 @@ error ("tree_decl_elt: invalid ID"); } -tree_decl_elt::~tree_decl_elt (void) +tree_decl_elt::~tree_decl_elt () { delete m_id; delete m_expr; @@ -84,7 +84,7 @@ } } -tree_decl_command::~tree_decl_command (void) +tree_decl_command::~tree_decl_command () { delete m_init_list; } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-decl.h --- a/libinterp/parse-tree/pt-decl.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-decl.h Tue Jan 24 17:19:44 2023 -0800 @@ -65,31 +65,31 @@ tree_decl_elt& operator = (const tree_decl_elt&) = delete; - ~tree_decl_elt (void); + ~tree_decl_elt (); - void mark_as_formal_parameter (void) + void mark_as_formal_parameter () { m_id->mark_as_formal_parameter (); } - bool lvalue_ok (void) { return m_id->lvalue_ok (); } + bool lvalue_ok () { return m_id->lvalue_ok (); } octave_lvalue lvalue (tree_evaluator& tw) { return m_id->lvalue (tw); } - void mark_global (void) { type = global; } - bool is_global (void) const { return type == global; } + void mark_global () { type = global; } + bool is_global () const { return type == global; } - void mark_persistent (void) { type = persistent; } - bool is_persistent (void) const { return type == persistent; } + void mark_persistent () { type = persistent; } + bool is_persistent () const { return type == persistent; } - tree_identifier * ident (void) { return m_id; } + tree_identifier * ident () { return m_id; } - std::string name (void) const { return m_id->name (); } + std::string name () const { return m_id->name (); } - tree_expression * expression (void) { return m_expr; } + tree_expression * expression () { return m_expr; } tree_decl_elt * dup (symbol_scope& scope) const; @@ -113,7 +113,7 @@ { public: - tree_decl_init_list (void) { } + tree_decl_init_list () { } tree_decl_init_list (tree_decl_elt *t) { append (t); } @@ -123,7 +123,7 @@ tree_decl_init_list& operator = (const tree_decl_init_list&) = delete; - ~tree_decl_init_list (void) + ~tree_decl_init_list () { while (! empty ()) { @@ -133,19 +133,19 @@ } } - void mark_global (void) + void mark_global () { for (tree_decl_elt *elt : *this) elt->mark_global (); } - void mark_persistent (void) + void mark_persistent () { for (tree_decl_elt *elt : *this) elt->mark_persistent (); } - std::list variable_names (void) const + std::list variable_names () const { std::list retval; @@ -184,23 +184,23 @@ tree_decl_command& operator = (const tree_decl_command&) = delete; - ~tree_decl_command (void); + ~tree_decl_command (); - void mark_global (void) + void mark_global () { if (m_init_list) m_init_list->mark_global (); } - void mark_persistent (void) + void mark_persistent () { if (m_init_list) m_init_list->mark_persistent (); } - tree_decl_init_list * initializer_list (void) { return m_init_list; } + tree_decl_init_list * initializer_list () { return m_init_list; } - std::string name (void) const { return m_cmd_name; } + std::string name () const { return m_cmd_name; } void accept (tree_walker& tw) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-eval.cc --- a/libinterp/parse-tree/pt-eval.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-eval.cc Tue Jan 24 17:19:44 2023 -0800 @@ -87,9 +87,9 @@ quit_debug_exception& operator = (const quit_debug_exception&) = default; - ~quit_debug_exception (void) = default; - - bool all (void) const { return m_all; } + ~quit_debug_exception () = default; + + bool all () const { return m_all; } private: @@ -113,13 +113,13 @@ m_execution_mode (EX_NORMAL), m_in_debug_repl (false) { } - int server_loop (void); + int server_loop (); void repl (const std::string& prompt = "debug> "); - bool in_debug_repl (void) const { return m_in_debug_repl; } - - void dbcont (void) { m_execution_mode = EX_CONTINUE; } + bool in_debug_repl () const { return m_in_debug_repl; } + + void dbcont () { m_execution_mode = EX_CONTINUE; } void dbquit (bool all = false) { @@ -129,7 +129,7 @@ m_execution_mode = EX_QUIT; } - bool quitting_debugger (void) const; + bool quitting_debugger () const; private: @@ -144,7 +144,7 @@ // with the corresponding tree_evaluator functions or do they need to // remain separate? They perform nearly the same functions. - int debugger::server_loop (void) + int debugger::server_loop () { // Process events from the event queue. @@ -503,7 +503,7 @@ } } - bool debugger::quitting_debugger (void) const + bool debugger::quitting_debugger () const { if (m_execution_mode == EX_QUIT) { @@ -531,7 +531,7 @@ return false; } - bool tree_evaluator::at_top_level (void) const + bool tree_evaluator::at_top_level () const { return m_call_stack.at_top_level (); } @@ -636,7 +636,7 @@ evmgr.pre_input_event (); } - void tree_evaluator::get_line_and_eval (void) + void tree_evaluator::get_line_and_eval () { std::mutex mtx; std::unique_lock lock (mtx); @@ -728,7 +728,7 @@ } } - int tree_evaluator::repl (void) + int tree_evaluator::repl () { // The big loop. Read, Eval, Print, Loop. Normally user // interaction at the command line in a terminal session, but we may @@ -869,7 +869,7 @@ return exit_status; } - int tree_evaluator::server_loop (void) + int tree_evaluator::server_loop () { // Process events from the event queue. @@ -1353,14 +1353,14 @@ } bool - tree_evaluator::statement_printing_enabled (void) + tree_evaluator::statement_printing_enabled () { return ! (m_silent_functions && (m_statement_context == SC_FUNCTION || m_statement_context == SC_SCRIPT)); } void - tree_evaluator::reset_debug_state (void) + tree_evaluator::reset_debug_state () { m_debug_mode = (m_bp_table.have_breakpoints () || m_dbstep_flag != 0 @@ -1414,7 +1414,7 @@ m_debugger_stack.push (dbgr); - frame.add ([=] (void) + frame.add ([=] () { delete m_debugger_stack.top (); m_debugger_stack.pop (); @@ -1437,7 +1437,7 @@ } Matrix - tree_evaluator::ignored_fcn_outputs (void) const + tree_evaluator::ignored_fcn_outputs () const { Matrix retval; @@ -2448,27 +2448,27 @@ m_call_stack.push (fcn); } - void tree_evaluator::pop_stack_frame (void) + void tree_evaluator::pop_stack_frame () { m_call_stack.pop (); } - int tree_evaluator::current_line (void) const + int tree_evaluator::current_line () const { return m_call_stack.current_line (); } - int tree_evaluator::current_column (void) const + int tree_evaluator::current_column () const { return m_call_stack.current_column (); } - int tree_evaluator::debug_user_code_line (void) const + int tree_evaluator::debug_user_code_line () const { return m_call_stack.debug_user_code_line (); } - int tree_evaluator::debug_user_code_column (void) const + int tree_evaluator::debug_user_code_column () const { return m_call_stack.debug_user_code_column (); } @@ -2480,17 +2480,17 @@ frm->display_stopped_in_message (os); } - octave_user_code * tree_evaluator::current_user_code (void) const + octave_user_code * tree_evaluator::current_user_code () const { return m_call_stack.current_user_code (); } - unwind_protect * tree_evaluator::curr_fcn_unwind_protect_frame (void) + unwind_protect * tree_evaluator::curr_fcn_unwind_protect_frame () { return m_call_stack.curr_fcn_unwind_protect_frame (); } - octave_user_code * tree_evaluator::debug_user_code (void) const + octave_user_code * tree_evaluator::debug_user_code () const { return m_call_stack.debug_user_code (); } @@ -2500,7 +2500,7 @@ return m_call_stack.current_function (skip_first); } - octave_function * tree_evaluator::caller_function (void) const + octave_function * tree_evaluator::caller_function () const { return m_call_stack.current_function (true); } @@ -2510,12 +2510,12 @@ return m_call_stack.goto_frame (n, verbose); } - void tree_evaluator::goto_caller_frame (void) + void tree_evaluator::goto_caller_frame () { m_call_stack.goto_caller_frame (); } - void tree_evaluator::goto_base_frame (void) + void tree_evaluator::goto_base_frame () { m_call_stack.goto_base_frame (); } @@ -2525,7 +2525,7 @@ return m_call_stack.restore_frame (n); } - std::string tree_evaluator::get_dispatch_class (void) const + std::string tree_evaluator::get_dispatch_class () const { return m_call_stack.get_dispatch_class (); } @@ -2554,7 +2554,7 @@ } std::list> - tree_evaluator::backtrace_frames (void) const + tree_evaluator::backtrace_frames () const { return m_call_stack.backtrace_frames (); } @@ -2566,7 +2566,7 @@ return m_call_stack.backtrace_info (curr_user_frame, print_subfn); } - std::list tree_evaluator::backtrace_info (void) const + std::list tree_evaluator::backtrace_info () const { return m_call_stack.backtrace_info (); } @@ -2578,17 +2578,17 @@ return m_call_stack.backtrace (curr_user_frame, print_subfn); } - octave_map tree_evaluator::backtrace (void) const + octave_map tree_evaluator::backtrace () const { return m_call_stack.backtrace (); } - octave_map tree_evaluator::empty_backtrace (void) const + octave_map tree_evaluator::empty_backtrace () const { return m_call_stack.empty_backtrace (); } - std::string tree_evaluator::backtrace_message (void) const + std::string tree_evaluator::backtrace_message () const { std::list frames = backtrace_info (); @@ -2623,17 +2623,17 @@ m_call_stack.push (dummy_scope); } - void tree_evaluator::pop_scope (void) + void tree_evaluator::pop_scope () { m_call_stack.pop (); } - symbol_scope tree_evaluator::get_top_scope (void) const + symbol_scope tree_evaluator::get_top_scope () const { return m_call_stack.top_scope (); } - symbol_scope tree_evaluator::get_current_scope (void) const + symbol_scope tree_evaluator::get_current_scope () const { return m_call_stack.current_scope (); } @@ -2686,7 +2686,7 @@ return m_call_stack.max_stack_depth (args, nargout); } - void tree_evaluator::display_call_stack (void) const + void tree_evaluator::display_call_stack () const { m_call_stack.display (); } @@ -2715,7 +2715,7 @@ return symtab.fcn_table_find (name, ovl ()); } - void tree_evaluator::clear_objects (void) + void tree_evaluator::clear_objects () { std::shared_ptr frame = m_call_stack.get_current_stack_frame (); @@ -2747,7 +2747,7 @@ frame->clear_variable_regexp (pattern); } - void tree_evaluator::clear_variables (void) + void tree_evaluator::clear_variables () { std::shared_ptr frame = m_call_stack.get_current_stack_frame (); @@ -2771,7 +2771,7 @@ m_call_stack.clear_global_variable_regexp (pattern); } - void tree_evaluator::clear_global_variables (void) + void tree_evaluator::clear_global_variables () { m_call_stack.clear_global_variables (); } @@ -2821,17 +2821,17 @@ symtab.clear_function_regexp (pattern); } - std::list tree_evaluator::global_variable_names (void) const + std::list tree_evaluator::global_variable_names () const { return m_call_stack.global_variable_names (); } - std::list tree_evaluator::top_level_variable_names (void) const + std::list tree_evaluator::top_level_variable_names () const { return m_call_stack.top_level_variable_names (); } - std::list tree_evaluator::variable_names (void) const + std::list tree_evaluator::variable_names () const { return m_call_stack.variable_names (); } @@ -2941,7 +2941,7 @@ } bool - tree_evaluator::in_user_code (void) const + tree_evaluator::in_user_code () const { return m_call_stack.current_user_code () != nullptr; } @@ -4546,18 +4546,18 @@ } symbol_info_list - tree_evaluator::get_symbol_info (void) + tree_evaluator::get_symbol_info () { return m_call_stack.get_symbol_info (); } symbol_info_list - tree_evaluator::top_scope_symbol_info (void) const + tree_evaluator::top_scope_symbol_info () const { return m_call_stack.top_scope_symbol_info (); } - octave_map tree_evaluator::get_autoload_map (void) const + octave_map tree_evaluator::get_autoload_map () const { Cell fcn_names (dim_vector (m_autoload_map.size (), 1)); Cell file_names (dim_vector (m_autoload_map.size (), 1)); @@ -4595,7 +4595,7 @@ return retval; } - std::list tree_evaluator::autoloaded_functions (void) const + std::list tree_evaluator::autoloaded_functions () const { std::list names; @@ -4799,7 +4799,7 @@ } void - tree_evaluator::maybe_set_echo_state (void) + tree_evaluator::maybe_set_echo_state () { octave_function *caller = caller_function (); @@ -4831,7 +4831,7 @@ m_echo_state, m_echo_file_name, m_echo_file_pos); } - bool tree_evaluator::maybe_push_echo_state_cleanup (void) + bool tree_evaluator::maybe_push_echo_state_cleanup () { // This function is expected to be called from ECHO, which would be // the top of the call stack. If the caller of ECHO is a @@ -4978,13 +4978,13 @@ return octave_value (); } - bool tree_evaluator::in_debug_repl (void) const + bool tree_evaluator::in_debug_repl () const { return (m_debugger_stack.empty () ? false : m_debugger_stack.top()->in_debug_repl ()); } - void tree_evaluator::dbcont (void) + void tree_evaluator::dbcont () { if (! m_debugger_stack.empty ()) m_debugger_stack.top()->dbcont (); @@ -5182,7 +5182,7 @@ } // Decide if it's time to quit a for or while loop. - bool tree_evaluator::quit_loop_now (void) + bool tree_evaluator::quit_loop_now () { octave_quit (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-eval.h --- a/libinterp/parse-tree/pt-eval.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-eval.h Tue Jan 24 17:19:44 2023 -0800 @@ -81,44 +81,44 @@ { public: - value_stack (void) = default; + value_stack () = default; value_stack (const value_stack&) = default; value_stack& operator = (const value_stack&) = default; - ~value_stack (void) = default; + ~value_stack () = default; void push (const T& val) { m_stack.push (val); } - void pop (void) + void pop () { m_stack.pop (); } - T val_pop (void) + T val_pop () { T retval = m_stack.top (); m_stack.pop (); return retval; } - T top (void) const + T top () const { return m_stack.top (); } - std::size_t size (void) const + std::size_t size () const { return m_stack.size (); } - bool empty (void) const + bool empty () const { return m_stack.empty (); } - void clear (void) + void clear () { while (! m_stack.empty ()) m_stack.pop (); @@ -154,9 +154,9 @@ tree_evaluator& operator = (const tree_evaluator&) = delete; - ~tree_evaluator (void) = default; + ~tree_evaluator () = default; - std::shared_ptr get_parser (void) + std::shared_ptr get_parser () { return m_parser; } @@ -166,7 +166,7 @@ m_parser = parser; } - bool at_top_level (void) const; + bool at_top_level () const; std::string mfilename (const std::string& opt = "") const; @@ -176,15 +176,15 @@ void parse_and_execute (const std::string& input, bool& incomplete_parse); - void get_line_and_eval (void); + void get_line_and_eval (); - int repl (void); + int repl (); - bool in_top_level_repl (void) const { return m_in_top_level_repl; } + bool in_top_level_repl () const { return m_in_top_level_repl; } - int server_loop (void); + int server_loop (); - bool server_mode (void) const { return m_server_mode; } + bool server_mode () const { return m_server_mode; } void server_mode (bool arg) { m_server_mode = arg; } @@ -333,9 +333,9 @@ void bind_ans (const octave_value& val, bool print); - bool statement_printing_enabled (void); + bool statement_printing_enabled (); - void reset_debug_state (void); + void reset_debug_state (); void reset_debug_state (bool mode); @@ -353,7 +353,7 @@ SC_OTHER // command-line input or eval string }; - Matrix ignored_fcn_outputs (void) const; + Matrix ignored_fcn_outputs () const; octave_value make_fcn_handle (const std::string& nm); @@ -424,11 +424,11 @@ bool switch_case_label_matches (tree_switch_case *expr, const octave_value& val); - interpreter& get_interpreter (void) { return m_interpreter; } + interpreter& get_interpreter () { return m_interpreter; } - bp_table& get_bp_table (void) { return m_bp_table; } + bp_table& get_bp_table () { return m_bp_table; } - profiler& get_profiler (void) { return m_profiler; } + profiler& get_profiler () { return m_profiler; } void push_stack_frame (const symbol_scope& scope); @@ -443,52 +443,52 @@ void push_stack_frame (octave_function *fcn); - void pop_stack_frame (void); + void pop_stack_frame (); - std::shared_ptr get_current_stack_frame (void) const + std::shared_ptr get_current_stack_frame () const { return m_call_stack.get_current_stack_frame (); } - std::shared_ptr current_user_frame (void) const + std::shared_ptr current_user_frame () const { return m_call_stack.current_user_frame (); } // Current line in current function. - int current_line (void) const; + int current_line () const; // Current column in current function. - int current_column (void) const; + int current_column () const; // Line number in current function that we are debugging. - int debug_user_code_line (void) const; + int debug_user_code_line () const; // Column number in current function that we are debugging. - int debug_user_code_column (void) const; + int debug_user_code_column () const; void debug_where (std::ostream& os) const; - octave_user_code * current_user_code (void) const; + octave_user_code * current_user_code () const; - unwind_protect * curr_fcn_unwind_protect_frame (void); + unwind_protect * curr_fcn_unwind_protect_frame (); // Current function that we are debugging. - octave_user_code * debug_user_code (void) const; + octave_user_code * debug_user_code () const; octave_function * current_function (bool skip_first = false) const; - octave_function * caller_function (void) const; + octave_function * caller_function () const; bool goto_frame (std::size_t n = 0, bool verbose = false); - void goto_caller_frame (void); + void goto_caller_frame (); - void goto_base_frame (void); + void goto_base_frame (); void restore_frame (std::size_t n); - std::string get_dispatch_class (void) const; + std::string get_dispatch_class () const; void set_dispatch_class (const std::string& class_name); @@ -504,22 +504,22 @@ std::list backtrace_info (octave_idx_type& curr_user_frame, bool print_subfn = true) const; - std::list backtrace_info (void) const; + std::list backtrace_info () const; octave_map backtrace (octave_idx_type& curr_user_frame, bool print_subfn = true) const; - octave_map backtrace (void) const; + octave_map backtrace () const; - octave_map empty_backtrace (void) const; + octave_map empty_backtrace () const; - std::string backtrace_message (void) const; + std::string backtrace_message () const; void push_dummy_scope (const std::string& name); - void pop_scope (void); + void pop_scope (); - symbol_scope get_top_scope (void) const; - symbol_scope get_current_scope (void) const; + symbol_scope get_top_scope () const; + symbol_scope get_current_scope () const; void mlock (bool skip_first = false) const; @@ -530,11 +530,11 @@ octave_value max_stack_depth (const octave_value_list& args, int nargout); // Useful for debugging - void display_call_stack (void) const; + void display_call_stack () const; octave_value find (const std::string& name); - void clear_objects (void); + void clear_objects (); void clear_variable (const std::string& name); @@ -542,7 +542,7 @@ void clear_variable_regexp (const std::string& pattern); - void clear_variables (void); + void clear_variables (); void clear_global_variable (const std::string& name); @@ -550,7 +550,7 @@ void clear_global_variable_regexp (const std::string& pattern); - void clear_global_variables (void); + void clear_global_variables (); void clear_all (bool force = false); @@ -560,32 +560,32 @@ void clear_symbol_regexp (const std::string& pattern); - std::list global_variable_names (void) const; + std::list global_variable_names () const; - std::list top_level_variable_names (void) const; + std::list top_level_variable_names () const; - std::list variable_names (void) const; + std::list variable_names () const; octave_user_code * get_user_code (const std::string& fname = "", const std::string& class_name = ""); std::string current_function_name (bool skip_first = false) const; - bool in_user_code (void) const; + bool in_user_code () const; symbol_info_list glob_symbol_info (const std::string& pattern) const; symbol_info_list regexp_symbol_info (const std::string& pattern) const; - symbol_info_list get_symbol_info (void); + symbol_info_list get_symbol_info (); - symbol_info_list top_scope_symbol_info (void) const; + symbol_info_list top_scope_symbol_info () const; - octave_map get_autoload_map (void) const; + octave_map get_autoload_map () const; std::string lookup_autoload (const std::string& nm) const; - std::list autoloaded_functions (void) const; + std::list autoloaded_functions () const; std::list reverse_lookup_autoload (const std::string& nm) const; @@ -593,7 +593,7 @@ void remove_autoload (const std::string& fcn, const std::string& nm); - int max_recursion_depth (void) const { return m_max_recursion_depth; } + int max_recursion_depth () const { return m_max_recursion_depth; } int max_recursion_depth (int n) { @@ -605,7 +605,7 @@ octave_value max_recursion_depth (const octave_value_list& args, int nargout); - bool silent_functions (void) const { return m_silent_functions; } + bool silent_functions () const { return m_silent_functions; } bool silent_functions (bool b) { @@ -616,7 +616,7 @@ octave_value whos_line_format (const octave_value_list& args, int nargout); - std::string whos_line_format (void) const { return m_whos_line_format; } + std::string whos_line_format () const { return m_whos_line_format; } std::string whos_line_format (const std::string& s) { @@ -628,7 +628,7 @@ octave_value silent_functions (const octave_value_list& args, int nargout); - std::size_t debug_frame (void) const { return m_debug_frame; } + std::size_t debug_frame () const { return m_debug_frame; } std::size_t debug_frame (std::size_t n) { @@ -637,12 +637,12 @@ return val; } - std::size_t current_call_stack_frame_number (void) const + std::size_t current_call_stack_frame_number () const { return m_call_stack.current_frame (); } - bool quiet_breakpoint_flag (void) const { return m_quiet_breakpoint_flag; } + bool quiet_breakpoint_flag () const { return m_quiet_breakpoint_flag; } bool quiet_breakpoint_flag (bool flag) { @@ -651,7 +651,7 @@ return val; } - char string_fill_char (void) const { return m_string_fill_char; } + char string_fill_char () const { return m_string_fill_char; } char string_fill_char (char c) { @@ -664,9 +664,9 @@ // call the corresponding functions in the debugger class for the // current debugger (if any). - bool in_debug_repl (void) const; + bool in_debug_repl () const; - void dbcont (void); + void dbcont (); // Return true if we are in the debug repl and m_execution_mode is // set to exit the debugger. Otherwise, do nothing. @@ -689,21 +689,21 @@ // Clear the set of expressions that may be evaluated when the // debugger stops at a breakpoint. - void clear_debug_watch_expressions (void) + void clear_debug_watch_expressions () { m_debug_watch_expressions.clear (); } // Return the set of expressions that may be evaluated when the // debugger stops at a breakpoint. - std::set debug_watch_expressions (void) const + std::set debug_watch_expressions () const { return m_debug_watch_expressions; } octave_value PS4 (const octave_value_list& args, int nargout); - std::string PS4 (void) const { return m_PS4; } + std::string PS4 () const { return m_PS4; } std::string PS4 (const std::string& s) { @@ -714,7 +714,7 @@ void set_PS4 (const std::string& s) { m_PS4 = s; } - octave_value indexed_object (void) const + octave_value indexed_object () const { return m_indexed_object; } @@ -724,7 +724,7 @@ m_indexed_object = obj; } - const std::list& index_list (void) const + const std::list& index_list () const { return m_index_list; } @@ -736,7 +736,7 @@ m_index_list = index_list; } - void clear_index_list (void) + void clear_index_list () { m_index_type = ""; m_index_list.clear (); @@ -748,18 +748,18 @@ m_index_list.push_back (idx); } - const std::string& index_type (void) const + const std::string& index_type () const { return m_index_type; } - int index_position (void) const { return m_index_position; } + int index_position () const { return m_index_position; } - int num_indices (void) const { return m_num_indices; } + int num_indices () const { return m_num_indices; } octave_value_list evaluate_end_expression (const octave_value_list& args); - const std::list * lvalue_list (void) const + const std::list * lvalue_list () const { return m_lvalue_list; } @@ -769,7 +769,7 @@ m_lvalue_list = lst; } - int breaking (void) const { return m_breaking; } + int breaking () const { return m_breaking; } int breaking (int n) { @@ -778,7 +778,7 @@ return val; } - int continuing (void) const { return m_continuing; } + int continuing () const { return m_continuing; } int continuing (int n) { @@ -787,7 +787,7 @@ return val; } - int returning (void) const { return m_returning; } + int returning () const { return m_returning; } int returning (int n) { @@ -796,7 +796,7 @@ return val; } - int dbstep_flag (void) const { return m_dbstep_flag; } + int dbstep_flag () const { return m_dbstep_flag; } int dbstep_flag (int val) { @@ -807,7 +807,7 @@ void set_dbstep_flag (int step) { m_dbstep_flag = step; } - bool break_on_next_statement (void) const + bool break_on_next_statement () const { return m_break_on_next_stmt; } @@ -826,7 +826,7 @@ octave_value echo (const octave_value_list& args, int nargout); - int echo (void) const { return m_echo; } + int echo () const { return m_echo; } int echo (int val) { @@ -859,11 +859,11 @@ void set_echo_state (int type, const std::string& file_name, int pos); - void maybe_set_echo_state (void); + void maybe_set_echo_state (); void push_echo_state_cleanup (unwind_protect& frame); - bool maybe_push_echo_state_cleanup (void); + bool maybe_push_echo_state_cleanup (); void do_breakpoint (tree_statement& stmt); @@ -879,7 +879,7 @@ void echo_code (int line); - bool quit_loop_now (void); + bool quit_loop_now (); void bind_auto_fcn_vars (const string_vector& arg_names, const Matrix& ignored_outputs, int nargin, diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-except.cc --- a/libinterp/parse-tree/pt-except.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-except.cc Tue Jan 24 17:19:44 2023 -0800 @@ -47,7 +47,7 @@ // Simple exception handling. -tree_try_catch_command::~tree_try_catch_command (void) +tree_try_catch_command::~tree_try_catch_command () { delete m_expr_id; delete m_try_code; @@ -59,7 +59,7 @@ // Simple exception handling. -tree_unwind_protect_command::~tree_unwind_protect_command (void) +tree_unwind_protect_command::~tree_unwind_protect_command () { delete m_unwind_protect_code; delete m_cleanup_code; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-except.h --- a/libinterp/parse-tree/pt-except.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-except.h Tue Jan 24 17:19:44 2023 -0800 @@ -65,19 +65,19 @@ tree_try_catch_command& operator = (const tree_try_catch_command&) = delete; - ~tree_try_catch_command (void); + ~tree_try_catch_command (); - tree_identifier * identifier (void) { return m_expr_id; } + tree_identifier * identifier () { return m_expr_id; } - tree_statement_list * body (void) { return m_try_code; } + tree_statement_list * body () { return m_try_code; } - tree_statement_list * cleanup (void) { return m_catch_code; } + tree_statement_list * cleanup () { return m_catch_code; } - comment_list * leading_comment (void) { return m_lead_comm; } + comment_list * leading_comment () { return m_lead_comm; } - comment_list * middle_comment (void) { return m_mid_comm; } + comment_list * middle_comment () { return m_mid_comm; } - comment_list * trailing_comment (void) { return m_trail_comm; } + comment_list * trailing_comment () { return m_trail_comm; } void accept (tree_walker& tw) { @@ -134,17 +134,17 @@ tree_unwind_protect_command& operator = (const tree_unwind_protect_command&) = delete; - ~tree_unwind_protect_command (void); + ~tree_unwind_protect_command (); - tree_statement_list * body (void) { return m_unwind_protect_code; } + tree_statement_list * body () { return m_unwind_protect_code; } - tree_statement_list * cleanup (void) { return m_cleanup_code; } + tree_statement_list * cleanup () { return m_cleanup_code; } - comment_list * leading_comment (void) { return m_lead_comm; } + comment_list * leading_comment () { return m_lead_comm; } - comment_list * middle_comment (void) { return m_mid_comm; } + comment_list * middle_comment () { return m_mid_comm; } - comment_list * trailing_comment (void) { return m_trail_comm; } + comment_list * trailing_comment () { return m_trail_comm; } void accept (tree_walker& tw) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-exp.cc --- a/libinterp/parse-tree/pt-exp.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-exp.cc Tue Jan 24 17:19:44 2023 -0800 @@ -46,7 +46,7 @@ } std::string -tree_expression::original_text (void) const +tree_expression::original_text () const { return ""; } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-exp.h --- a/libinterp/parse-tree/pt-exp.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-exp.h Tue Jan 24 17:19:44 2023 -0800 @@ -57,61 +57,61 @@ tree_expression& operator = (const tree_expression&) = delete; - virtual ~tree_expression (void) = default; + virtual ~tree_expression () = default; virtual tree_expression * dup (symbol_scope& scope) const = 0; - virtual bool is_constant (void) const { return false; } + virtual bool is_constant () const { return false; } - virtual bool is_matrix (void) const { return false; } + virtual bool is_matrix () const { return false; } - virtual bool iscell (void) const { return false; } + virtual bool iscell () const { return false; } - virtual bool is_identifier (void) const { return false; } + virtual bool is_identifier () const { return false; } - virtual bool is_index_expression (void) const { return false; } + virtual bool is_index_expression () const { return false; } - virtual bool is_assignment_expression (void) const { return false; } + virtual bool is_assignment_expression () const { return false; } - virtual bool is_prefix_expression (void) const { return false; } + virtual bool is_prefix_expression () const { return false; } - virtual bool is_unary_expression (void) const { return false; } + virtual bool is_unary_expression () const { return false; } - virtual bool is_binary_expression (void) const { return false; } + virtual bool is_binary_expression () const { return false; } - virtual bool is_boolean_expression (void) const { return false; } + virtual bool is_boolean_expression () const { return false; } - virtual bool is_colon_expression (void) const { return false; } + virtual bool is_colon_expression () const { return false; } - virtual bool lvalue_ok (void) const { return false; } + virtual bool lvalue_ok () const { return false; } - virtual bool rvalue_ok (void) const { return false; } + virtual bool rvalue_ok () const { return false; } virtual octave_lvalue lvalue (tree_evaluator&); - int paren_count (void) const { return m_num_parens; } + int paren_count () const { return m_num_parens; } - bool is_postfix_indexed (void) const + bool is_postfix_indexed () const { return (m_postfix_index_type != '\0'); } - char postfix_index (void) const { return m_postfix_index_type; } + char postfix_index () const { return m_postfix_index_type; } // Check if the result of the expression should be printed. // Should normally be used in conjunction with // tree_evaluator::statement_printing_enabled. - bool print_result (void) const { return m_print_flag; } + bool print_result () const { return m_print_flag; } - virtual std::string oper (void) const { return ""; } + virtual std::string oper () const { return ""; } - virtual std::string name (void) const { return ""; } + virtual std::string name () const { return ""; } - virtual std::string original_text (void) const; + virtual std::string original_text () const; - void mark_as_for_cmd_expr (void) { m_for_cmd_expr = true; } + void mark_as_for_cmd_expr () { m_for_cmd_expr = true; } - bool is_for_cmd_expr (void) const { return m_for_cmd_expr; } + bool is_for_cmd_expr () const { return m_for_cmd_expr; } - tree_expression * mark_in_parens (void) + tree_expression * mark_in_parens () { m_num_parens++; return this; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-fcn-handle.cc --- a/libinterp/parse-tree/pt-fcn-handle.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-fcn-handle.cc Tue Jan 24 17:19:44 2023 -0800 @@ -66,7 +66,7 @@ return tw.make_fcn_handle (m_name); } -tree_anon_fcn_handle::~tree_anon_fcn_handle (void) +tree_anon_fcn_handle::~tree_anon_fcn_handle () { delete m_parameter_list; delete m_expression; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-fcn-handle.h --- a/libinterp/parse-tree/pt-fcn-handle.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-fcn-handle.h Tue Jan 24 17:19:44 2023 -0800 @@ -61,7 +61,7 @@ tree_fcn_handle& operator = (const tree_fcn_handle&) = delete; - ~tree_fcn_handle (void) = default; + ~tree_fcn_handle () = default; void print (std::ostream& os, bool pr_as_read_syntax = false, bool pr_orig_txt = true); @@ -69,9 +69,9 @@ void print_raw (std::ostream& os, bool pr_as_read_syntax = false, bool pr_orig_txt = true); - std::string name (void) const { return m_name; } + std::string name () const { return m_name; } - bool rvalue_ok (void) const { return true; } + bool rvalue_ok () const { return true; } tree_expression * dup (symbol_scope& scope) const; @@ -117,22 +117,22 @@ tree_anon_fcn_handle& operator = (const tree_anon_fcn_handle&) = delete; - ~tree_anon_fcn_handle (void); + ~tree_anon_fcn_handle (); - bool rvalue_ok (void) const { return true; } + bool rvalue_ok () const { return true; } - tree_parameter_list * parameter_list (void) const + tree_parameter_list * parameter_list () const { return m_parameter_list; } - tree_expression * expression (void) const { return m_expression; } + tree_expression * expression () const { return m_expression; } - symbol_scope scope (void) const { return m_scope; } + symbol_scope scope () const { return m_scope; } - symbol_scope parent_scope (void) const { return m_parent_scope; } + symbol_scope parent_scope () const { return m_parent_scope; } - bool has_parent_scope (void) const { return m_parent_scope.is_valid (); } + bool has_parent_scope () const { return m_parent_scope.is_valid (); } tree_expression * dup (symbol_scope& scope) const; @@ -147,7 +147,7 @@ void stash_file_name (const std::string& file) { m_file_name = file; } - std::string file_name (void) const { return m_file_name; } + std::string file_name () const { return m_file_name; } private: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-id.cc --- a/libinterp/parse-tree/pt-id.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-id.cc Tue Jan 24 17:19:44 2023 -0800 @@ -41,7 +41,7 @@ // Symbols from the symbol table. void -tree_identifier::eval_undefined_error (void) +tree_identifier::eval_undefined_error () { int l = line (); int c = column (); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-id.h --- a/libinterp/parse-tree/pt-id.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-id.h Tue Jan 24 17:19:44 2023 -0800 @@ -66,26 +66,26 @@ tree_identifier& operator = (const tree_identifier&) = delete; - ~tree_identifier (void) = default; + ~tree_identifier () = default; - bool is_identifier (void) const { return true; } + bool is_identifier () const { return true; } - std::string name (void) const { return m_sym.name (); } + std::string name () const { return m_sym.name (); } - virtual bool is_black_hole (void) const { return false; } + virtual bool is_black_hole () const { return false; } - void mark_as_formal_parameter (void) { m_sym.mark_formal (); } + void mark_as_formal_parameter () { m_sym.mark_formal (); } // We really need to know whether this symbol refers to a variable // or a function, but we may not know that yet. - bool lvalue_ok (void) const { return true; } + bool lvalue_ok () const { return true; } octave_lvalue lvalue (tree_evaluator& tw); - void eval_undefined_error (void); + void eval_undefined_error (); - void static_workspace_error (void) + void static_workspace_error () { error (R"(can not add variable "%s" to a static workspace)", name ().c_str ()); @@ -107,7 +107,7 @@ tw.visit_identifier (*this); } - symbol_record symbol (void) const { return m_sym; } + symbol_record symbol () const { return m_sym; } protected: @@ -122,9 +122,9 @@ tree_black_hole (int l = -1, int c = -1) : tree_identifier (l, c) { } - std::string name (void) const { return "~"; } + std::string name () const { return "~"; } - bool is_black_hole (void) const { return true; } + bool is_black_hole () const { return true; } tree_black_hole * dup (symbol_scope&) const { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-idx.cc --- a/libinterp/parse-tree/pt-idx.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-idx.cc Tue Jan 24 17:19:44 2023 -0800 @@ -113,7 +113,7 @@ return this; } -tree_index_expression::~tree_index_expression (void) +tree_index_expression::~tree_index_expression () { delete m_expr; @@ -136,7 +136,7 @@ // assignment. std::string -tree_index_expression::name (void) const +tree_index_expression::name () const { return m_expr->name (); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-idx.h --- a/libinterp/parse-tree/pt-idx.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-idx.h Tue Jan 24 17:19:44 2023 -0800 @@ -68,7 +68,7 @@ tree_index_expression& operator = (const tree_index_expression&) = delete; - ~tree_index_expression (void); + ~tree_index_expression (); tree_index_expression * append (tree_argument_list *lst = nullptr, char t = '('); @@ -77,27 +77,27 @@ tree_index_expression * append (tree_expression *df); - bool is_index_expression (void) const { return true; } + bool is_index_expression () const { return true; } - std::string name (void) const; + std::string name () const; - tree_expression * expression (void) { return m_expr; } + tree_expression * expression () { return m_expr; } - std::list arg_lists (void) { return m_args; } + std::list arg_lists () { return m_args; } - std::string type_tags (void) { return m_type; } + std::string type_tags () { return m_type; } - std::list arg_names (void) { return m_arg_nm; } + std::list arg_names () { return m_arg_nm; } - std::list dyn_fields (void) { return m_dyn_field; } + std::list dyn_fields () { return m_dyn_field; } - void mark_word_list_cmd (void) { m_word_list_cmd = true; } + void mark_word_list_cmd () { m_word_list_cmd = true; } - bool is_word_list_cmd (void) const { return m_word_list_cmd; } + bool is_word_list_cmd () const { return m_word_list_cmd; } - bool lvalue_ok (void) const { return m_expr->lvalue_ok (); } + bool lvalue_ok () const { return m_expr->lvalue_ok (); } - bool rvalue_ok (void) const { return true; } + bool rvalue_ok () const { return true; } octave_lvalue lvalue (tree_evaluator& tw); @@ -145,7 +145,7 @@ tree_index_expression (int l, int c); - octave_map make_arg_struct (void) const; + octave_map make_arg_struct () const; }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-jump.h --- a/libinterp/parse-tree/pt-jump.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-jump.h Tue Jan 24 17:19:44 2023 -0800 @@ -48,7 +48,7 @@ tree_break_command& operator = (const tree_break_command&) = delete; - ~tree_break_command (void) = default; + ~tree_break_command () = default; void accept (tree_walker& tw) { @@ -71,7 +71,7 @@ tree_continue_command& operator = (const tree_continue_command&) = delete; - ~tree_continue_command (void) = default; + ~tree_continue_command () = default; void accept (tree_walker& tw) { @@ -94,7 +94,7 @@ tree_return_command& operator = (const tree_return_command&) = delete; - ~tree_return_command (void) = default; + ~tree_return_command () = default; void accept (tree_walker& tw) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-loop.cc --- a/libinterp/parse-tree/pt-loop.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-loop.cc Tue Jan 24 17:19:44 2023 -0800 @@ -36,7 +36,7 @@ // While. -tree_while_command::~tree_while_command (void) +tree_while_command::~tree_while_command () { delete m_expr; delete m_list; @@ -46,7 +46,7 @@ // For. -tree_simple_for_command::~tree_simple_for_command (void) +tree_simple_for_command::~tree_simple_for_command () { delete m_lhs; delete m_expr; @@ -56,7 +56,7 @@ delete m_trail_comm; } -tree_complex_for_command::~tree_complex_for_command (void) +tree_complex_for_command::~tree_complex_for_command () { delete m_lhs; delete m_expr; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-loop.h --- a/libinterp/parse-tree/pt-loop.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-loop.h Tue Jan 24 17:19:44 2023 -0800 @@ -72,15 +72,15 @@ tree_while_command& operator = (const tree_while_command&) = delete; - ~tree_while_command (void); + ~tree_while_command (); - tree_expression * condition (void) { return m_expr; } + tree_expression * condition () { return m_expr; } - tree_statement_list * body (void) { return m_list; } + tree_statement_list * body () { return m_list; } - comment_list * leading_comment (void) { return m_lead_comm; } + comment_list * leading_comment () { return m_lead_comm; } - comment_list * trailing_comment (void) { return m_trail_comm; } + comment_list * trailing_comment () { return m_trail_comm; } void accept (tree_walker& tw) { @@ -132,7 +132,7 @@ tree_do_until_command& operator = (const tree_do_until_command&) = delete; - ~tree_do_until_command (void) = default; + ~tree_do_until_command () = default; void accept (tree_walker& tw) { @@ -170,21 +170,21 @@ tree_simple_for_command& operator = (const tree_simple_for_command&) = delete; - ~tree_simple_for_command (void); + ~tree_simple_for_command (); - bool in_parallel (void) { return m_parallel; } + bool in_parallel () { return m_parallel; } - tree_expression * left_hand_side (void) { return m_lhs; } + tree_expression * left_hand_side () { return m_lhs; } - tree_expression * control_expr (void) { return m_expr; } + tree_expression * control_expr () { return m_expr; } - tree_expression * maxproc_expr (void) { return m_maxproc; } + tree_expression * maxproc_expr () { return m_maxproc; } - tree_statement_list * body (void) { return m_list; } + tree_statement_list * body () { return m_list; } - comment_list * leading_comment (void) { return m_lead_comm; } + comment_list * leading_comment () { return m_lead_comm; } - comment_list * trailing_comment (void) { return m_trail_comm; } + comment_list * trailing_comment () { return m_trail_comm; } void accept (tree_walker& tw) { @@ -240,17 +240,17 @@ tree_complex_for_command& operator = (const tree_complex_for_command&) = delete; - ~tree_complex_for_command (void); + ~tree_complex_for_command (); - tree_argument_list * left_hand_side (void) { return m_lhs; } + tree_argument_list * left_hand_side () { return m_lhs; } - tree_expression * control_expr (void) { return m_expr; } + tree_expression * control_expr () { return m_expr; } - tree_statement_list * body (void) { return m_list; } + tree_statement_list * body () { return m_list; } - comment_list * leading_comment (void) { return m_lead_comm; } + comment_list * leading_comment () { return m_lead_comm; } - comment_list * trailing_comment (void) { return m_trail_comm; } + comment_list * trailing_comment () { return m_trail_comm; } void accept (tree_walker& tw) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-mat.h --- a/libinterp/parse-tree/pt-mat.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-mat.h Tue Jan 24 17:19:44 2023 -0800 @@ -60,11 +60,11 @@ tree_matrix& operator = (const tree_matrix&) = delete; - ~tree_matrix (void) = default; + ~tree_matrix () = default; - bool is_matrix (void) const { return true; } + bool is_matrix () const { return true; } - bool rvalue_ok (void) const { return true; } + bool rvalue_ok () const { return true; } tree_expression * dup (symbol_scope& scope) const; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-misc.cc --- a/libinterp/parse-tree/pt-misc.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-misc.cc Tue Jan 24 17:19:44 2023 -0800 @@ -34,7 +34,7 @@ // Parameter lists. -tree_parameter_list::~tree_parameter_list (void) +tree_parameter_list::~tree_parameter_list () { while (! empty ()) { @@ -45,14 +45,14 @@ } void -tree_parameter_list::mark_as_formal_parameters (void) +tree_parameter_list::mark_as_formal_parameters () { for (tree_decl_elt *elt : *this) elt->mark_as_formal_parameter (); } std::list -tree_parameter_list::variable_names (void) const +tree_parameter_list::variable_names () const { std::list retval; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-misc.h --- a/libinterp/parse-tree/pt-misc.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-misc.h Tue Jan 24 17:19:44 2023 -0800 @@ -74,25 +74,25 @@ tree_parameter_list& operator = (const tree_parameter_list&) = delete; - ~tree_parameter_list (void); + ~tree_parameter_list (); - void mark_as_formal_parameters (void); + void mark_as_formal_parameters (); - void mark_varargs (void) { m_marked_for_varargs = 1; } + void mark_varargs () { m_marked_for_varargs = 1; } - void mark_varargs_only (void) { m_marked_for_varargs = -1; } + void mark_varargs_only () { m_marked_for_varargs = -1; } - bool takes_varargs (void) const { return m_marked_for_varargs != 0; } + bool takes_varargs () const { return m_marked_for_varargs != 0; } - bool varargs_only (void) { return (m_marked_for_varargs < 0); } + bool varargs_only () { return (m_marked_for_varargs < 0); } - bool is_input_list (void) const { return m_in_or_out == in; } + bool is_input_list () const { return m_in_or_out == in; } - bool is_output_list (void) const { return m_in_or_out == out; } + bool is_output_list () const { return m_in_or_out == out; } - std::list variable_names (void) const; + std::list variable_names () const; - std::string varargs_symbol_name (void) const + std::string varargs_symbol_name () const { return m_in_or_out == in ? "varargin" : "varargout"; } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-pr-code.cc --- a/libinterp/parse-tree/pt-pr-code.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-pr-code.cc Tue Jan 24 17:19:44 2023 -0800 @@ -1201,7 +1201,7 @@ // Each print_code() function should call this before printing anything. void -tree_print_code::indent (void) +tree_print_code::indent () { panic_unless (m_curr_print_indent_level >= 0); @@ -1236,7 +1236,7 @@ // For resetting print_code state. void -tree_print_code::reset (void) +tree_print_code::reset () { m_beginning_of_line = true; m_curr_print_indent_level = 0; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-pr-code.h --- a/libinterp/parse-tree/pt-pr-code.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-pr-code.h Tue Jan 24 17:19:44 2023 -0800 @@ -64,7 +64,7 @@ tree_print_code& operator = (const tree_print_code&) = delete; - ~tree_print_code (void) = default; + ~tree_print_code () = default; void visit_anon_fcn_handle (tree_anon_fcn_handle&); @@ -185,17 +185,17 @@ // Nonzero means we are not printing newlines and indenting. int m_suppress_newlines; - void reset_indent_level (void) { m_curr_print_indent_level = 0; } + void reset_indent_level () { m_curr_print_indent_level = 0; } - void increment_indent_level (void) { m_curr_print_indent_level += 2; } + void increment_indent_level () { m_curr_print_indent_level += 2; } - void decrement_indent_level (void) { m_curr_print_indent_level -= 2; } + void decrement_indent_level () { m_curr_print_indent_level -= 2; } void newline (const char *alt_txt = ", "); - void indent (void); + void indent (); - void reset (void); + void reset (); void print_parens (const tree_expression& expr, const char *txt); @@ -207,7 +207,7 @@ // Must create with an output stream! - tree_print_code (void); + tree_print_code (); }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-select.cc --- a/libinterp/parse-tree/pt-select.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-select.cc Tue Jan 24 17:19:44 2023 -0800 @@ -35,7 +35,7 @@ // If clauses. -tree_if_clause::~tree_if_clause (void) +tree_if_clause::~tree_if_clause () { delete m_expr; delete m_list; @@ -44,7 +44,7 @@ // If. -tree_if_command::~tree_if_command (void) +tree_if_command::~tree_if_command () { delete m_list; delete m_lead_comm; @@ -53,7 +53,7 @@ // Switch cases. -tree_switch_case::~tree_switch_case (void) +tree_switch_case::~tree_switch_case () { delete m_label; delete m_list; @@ -62,7 +62,7 @@ // Switch. -tree_switch_command::~tree_switch_command (void) +tree_switch_command::~tree_switch_command () { delete m_expr; delete m_list; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-select.h --- a/libinterp/parse-tree/pt-select.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-select.h Tue Jan 24 17:19:44 2023 -0800 @@ -63,15 +63,15 @@ tree_if_clause& operator = (const tree_if_clause&) = delete; - ~tree_if_clause (void); + ~tree_if_clause (); - bool is_else_clause (void) { return ! m_expr; } + bool is_else_clause () { return ! m_expr; } - tree_expression * condition (void) { return m_expr; } + tree_expression * condition () { return m_expr; } - tree_statement_list * commands (void) { return m_list; } + tree_statement_list * commands () { return m_list; } - comment_list * leading_comment (void) { return m_lead_comm; } + comment_list * leading_comment () { return m_lead_comm; } void accept (tree_walker& tw) { @@ -94,7 +94,7 @@ { public: - tree_if_command_list (void) { } + tree_if_command_list () { } tree_if_command_list (tree_if_clause *t) { append (t); } @@ -104,7 +104,7 @@ tree_if_command_list& operator = (const tree_if_command_list&) = delete; - ~tree_if_command_list (void) + ~tree_if_command_list () { while (! empty ()) { @@ -140,13 +140,13 @@ tree_if_command& operator = (const tree_if_command&) = delete; - ~tree_if_command (void); + ~tree_if_command (); - tree_if_command_list * cmd_list (void) { return m_list; } + tree_if_command_list * cmd_list () { return m_list; } - comment_list * leading_comment (void) { return m_lead_comm; } + comment_list * leading_comment () { return m_lead_comm; } - comment_list * trailing_comment (void) { return m_trail_comm; } + comment_list * trailing_comment () { return m_trail_comm; } void accept (tree_walker& tw) { @@ -190,15 +190,15 @@ tree_switch_case& operator = (const tree_switch_case&) = delete; - ~tree_switch_case (void); + ~tree_switch_case (); - bool is_default_case (void) { return ! m_label; } + bool is_default_case () { return ! m_label; } - tree_expression * case_label (void) { return m_label; } + tree_expression * case_label () { return m_label; } - tree_statement_list * commands (void) { return m_list; } + tree_statement_list * commands () { return m_list; } - comment_list * leading_comment (void) { return m_lead_comm; } + comment_list * leading_comment () { return m_lead_comm; } void accept (tree_walker& tw) { @@ -221,7 +221,7 @@ { public: - tree_switch_case_list (void) { } + tree_switch_case_list () { } tree_switch_case_list (tree_switch_case *t) { append (t); } @@ -231,7 +231,7 @@ tree_switch_case_list& operator = (const tree_switch_case_list&) = delete; - ~tree_switch_case_list (void) + ~tree_switch_case_list () { while (! empty ()) { @@ -267,15 +267,15 @@ tree_switch_command& operator = (const tree_switch_command&) = delete; - ~tree_switch_command (void); + ~tree_switch_command (); - tree_expression * switch_value (void) { return m_expr; } + tree_expression * switch_value () { return m_expr; } - tree_switch_case_list * case_list (void) { return m_list; } + tree_switch_case_list * case_list () { return m_list; } - comment_list * leading_comment (void) { return m_lead_comm; } + comment_list * leading_comment () { return m_lead_comm; } - comment_list * trailing_comment (void) { return m_trail_comm; } + comment_list * trailing_comment () { return m_trail_comm; } void accept (tree_walker& tw) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-spmd.cc --- a/libinterp/parse-tree/pt-spmd.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-spmd.cc Tue Jan 24 17:19:44 2023 -0800 @@ -33,7 +33,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) -tree_spmd_command::~tree_spmd_command (void) +tree_spmd_command::~tree_spmd_command () { delete m_body; delete m_lead_comm; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-spmd.h --- a/libinterp/parse-tree/pt-spmd.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-spmd.h Tue Jan 24 17:19:44 2023 -0800 @@ -54,13 +54,13 @@ tree_spmd_command& operator = (const tree_spmd_command&) = delete; - ~tree_spmd_command (void); + ~tree_spmd_command (); - tree_statement_list * body (void) { return m_body; } + tree_statement_list * body () { return m_body; } - comment_list * leading_comment (void) { return m_lead_comm; } + comment_list * leading_comment () { return m_lead_comm; } - comment_list * trailing_comment (void) { return m_trail_comm; } + comment_list * trailing_comment () { return m_trail_comm; } void accept (tree_walker& tw) { diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-stmt.cc --- a/libinterp/parse-tree/pt-stmt.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-stmt.cc Tue Jan 24 17:19:44 2023 -0800 @@ -53,7 +53,7 @@ // A list of commands to be executed. -tree_statement::~tree_statement (void) +tree_statement::~tree_statement () { delete m_command; delete m_expression; @@ -68,7 +68,7 @@ } bool -tree_statement::print_result (void) +tree_statement::print_result () { return m_expression && m_expression->print_result (); } @@ -83,7 +83,7 @@ } void -tree_statement::delete_breakpoint (void) +tree_statement::delete_breakpoint () { if (m_command) m_command->delete_breakpoint (); @@ -92,7 +92,7 @@ } bool -tree_statement::is_breakpoint (void) const +tree_statement::is_breakpoint () const { return m_command ? m_command->is_breakpoint () : (m_expression ? m_expression->is_breakpoint () @@ -116,7 +116,7 @@ } int -tree_statement::line (void) const +tree_statement::line () const { return (m_command ? m_command->line () @@ -124,7 +124,7 @@ } int -tree_statement::column (void) const +tree_statement::column () const { return (m_command ? m_command->column () @@ -149,7 +149,7 @@ } bool -tree_statement::is_end_of_fcn_or_script (void) const +tree_statement::is_end_of_fcn_or_script () const { bool retval = false; @@ -166,7 +166,7 @@ } bool -tree_statement::is_end_of_file (void) const +tree_statement::is_end_of_file () const { bool retval = false; @@ -218,7 +218,7 @@ } octave_value_list -tree_statement_list::list_breakpoints (void) +tree_statement_list::list_breakpoints () { tree_breakpoint tbp (0, tree_breakpoint::list); accept (tbp); @@ -228,7 +228,7 @@ // Get list of pairs (breakpoint line, breakpoint condition) std::list -tree_statement_list::breakpoints_and_conds (void) +tree_statement_list::breakpoints_and_conds () { tree_breakpoint tbp (0, tree_breakpoint::list); accept (tbp); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-stmt.h --- a/libinterp/parse-tree/pt-stmt.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-stmt.h Tue Jan 24 17:19:44 2023 -0800 @@ -53,7 +53,7 @@ { public: - tree_statement (void) + tree_statement () : m_command (nullptr), m_expression (nullptr), m_comment_list (nullptr) { } @@ -69,47 +69,47 @@ tree_statement& operator = (const tree_statement&) = delete; - ~tree_statement (void); + ~tree_statement (); void set_print_flag (bool print_flag); - bool print_result (void); + bool print_result (); - bool is_command (void) const { return m_command != nullptr; } + bool is_command () const { return m_command != nullptr; } - bool is_expression (void) const { return m_expression != nullptr; } + bool is_expression () const { return m_expression != nullptr; } void set_breakpoint (const std::string& condition); - void delete_breakpoint (void); + void delete_breakpoint (); - bool is_breakpoint (void) const; + bool is_breakpoint () const; bool is_active_breakpoint (tree_evaluator& tw) const; std::string bp_cond () const; - int line (void) const; - int column (void) const; + int line () const; + int column () const; void set_location (int l, int c); void echo_code (const std::string& prefix); - tree_command * command (void) { return m_command; } + tree_command * command () { return m_command; } - tree_expression * expression (void) { return m_expression; } + tree_expression * expression () { return m_expression; } - comment_list * comment_text (void) { return m_comment_list; } + comment_list * comment_text () { return m_comment_list; } - bool is_null_statement (void) const + bool is_null_statement () const { return ! (m_command || m_expression || m_comment_list); } - bool is_end_of_fcn_or_script (void) const; + bool is_end_of_fcn_or_script () const; - bool is_end_of_file (void) const; + bool is_end_of_file () const; // Allow modification of this statement. Note that there is no // checking. If you use these, are you sure you know what you are @@ -144,7 +144,7 @@ { public: - tree_statement_list (void) + tree_statement_list () : m_function_body (false), m_anon_function_body (false), m_script_body (false) { } @@ -158,7 +158,7 @@ tree_statement_list& operator = (const tree_statement_list&) = delete; - ~tree_statement_list (void) + ~tree_statement_list () { while (! empty ()) { @@ -168,25 +168,25 @@ } } - void mark_as_function_body (void) { m_function_body = true; } + void mark_as_function_body () { m_function_body = true; } - void mark_as_anon_function_body (void) { m_anon_function_body = true; } + void mark_as_anon_function_body () { m_anon_function_body = true; } - void mark_as_script_body (void) { m_script_body = true; } + void mark_as_script_body () { m_script_body = true; } - bool is_function_body (void) const { return m_function_body; } + bool is_function_body () const { return m_function_body; } - bool is_anon_function_body (void) const { return m_anon_function_body; } + bool is_anon_function_body () const { return m_anon_function_body; } - bool is_script_body (void) const { return m_script_body; } + bool is_script_body () const { return m_script_body; } int set_breakpoint (int line, const std::string& condition); void delete_breakpoint (int line); - octave_value_list list_breakpoints (void); + octave_value_list list_breakpoints (); - std::list breakpoints_and_conds (void); + std::list breakpoints_and_conds (); bp_table::bp_lines add_breakpoint (event_manager& evmgr, const std::string& file, diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-tm-const.cc --- a/libinterp/parse-tree/pt-tm-const.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-tm-const.cc Tue Jan 24 17:19:44 2023 -0800 @@ -60,7 +60,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) -void tm_row_const::cellify (void) +void tm_row_const::cellify () { bool elt_changed = false; @@ -421,7 +421,7 @@ return octave_value (result, type); } -octave_value tm_const::class_concat (void) const +octave_value tm_const::class_concat () const { octave_value retval; @@ -454,7 +454,7 @@ return retval; } -octave_value tm_const::generic_concat (void) const +octave_value tm_const::generic_concat () const { // The line below might seem crazy, since we take a copy of the // first argument, resize it to be empty and then resize it to be @@ -590,7 +590,7 @@ } template -TYPE tm_const::array_concat (void) const +TYPE tm_const::array_concat () const { typedef typename TYPE::element_type ELT_T; @@ -639,7 +639,7 @@ } template -TYPE tm_const::sparse_array_concat (void) const +TYPE tm_const::sparse_array_concat () const { if (m_dv.any_zero ()) return TYPE (m_dv); @@ -673,7 +673,7 @@ } template -octave_map tm_const::map_concat (void) const +octave_map tm_const::map_concat () const { if (m_dv.any_zero ()) return octave_map (m_dv); diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-tm-const.h --- a/libinterp/parse-tree/pt-tm-const.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-tm-const.h Tue Jan 24 17:19:44 2023 -0800 @@ -77,25 +77,25 @@ m_first_elem_is_struct (false), m_class_name () { } - dim_vector dims (void) const { return m_dv; } + dim_vector dims () const { return m_dv; } - octave_idx_type rows (void) const { return m_dv(0); } - octave_idx_type cols (void) const { return m_dv(1); } + octave_idx_type rows () const { return m_dv(0); } + octave_idx_type cols () const { return m_dv(1); } - bool all_strings_p (void) const { return m_all_strings; } - bool all_sq_strings_p (void) const { return m_all_sq_strings; } - bool all_dq_strings_p (void) const { return m_all_dq_strings; } - bool some_strings_p (void) const { return m_some_strings; } - bool all_real_p (void) const { return m_all_real; } - bool all_complex_p (void) const { return m_all_complex; } - bool all_empty_p (void) const { return m_all_empty; } - bool any_cell_p (void) const { return m_any_cell; } - bool any_sparse_p (void) const { return m_any_sparse; } - bool any_class_p (void) const { return m_any_class; } - bool all_1x1_p (void) const { return m_all_1x1; } - bool first_elem_struct_p (void) const { return m_first_elem_is_struct; } + bool all_strings_p () const { return m_all_strings; } + bool all_sq_strings_p () const { return m_all_sq_strings; } + bool all_dq_strings_p () const { return m_all_dq_strings; } + bool some_strings_p () const { return m_some_strings; } + bool all_real_p () const { return m_all_real; } + bool all_complex_p () const { return m_all_complex; } + bool all_empty_p () const { return m_all_empty; } + bool any_cell_p () const { return m_any_cell; } + bool any_sparse_p () const { return m_any_sparse; } + bool any_class_p () const { return m_any_class; } + bool all_1x1_p () const { return m_all_1x1; } + bool first_elem_struct_p () const { return m_first_elem_is_struct; } - std::string class_name (void) const { return m_class_name; } + std::string class_name () const { return m_class_name; } protected: @@ -149,7 +149,7 @@ typedef std::list::iterator iterator; typedef std::list::const_iterator const_iterator; - tm_row_const (void) = delete; + tm_row_const () = delete; tm_row_const (const tree_argument_list& row, tree_evaluator& tw) : tm_info (row.empty ()), m_values () @@ -161,19 +161,19 @@ tm_row_const& operator = (const tm_row_const&) = delete; - ~tm_row_const (void) = default; + ~tm_row_const () = default; - iterator begin (void) { return m_values.begin (); } - const_iterator begin (void) const { return m_values.begin (); } + iterator begin () { return m_values.begin (); } + const_iterator begin () const { return m_values.begin (); } - iterator end (void) { return m_values.end (); } - const_iterator end (void) const { return m_values.end (); } + iterator end () { return m_values.end (); } + const_iterator end () const { return m_values.end (); } - bool empty (void) const { return m_values.empty (); } + bool empty () const { return m_values.empty (); } - std::size_t length (void) const { return m_values.size (); } + std::size_t length () const { return m_values.size (); } - void cellify (void); + void cellify (); private: @@ -191,7 +191,7 @@ typedef std::list::iterator iterator; typedef std::list::const_iterator const_iterator; - tm_const (void) = delete; + tm_const () = delete; tm_const (const tree_matrix& tm, tree_evaluator& tw) : tm_info (tm.empty ()), m_evaluator (tw), m_tm_rows () @@ -205,7 +205,7 @@ tm_const& operator = (const tm_const&) = delete; - ~tm_const (void) = default; + ~tm_const () = default; octave_value concat (char string_fill_char) const; @@ -223,21 +223,21 @@ octave_value char_array_concat (char string_fill_char) const; - octave_value class_concat (void) const; + octave_value class_concat () const; - octave_value generic_concat (void) const; + octave_value generic_concat () const; template void array_concat_internal (TYPE& result) const; template - TYPE array_concat (void) const; + TYPE array_concat () const; template - TYPE sparse_array_concat (void) const; + TYPE sparse_array_concat () const; template - octave_map map_concat (void) const; + octave_map map_concat () const; }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-unop.cc --- a/libinterp/parse-tree/pt-unop.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-unop.cc Tue Jan 24 17:19:44 2023 -0800 @@ -37,7 +37,7 @@ // Unary expressions. std::string -tree_unary_expression::oper (void) const +tree_unary_expression::oper () const { return octave_value::unary_op_as_string (m_etype); } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-unop.h --- a/libinterp/parse-tree/pt-unop.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-unop.h Tue Jan 24 17:19:44 2023 -0800 @@ -65,15 +65,15 @@ tree_unary_expression& operator = (const tree_unary_expression&) = delete; - ~tree_unary_expression (void) { delete m_op; } + ~tree_unary_expression () { delete m_op; } - bool is_unary_expression (void) const { return true; } + bool is_unary_expression () const { return true; } - tree_expression * operand (void) { return m_op; } + tree_expression * operand () { return m_op; } - std::string oper (void) const; + std::string oper () const; - octave_value::unary_op op_type (void) const { return m_etype; } + octave_value::unary_op op_type () const { return m_etype; } protected: @@ -104,9 +104,9 @@ tree_prefix_expression& operator = (const tree_prefix_expression&) = delete; - ~tree_prefix_expression (void) = default; + ~tree_prefix_expression () = default; - bool rvalue_ok (void) const { return true; } + bool rvalue_ok () const { return true; } tree_expression * dup (symbol_scope& scope) const; @@ -122,7 +122,7 @@ tw.visit_prefix_expression (*this); } - std::string profiler_name (void) const { return "prefix " + oper (); } + std::string profiler_name () const { return "prefix " + oper (); } }; // Postfix expressions. @@ -145,9 +145,9 @@ tree_postfix_expression& operator = (const tree_postfix_expression&) = delete; - ~tree_postfix_expression (void) = default; + ~tree_postfix_expression () = default; - bool rvalue_ok (void) const { return true; } + bool rvalue_ok () const { return true; } tree_expression * dup (symbol_scope& scope) const; @@ -163,7 +163,7 @@ tw.visit_postfix_expression (*this); } - std::string profiler_name (void) const { return "postfix " + oper (); } + std::string profiler_name () const { return "postfix " + oper (); } }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt-walk.h --- a/libinterp/parse-tree/pt-walk.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt-walk.h Tue Jan 24 17:19:44 2023 -0800 @@ -111,9 +111,9 @@ { protected: - tree_walker (void) { } + tree_walker () { } - virtual ~tree_walker (void) = default; + virtual ~tree_walker () = default; public: diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt.cc --- a/libinterp/parse-tree/pt.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt.cc Tue Jan 24 17:19:44 2023 -0800 @@ -43,7 +43,7 @@ // create a memory leak. std::string -tree::str_print_code (void) +tree::str_print_code () { std::ostringstream buf; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/pt.h --- a/libinterp/parse-tree/pt.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/pt.h Tue Jan 24 17:19:44 2023 -0800 @@ -55,11 +55,11 @@ tree& operator = (const tree&) = delete; - virtual ~tree (void) = default; + virtual ~tree () = default; - virtual int line (void) const { return m_line_num; } + virtual int line () const { return m_line_num; } - virtual int column (void) const { return m_column_num; } + virtual int column () const { return m_column_num; } void line (int l) { m_line_num = l; } @@ -79,7 +79,7 @@ m_bp_cond = new std::string (condition); } - virtual void delete_breakpoint (void) + virtual void delete_breakpoint () { if (m_bp_cond) { @@ -91,7 +91,7 @@ bool meets_bp_condition (tree_evaluator& tw) const; - bool is_breakpoint (void) const + bool is_breakpoint () const { return m_bp_cond; } @@ -103,12 +103,12 @@ // breakpoint condition, or "0" (i.e., "false") if no breakpoint. // To distinguish "0" from a disabled breakpoint, test "is_breakpoint" too. - const std::string bp_cond (void) const + const std::string bp_cond () const { return m_bp_cond ? *m_bp_cond : "0"; } - std::string str_print_code (void); + std::string str_print_code (); virtual void accept (tree_walker& tw) = 0; diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/token.cc --- a/libinterp/parse-tree/token.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/token.cc Tue Jan 24 17:19:44 2023 -0800 @@ -83,7 +83,7 @@ m_tok_info (meth, cls), m_orig_text () { } -token::~token (void) +token::~token () { if (m_type_tag == string_token) delete m_tok_info.m_str; @@ -94,48 +94,48 @@ } std::string -token::text (void) const +token::text () const { panic_if (m_type_tag != string_token); return *m_tok_info.m_str; } octave_value -token::number (void) const +token::number () const { panic_if (m_type_tag != numeric_token); return *m_tok_info.m_num; } token::token_type -token::ttype (void) const +token::ttype () const { return m_type_tag; } token::end_tok_type -token::ettype (void) const +token::ettype () const { panic_if (m_type_tag != ettype_token); return m_tok_info.m_et; } std::string -token::superclass_method_name (void) const +token::superclass_method_name () const { panic_if (m_type_tag != scls_name_token); return m_tok_info.m_superclass_info->m_method_name; } std::string -token::superclass_class_name (void) const +token::superclass_class_name () const { panic_if (m_type_tag != scls_name_token); return m_tok_info.m_superclass_info->m_class_name; } std::string -token::text_rep (void) const +token::text_rep () const { return m_orig_text; } diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/parse-tree/token.h --- a/libinterp/parse-tree/token.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/parse-tree/token.h Tue Jan 24 17:19:44 2023 -0800 @@ -95,43 +95,43 @@ token& operator = (const token&) = delete; - ~token (void); + ~token (); - void mark_may_be_command (void) { m_maybe_cmd = true; } - bool may_be_command (void) const { return m_maybe_cmd; } + void mark_may_be_command () { m_maybe_cmd = true; } + bool may_be_command () const { return m_maybe_cmd; } - void mark_trailing_space (void) { m_tspc = true; } - bool space_follows_token (void) const { return m_tspc; } + void mark_trailing_space () { m_tspc = true; } + bool space_follows_token () const { return m_tspc; } - int token_value (void) const { return m_tok_val; } + int token_value () const { return m_tok_val; } bool token_value_is (int tv) const { return tv == m_tok_val; } - filepos beg_pos (void) const { return m_beg_pos; } - filepos end_pos (void) const { return m_end_pos; } + filepos beg_pos () const { return m_beg_pos; } + filepos end_pos () const { return m_end_pos; } void beg_pos (const filepos& pos) { m_beg_pos = pos; } void end_pos (const filepos& pos) { m_end_pos = pos; } // These will probably be removed. - int line (void) const { return m_beg_pos.line (); } - int column (void) const { return m_beg_pos.column (); } + int line () const { return m_beg_pos.line (); } + int column () const { return m_beg_pos.column (); } - bool iskeyword (void) const + bool iskeyword () const { return m_type_tag == keyword_token || m_type_tag == ettype_token; } - bool isstring (void) const { return m_type_tag == string_token; } + bool isstring () const { return m_type_tag == string_token; } - std::string text (void) const; - octave_value number (void) const; - token_type ttype (void) const; - end_tok_type ettype (void) const; + std::string text () const; + octave_value number () const; + token_type ttype () const; + end_tok_type ettype () const; - std::string superclass_method_name (void) const; - std::string superclass_class_name (void) const; + std::string superclass_method_name () const; + std::string superclass_class_name () const; - std::string text_rep (void) const; + std::string text_rep () const; private: @@ -148,7 +148,7 @@ union tok_info { - tok_info (void) { } + tok_info () { } tok_info (const char *s) : m_str (new std::string (s)) { } @@ -166,7 +166,7 @@ tok_info& operator = (const tok_info&) = delete; - ~tok_info (void) { } + ~tok_info () { } std::string *m_str; @@ -181,13 +181,13 @@ : m_method_name (meth), m_class_name (cls) { } - superclass_info (void) = delete; + superclass_info () = delete; superclass_info (const superclass_info&) = delete; superclass_info& operator = (const superclass_info&) = delete; - ~superclass_info (void) = default; + ~superclass_info () = default; //-------- diff -r 1d1eff97670e -r 21f9b34eb893 libinterp/usage.h --- a/libinterp/usage.h Tue Jan 24 16:17:31 2023 -0500 +++ b/libinterp/usage.h Tue Jan 24 17:19:44 2023 -0800 @@ -46,7 +46,7 @@ // Usage message with extra help. static void -octave_print_verbose_usage_and_exit (void) +octave_print_verbose_usage_and_exit () { std::cout << octave_name_version_copyright_copying_and_warranty () << "\n\ @@ -103,7 +103,7 @@ // Terse usage message. static void -octave_print_terse_usage_and_exit (void) +octave_print_terse_usage_and_exit () { std::cerr << "\nusage: " << usage_string << "\n\n"; @@ -111,7 +111,7 @@ } static void -octave_print_version_and_exit (void) +octave_print_version_and_exit () { std::cout << octave_name_version_copyright_copying_warranty_and_bugs () << "\n"; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/Array-base.cc --- a/liboctave/array/Array-base.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/Array-base.cc Tue Jan 24 17:19:44 2023 -0800 @@ -43,7 +43,7 @@ template typename Array::ArrayRep * -Array::nil_rep (void) +Array::nil_rep () { static ArrayRep nr; return &nr; @@ -106,7 +106,7 @@ template void -Array::clear (void) +Array::clear () { if (--m_rep->m_count == 0) delete m_rep; @@ -136,7 +136,7 @@ template Array -Array::squeeze (void) const +Array::squeeze () const { Array retval = *this; @@ -356,7 +356,7 @@ rec_permute_helper& operator = (const rec_permute_helper&) = delete; - ~rec_permute_helper (void) { delete [] m_dim; } + ~rec_permute_helper () { delete [] m_dim; } template void permute (const T *src, T *dest) const { do_permute (src, dest, m_top); } @@ -561,7 +561,7 @@ rec_index_helper& operator = (const rec_index_helper&) = delete; - ~rec_index_helper (void) { delete [] m_idx; delete [] m_dim; } + ~rec_index_helper () { delete [] m_idx; delete [] m_dim; } template void index (const T *src, T *dest) const { do_index (src, dest, m_top); } @@ -677,7 +677,7 @@ rec_resize_helper& operator = (const rec_resize_helper&) = delete; - ~rec_resize_helper (void) { delete [] m_cext; } + ~rec_resize_helper () { delete [] m_cext; } template void resize_fill (const T *src, T *dest, const T& rfv) const @@ -905,7 +905,7 @@ template T -Array::resize_fill_value (void) const +Array::resize_fill_value () const { static T zero = T (); return zero; @@ -1622,7 +1622,7 @@ template Array -Array::transpose (void) const +Array::transpose () const { assert (ndims () == 2); @@ -1763,7 +1763,7 @@ template T * -Array::fortran_vec (void) +Array::fortran_vec () { make_unique (); @@ -2222,7 +2222,7 @@ template octave_idx_type -Array::nnz (void) const +Array::nnz () const { const T *src = data (); octave_idx_type nel = numel (); @@ -2522,7 +2522,7 @@ return Array (); \ } \ template <> API octave_idx_type \ - Array::nnz (void) const \ + Array::nnz () const \ { \ return 0; \ } \ diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/Array.h --- a/liboctave/array/Array.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/Array.h Tue Jan 24 17:19:44 2023 -0800 @@ -160,7 +160,7 @@ // Use new instead of setting data to 0 so that fortran_vec and // data always return valid addresses, even for zero-size arrays. - ArrayRep (void) + ArrayRep () : Alloc (), m_data (allocate (0)), m_len (0), m_count (1) { } explicit ArrayRep (octave_idx_type len) @@ -185,9 +185,9 @@ std::copy_n (a.m_data, a.m_len, m_data); } - ~ArrayRep (void) { deallocate (m_data, m_len); } + ~ArrayRep () { deallocate (m_data, m_len); } - octave_idx_type numel (void) const { return m_len; } + octave_idx_type numel () const { return m_len; } // No assignment! @@ -213,7 +213,7 @@ public: - OCTARRAY_OVERRIDABLE_FUNC_API void make_unique (void) + OCTARRAY_OVERRIDABLE_FUNC_API void make_unique () { if (m_rep->m_count > 1) { @@ -267,12 +267,12 @@ private: - static OCTARRAY_API typename Array::ArrayRep *nil_rep (void); + static OCTARRAY_API typename Array::ArrayRep *nil_rep (); public: //! Empty ctor (0 by 0). - Array (void) + Array () : m_dimensions (), m_rep (nil_rep ()), m_slice_data (m_rep->m_data), m_slice_len (m_rep->m_len) { @@ -348,7 +348,7 @@ public: - virtual ~Array (void) + virtual ~Array () { // Because we define a move constructor and a move assignment // operator, m_rep may be a nullptr here. We should only need to @@ -403,7 +403,7 @@ OCTARRAY_API void fill (const T& val); - OCTARRAY_API void clear (void); + OCTARRAY_API void clear (); OCTARRAY_API void clear (const dim_vector& dv); void clear (octave_idx_type r, octave_idx_type c) @@ -411,13 +411,13 @@ //! Number of elements in the array. OCTARRAY_OVERRIDABLE_FUNC_API octave_idx_type - numel (void) const + numel () const { return m_slice_len; } //@} //! Return the array as a column vector. OCTARRAY_OVERRIDABLE_FUNC_API Array - as_column (void) const + as_column () const { Array retval (*this); if (m_dimensions.ndims () != 2 || m_dimensions(1) != 1) @@ -428,7 +428,7 @@ //! Return the array as a row vector. OCTARRAY_OVERRIDABLE_FUNC_API Array - as_row (void) const + as_row () const { Array retval (*this); if (m_dimensions.ndims () != 2 || m_dimensions(0) != 1) @@ -439,7 +439,7 @@ //! Return the array as a matrix. OCTARRAY_OVERRIDABLE_FUNC_API Array - as_matrix (void) const + as_matrix () const { Array retval (*this); if (m_dimensions.ndims () != 2) @@ -453,10 +453,10 @@ //! Get the first dimension of the array (number of rows) //@{ OCTARRAY_OVERRIDABLE_FUNC_API octave_idx_type - dim1 (void) const + dim1 () const { return m_dimensions(0); } OCTARRAY_OVERRIDABLE_FUNC_API octave_idx_type - rows (void) const + rows () const { return dim1 (); } //@} @@ -464,11 +464,11 @@ //! //! Get the second dimension of the array (number of columns) //@{ - OCTARRAY_OVERRIDABLE_FUNC_API octave_idx_type dim2 (void) const + OCTARRAY_OVERRIDABLE_FUNC_API octave_idx_type dim2 () const { return m_dimensions(1); } - OCTARRAY_OVERRIDABLE_FUNC_API octave_idx_type cols (void) const + OCTARRAY_OVERRIDABLE_FUNC_API octave_idx_type cols () const { return dim2 (); } - OCTARRAY_OVERRIDABLE_FUNC_API octave_idx_type columns (void) const + OCTARRAY_OVERRIDABLE_FUNC_API octave_idx_type columns () const { return dim2 (); } //@} @@ -476,9 +476,9 @@ //! //! Get the third dimension of the array (number of pages) //@{ - OCTARRAY_OVERRIDABLE_FUNC_API octave_idx_type dim3 (void) const + OCTARRAY_OVERRIDABLE_FUNC_API octave_idx_type dim3 () const { return m_dimensions.ndims () >= 3 ? m_dimensions(2) : 1; } - OCTARRAY_OVERRIDABLE_FUNC_API octave_idx_type pages (void) const + OCTARRAY_OVERRIDABLE_FUNC_API octave_idx_type pages () const { return dim3 (); } //@} @@ -496,15 +496,15 @@ return d >= ndims () ? 1 : m_dimensions(d); } - OCTARRAY_OVERRIDABLE_FUNC_API std::size_t byte_size (void) const + OCTARRAY_OVERRIDABLE_FUNC_API std::size_t byte_size () const { return static_cast (numel ()) * sizeof (T); } //! Return a const-reference so that dims ()(i) works efficiently. - OCTARRAY_OVERRIDABLE_FUNC_API const dim_vector& dims (void) const + OCTARRAY_OVERRIDABLE_FUNC_API const dim_vector& dims () const { return m_dimensions; } //! Chop off leading singleton dimensions - OCTARRAY_API Array squeeze (void) const; + OCTARRAY_API Array squeeze () const; OCTARRAY_API octave_idx_type compute_index (octave_idx_type i, octave_idx_type j) const; @@ -645,30 +645,30 @@ ipermute (const Array& vec) const { return permute (vec, true); } - OCTARRAY_OVERRIDABLE_FUNC_API bool issquare (void) const + OCTARRAY_OVERRIDABLE_FUNC_API bool issquare () const { return (dim1 () == dim2 ()); } - OCTARRAY_OVERRIDABLE_FUNC_API bool isempty (void) const + OCTARRAY_OVERRIDABLE_FUNC_API bool isempty () const { return numel () == 0; } - OCTARRAY_OVERRIDABLE_FUNC_API bool isvector (void) const + OCTARRAY_OVERRIDABLE_FUNC_API bool isvector () const { return m_dimensions.isvector (); } - OCTARRAY_OVERRIDABLE_FUNC_API bool is_nd_vector (void) const + OCTARRAY_OVERRIDABLE_FUNC_API bool is_nd_vector () const { return m_dimensions.is_nd_vector (); } - OCTARRAY_API Array transpose (void) const; + OCTARRAY_API Array transpose () const; OCTARRAY_API Array hermitian (T (*fcn) (const T&) = nullptr) const; - OCTARRAY_OVERRIDABLE_FUNC_API const T * data (void) const + OCTARRAY_OVERRIDABLE_FUNC_API const T * data () const { return m_slice_data; } - OCTARRAY_API T * fortran_vec (void); + OCTARRAY_API T * fortran_vec (); - OCTARRAY_OVERRIDABLE_FUNC_API bool is_shared (void) const + OCTARRAY_OVERRIDABLE_FUNC_API bool is_shared () const { return m_rep->m_count > 1; } - OCTARRAY_OVERRIDABLE_FUNC_API int ndims (void) const + OCTARRAY_OVERRIDABLE_FUNC_API int ndims () const { return m_dimensions.ndims (); } //@{ @@ -680,7 +680,7 @@ OCTARRAY_API Array index (const Array& ia) const; //@} - virtual OCTARRAY_API T resize_fill_value (void) const; + virtual OCTARRAY_API T resize_fill_value () const; //@{ //! Resizing (with fill). @@ -786,7 +786,7 @@ OCTARRAY_API Array& insert (const Array& a, octave_idx_type r, octave_idx_type c); - OCTARRAY_OVERRIDABLE_FUNC_API void maybe_economize (void) + OCTARRAY_OVERRIDABLE_FUNC_API void maybe_economize () { if (m_rep->m_count == 1 && m_slice_len != m_rep->m_len) { @@ -822,7 +822,7 @@ sortmode mode = UNSORTED) const; //! Count nonzero elements. - OCTARRAY_API octave_idx_type nnz (void) const; + OCTARRAY_API octave_idx_type nnz () const; //! Find indices of (at most n) nonzero elements. If n is specified, //! backward specifies search from backward. diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/CColVector.cc --- a/liboctave/array/CColVector.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/CColVector.cc Tue Jan 24 17:19:44 2023 -0800 @@ -196,19 +196,19 @@ } ComplexRowVector -ComplexColumnVector::hermitian (void) const +ComplexColumnVector::hermitian () const { return MArray::hermitian (std::conj); } ComplexRowVector -ComplexColumnVector::transpose (void) const +ComplexColumnVector::transpose () const { return MArray::transpose (); } ColumnVector -ComplexColumnVector::abs (void) const +ComplexColumnVector::abs () const { return do_mx_unary_map (*this); } @@ -420,7 +420,7 @@ // other operations Complex -ComplexColumnVector::min (void) const +ComplexColumnVector::min () const { octave_idx_type len = numel (); if (len == 0) @@ -440,7 +440,7 @@ } Complex -ComplexColumnVector::max (void) const +ComplexColumnVector::max () const { octave_idx_type len = numel (); if (len == 0) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/CColVector.h --- a/liboctave/array/CColVector.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/CColVector.h Tue Jan 24 17:19:44 2023 -0800 @@ -40,7 +40,7 @@ public: - ComplexColumnVector (void) : MArray (dim_vector (0, 1)) { } + ComplexColumnVector () : MArray (dim_vector (0, 1)) { } explicit ComplexColumnVector (octave_idx_type n) : MArray (dim_vector (n, 1)) { } @@ -87,8 +87,8 @@ OCTAVE_API ComplexColumnVector stack (const ColumnVector& a) const; OCTAVE_API ComplexColumnVector stack (const ComplexColumnVector& a) const; - OCTAVE_API ComplexRowVector hermitian (void) const; - OCTAVE_API ComplexRowVector transpose (void) const; + OCTAVE_API ComplexRowVector hermitian () const; + OCTAVE_API ComplexRowVector transpose () const; friend OCTAVE_API ComplexColumnVector conj (const ComplexColumnVector& a); @@ -131,10 +131,10 @@ // other operations - OCTAVE_API Complex min (void) const; - OCTAVE_API Complex max (void) const; + OCTAVE_API Complex min () const; + OCTAVE_API Complex max () const; - OCTAVE_API ColumnVector abs (void) const; + OCTAVE_API ColumnVector abs () const; // i/o diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/CDiagMatrix.cc --- a/liboctave/array/CDiagMatrix.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/CDiagMatrix.cc Tue Jan 24 17:19:44 2023 -0800 @@ -206,7 +206,7 @@ } DiagMatrix -ComplexDiagMatrix::abs (void) const +ComplexDiagMatrix::abs () const { return DiagMatrix (extract_diag ().abs (), rows (), columns ()); } @@ -301,7 +301,7 @@ } ComplexDiagMatrix -ComplexDiagMatrix::inverse (void) const +ComplexDiagMatrix::inverse () const { octave_idx_type info; return inverse (info); @@ -374,7 +374,7 @@ } bool -ComplexDiagMatrix::all_elements_are_real (void) const +ComplexDiagMatrix::all_elements_are_real () const { return mx_inline_all_real (length (), data ()); } @@ -490,7 +490,7 @@ // other operations ComplexDET -ComplexDiagMatrix::determinant (void) const +ComplexDiagMatrix::determinant () const { ComplexDET det (1.0); if (rows () != cols ()) @@ -504,7 +504,7 @@ } double -ComplexDiagMatrix::rcond (void) const +ComplexDiagMatrix::rcond () const { ColumnVector av = extract_diag (0).map (std::abs); double amx = av.max (); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/CDiagMatrix.h --- a/liboctave/array/CDiagMatrix.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/CDiagMatrix.h Tue Jan 24 17:19:44 2023 -0800 @@ -48,13 +48,13 @@ typedef Complex complex_elt_type; typedef Complex element_type; - ComplexDiagMatrix (void) = default; + ComplexDiagMatrix () = default; ComplexDiagMatrix (const ComplexDiagMatrix& a) = default; ComplexDiagMatrix& operator = (const ComplexDiagMatrix& a) = default; - ~ComplexDiagMatrix (void) = default; + ~ComplexDiagMatrix () = default; ComplexDiagMatrix (octave_idx_type r, octave_idx_type c) : MDiagArray2 (r, c) { } @@ -102,11 +102,11 @@ OCTAVE_API ComplexDiagMatrix& fill (const ComplexRowVector& a, octave_idx_type beg); - ComplexDiagMatrix hermitian (void) const + ComplexDiagMatrix hermitian () const { return MDiagArray2::hermitian (std::conj); } - ComplexDiagMatrix transpose (void) const + ComplexDiagMatrix transpose () const { return MDiagArray2::transpose (); } - DiagMatrix abs (void) const; + DiagMatrix abs () const; friend OCTAVE_API ComplexDiagMatrix conj (const ComplexDiagMatrix& a); @@ -125,10 +125,10 @@ OCTAVE_API ComplexColumnVector column (char *s) const; OCTAVE_API ComplexDiagMatrix inverse (octave_idx_type& info) const; - OCTAVE_API ComplexDiagMatrix inverse (void) const; + OCTAVE_API ComplexDiagMatrix inverse () const; OCTAVE_API ComplexDiagMatrix pseudo_inverse (double tol = 0.0) const; - OCTAVE_API bool all_elements_are_real (void) const; + OCTAVE_API bool all_elements_are_real () const; // diagonal matrix by diagonal matrix -> diagonal matrix operations @@ -140,8 +140,8 @@ ComplexColumnVector extract_diag (octave_idx_type k = 0) const { return MDiagArray2::extract_diag (k); } - OCTAVE_API ComplexDET determinant (void) const; - OCTAVE_API double rcond (void) const; + OCTAVE_API ComplexDET determinant () const; + OCTAVE_API double rcond () const; // i/o diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/CMatrix.cc --- a/liboctave/array/CMatrix.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/CMatrix.cc Tue Jan 24 17:19:44 2023 -0800 @@ -171,7 +171,7 @@ } bool -ComplexMatrix::ishermitian (void) const +ComplexMatrix::ishermitian () const { octave_idx_type nr = rows (); octave_idx_type nc = cols (); @@ -734,7 +734,7 @@ } ComplexMatrix -ComplexMatrix::inverse (void) const +ComplexMatrix::inverse () const { octave_idx_type info; double rcon; @@ -1042,7 +1042,7 @@ #if defined (HAVE_FFTW) ComplexMatrix -ComplexMatrix::fourier (void) const +ComplexMatrix::fourier () const { std::size_t nr = rows (); std::size_t nc = cols (); @@ -1071,7 +1071,7 @@ } ComplexMatrix -ComplexMatrix::ifourier (void) const +ComplexMatrix::ifourier () const { std::size_t nr = rows (); std::size_t nc = cols (); @@ -1100,7 +1100,7 @@ } ComplexMatrix -ComplexMatrix::fourier2d (void) const +ComplexMatrix::fourier2d () const { dim_vector dv (rows (), cols ()); @@ -1114,7 +1114,7 @@ } ComplexMatrix -ComplexMatrix::ifourier2d (void) const +ComplexMatrix::ifourier2d () const { dim_vector dv (rows (), cols ()); @@ -1130,7 +1130,7 @@ #else ComplexMatrix -ComplexMatrix::fourier (void) const +ComplexMatrix::fourier () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -1139,7 +1139,7 @@ } ComplexMatrix -ComplexMatrix::ifourier (void) const +ComplexMatrix::ifourier () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -1148,7 +1148,7 @@ } ComplexMatrix -ComplexMatrix::fourier2d (void) const +ComplexMatrix::fourier2d () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -1157,7 +1157,7 @@ } ComplexMatrix -ComplexMatrix::ifourier2d (void) const +ComplexMatrix::ifourier2d () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -1168,7 +1168,7 @@ #endif ComplexDET -ComplexMatrix::determinant (void) const +ComplexMatrix::determinant () const { octave_idx_type info; double rcon; @@ -1347,7 +1347,7 @@ } double -ComplexMatrix::rcond (void) const +ComplexMatrix::rcond () const { MatrixType mattype (*this); return rcond (mattype); @@ -2821,7 +2821,7 @@ } Matrix -ComplexMatrix::abs (void) const +ComplexMatrix::abs () const { return ComplexNDArray::abs (); } @@ -2883,7 +2883,7 @@ } ComplexColumnVector -ComplexMatrix::row_min (void) const +ComplexMatrix::row_min () const { Array dummy_idx; return row_min (dummy_idx); @@ -2958,7 +2958,7 @@ } ComplexColumnVector -ComplexMatrix::row_max (void) const +ComplexMatrix::row_max () const { Array dummy_idx; return row_max (dummy_idx); @@ -3033,7 +3033,7 @@ } ComplexRowVector -ComplexMatrix::column_min (void) const +ComplexMatrix::column_min () const { Array dummy_idx; return column_min (dummy_idx); @@ -3108,7 +3108,7 @@ } ComplexRowVector -ComplexMatrix::column_max (void) const +ComplexMatrix::column_max () const { Array dummy_idx; return column_max (dummy_idx); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/CMatrix.h --- a/liboctave/array/CMatrix.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/CMatrix.h Tue Jan 24 17:19:44 2023 -0800 @@ -60,13 +60,13 @@ typedef void (*solve_singularity_handler) (double rcon); - ComplexMatrix (void) = default; + ComplexMatrix () = default; ComplexMatrix (const ComplexMatrix& a) = default; ComplexMatrix& operator = (const ComplexMatrix& a) = default; - ~ComplexMatrix (void) = default; + ~ComplexMatrix () = default; ComplexMatrix (octave_idx_type r, octave_idx_type c) : ComplexNDArray (dim_vector (r, c)) { } @@ -116,7 +116,7 @@ OCTAVE_API bool operator == (const ComplexMatrix& a) const; OCTAVE_API bool operator != (const ComplexMatrix& a) const; - OCTAVE_API bool ishermitian (void) const; + OCTAVE_API bool ishermitian () const; // destructive insert/delete/reorder operations @@ -167,9 +167,9 @@ OCTAVE_API ComplexMatrix stack (const ComplexColumnVector& a) const; OCTAVE_API ComplexMatrix stack (const ComplexDiagMatrix& a) const; - ComplexMatrix hermitian (void) const + ComplexMatrix hermitian () const { return MArray::hermitian (std::conj); } - ComplexMatrix transpose (void) const + ComplexMatrix transpose () const { return MArray::transpose (); } friend OCTAVE_API ComplexMatrix conj (const ComplexMatrix& a); @@ -204,7 +204,7 @@ double& rcon, bool force, bool calc_cond) const; public: - OCTAVE_API ComplexMatrix inverse (void) const; + OCTAVE_API ComplexMatrix inverse () const; OCTAVE_API ComplexMatrix inverse (octave_idx_type& info) const; OCTAVE_API ComplexMatrix inverse (octave_idx_type& info, double& rcon, @@ -219,13 +219,13 @@ OCTAVE_API ComplexMatrix pseudo_inverse (double tol = 0.0) const; - OCTAVE_API ComplexMatrix fourier (void) const; - OCTAVE_API ComplexMatrix ifourier (void) const; + OCTAVE_API ComplexMatrix fourier () const; + OCTAVE_API ComplexMatrix ifourier () const; - OCTAVE_API ComplexMatrix fourier2d (void) const; - OCTAVE_API ComplexMatrix ifourier2d (void) const; + OCTAVE_API ComplexMatrix fourier2d () const; + OCTAVE_API ComplexMatrix ifourier2d () const; - OCTAVE_API ComplexDET determinant (void) const; + OCTAVE_API ComplexDET determinant () const; OCTAVE_API ComplexDET determinant (octave_idx_type& info) const; OCTAVE_API ComplexDET determinant (octave_idx_type& info, double& rcon, @@ -234,7 +234,7 @@ determinant (MatrixType& mattype, octave_idx_type& info, double& rcon, bool calc_cond = true) const; - OCTAVE_API double rcond (void) const; + OCTAVE_API double rcond () const; OCTAVE_API double rcond (MatrixType& mattype) const; private: @@ -418,7 +418,7 @@ OCTAVE_API ComplexMatrix prod (int dim = -1) const; OCTAVE_API ComplexMatrix sum (int dim = -1) const; OCTAVE_API ComplexMatrix sumsq (int dim = -1) const; - OCTAVE_API Matrix abs (void) const; + OCTAVE_API Matrix abs () const; OCTAVE_API ComplexMatrix diag (octave_idx_type k = 0) const; @@ -428,14 +428,14 @@ OCTAVE_API bool row_is_real_only (octave_idx_type) const; OCTAVE_API bool column_is_real_only (octave_idx_type) const; - OCTAVE_API ComplexColumnVector row_min (void) const; - OCTAVE_API ComplexColumnVector row_max (void) const; + OCTAVE_API ComplexColumnVector row_min () const; + OCTAVE_API ComplexColumnVector row_max () const; OCTAVE_API ComplexColumnVector row_min (Array& index) const; OCTAVE_API ComplexColumnVector row_max (Array& index) const; - OCTAVE_API ComplexRowVector column_min (void) const; - OCTAVE_API ComplexRowVector column_max (void) const; + OCTAVE_API ComplexRowVector column_min () const; + OCTAVE_API ComplexRowVector column_max () const; OCTAVE_API ComplexRowVector column_min (Array& index) const; OCTAVE_API ComplexRowVector column_max (Array& index) const; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/CNDArray.cc --- a/liboctave/array/CNDArray.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/CNDArray.cc Tue Jan 24 17:19:44 2023 -0800 @@ -117,7 +117,7 @@ } ComplexNDArray -ComplexNDArray::fourier2d (void) const +ComplexNDArray::fourier2d () const { dim_vector dv = dims (); if (dv.ndims () < 2) @@ -137,7 +137,7 @@ } ComplexNDArray -ComplexNDArray::ifourier2d (void) const +ComplexNDArray::ifourier2d () const { dim_vector dv = dims (); if (dv.ndims () < 2) @@ -157,7 +157,7 @@ } ComplexNDArray -ComplexNDArray::fourierNd (void) const +ComplexNDArray::fourierNd () const { dim_vector dv = dims (); int rank = dv.ndims (); @@ -172,7 +172,7 @@ } ComplexNDArray -ComplexNDArray::ifourierNd (void) const +ComplexNDArray::ifourierNd () const { dim_vector dv = dims (); int rank = dv.ndims (); @@ -211,7 +211,7 @@ } ComplexNDArray -ComplexNDArray::fourier2d (void) const +ComplexNDArray::fourier2d () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -220,7 +220,7 @@ } ComplexNDArray -ComplexNDArray::ifourier2d (void) const +ComplexNDArray::ifourier2d () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -229,7 +229,7 @@ } ComplexNDArray -ComplexNDArray::fourierNd (void) const +ComplexNDArray::fourierNd () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -238,7 +238,7 @@ } ComplexNDArray -ComplexNDArray::ifourierNd (void) const +ComplexNDArray::ifourierNd () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -251,7 +251,7 @@ // unary operations boolNDArray -ComplexNDArray::operator ! (void) const +ComplexNDArray::operator ! () const { if (any_element_is_nan ()) octave::err_nan_to_logical_conversion (); @@ -262,13 +262,13 @@ // FIXME: this is not quite the right thing. bool -ComplexNDArray::any_element_is_nan (void) const +ComplexNDArray::any_element_is_nan () const { return do_mx_check (*this, mx_inline_any_nan); } bool -ComplexNDArray::any_element_is_inf_or_nan (void) const +ComplexNDArray::any_element_is_inf_or_nan () const { return ! do_mx_check (*this, mx_inline_all_finite); } @@ -276,7 +276,7 @@ // Return true if no elements have imaginary components. bool -ComplexNDArray::all_elements_are_real (void) const +ComplexNDArray::all_elements_are_real () const { return do_mx_check (*this, mx_inline_all_real); } @@ -337,7 +337,7 @@ } bool -ComplexNDArray::too_large_for_float (void) const +ComplexNDArray::too_large_for_float () const { return test_any (octave::too_large_for_float); } @@ -475,25 +475,25 @@ } NDArray -ComplexNDArray::abs (void) const +ComplexNDArray::abs () const { return do_mx_unary_map (*this); } boolNDArray -ComplexNDArray::isnan (void) const +ComplexNDArray::isnan () const { return do_mx_unary_map (*this); } boolNDArray -ComplexNDArray::isinf (void) const +ComplexNDArray::isinf () const { return do_mx_unary_map (*this); } boolNDArray -ComplexNDArray::isfinite (void) const +ComplexNDArray::isfinite () const { return do_mx_unary_map (*this); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/CNDArray.h --- a/liboctave/array/CNDArray.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/CNDArray.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,7 +39,7 @@ { public: - ComplexNDArray (void) : MArray () { } + ComplexNDArray () : MArray () { } ComplexNDArray (const dim_vector& dv) : MArray (dv) { } @@ -64,15 +64,15 @@ // unary operations - OCTAVE_API boolNDArray operator ! (void) const; + OCTAVE_API boolNDArray operator ! () const; // FIXME: this is not quite the right thing. - OCTAVE_API bool any_element_is_nan (void) const; - OCTAVE_API bool any_element_is_inf_or_nan (void) const; - OCTAVE_API bool all_elements_are_real (void) const; + OCTAVE_API bool any_element_is_nan () const; + OCTAVE_API bool any_element_is_inf_or_nan () const; + OCTAVE_API bool all_elements_are_real () const; OCTAVE_API bool all_integers (double& max_val, double& min_val) const; - OCTAVE_API bool too_large_for_float (void) const; + OCTAVE_API bool too_large_for_float () const; OCTAVE_API boolNDArray all (int dim = -1) const; OCTAVE_API boolNDArray any (int dim = -1) const; @@ -112,23 +112,23 @@ OCTAVE_API ComplexNDArray& insert (const ComplexNDArray& a, const Array& ra_idx); - OCTAVE_API NDArray abs (void) const; - OCTAVE_API boolNDArray isnan (void) const; - OCTAVE_API boolNDArray isinf (void) const; - OCTAVE_API boolNDArray isfinite (void) const; + OCTAVE_API NDArray abs () const; + OCTAVE_API boolNDArray isnan () const; + OCTAVE_API boolNDArray isinf () const; + OCTAVE_API boolNDArray isfinite () const; friend OCTAVE_API ComplexNDArray conj (const ComplexNDArray& a); OCTAVE_API ComplexNDArray fourier (int dim = 1) const; OCTAVE_API ComplexNDArray ifourier (int dim = 1) const; - OCTAVE_API ComplexNDArray fourier2d (void) const; - OCTAVE_API ComplexNDArray ifourier2d (void) const; + OCTAVE_API ComplexNDArray fourier2d () const; + OCTAVE_API ComplexNDArray ifourier2d () const; - OCTAVE_API ComplexNDArray fourierNd (void) const; - OCTAVE_API ComplexNDArray ifourierNd (void) const; + OCTAVE_API ComplexNDArray fourierNd () const; + OCTAVE_API ComplexNDArray ifourierNd () const; - ComplexNDArray squeeze (void) const { return MArray::squeeze (); } + ComplexNDArray squeeze () const { return MArray::squeeze (); } static OCTAVE_API void increment_index (Array& ra_idx, @@ -146,14 +146,14 @@ friend OCTAVE_API std::istream& operator >> (std::istream& is, ComplexNDArray& a); - // bool all_elements_are_real (void) const; + // bool all_elements_are_real () const; // bool all_integers (double& max_val, double& min_val) const; OCTAVE_API ComplexNDArray diag (octave_idx_type k = 0) const; OCTAVE_API ComplexNDArray diag (octave_idx_type m, octave_idx_type n) const; - ComplexNDArray& changesign (void) + ComplexNDArray& changesign () { MArray::changesign (); return *this; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/CRowVector.cc --- a/liboctave/array/CRowVector.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/CRowVector.cc Tue Jan 24 17:19:44 2023 -0800 @@ -193,13 +193,13 @@ } ComplexColumnVector -ComplexRowVector::hermitian (void) const +ComplexRowVector::hermitian () const { return MArray::hermitian (std::conj); } ComplexColumnVector -ComplexRowVector::transpose (void) const +ComplexRowVector::transpose () const { return MArray::transpose (); } @@ -323,7 +323,7 @@ // other operations Complex -ComplexRowVector::min (void) const +ComplexRowVector::min () const { octave_idx_type len = numel (); if (len == 0) @@ -343,7 +343,7 @@ } Complex -ComplexRowVector::max (void) const +ComplexRowVector::max () const { octave_idx_type len = numel (); if (len == 0) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/CRowVector.h --- a/liboctave/array/CRowVector.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/CRowVector.h Tue Jan 24 17:19:44 2023 -0800 @@ -40,7 +40,7 @@ public: - ComplexRowVector (void) : MArray (dim_vector (1, 0)) { } + ComplexRowVector () : MArray (dim_vector (1, 0)) { } explicit ComplexRowVector (octave_idx_type n) : MArray (dim_vector (1, n)) { } @@ -86,8 +86,8 @@ OCTAVE_API ComplexRowVector append (const RowVector& a) const; OCTAVE_API ComplexRowVector append (const ComplexRowVector& a) const; - OCTAVE_API ComplexColumnVector hermitian (void) const; - OCTAVE_API ComplexColumnVector transpose (void) const; + OCTAVE_API ComplexColumnVector hermitian () const; + OCTAVE_API ComplexColumnVector transpose () const; friend OCTAVE_API ComplexRowVector conj (const ComplexRowVector& a); @@ -114,8 +114,8 @@ // other operations - OCTAVE_API Complex min (void) const; - OCTAVE_API Complex max (void) const; + OCTAVE_API Complex min () const; + OCTAVE_API Complex max () const; // i/o diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/CSparse.cc --- a/liboctave/array/CSparse.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/CSparse.cc Tue Jan 24 17:19:44 2023 -0800 @@ -139,7 +139,7 @@ } bool -SparseComplexMatrix::ishermitian (void) const +SparseComplexMatrix::ishermitian () const { octave_idx_type nr = rows (); octave_idx_type nc = cols (); @@ -597,13 +597,13 @@ } ComplexMatrix -SparseComplexMatrix::matrix_value (void) const +SparseComplexMatrix::matrix_value () const { return Sparse::array_value (); } SparseComplexMatrix -SparseComplexMatrix::hermitian (void) const +SparseComplexMatrix::hermitian () const { octave_idx_type nr = rows (); octave_idx_type nc = cols (); @@ -657,7 +657,7 @@ } SparseComplexMatrix -SparseComplexMatrix::inverse (void) const +SparseComplexMatrix::inverse () const { octave_idx_type info; double rcond; @@ -1068,7 +1068,7 @@ } ComplexDET -SparseComplexMatrix::determinant (void) const +SparseComplexMatrix::determinant () const { octave_idx_type info; double rcond; @@ -7210,7 +7210,7 @@ // unary operations SparseBoolMatrix -SparseComplexMatrix::operator ! (void) const +SparseComplexMatrix::operator ! () const { if (any_element_is_nan ()) octave::err_nan_to_logical_conversion (); @@ -7244,7 +7244,7 @@ } SparseComplexMatrix -SparseComplexMatrix::squeeze (void) const +SparseComplexMatrix::squeeze () const { return MSparse::squeeze (); } @@ -7270,7 +7270,7 @@ // other operations bool -SparseComplexMatrix::any_element_is_nan (void) const +SparseComplexMatrix::any_element_is_nan () const { octave_idx_type nel = nnz (); @@ -7285,7 +7285,7 @@ } bool -SparseComplexMatrix::any_element_is_inf_or_nan (void) const +SparseComplexMatrix::any_element_is_inf_or_nan () const { octave_idx_type nel = nnz (); @@ -7302,7 +7302,7 @@ // Return true if no elements have imaginary components. bool -SparseComplexMatrix::all_elements_are_real (void) const +SparseComplexMatrix::all_elements_are_real () const { return mx_inline_all_real (nnz (), data ()); } @@ -7350,7 +7350,7 @@ } bool -SparseComplexMatrix::too_large_for_float (void) const +SparseComplexMatrix::too_large_for_float () const { return test_any (octave::too_large_for_float); } @@ -7417,7 +7417,7 @@ #undef COL_EXPR } -SparseMatrix SparseComplexMatrix::abs (void) const +SparseMatrix SparseComplexMatrix::abs () const { octave_idx_type nz = nnz (); octave_idx_type nc = cols (); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/CSparse.h --- a/liboctave/array/CSparse.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/CSparse.h Tue Jan 24 17:19:44 2023 -0800 @@ -52,7 +52,7 @@ typedef void (*solve_singularity_handler) (double rcond); - SparseComplexMatrix (void) : MSparse () { } + SparseComplexMatrix () : MSparse () { } SparseComplexMatrix (octave_idx_type r, octave_idx_type c) : MSparse (r, c) { } @@ -108,7 +108,7 @@ OCTAVE_API bool operator == (const SparseComplexMatrix& a) const; OCTAVE_API bool operator != (const SparseComplexMatrix& a) const; - OCTAVE_API bool ishermitian (void) const; + OCTAVE_API bool ishermitian () const; OCTAVE_API SparseComplexMatrix max (int dim = -1) const; OCTAVE_API SparseComplexMatrix @@ -131,10 +131,10 @@ OCTAVE_API SparseComplexMatrix concat (const SparseMatrix& rb, const Array& ra_idx); - OCTAVE_API ComplexMatrix matrix_value (void) const; + OCTAVE_API ComplexMatrix matrix_value () const; - OCTAVE_API SparseComplexMatrix hermitian (void) const; // complex conjugate transpose - SparseComplexMatrix transpose (void) const + OCTAVE_API SparseComplexMatrix hermitian () const; // complex conjugate transpose + SparseComplexMatrix transpose () const { return MSparse::transpose (); } friend OCTAVE_API SparseComplexMatrix conj (const SparseComplexMatrix& a); @@ -155,7 +155,7 @@ const bool calccond = true) const; public: - OCTAVE_API SparseComplexMatrix inverse (void) const; + OCTAVE_API SparseComplexMatrix inverse () const; OCTAVE_API SparseComplexMatrix inverse (MatrixType& mattype) const; OCTAVE_API SparseComplexMatrix inverse (MatrixType& mattype, octave_idx_type& info) const; @@ -163,7 +163,7 @@ inverse (MatrixType& mattype, octave_idx_type& info, double& rcond, bool force = false, bool calc_cond = true) const; - OCTAVE_API ComplexDET determinant (void) const; + OCTAVE_API ComplexDET determinant () const; OCTAVE_API ComplexDET determinant (octave_idx_type& info) const; OCTAVE_API ComplexDET determinant (octave_idx_type& info, double& rcond, @@ -437,7 +437,7 @@ solve (const ComplexColumnVector& b, octave_idx_type& info, double& rcond, solve_singularity_handler sing_handler) const; - OCTAVE_API SparseComplexMatrix squeeze (void) const; + OCTAVE_API SparseComplexMatrix squeeze () const; OCTAVE_API SparseComplexMatrix reshape (const dim_vector& new_dims) const; @@ -447,13 +447,13 @@ OCTAVE_API SparseComplexMatrix ipermute (const Array& vec) const; - OCTAVE_API bool any_element_is_nan (void) const; - OCTAVE_API bool any_element_is_inf_or_nan (void) const; - OCTAVE_API bool all_elements_are_real (void) const; + OCTAVE_API bool any_element_is_nan () const; + OCTAVE_API bool any_element_is_inf_or_nan () const; + OCTAVE_API bool all_elements_are_real () const; OCTAVE_API bool all_integers (double& max_val, double& min_val) const; - OCTAVE_API bool too_large_for_float (void) const; + OCTAVE_API bool too_large_for_float () const; - OCTAVE_API SparseBoolMatrix operator ! (void) const; + OCTAVE_API SparseBoolMatrix operator ! () const; OCTAVE_API SparseBoolMatrix all (int dim = -1) const; OCTAVE_API SparseBoolMatrix any (int dim = -1) const; @@ -463,7 +463,7 @@ OCTAVE_API SparseComplexMatrix prod (int dim = -1) const; OCTAVE_API SparseComplexMatrix sum (int dim = -1) const; OCTAVE_API SparseComplexMatrix sumsq (int dim = -1) const; - OCTAVE_API SparseMatrix abs (void) const; + OCTAVE_API SparseMatrix abs () const; OCTAVE_API SparseComplexMatrix diag (octave_idx_type k = 0) const; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/DiagArray2.cc --- a/liboctave/array/DiagArray2.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/DiagArray2.cc Tue Jan 24 17:19:44 2023 -0800 @@ -66,7 +66,7 @@ template DiagArray2 -DiagArray2::transpose (void) const +DiagArray2::transpose () const { return DiagArray2 (*this, m_d2, m_d1); } @@ -113,7 +113,7 @@ template Array -DiagArray2::array_value (void) const +DiagArray2::array_value () const { Array result (dims (), T (0)); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/DiagArray2.h --- a/liboctave/array/DiagArray2.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/DiagArray2.h Tue Jan 24 17:19:44 2023 -0800 @@ -48,7 +48,7 @@ using typename Array::element_type; - DiagArray2 (void) + DiagArray2 () : Array (), m_d1 (0), m_d2 (0) { } DiagArray2 (octave_idx_type r, octave_idx_type c) @@ -69,7 +69,7 @@ DiagArray2 (const DiagArray2& a) : Array (a.extract_diag ()), m_d1 (a.dim1 ()), m_d2 (a.dim2 ()) { } - ~DiagArray2 (void) = default; + ~DiagArray2 () = default; DiagArray2& operator = (const DiagArray2& a) { @@ -83,26 +83,26 @@ return *this; } - octave_idx_type dim1 (void) const { return m_d1; } - octave_idx_type dim2 (void) const { return m_d2; } + octave_idx_type dim1 () const { return m_d1; } + octave_idx_type dim2 () const { return m_d2; } - octave_idx_type rows (void) const { return dim1 (); } - octave_idx_type cols (void) const { return dim2 (); } - octave_idx_type columns (void) const { return dim2 (); } + octave_idx_type rows () const { return dim1 (); } + octave_idx_type cols () const { return dim2 (); } + octave_idx_type columns () const { return dim2 (); } - octave_idx_type diag_length (void) const { return Array::numel (); } + octave_idx_type diag_length () const { return Array::numel (); } // FIXME: a dangerous ambiguity? - octave_idx_type length (void) const { return Array::numel (); } - octave_idx_type nelem (void) const { return dim1 () * dim2 (); } - octave_idx_type numel (void) const { return nelem (); } + octave_idx_type length () const { return Array::numel (); } + octave_idx_type nelem () const { return dim1 () * dim2 (); } + octave_idx_type numel () const { return nelem (); } - std::size_t byte_size (void) const { return Array::byte_size (); } + std::size_t byte_size () const { return Array::byte_size (); } - dim_vector dims (void) const { return dim_vector (m_d1, m_d2); } + dim_vector dims () const { return dim_vector (m_d1, m_d2); } - bool isempty (void) const { return numel () == 0; } + bool isempty () const { return numel () == 0; } - int ndims (void) const { return 2; } + int ndims () const { return 2; } OCTAVE_API Array extract_diag (octave_idx_type k = 0) const; @@ -161,14 +161,14 @@ resize (n, m, Array::resize_fill_value ()); } - OCTAVE_API DiagArray2 transpose (void) const; + OCTAVE_API DiagArray2 transpose () const; OCTAVE_API DiagArray2 hermitian (T (*fcn) (const T&) = nullptr) const; - OCTAVE_API Array array_value (void) const; + OCTAVE_API Array array_value () const; - const T * data (void) const { return Array::data (); } + const T * data () const { return Array::data (); } - T * fortran_vec (void) { return Array::fortran_vec (); } + T * fortran_vec () { return Array::fortran_vec (); } void print_info (std::ostream& os, const std::string& prefix) const { Array::print_info (os, prefix); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/MArray.cc --- a/liboctave/array/MArray.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/MArray.cc Tue Jan 24 17:19:44 2023 -0800 @@ -213,7 +213,7 @@ // N-dimensional array with math ops. template void -MArray::changesign (void) +MArray::changesign () { if (Array::is_shared ()) *this = - *this; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/MArray.h --- a/liboctave/array/MArray.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/MArray.h Tue Jan 24 17:19:44 2023 -0800 @@ -63,7 +63,7 @@ { public: - MArray (void) : Array () { } + MArray () : Array () { } explicit MArray (const dim_vector& dv) : Array (dv) { } @@ -76,7 +76,7 @@ template MArray (const Array& a) : Array (a) { } - ~MArray (void) = default; + ~MArray () = default; MArray& operator = (const MArray& a) { @@ -94,9 +94,9 @@ MArray ipermute (const Array& vec) const { return Array::ipermute (vec); } - MArray squeeze (void) const { return Array::squeeze (); } + MArray squeeze () const { return Array::squeeze (); } - MArray transpose (void) const + MArray transpose () const { return Array::transpose (); } MArray hermitian (T (*fcn) (const T&) = nullptr) const @@ -119,7 +119,7 @@ idx_add_nd (const octave::idx_vector& idx, const MArray& vals, int dim = -1); - OCTARRAY_API void changesign (void); + OCTARRAY_API void changesign (); private: OCTARRAY_API static void instantiation_guard (); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/MDiagArray2.h --- a/liboctave/array/MDiagArray2.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/MDiagArray2.h Tue Jan 24 17:19:44 2023 -0800 @@ -56,7 +56,7 @@ { public: - MDiagArray2 (void) : DiagArray2 () { } + MDiagArray2 () : DiagArray2 () { } MDiagArray2 (octave_idx_type r, octave_idx_type c) : DiagArray2 (r, c) { } @@ -75,7 +75,7 @@ MDiagArray2 (const Array& a, octave_idx_type r, octave_idx_type c) : DiagArray2 (a, r, c) { } - ~MDiagArray2 (void) = default; + ~MDiagArray2 () = default; MDiagArray2& operator = (const MDiagArray2& a) { @@ -88,7 +88,7 @@ return DiagArray2::array_value (); } - octave_idx_type nnz (void) const + octave_idx_type nnz () const { const T *d = this->data (); @@ -103,7 +103,7 @@ MArray diag (octave_idx_type k = 0) const { return DiagArray2::extract_diag (k); } - MDiagArray2 transpose (void) const { return DiagArray2::transpose (); } + MDiagArray2 transpose () const { return DiagArray2::transpose (); } MDiagArray2 hermitian (T (*fcn) (const T&) = nullptr) const { return DiagArray2::hermitian (fcn); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/MSparse.h --- a/liboctave/array/MSparse.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/MSparse.h Tue Jan 24 17:19:44 2023 -0800 @@ -46,7 +46,7 @@ { public: - MSparse (void) : Sparse () { } + MSparse () : Sparse () { } MSparse (octave_idx_type n, octave_idx_type m) : Sparse (n, m) { } @@ -75,7 +75,7 @@ MSparse (octave_idx_type r, octave_idx_type c, octave_idx_type num_nz) : Sparse (r, c, num_nz) { } - ~MSparse (void) = default; + ~MSparse () = default; MSparse& operator = (const MSparse& a) { @@ -95,9 +95,9 @@ return *this; } - MSparse transpose (void) const { return Sparse::transpose (); } + MSparse transpose () const { return Sparse::transpose (); } - MSparse squeeze (void) const { return Sparse::squeeze (); } + MSparse squeeze () const { return Sparse::squeeze (); } MSparse reshape (const dim_vector& new_dims) const { return Sparse::reshape (new_dims); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/MatrixType.cc --- a/liboctave/array/MatrixType.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/MatrixType.cc Tue Jan 24 17:19:44 2023 -0800 @@ -41,21 +41,21 @@ #include "oct-locbuf.h" static void -warn_cached (void) +warn_cached () { (*current_liboctave_warning_with_id_handler) ("Octave:matrix-type-info", "using cached matrix type"); } static void -warn_invalid (void) +warn_invalid () { (*current_liboctave_warning_with_id_handler) ("Octave:matrix-type-info", "invalid matrix type"); } static void -warn_calculating_sparse_type (void) +warn_calculating_sparse_type () { (*current_liboctave_warning_with_id_handler) ("Octave:matrix-type-info", "calculating sparse matrix type"); @@ -63,7 +63,7 @@ // FIXME: There is a large code duplication here -MatrixType::MatrixType (void) +MatrixType::MatrixType () : m_type (MatrixType::Unknown), m_sp_bandden (octave::sparse_params::get_bandden ()), m_bandden (0), m_upper_band (0), m_lower_band (0), @@ -613,7 +613,7 @@ warn_invalid (); } -MatrixType::~MatrixType (void) +MatrixType::~MatrixType () { if (m_nperm != 0) { @@ -900,7 +900,7 @@ } void -MatrixType::mark_as_symmetric (void) +MatrixType::mark_as_symmetric () { if (m_type == MatrixType::Tridiagonal || m_type == MatrixType::Tridiagonal_Hermitian) @@ -917,7 +917,7 @@ } void -MatrixType::mark_as_unsymmetric (void) +MatrixType::mark_as_unsymmetric () { if (m_type == MatrixType::Tridiagonal || m_type == MatrixType::Tridiagonal_Hermitian) @@ -952,7 +952,7 @@ } void -MatrixType::mark_as_unpermuted (void) +MatrixType::mark_as_unpermuted () { if (m_nperm) { @@ -970,7 +970,7 @@ } MatrixType -MatrixType::transpose (void) const +MatrixType::transpose () const { MatrixType retval (*this); if (m_type == MatrixType::Upper) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/MatrixType.h --- a/liboctave/array/MatrixType.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/MatrixType.h Tue Jan 24 17:19:44 2023 -0800 @@ -54,7 +54,7 @@ Rectangular }; - OCTAVE_API MatrixType (void); + OCTAVE_API MatrixType (); OCTAVE_API MatrixType (const MatrixType& a); @@ -78,7 +78,7 @@ OCTAVE_API MatrixType (const matrix_type t, const octave_idx_type ku, const octave_idx_type kl, bool _full = false); - OCTAVE_API ~MatrixType (void); + OCTAVE_API ~MatrixType (); OCTAVE_API MatrixType& operator = (const MatrixType& a); @@ -96,77 +96,77 @@ OCTAVE_API int type (const SparseComplexMatrix& a); - double band_density (void) const { return m_bandden; } + double band_density () const { return m_bandden; } - int nupper (void) const { return m_upper_band; } + int nupper () const { return m_upper_band; } - int nlower (void) const { return m_lower_band; } + int nlower () const { return m_lower_band; } - bool is_dense (void) const { return m_dense; } + bool is_dense () const { return m_dense; } - bool isdiag (void) const + bool isdiag () const { return (m_type == Diagonal || m_type == Permuted_Diagonal); } - bool istriu (void) const + bool istriu () const { return (m_type == Upper || m_type == Permuted_Upper); } - bool istril (void) const + bool istril () const { return (m_type == Lower || m_type == Permuted_Lower); } - bool isbanded (void) const + bool isbanded () const { return (m_type == Banded || m_type == Banded_Hermitian); } - bool is_tridiagonal (void) const + bool is_tridiagonal () const { return (m_type == Tridiagonal || m_type == Tridiagonal_Hermitian); } - bool ishermitian (void) const + bool ishermitian () const { return (m_type == Banded_Hermitian || m_type == Tridiagonal_Hermitian || m_type == Hermitian); } - bool is_rectangular (void) const { return (m_type == Rectangular); } + bool is_rectangular () const { return (m_type == Rectangular); } - bool is_known (void) const { return (m_type != Unknown); } + bool is_known () const { return (m_type != Unknown); } - bool is_unknown (void) const { return (m_type == Unknown); } + bool is_unknown () const { return (m_type == Unknown); } - OCTAVE_API void info (void) const; + OCTAVE_API void info () const; - octave_idx_type * triangular_perm (void) const { return m_perm; } + octave_idx_type * triangular_perm () const { return m_perm; } - void invalidate_type (void) { m_type = Unknown; } + void invalidate_type () { m_type = Unknown; } - void mark_as_diagonal (void) { m_type = Diagonal; } + void mark_as_diagonal () { m_type = Diagonal; } - void mark_as_permuted_diagonal (void) { m_type = Permuted_Diagonal; } + void mark_as_permuted_diagonal () { m_type = Permuted_Diagonal; } - void mark_as_upper_triangular (void) { m_type = Upper; } + void mark_as_upper_triangular () { m_type = Upper; } - void mark_as_lower_triangular (void) { m_type = Lower; } + void mark_as_lower_triangular () { m_type = Lower; } - void mark_as_tridiagonal (void) {m_type = Tridiagonal; } + void mark_as_tridiagonal () {m_type = Tridiagonal; } void mark_as_banded (const octave_idx_type ku, const octave_idx_type kl) { m_type = Banded; m_upper_band = ku; m_lower_band = kl; } - void mark_as_full (void) { m_type = Full; } + void mark_as_full () { m_type = Full; } - void mark_as_rectangular (void) { m_type = Rectangular; } + void mark_as_rectangular () { m_type = Rectangular; } - void mark_as_dense (void) { m_dense = true; } + void mark_as_dense () { m_dense = true; } - void mark_as_not_dense (void) { m_dense = false; } + void mark_as_not_dense () { m_dense = false; } - OCTAVE_API void mark_as_symmetric (void); + OCTAVE_API void mark_as_symmetric (); - OCTAVE_API void mark_as_unsymmetric (void); + OCTAVE_API void mark_as_unsymmetric (); OCTAVE_API void mark_as_permuted (const octave_idx_type np, const octave_idx_type *p); - OCTAVE_API void mark_as_unpermuted (void); + OCTAVE_API void mark_as_unpermuted (); - OCTAVE_API MatrixType transpose (void) const; + OCTAVE_API MatrixType transpose () const; private: void type (int new_typ) { m_type = static_cast (new_typ); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/PermMatrix.cc --- a/liboctave/array/PermMatrix.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/PermMatrix.cc Tue Jan 24 17:19:44 2023 -0800 @@ -34,7 +34,7 @@ OCTAVE_NORETURN static void -err_invalid_permutation (void) +err_invalid_permutation () { (*current_liboctave_error_handler) ("PermMatrix: invalid permutation vector"); } @@ -98,7 +98,7 @@ } PermMatrix -PermMatrix::transpose (void) const +PermMatrix::transpose () const { octave_idx_type len = Array::numel (); @@ -111,13 +111,13 @@ } PermMatrix -PermMatrix::inverse (void) const +PermMatrix::inverse () const { return transpose (); } octave_idx_type -PermMatrix::determinant (void) const +PermMatrix::determinant () const { // Determine the sign of a permutation in linear time. // Is this widely known? diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/PermMatrix.h --- a/liboctave/array/PermMatrix.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/PermMatrix.h Tue Jan 24 17:19:44 2023 -0800 @@ -38,13 +38,13 @@ { public: - PermMatrix (void) = default; + PermMatrix () = default; PermMatrix (const PermMatrix& m) = default; PermMatrix& operator = (const PermMatrix& m) = default; - ~PermMatrix (void) = default; + ~PermMatrix () = default; OCTAVE_API PermMatrix (octave_idx_type n); @@ -54,33 +54,33 @@ OCTAVE_API PermMatrix (const octave::idx_vector& idx, bool colp, octave_idx_type n = 0); - octave_idx_type dim1 (void) const + octave_idx_type dim1 () const { return Array::numel (); } - octave_idx_type dim2 (void) const + octave_idx_type dim2 () const { return Array::numel (); } - octave_idx_type rows (void) const { return dim1 (); } - octave_idx_type cols (void) const { return dim2 (); } - octave_idx_type columns (void) const { return dim2 (); } + octave_idx_type rows () const { return dim1 (); } + octave_idx_type cols () const { return dim2 (); } + octave_idx_type columns () const { return dim2 (); } - octave_idx_type perm_length (void) const + octave_idx_type perm_length () const { return Array::numel (); } // FIXME: a dangerous ambiguity? - octave_idx_type length (void) const + octave_idx_type length () const { return perm_length (); } - octave_idx_type numel (void) const { return dim1 () * dim2 (); } + octave_idx_type numel () const { return dim1 () * dim2 (); } - std::size_t byte_size (void) const + std::size_t byte_size () const { return Array::byte_size (); } - dim_vector dims (void) const { return dim_vector (dim1 (), dim2 ()); } + dim_vector dims () const { return dim_vector (dim1 (), dim2 ()); } - bool isempty (void) const { return numel () == 0; } + bool isempty () const { return numel () == 0; } - int ndims (void) const { return 2; } + int ndims () const { return 2; } - const Array& col_perm_vec (void) const + const Array& col_perm_vec () const { return *this; } octave_idx_type @@ -99,17 +99,17 @@ } // These are, in fact, super-fast. - OCTAVE_API PermMatrix transpose (void) const; - OCTAVE_API PermMatrix inverse (void) const; + OCTAVE_API PermMatrix transpose () const; + OCTAVE_API PermMatrix inverse () const; // Determinant, i.e., the sign of permutation. - OCTAVE_API octave_idx_type determinant (void) const; + OCTAVE_API octave_idx_type determinant () const; // Efficient integer power of a permutation. OCTAVE_API PermMatrix power (octave_idx_type n) const; - bool is_col_perm (void) const { return true; } - bool is_row_perm (void) const { return false; } + bool is_col_perm () const { return true; } + bool is_row_perm () const { return false; } void print_info (std::ostream& os, const std::string& prefix) const { Array::print_info (os, prefix); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/Range.cc --- a/liboctave/array/Range.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/Range.cc Tue Jan 24 17:19:44 2023 -0800 @@ -302,28 +302,28 @@ template <> bool -range::all_elements_are_ints (void) const +range::all_elements_are_ints () const { return xall_elements_are_ints (m_base, m_increment, m_final, m_numel); } template <> bool -range::all_elements_are_ints (void) const +range::all_elements_are_ints () const { return xall_elements_are_ints (m_base, m_increment, m_final, m_numel); } template <> void -range::init (void) +range::init () { xinit (m_base, m_limit, m_increment, m_reverse, m_final, m_numel); } template <> void -range::init (void) +range::init () { xinit (m_base, m_limit, m_increment, m_reverse, m_final, m_numel); } @@ -334,56 +334,56 @@ template <> void -range::init (void) +range::init () { xinit (m_base, m_limit, m_increment, m_reverse, m_final, m_numel); } template <> void -range::init (void) +range::init () { xinit (m_base, m_limit, m_increment, m_reverse, m_final, m_numel); } template <> void -range::init (void) +range::init () { xinit (m_base, m_limit, m_increment, m_reverse, m_final, m_numel); } template <> void -range::init (void) +range::init () { xinit (m_base, m_limit, m_increment, m_reverse, m_final, m_numel); } template <> void -range::init (void) +range::init () { xinit (m_base, m_limit, m_increment, m_reverse, m_final, m_numel); } template <> void -range::init (void) +range::init () { xinit (m_base, m_limit, m_increment, m_reverse, m_final, m_numel); } template <> void -range::init (void) +range::init () { xinit (m_base, m_limit, m_increment, m_reverse, m_final, m_numel); } template <> void -range::init (void) +range::init () { xinit (m_base, m_limit, m_increment, m_reverse, m_final, m_numel); } @@ -392,14 +392,14 @@ template <> bool -range::is_storable (void) const +range::is_storable () const { return xis_storable (m_base, m_limit, m_numel); } template <> bool -range::is_storable (void) const +range::is_storable () const { return xis_storable (m_base, m_limit, m_numel); } @@ -440,14 +440,14 @@ template <> octave_idx_type -range::nnz (void) const +range::nnz () const { return xnnz (m_base, m_limit, m_increment, m_final, m_numel); } template <> octave_idx_type -range::nnz (void) const +range::nnz () const { return xnnz (m_base, m_limit, m_increment, m_final, m_numel); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/Range.h --- a/liboctave/array/Range.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/Range.h Tue Jan 24 17:19:44 2023 -0800 @@ -50,7 +50,7 @@ { public: - range (void) + range () : m_base (0), m_increment (0), m_limit (0), m_final (0), m_numel (0), m_reverse (false) { } @@ -127,16 +127,16 @@ return *this; } - ~range (void) = default; + ~range () = default; - T base (void) const { return m_base; } - T increment (void) const { return m_increment; } - T limit (void) const { return m_limit; } - bool reverse (void) const { return m_reverse; } + T base () const { return m_base; } + T increment () const { return m_increment; } + T limit () const { return m_limit; } + bool reverse () const { return m_reverse; } - T final_value (void) const { return m_final; } + T final_value () const { return m_final; } - T min (void) const + T min () const { return (m_numel > 0 ? ((m_reverse ? m_increment > T (0) @@ -144,7 +144,7 @@ : T (0)); } - T max (void) const + T max () const { return (m_numel > 0 ? ((m_reverse ? m_increment < T (0) @@ -152,7 +152,7 @@ : T (0)); } - octave_idx_type numel (void) const { return m_numel; } + octave_idx_type numel () const { return m_numel; } // To support things like "for i = 1:Inf; ...; end" that are // required for Matlab compatibility, creation of a range object @@ -162,18 +162,18 @@ // us to easily distinguish ranges with an infinite number of // elements. There are specializations for double and float. - bool is_storable (void) const { return true; } + bool is_storable () const { return true; } - dim_vector dims (void) const { return dim_vector (1, m_numel); } + dim_vector dims () const { return dim_vector (1, m_numel); } - octave_idx_type rows (void) const { return 1; } + octave_idx_type rows () const { return 1; } - octave_idx_type cols (void) const { return numel (); } - octave_idx_type columns (void) const { return numel (); } + octave_idx_type cols () const { return numel (); } + octave_idx_type columns () const { return numel (); } - bool isempty (void) const { return numel () == 0; } + bool isempty () const { return numel () == 0; } - bool all_elements_are_ints (void) const { return true; } + bool all_elements_are_ints () const { return true; } sortmode issorted (sortmode mode = ASCENDING) const { @@ -189,7 +189,7 @@ return mode; } - OCTAVE_API octave_idx_type nnz (void) const; + OCTAVE_API octave_idx_type nnz () const; // Support for single-index subscripting, without generating matrix cache. @@ -294,7 +294,7 @@ return array_value ().diag (k); } - Array array_value (void) const + Array array_value () const { octave_idx_type nel = numel (); @@ -338,7 +338,7 @@ // These calculations are appropriate for integer ranges. There are // specializations for double and float. - void init (void) + void init () { if (m_reverse) { @@ -365,11 +365,11 @@ // Specializations defined externally. - template <> OCTAVE_API bool range::all_elements_are_ints (void) const; - template <> OCTAVE_API bool range::all_elements_are_ints (void) const; + template <> OCTAVE_API bool range::all_elements_are_ints () const; + template <> OCTAVE_API bool range::all_elements_are_ints () const; - template <> OCTAVE_API void range::init (void); - template <> OCTAVE_API void range::init (void); + template <> OCTAVE_API void range::init (); + template <> OCTAVE_API void range::init (); // For now, only define for floating point types. However, we only // need range as a temporary local variable in make_float_range @@ -377,22 +377,22 @@ #if 0 - template <> OCTAVE_API void range::init (void); - template <> OCTAVE_API void range::init (void); - template <> OCTAVE_API void range::init (void); - template <> OCTAVE_API void range::init (void); - template <> OCTAVE_API void range::init (void); - template <> OCTAVE_API void range::init (void); - template <> OCTAVE_API void range::init (void); - template <> OCTAVE_API void range::init (void); + template <> OCTAVE_API void range::init (); + template <> OCTAVE_API void range::init (); + template <> OCTAVE_API void range::init (); + template <> OCTAVE_API void range::init (); + template <> OCTAVE_API void range::init (); + template <> OCTAVE_API void range::init (); + template <> OCTAVE_API void range::init (); + template <> OCTAVE_API void range::init (); #endif - template <> OCTAVE_API bool range::is_storable (void) const; - template <> OCTAVE_API bool range::is_storable (void) const; + template <> OCTAVE_API bool range::is_storable () const; + template <> OCTAVE_API bool range::is_storable () const; - template <> OCTAVE_API octave_idx_type range::nnz (void) const; - template <> OCTAVE_API octave_idx_type range::nnz (void) const; + template <> OCTAVE_API octave_idx_type range::nnz () const; + template <> OCTAVE_API octave_idx_type range::nnz () const; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/Sparse-b.cc --- a/liboctave/array/Sparse-b.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/Sparse-b.cc Tue Jan 24 17:19:44 2023 -0800 @@ -36,7 +36,7 @@ template <> OCTAVE_API bool -Sparse::SparseRep::any_element_is_nan (void) const +Sparse::SparseRep::any_element_is_nan () const { return false; } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/Sparse.cc --- a/liboctave/array/Sparse.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/Sparse.cc Tue Jan 24 17:19:44 2023 -0800 @@ -54,7 +54,7 @@ template OCTAVE_API typename Sparse::SparseRep * -Sparse::nil_rep (void) +Sparse::nil_rep () { static typename Sparse::SparseRep nr; return &nr; @@ -176,7 +176,7 @@ template OCTAVE_API bool -Sparse::SparseRep::indices_ok (void) const +Sparse::SparseRep::indices_ok () const { return sparse_indices_ok (m_ridx, m_cidx, m_nrows, m_ncols, nnz ()); } @@ -184,7 +184,7 @@ template OCTAVE_API bool -Sparse::SparseRep::any_element_is_nan (void) const +Sparse::SparseRep::any_element_is_nan () const { octave_idx_type nz = nnz (); @@ -705,7 +705,7 @@ template OCTAVE_API -Sparse::~Sparse (void) +Sparse::~Sparse () { if (--m_rep->m_count == 0) delete m_rep; @@ -1135,7 +1135,7 @@ template OCTAVE_API Sparse -Sparse::transpose (void) const +Sparse::transpose () const { assert (ndims () == 2); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/Sparse.h --- a/liboctave/array/Sparse.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/Sparse.h Tue Jan 24 17:19:44 2023 -0800 @@ -76,7 +76,7 @@ octave_idx_type m_ncols; octave::refcount m_count; - SparseRep (void) + SparseRep () : Alloc (), m_data (T_allocate (1)), m_ridx (idx_type_allocate (1)), m_cidx (idx_type_allocate (1)), m_nzmax (1), m_nrows (0), m_ncols (0), m_count (1) @@ -141,19 +141,19 @@ std::copy_n (a.m_cidx, m_ncols + 1, m_cidx); } - ~SparseRep (void) + ~SparseRep () { T_deallocate (m_data, m_nzmax); idx_type_deallocate (m_ridx, m_nzmax); idx_type_deallocate (m_cidx, m_ncols + 1); } - octave_idx_type nzmax (void) const { return m_nzmax; } - octave_idx_type nnz (void) const { return m_cidx[m_ncols]; } + octave_idx_type nzmax () const { return m_nzmax; } + octave_idx_type nnz () const { return m_cidx[m_ncols]; } - octave_idx_type rows (void) const { return m_nrows; } - octave_idx_type cols (void) const { return m_ncols; } - octave_idx_type columns (void) const { return m_ncols; } + octave_idx_type rows () const { return m_nrows; } + octave_idx_type cols () const { return m_ncols; } + octave_idx_type columns () const { return m_ncols; } OCTAVE_API T& elem (octave_idx_type r, octave_idx_type c); @@ -175,12 +175,12 @@ OCTAVE_API void change_length (octave_idx_type nz); - OCTAVE_API bool indices_ok (void) const; + OCTAVE_API bool indices_ok () const; - OCTAVE_API bool any_element_is_nan (void) const; + OCTAVE_API bool any_element_is_nan () const; // Prefer nzmax. - octave_idx_type length (void) const { return m_nzmax; } + octave_idx_type length () const { return m_nzmax; } template friend class Sparse; @@ -231,7 +231,7 @@ //-------------------------------------------------------------------- - void make_unique (void) + void make_unique () { if (m_rep->m_count > 1) { @@ -252,11 +252,11 @@ private: - static OCTAVE_API typename Sparse::SparseRep * nil_rep (void); + static OCTAVE_API typename Sparse::SparseRep * nil_rep (); public: - Sparse (void) + Sparse () : m_rep (nil_rep ()), m_dimensions (dim_vector (0, 0)) { m_rep->m_count++; @@ -327,30 +327,30 @@ // Sparsify a normal matrix OCTAVE_API Sparse (const Array& a); - virtual ~Sparse (void); + virtual ~Sparse (); OCTAVE_API Sparse& operator = (const Sparse& a); //! Amount of storage for nonzero elements. //! This may differ from the actual number of elements, see nnz(). - octave_idx_type nzmax (void) const { return m_rep->nzmax (); } + octave_idx_type nzmax () const { return m_rep->nzmax (); } //! Actual number of nonzero terms. - octave_idx_type nnz (void) const { return m_rep->nnz (); } + octave_idx_type nnz () const { return m_rep->nnz (); } // Querying the number of elements (incl. zeros) may overflow the index type, // so don't do it unless you really need it. - octave_idx_type numel (void) const + octave_idx_type numel () const { return m_dimensions.safe_numel (); } - octave_idx_type dim1 (void) const { return m_dimensions(0); } - octave_idx_type dim2 (void) const { return m_dimensions(1); } + octave_idx_type dim1 () const { return m_dimensions(0); } + octave_idx_type dim2 () const { return m_dimensions(1); } - octave_idx_type rows (void) const { return dim1 (); } - octave_idx_type cols (void) const { return dim2 (); } - octave_idx_type columns (void) const { return dim2 (); } + octave_idx_type rows () const { return dim1 (); } + octave_idx_type cols () const { return dim2 (); } + octave_idx_type columns () const { return dim2 (); } octave_idx_type get_row_index (octave_idx_type k) { return ridx (k); } octave_idx_type get_col_index (octave_idx_type k) @@ -361,16 +361,16 @@ return ret; } - std::size_t byte_size (void) const + std::size_t byte_size () const { return (static_cast (cols () + 1) * sizeof (octave_idx_type) + static_cast (nzmax ()) * (sizeof (T) + sizeof (octave_idx_type))); } - dim_vector dims (void) const { return m_dimensions; } + dim_vector dims () const { return m_dimensions; } - Sparse squeeze (void) const { return *this; } + Sparse squeeze () const { return *this; } OCTAVE_API octave_idx_type compute_index (const Array& ra_idx) const; @@ -565,48 +565,48 @@ OCTAVE_API Sparse& insert (const Sparse& a, const Array& idx); - bool issquare (void) const { return (dim1 () == dim2 ()); } + bool issquare () const { return (dim1 () == dim2 ()); } - bool isempty (void) const { return (rows () < 1 || cols () < 1); } + bool isempty () const { return (rows () < 1 || cols () < 1); } - OCTAVE_API Sparse transpose (void) const; + OCTAVE_API Sparse transpose () const; - T * data (void) { make_unique (); return m_rep->m_data; } + T * data () { make_unique (); return m_rep->m_data; } T& data (octave_idx_type i) { make_unique (); return m_rep->data (i); } - T * xdata (void) { return m_rep->m_data; } + T * xdata () { return m_rep->m_data; } T& xdata (octave_idx_type i) { return m_rep->data (i); } T data (octave_idx_type i) const { return m_rep->data (i); } // FIXME: shouldn't this be returning const T*? - T * data (void) const { return m_rep->m_data; } + T * data () const { return m_rep->m_data; } - octave_idx_type * ridx (void) { make_unique (); return m_rep->m_ridx; } + octave_idx_type * ridx () { make_unique (); return m_rep->m_ridx; } octave_idx_type& ridx (octave_idx_type i) { make_unique (); return m_rep->ridx (i); } - octave_idx_type * xridx (void) { return m_rep->m_ridx; } + octave_idx_type * xridx () { return m_rep->m_ridx; } octave_idx_type& xridx (octave_idx_type i) { return m_rep->ridx (i); } octave_idx_type ridx (octave_idx_type i) const { return m_rep->cridx (i); } // FIXME: shouldn't this be returning const octave_idx_type*? - octave_idx_type * ridx (void) const { return m_rep->m_ridx; } + octave_idx_type * ridx () const { return m_rep->m_ridx; } - octave_idx_type * cidx (void) { make_unique (); return m_rep->m_cidx; } + octave_idx_type * cidx () { make_unique (); return m_rep->m_cidx; } octave_idx_type& cidx (octave_idx_type i) { make_unique (); return m_rep->cidx (i); } - octave_idx_type * xcidx (void) { return m_rep->m_cidx; } + octave_idx_type * xcidx () { return m_rep->m_cidx; } octave_idx_type& xcidx (octave_idx_type i) { return m_rep->cidx (i); } octave_idx_type cidx (octave_idx_type i) const { return m_rep->ccidx (i); } // FIXME: shouldn't this be returning const octave_idx_type*? - octave_idx_type * cidx (void) const { return m_rep->m_cidx; } + octave_idx_type * cidx () const { return m_rep->m_cidx; } - octave_idx_type ndims (void) const { return m_dimensions.ndims (); } + octave_idx_type ndims () const { return m_dimensions.ndims (); } OCTAVE_API void delete_elements (const octave::idx_vector& i); @@ -649,7 +649,7 @@ static OCTAVE_API Sparse cat (int dim, octave_idx_type n, const Sparse *sparse_list); - OCTAVE_API Array array_value (void) const; + OCTAVE_API Array array_value () const; // Generic any/all test functionality with arbitrary predicate. template @@ -746,9 +746,9 @@ map (U (&fcn) (const T&)) const { return map (fcn); } - bool indices_ok (void) const { return m_rep->indices_ok (); } + bool indices_ok () const { return m_rep->indices_ok (); } - bool any_element_is_nan (void) const + bool any_element_is_nan () const { return m_rep->any_element_is_nan (); } }; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/boolMatrix.cc --- a/liboctave/array/boolMatrix.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/boolMatrix.cc Tue Jan 24 17:19:44 2023 -0800 @@ -63,7 +63,7 @@ // unary operations boolMatrix -boolMatrix::operator ! (void) const +boolMatrix::operator ! () const { octave_idx_type nr = rows (); octave_idx_type nc = cols (); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/boolMatrix.h --- a/liboctave/array/boolMatrix.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/boolMatrix.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,13 +39,13 @@ { public: - boolMatrix (void) = default; + boolMatrix () = default; boolMatrix (const boolMatrix& a) = default; boolMatrix& operator = (const boolMatrix& a) = default; - ~boolMatrix (void) = default; + ~boolMatrix () = default; boolMatrix (octave_idx_type r, octave_idx_type c) : boolNDArray (dim_vector (r, c)) { } @@ -63,7 +63,7 @@ OCTAVE_API bool operator == (const boolMatrix& a) const; OCTAVE_API bool operator != (const boolMatrix& a) const; - boolMatrix transpose (void) const { return Array::transpose (); } + boolMatrix transpose () const { return Array::transpose (); } // destructive insert/delete/reorder operations @@ -72,7 +72,7 @@ // unary operations - OCTAVE_API boolMatrix operator ! (void) const; + OCTAVE_API boolMatrix operator ! () const; // other operations diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/boolNDArray.cc --- a/liboctave/array/boolNDArray.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/boolNDArray.cc Tue Jan 24 17:19:44 2023 -0800 @@ -39,13 +39,13 @@ // unary operations boolNDArray -boolNDArray::operator ! (void) const +boolNDArray::operator ! () const { return do_mx_unary_op (*this, mx_inline_not); } boolNDArray& -boolNDArray::invert (void) +boolNDArray::invert () { if (is_shared ()) *this = ! *this; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/boolNDArray.h --- a/liboctave/array/boolNDArray.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/boolNDArray.h Tue Jan 24 17:19:44 2023 -0800 @@ -41,7 +41,7 @@ typedef boolMatrix matrix_type; - boolNDArray (void) : Array () { } + boolNDArray () : Array () { } boolNDArray (const dim_vector& dv) : Array (dv) { } @@ -60,11 +60,11 @@ // unary operations - OCTAVE_API boolNDArray operator ! (void) const; + OCTAVE_API boolNDArray operator ! () const; - OCTAVE_API boolNDArray& invert (void); + OCTAVE_API boolNDArray& invert (); - bool any_element_is_nan (void) const { return false; } + bool any_element_is_nan () const { return false; } // FIXME: this is not quite the right thing. @@ -79,7 +79,7 @@ OCTAVE_API boolNDArray& insert (const boolNDArray& a, const Array& ra_idx); - boolNDArray squeeze (void) const { return Array::squeeze (); } + boolNDArray squeeze () const { return Array::squeeze (); } static OCTAVE_API void increment_index (Array& ra_idx, @@ -94,7 +94,7 @@ // friend std::ostream& operator << (std::ostream& os, const NDArray& a); // friend std::istream& operator >> (std::istream& is, NDArray& a); - // bool all_elements_are_real (void) const; + // bool all_elements_are_real () const; // bool all_integers (double& max_val, double& min_val) const; OCTAVE_API boolNDArray diag (octave_idx_type k = 0) const; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/boolSparse.cc --- a/liboctave/array/boolSparse.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/boolSparse.cc Tue Jan 24 17:19:44 2023 -0800 @@ -102,7 +102,7 @@ // unary operations SparseBoolMatrix -SparseBoolMatrix::operator ! (void) const +SparseBoolMatrix::operator ! () const { octave_idx_type nr = rows (); octave_idx_type nc = cols (); @@ -245,7 +245,7 @@ } boolMatrix -SparseBoolMatrix::matrix_value (void) const +SparseBoolMatrix::matrix_value () const { octave_idx_type nr = rows (); octave_idx_type nc = cols (); @@ -284,7 +284,7 @@ } SparseBoolMatrix -SparseBoolMatrix::squeeze (void) const +SparseBoolMatrix::squeeze () const { return Sparse::squeeze (); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/boolSparse.h --- a/liboctave/array/boolSparse.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/boolSparse.h Tue Jan 24 17:19:44 2023 -0800 @@ -44,7 +44,7 @@ // Corresponding dense matrix type for this sparse matrix type. typedef boolMatrix dense_matrix_type; - SparseBoolMatrix (void) : Sparse () { } + SparseBoolMatrix () : Sparse () { } SparseBoolMatrix (octave_idx_type r, octave_idx_type c) : Sparse (r, c) { } @@ -86,7 +86,7 @@ OCTAVE_API bool operator == (const SparseBoolMatrix& a) const; OCTAVE_API bool operator != (const SparseBoolMatrix& a) const; - SparseBoolMatrix transpose (void) const + SparseBoolMatrix transpose () const { return Sparse::transpose (); } // destructive insert/delete/reorder operations @@ -102,9 +102,9 @@ OCTAVE_API SparseBoolMatrix diag (octave_idx_type k = 0) const; - OCTAVE_API boolMatrix matrix_value (void) const; + OCTAVE_API boolMatrix matrix_value () const; - OCTAVE_API SparseBoolMatrix squeeze (void) const; + OCTAVE_API SparseBoolMatrix squeeze () const; OCTAVE_API SparseBoolMatrix index (const octave::idx_vector& i, bool resize_ok) const; @@ -123,7 +123,7 @@ // unary operations - OCTAVE_API SparseBoolMatrix operator ! (void) const; + OCTAVE_API SparseBoolMatrix operator ! () const; // other operations diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/chMatrix.h --- a/liboctave/array/chMatrix.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/chMatrix.h Tue Jan 24 17:19:44 2023 -0800 @@ -44,13 +44,13 @@ public: - charMatrix (void) = default; + charMatrix () = default; charMatrix (const charMatrix& a) = default; charMatrix& operator = (const charMatrix& a) = default; - ~charMatrix (void) = default; + ~charMatrix () = default; charMatrix (octave_idx_type r, octave_idx_type c) : charNDArray (dim_vector (r, c)) { } @@ -77,7 +77,7 @@ OCTAVE_API bool operator == (const charMatrix& a) const; OCTAVE_API bool operator != (const charMatrix& a) const; - charMatrix transpose (void) const { return Array::transpose (); } + charMatrix transpose () const { return Array::transpose (); } // destructive insert/delete/reorder operations diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/chNDArray.h --- a/liboctave/array/chNDArray.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/chNDArray.h Tue Jan 24 17:19:44 2023 -0800 @@ -42,7 +42,7 @@ typedef charMatrix matrix_type; - charNDArray (void) : Array () { } + charNDArray () : Array () { } charNDArray (const dim_vector& dv) : Array (dv) { } @@ -66,7 +66,7 @@ return *this; } - bool any_element_is_nan (void) const { return false; } + bool any_element_is_nan () const { return false; } // FIXME: this is not quite the right thing. @@ -89,7 +89,7 @@ OCTAVE_API charNDArray& insert (const charNDArray& a, const Array& ra_idx); - charNDArray squeeze (void) const { return Array::squeeze (); } + charNDArray squeeze () const { return Array::squeeze (); } static OCTAVE_API void increment_index (Array& ra_idx, diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/dColVector.cc --- a/liboctave/array/dColVector.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/dColVector.cc Tue Jan 24 17:19:44 2023 -0800 @@ -122,13 +122,13 @@ } RowVector -ColumnVector::transpose (void) const +ColumnVector::transpose () const { return MArray::transpose (); } ColumnVector -ColumnVector::abs (void) const +ColumnVector::abs () const { return do_mx_unary_map (*this); } @@ -242,7 +242,7 @@ // other operations double -ColumnVector::min (void) const +ColumnVector::min () const { octave_idx_type len = numel (); if (len == 0) @@ -258,7 +258,7 @@ } double -ColumnVector::max (void) const +ColumnVector::max () const { octave_idx_type len = numel (); if (len == 0) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/dColVector.h --- a/liboctave/array/dColVector.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/dColVector.h Tue Jan 24 17:19:44 2023 -0800 @@ -37,7 +37,7 @@ { public: - ColumnVector (void) : MArray (dim_vector (0, 1)) { } + ColumnVector () : MArray (dim_vector (0, 1)) { } explicit ColumnVector (octave_idx_type n) : MArray (dim_vector (n, 1)) { } @@ -72,7 +72,7 @@ OCTAVE_API ColumnVector stack (const ColumnVector& a) const; - OCTAVE_API RowVector transpose (void) const; + OCTAVE_API RowVector transpose () const; friend OCTAVE_API ColumnVector real (const ComplexColumnVector& a); friend OCTAVE_API ColumnVector imag (const ComplexColumnVector& a); @@ -97,10 +97,10 @@ // other operations - OCTAVE_API double min (void) const; - OCTAVE_API double max (void) const; + OCTAVE_API double min () const; + OCTAVE_API double max () const; - OCTAVE_API ColumnVector abs (void) const; + OCTAVE_API ColumnVector abs () const; // i/o diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/dDiagMatrix.cc --- a/liboctave/array/dDiagMatrix.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/dDiagMatrix.cc Tue Jan 24 17:19:44 2023 -0800 @@ -125,7 +125,7 @@ } DiagMatrix -DiagMatrix::abs (void) const +DiagMatrix::abs () const { return DiagMatrix (extract_diag ().abs (), rows (), columns ()); } @@ -224,7 +224,7 @@ } DiagMatrix -DiagMatrix::inverse (void) const +DiagMatrix::inverse () const { octave_idx_type info; return inverse (info); @@ -328,7 +328,7 @@ // other operations DET -DiagMatrix::determinant (void) const +DiagMatrix::determinant () const { DET det (1.0); if (rows () != cols ()) @@ -342,7 +342,7 @@ } double -DiagMatrix::rcond (void) const +DiagMatrix::rcond () const { ColumnVector av = extract_diag (0).map (fabs); double amx = av.max (); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/dDiagMatrix.h --- a/liboctave/array/dDiagMatrix.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/dDiagMatrix.h Tue Jan 24 17:19:44 2023 -0800 @@ -42,13 +42,13 @@ typedef Matrix full_matrix_type; - DiagMatrix (void) = default; + DiagMatrix () = default; DiagMatrix (const DiagMatrix& a) = default; DiagMatrix& operator = (const DiagMatrix& a) = default; - ~DiagMatrix (void) = default; + ~DiagMatrix () = default; DiagMatrix (octave_idx_type r, octave_idx_type c) : MDiagArray2 (r, c) { } @@ -77,9 +77,9 @@ OCTAVE_API DiagMatrix& fill (const ColumnVector& a, octave_idx_type beg); OCTAVE_API DiagMatrix& fill (const RowVector& a, octave_idx_type beg); - DiagMatrix transpose (void) const + DiagMatrix transpose () const { return MDiagArray2::transpose (); } - DiagMatrix abs (void) const; + DiagMatrix abs () const; friend OCTAVE_API DiagMatrix real (const ComplexDiagMatrix& a); friend OCTAVE_API DiagMatrix imag (const ComplexDiagMatrix& a); @@ -98,7 +98,7 @@ OCTAVE_API ColumnVector column (octave_idx_type i) const; OCTAVE_API ColumnVector column (char *s) const; - OCTAVE_API DiagMatrix inverse (void) const; + OCTAVE_API DiagMatrix inverse () const; OCTAVE_API DiagMatrix inverse (octave_idx_type& info) const; OCTAVE_API DiagMatrix pseudo_inverse (double tol = 0.0) const; @@ -107,8 +107,8 @@ ColumnVector extract_diag (octave_idx_type k = 0) const { return MDiagArray2::extract_diag (k); } - OCTAVE_API DET determinant (void) const; - OCTAVE_API double rcond (void) const; + OCTAVE_API DET determinant () const; + OCTAVE_API double rcond () const; // i/o diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/dMatrix.cc --- a/liboctave/array/dMatrix.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/dMatrix.cc Tue Jan 24 17:19:44 2023 -0800 @@ -133,7 +133,7 @@ } bool -Matrix::issymmetric (void) const +Matrix::issymmetric () const { if (issquare () && rows () > 0) { @@ -448,7 +448,7 @@ } Matrix -Matrix::inverse (void) const +Matrix::inverse () const { octave_idx_type info; double rcon; @@ -731,7 +731,7 @@ #if defined (HAVE_FFTW) ComplexMatrix -Matrix::fourier (void) const +Matrix::fourier () const { std::size_t nr = rows (); std::size_t nc = cols (); @@ -760,7 +760,7 @@ } ComplexMatrix -Matrix::ifourier (void) const +Matrix::ifourier () const { std::size_t nr = rows (); std::size_t nc = cols (); @@ -790,7 +790,7 @@ } ComplexMatrix -Matrix::fourier2d (void) const +Matrix::fourier2d () const { dim_vector dv (rows (), cols ()); @@ -802,7 +802,7 @@ } ComplexMatrix -Matrix::ifourier2d (void) const +Matrix::ifourier2d () const { dim_vector dv (rows (), cols ()); @@ -817,7 +817,7 @@ #else ComplexMatrix -Matrix::fourier (void) const +Matrix::fourier () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -826,7 +826,7 @@ } ComplexMatrix -Matrix::ifourier (void) const +Matrix::ifourier () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -835,7 +835,7 @@ } ComplexMatrix -Matrix::fourier2d (void) const +Matrix::fourier2d () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -844,7 +844,7 @@ } ComplexMatrix -Matrix::ifourier2d (void) const +Matrix::ifourier2d () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -855,7 +855,7 @@ #endif DET -Matrix::determinant (void) const +Matrix::determinant () const { octave_idx_type info; double rcon; @@ -1026,7 +1026,7 @@ } double -Matrix::rcond (void) const +Matrix::rcond () const { MatrixType mattype (*this); return rcond (mattype); @@ -2398,7 +2398,7 @@ } Matrix -Matrix::abs (void) const +Matrix::abs () const { return NDArray::abs (); } @@ -2426,7 +2426,7 @@ } ColumnVector -Matrix::row_min (void) const +Matrix::row_min () const { Array dummy_idx; return row_min (dummy_idx); @@ -2481,7 +2481,7 @@ } ColumnVector -Matrix::row_max (void) const +Matrix::row_max () const { Array dummy_idx; return row_max (dummy_idx); @@ -2536,7 +2536,7 @@ } RowVector -Matrix::column_min (void) const +Matrix::column_min () const { Array dummy_idx; return column_min (dummy_idx); @@ -2591,7 +2591,7 @@ } RowVector -Matrix::column_max (void) const +Matrix::column_max () const { Array dummy_idx; return column_max (dummy_idx); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/dMatrix.h --- a/liboctave/array/dMatrix.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/dMatrix.h Tue Jan 24 17:19:44 2023 -0800 @@ -59,13 +59,13 @@ typedef void (*solve_singularity_handler) (double rcon); - Matrix (void) = default; + Matrix () = default; Matrix (const Matrix& a) = default; Matrix& operator = (const Matrix& a) = default; - ~Matrix (void) = default; + ~Matrix () = default; Matrix (octave_idx_type r, octave_idx_type c) : NDArray (dim_vector (r, c)) { } @@ -103,7 +103,7 @@ OCTAVE_API bool operator == (const Matrix& a) const; OCTAVE_API bool operator != (const Matrix& a) const; - OCTAVE_API bool issymmetric (void) const; + OCTAVE_API bool issymmetric () const; // destructive insert/delete/reorder operations @@ -136,8 +136,8 @@ friend class ComplexMatrix; - Matrix hermitian (void) const { return MArray::transpose (); } - Matrix transpose (void) const { return MArray::transpose (); } + Matrix hermitian () const { return MArray::transpose (); } + Matrix transpose () const { return MArray::transpose (); } // resize is the destructive equivalent for this one @@ -168,7 +168,7 @@ bool force, bool calc_cond) const; public: - OCTAVE_API Matrix inverse (void) const; + OCTAVE_API Matrix inverse () const; OCTAVE_API Matrix inverse (octave_idx_type& info) const; OCTAVE_API Matrix inverse (octave_idx_type& info, double& rcon, bool force = false, @@ -182,13 +182,13 @@ OCTAVE_API Matrix pseudo_inverse (double tol = 0.0) const; - OCTAVE_API ComplexMatrix fourier (void) const; - OCTAVE_API ComplexMatrix ifourier (void) const; + OCTAVE_API ComplexMatrix fourier () const; + OCTAVE_API ComplexMatrix ifourier () const; - OCTAVE_API ComplexMatrix fourier2d (void) const; - OCTAVE_API ComplexMatrix ifourier2d (void) const; + OCTAVE_API ComplexMatrix fourier2d () const; + OCTAVE_API ComplexMatrix ifourier2d () const; - OCTAVE_API DET determinant (void) const; + OCTAVE_API DET determinant () const; OCTAVE_API DET determinant (octave_idx_type& info) const; OCTAVE_API DET determinant (octave_idx_type& info, double& rcon, @@ -197,7 +197,7 @@ determinant (MatrixType& mattype, octave_idx_type& info, double& rcon, bool calc_cond = true) const; - OCTAVE_API double rcond (void) const; + OCTAVE_API double rcond () const; OCTAVE_API double rcond (MatrixType& mattype) const; private: @@ -371,20 +371,20 @@ OCTAVE_API Matrix prod (int dim = -1) const; OCTAVE_API Matrix sum (int dim = -1) const; OCTAVE_API Matrix sumsq (int dim = -1) const; - OCTAVE_API Matrix abs (void) const; + OCTAVE_API Matrix abs () const; OCTAVE_API Matrix diag (octave_idx_type k = 0) const; OCTAVE_API DiagMatrix diag (octave_idx_type m, octave_idx_type n) const; - OCTAVE_API ColumnVector row_min (void) const; - OCTAVE_API ColumnVector row_max (void) const; + OCTAVE_API ColumnVector row_min () const; + OCTAVE_API ColumnVector row_max () const; OCTAVE_API ColumnVector row_min (Array& index) const; OCTAVE_API ColumnVector row_max (Array& index) const; - OCTAVE_API RowVector column_min (void) const; - OCTAVE_API RowVector column_max (void) const; + OCTAVE_API RowVector column_min () const; + OCTAVE_API RowVector column_max () const; OCTAVE_API RowVector column_min (Array& index) const; OCTAVE_API RowVector column_max (Array& index) const; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/dNDArray.cc --- a/liboctave/array/dNDArray.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/dNDArray.cc Tue Jan 24 17:19:44 2023 -0800 @@ -158,7 +158,7 @@ } ComplexNDArray -NDArray::fourier2d (void) const +NDArray::fourier2d () const { dim_vector dv = dims (); if (dv.ndims () < 2) @@ -178,7 +178,7 @@ } ComplexNDArray -NDArray::ifourier2d (void) const +NDArray::ifourier2d () const { dim_vector dv = dims (); if (dv.ndims () < 2) @@ -197,7 +197,7 @@ } ComplexNDArray -NDArray::fourierNd (void) const +NDArray::fourierNd () const { dim_vector dv = dims (); int rank = dv.ndims (); @@ -212,7 +212,7 @@ } ComplexNDArray -NDArray::ifourierNd (void) const +NDArray::ifourierNd () const { dim_vector dv = dims (); int rank = dv.ndims (); @@ -252,7 +252,7 @@ } ComplexNDArray -NDArray::fourier2d (void) const +NDArray::fourier2d () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -261,7 +261,7 @@ } ComplexNDArray -NDArray::ifourier2d (void) const +NDArray::ifourier2d () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -270,7 +270,7 @@ } ComplexNDArray -NDArray::fourierNd (void) const +NDArray::fourierNd () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -279,7 +279,7 @@ } ComplexNDArray -NDArray::ifourierNd (void) const +NDArray::ifourierNd () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -292,7 +292,7 @@ // unary operations boolNDArray -NDArray::operator ! (void) const +NDArray::operator ! () const { if (any_element_is_nan ()) octave::err_nan_to_logical_conversion (); @@ -315,31 +315,31 @@ } bool -NDArray::any_element_is_nan (void) const +NDArray::any_element_is_nan () const { return do_mx_check (*this, mx_inline_any_nan); } bool -NDArray::any_element_is_inf_or_nan (void) const +NDArray::any_element_is_inf_or_nan () const { return ! do_mx_check (*this, mx_inline_all_finite); } bool -NDArray::any_element_not_one_or_zero (void) const +NDArray::any_element_not_one_or_zero () const { return ! test_all (octave::is_one_or_zero); } bool -NDArray::all_elements_are_zero (void) const +NDArray::all_elements_are_zero () const { return test_all (octave::is_zero); } bool -NDArray::all_elements_are_int_or_inf_or_nan (void) const +NDArray::all_elements_are_int_or_inf_or_nan () const { return test_all (octave::is_int_or_inf_or_nan); } @@ -378,13 +378,13 @@ } bool -NDArray::all_integers (void) const +NDArray::all_integers () const { return test_all (octave::math::isinteger); } bool -NDArray::too_large_for_float (void) const +NDArray::too_large_for_float () const { return test_any (octave::too_large_for_float); } @@ -567,25 +567,25 @@ } NDArray -NDArray::abs (void) const +NDArray::abs () const { return do_mx_unary_map (*this); } boolNDArray -NDArray::isnan (void) const +NDArray::isnan () const { return do_mx_unary_map (*this); } boolNDArray -NDArray::isinf (void) const +NDArray::isinf () const { return do_mx_unary_map (*this); } boolNDArray -NDArray::isfinite (void) const +NDArray::isfinite () const { return do_mx_unary_map (*this); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/dNDArray.h --- a/liboctave/array/dNDArray.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/dNDArray.h Tue Jan 24 17:19:44 2023 -0800 @@ -40,7 +40,7 @@ { public: - NDArray (void) : MArray () { } + NDArray () : MArray () { } NDArray (const dim_vector& dv) : MArray (dv) { } @@ -71,18 +71,18 @@ // unary operations - OCTAVE_API boolNDArray operator ! (void) const; + OCTAVE_API boolNDArray operator ! () const; OCTAVE_API bool any_element_is_negative (bool = false) const; OCTAVE_API bool any_element_is_positive (bool = false) const; - OCTAVE_API bool any_element_is_nan (void) const; - OCTAVE_API bool any_element_is_inf_or_nan (void) const; - OCTAVE_API bool any_element_not_one_or_zero (void) const; - OCTAVE_API bool all_elements_are_zero (void) const; - OCTAVE_API bool all_elements_are_int_or_inf_or_nan (void) const; + OCTAVE_API bool any_element_is_nan () const; + OCTAVE_API bool any_element_is_inf_or_nan () const; + OCTAVE_API bool any_element_not_one_or_zero () const; + OCTAVE_API bool all_elements_are_zero () const; + OCTAVE_API bool all_elements_are_int_or_inf_or_nan () const; OCTAVE_API bool all_integers (double& max_val, double& min_val) const; - OCTAVE_API bool all_integers (void) const; - OCTAVE_API bool too_large_for_float (void) const; + OCTAVE_API bool all_integers () const; + OCTAVE_API bool too_large_for_float () const; // FIXME: this is not quite the right thing. @@ -121,26 +121,26 @@ OCTAVE_API NDArray& insert (const NDArray& a, const Array& ra_idx); - OCTAVE_API NDArray abs (void) const; - OCTAVE_API boolNDArray isnan (void) const; - OCTAVE_API boolNDArray isinf (void) const; - OCTAVE_API boolNDArray isfinite (void) const; + OCTAVE_API NDArray abs () const; + OCTAVE_API boolNDArray isnan () const; + OCTAVE_API boolNDArray isinf () const; + OCTAVE_API boolNDArray isfinite () const; OCTAVE_API ComplexNDArray fourier (int dim = 1) const; OCTAVE_API ComplexNDArray ifourier (int dim = 1) const; - OCTAVE_API ComplexNDArray fourier2d (void) const; - OCTAVE_API ComplexNDArray ifourier2d (void) const; + OCTAVE_API ComplexNDArray fourier2d () const; + OCTAVE_API ComplexNDArray ifourier2d () const; - OCTAVE_API ComplexNDArray fourierNd (void) const; - OCTAVE_API ComplexNDArray ifourierNd (void) const; + OCTAVE_API ComplexNDArray fourierNd () const; + OCTAVE_API ComplexNDArray ifourierNd () const; friend OCTAVE_API NDArray real (const ComplexNDArray& a); friend OCTAVE_API NDArray imag (const ComplexNDArray& a); friend class ComplexNDArray; - NDArray squeeze (void) const { return MArray::squeeze (); } + NDArray squeeze () const { return MArray::squeeze (); } static OCTAVE_API void increment_index (Array& ra_idx, @@ -159,7 +159,7 @@ OCTAVE_API NDArray diag (octave_idx_type m, octave_idx_type n) const; - NDArray& changesign (void) + NDArray& changesign () { MArray::changesign (); return *this; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/dRowVector.cc --- a/liboctave/array/dRowVector.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/dRowVector.cc Tue Jan 24 17:19:44 2023 -0800 @@ -123,7 +123,7 @@ } ColumnVector -RowVector::transpose (void) const +RowVector::transpose () const { return MArray::transpose (); } @@ -204,7 +204,7 @@ // other operations double -RowVector::min (void) const +RowVector::min () const { octave_idx_type len = numel (); if (len == 0) @@ -220,7 +220,7 @@ } double -RowVector::max (void) const +RowVector::max () const { octave_idx_type len = numel (); if (len == 0) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/dRowVector.h --- a/liboctave/array/dRowVector.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/dRowVector.h Tue Jan 24 17:19:44 2023 -0800 @@ -37,7 +37,7 @@ { public: - RowVector (void) : MArray (dim_vector (1, 0)) { } + RowVector () : MArray (dim_vector (1, 0)) { } explicit RowVector (octave_idx_type n) : MArray (dim_vector (1, n)) { } @@ -71,7 +71,7 @@ OCTAVE_API RowVector append (const RowVector& a) const; - OCTAVE_API ColumnVector transpose (void) const; + OCTAVE_API ColumnVector transpose () const; friend OCTAVE_API RowVector real (const ComplexRowVector& a); friend OCTAVE_API RowVector imag (const ComplexRowVector& a); @@ -88,8 +88,8 @@ // other operations - OCTAVE_API double min (void) const; - OCTAVE_API double max (void) const; + OCTAVE_API double min () const; + OCTAVE_API double max () const; // i/o diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/dSparse.cc --- a/liboctave/array/dSparse.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/dSparse.cc Tue Jan 24 17:19:44 2023 -0800 @@ -128,7 +128,7 @@ } bool -SparseMatrix::issymmetric (void) const +SparseMatrix::issymmetric () const { octave_idx_type nr = rows (); octave_idx_type nc = cols (); @@ -600,7 +600,7 @@ */ SparseMatrix -SparseMatrix::inverse (void) const +SparseMatrix::inverse () const { octave_idx_type info; double rcond; @@ -1009,7 +1009,7 @@ } DET -SparseMatrix::determinant (void) const +SparseMatrix::determinant () const { octave_idx_type info; double rcond; @@ -7216,7 +7216,7 @@ } bool -SparseMatrix::any_element_is_nan (void) const +SparseMatrix::any_element_is_nan () const { octave_idx_type nel = nnz (); @@ -7231,7 +7231,7 @@ } bool -SparseMatrix::any_element_is_inf_or_nan (void) const +SparseMatrix::any_element_is_inf_or_nan () const { octave_idx_type nel = nnz (); @@ -7246,7 +7246,7 @@ } bool -SparseMatrix::any_element_not_one_or_zero (void) const +SparseMatrix::any_element_not_one_or_zero () const { octave_idx_type nel = nnz (); @@ -7261,7 +7261,7 @@ } bool -SparseMatrix::all_elements_are_zero (void) const +SparseMatrix::all_elements_are_zero () const { octave_idx_type nel = nnz (); @@ -7273,7 +7273,7 @@ } bool -SparseMatrix::all_elements_are_int_or_inf_or_nan (void) const +SparseMatrix::all_elements_are_int_or_inf_or_nan () const { octave_idx_type nel = nnz (); @@ -7321,13 +7321,13 @@ } bool -SparseMatrix::too_large_for_float (void) const +SparseMatrix::too_large_for_float () const { return test_any (octave::too_large_for_float); } SparseBoolMatrix -SparseMatrix::operator ! (void) const +SparseMatrix::operator ! () const { if (any_element_is_nan ()) octave::err_nan_to_logical_conversion (); @@ -7423,7 +7423,7 @@ } SparseMatrix -SparseMatrix::abs (void) const +SparseMatrix::abs () const { octave_idx_type nz = nnz (); @@ -7442,7 +7442,7 @@ } Matrix -SparseMatrix::matrix_value (void) const +SparseMatrix::matrix_value () const { return Sparse::array_value (); } @@ -7477,7 +7477,7 @@ } SparseMatrix -SparseMatrix::squeeze (void) const +SparseMatrix::squeeze () const { return MSparse::squeeze (); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/dSparse.h --- a/liboctave/array/dSparse.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/dSparse.h Tue Jan 24 17:19:44 2023 -0800 @@ -50,7 +50,7 @@ typedef void (*solve_singularity_handler) (double rcond); - SparseMatrix (void) : MSparse () { } + SparseMatrix () : MSparse () { } SparseMatrix (octave_idx_type r, octave_idx_type c) : MSparse (r, c) { } @@ -98,7 +98,7 @@ OCTAVE_API bool operator == (const SparseMatrix& a) const; OCTAVE_API bool operator != (const SparseMatrix& a) const; - OCTAVE_API bool issymmetric (void) const; + OCTAVE_API bool issymmetric () const; OCTAVE_API SparseMatrix max (int dim = -1) const; OCTAVE_API SparseMatrix max (Array& index, int dim = -1) const; @@ -121,11 +121,11 @@ friend OCTAVE_API SparseMatrix real (const SparseComplexMatrix& a); friend OCTAVE_API SparseMatrix imag (const SparseComplexMatrix& a); - SparseMatrix transpose (void) const + SparseMatrix transpose () const { return MSparse::transpose (); } - SparseMatrix hermitian (void) const { return transpose (); } + SparseMatrix hermitian () const { return transpose (); } // extract row or column i. @@ -143,7 +143,7 @@ const bool force = false, const bool calccond = true) const; public: - OCTAVE_API SparseMatrix inverse (void) const; + OCTAVE_API SparseMatrix inverse () const; OCTAVE_API SparseMatrix inverse (MatrixType& mattype) const; OCTAVE_API SparseMatrix inverse (MatrixType& mattype, octave_idx_type& info) const; @@ -151,7 +151,7 @@ inverse (MatrixType& mattype, octave_idx_type& info, double& rcond, bool force = false, bool calc_cond = true) const; - OCTAVE_API DET determinant (void) const; + OCTAVE_API DET determinant () const; OCTAVE_API DET determinant (octave_idx_type& info) const; OCTAVE_API DET determinant (octave_idx_type& info, double& rcond, bool calc_cond = true) const; @@ -420,15 +420,15 @@ // other operations OCTAVE_API bool any_element_is_negative (bool = false) const; - OCTAVE_API bool any_element_is_nan (void) const; - OCTAVE_API bool any_element_is_inf_or_nan (void) const; - OCTAVE_API bool any_element_not_one_or_zero (void) const; - OCTAVE_API bool all_elements_are_zero (void) const; - OCTAVE_API bool all_elements_are_int_or_inf_or_nan (void) const; + OCTAVE_API bool any_element_is_nan () const; + OCTAVE_API bool any_element_is_inf_or_nan () const; + OCTAVE_API bool any_element_not_one_or_zero () const; + OCTAVE_API bool all_elements_are_zero () const; + OCTAVE_API bool all_elements_are_int_or_inf_or_nan () const; OCTAVE_API bool all_integers (double& max_val, double& min_val) const; - OCTAVE_API bool too_large_for_float (void) const; + OCTAVE_API bool too_large_for_float () const; - OCTAVE_API SparseBoolMatrix operator ! (void) const; + OCTAVE_API SparseBoolMatrix operator ! () const; OCTAVE_API SparseBoolMatrix all (int dim = -1) const; OCTAVE_API SparseBoolMatrix any (int dim = -1) const; @@ -438,13 +438,13 @@ OCTAVE_API SparseMatrix prod (int dim = -1) const; OCTAVE_API SparseMatrix sum (int dim = -1) const; OCTAVE_API SparseMatrix sumsq (int dim = -1) const; - OCTAVE_API SparseMatrix abs (void) const; + OCTAVE_API SparseMatrix abs () const; OCTAVE_API SparseMatrix diag (octave_idx_type k = 0) const; - OCTAVE_API Matrix matrix_value (void) const; + OCTAVE_API Matrix matrix_value () const; - OCTAVE_API SparseMatrix squeeze (void) const; + OCTAVE_API SparseMatrix squeeze () const; OCTAVE_API SparseMatrix reshape (const dim_vector& new_dims) const; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/dim-vector.cc --- a/liboctave/array/dim-vector.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/dim-vector.cc Tue Jan 24 17:19:44 2023 -0800 @@ -41,13 +41,13 @@ // Currently 1 is subtracted to allow safe conversion of any 2D Array into // Sparse, but this offset may change in the future. octave_idx_type -dim_vector::dim_max (void) +dim_vector::dim_max () { return std::numeric_limits::max () - 1; } void -dim_vector::chop_all_singletons (void) +dim_vector::chop_all_singletons () { int j = 0; int nd = ndims (); @@ -83,7 +83,7 @@ } int -dim_vector::num_ones (void) const +dim_vector::num_ones () const { int retval = 0; @@ -95,7 +95,7 @@ } octave_idx_type -dim_vector::safe_numel (void) const +dim_vector::safe_numel () const { octave_idx_type idx_max = dim_max (); octave_idx_type n = 1; @@ -114,7 +114,7 @@ } dim_vector -dim_vector::squeeze (void) const +dim_vector::squeeze () const { dim_vector new_dims = *this; new_dims.chop_all_singletons (); @@ -263,7 +263,7 @@ } Array -dim_vector::as_array (void) const +dim_vector::as_array () const { octave_idx_type nd = ndims (); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/dim-vector.h --- a/liboctave/array/dim-vector.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/dim-vector.h Tue Jan 24 17:19:44 2023 -0800 @@ -161,13 +161,13 @@ octave_idx_type elem (int i) const { return xelem (i); } - void chop_trailing_singletons (void) + void chop_trailing_singletons () { while (m_num_dims > 2 && xelem(m_num_dims-1) == 1) m_num_dims--; } - OCTAVE_API void chop_all_singletons (void); + OCTAVE_API void chop_all_singletons (); private: @@ -179,9 +179,9 @@ public: - static OCTAVE_API octave_idx_type dim_max (void); + static OCTAVE_API octave_idx_type dim_max (); - explicit dim_vector (void) + explicit dim_vector () : m_num_dims (2), m_dims (new octave_idx_type [m_num_dims]) { std::fill_n (m_dims, m_num_dims, 0); @@ -239,7 +239,7 @@ return *this; } - ~dim_vector (void) + ~dim_vector () { // Because we define a move constructor and a move assignment // operator, m_dims may be a nullptr here. We should only need to @@ -254,7 +254,7 @@ //! elements in the dim_vector including trailing singletons. It is also //! the number of dimensions an Array with this dim_vector would have. - octave_idx_type ndims (void) const { return m_num_dims; } + octave_idx_type ndims () const { return m_num_dims; } //! Number of dimensions. //! Synonymous with ndims(). @@ -263,7 +263,7 @@ //! instead to avoid confusion. Array does not have length because of its //! odd definition as length of the longest dimension. - int length (void) const { return ndims (); } + int length () const { return ndims (); } octave_idx_type& operator () (int i) { return elem (i); } @@ -297,31 +297,31 @@ OCTAVE_API std::string str (char sep = 'x') const; - bool all_zero (void) const + bool all_zero () const { return std::all_of (m_dims, m_dims + ndims (), [] (octave_idx_type dim) { return dim == 0; }); } - bool empty_2d (void) const + bool empty_2d () const { return ndims () == 2 && (xelem (0) == 0 || xelem (1) == 0); } - bool zero_by_zero (void) const + bool zero_by_zero () const { return ndims () == 2 && xelem (0) == 0 && xelem (1) == 0; } - bool any_zero (void) const + bool any_zero () const { return std::any_of (m_dims, m_dims + ndims (), [] (octave_idx_type dim) { return dim == 0; }); } - OCTAVE_API int num_ones (void) const; + OCTAVE_API int num_ones () const; - bool all_ones (void) const + bool all_ones () const { return (num_ones () == ndims ()); } @@ -352,15 +352,15 @@ //! function that is iterating over an array using octave_idx_type //! indices. - OCTAVE_API octave_idx_type safe_numel (void) const; + OCTAVE_API octave_idx_type safe_numel () const; - bool any_neg (void) const + bool any_neg () const { return std::any_of (m_dims, m_dims + ndims (), [] (octave_idx_type dim) { return dim < 0; }); } - OCTAVE_API dim_vector squeeze (void) const; + OCTAVE_API dim_vector squeeze () const; //! This corresponds to cat(). OCTAVE_API bool concat (const dim_vector& dvb, int dim); @@ -376,7 +376,7 @@ OCTAVE_API dim_vector redim (int n) const; - dim_vector as_column (void) const + dim_vector as_column () const { if (ndims () == 2 && xelem (1) == 1) return *this; @@ -384,7 +384,7 @@ return dim_vector (numel (), 1); } - dim_vector as_row (void) const + dim_vector as_row () const { if (ndims () == 2 && xelem (0) == 1) return *this; @@ -392,12 +392,12 @@ return dim_vector (1, numel ()); } - bool isvector (void) const + bool isvector () const { return (ndims () == 2 && (xelem (0) == 1 || xelem (1) == 1)); } - bool is_nd_vector (void) const + bool is_nd_vector () const { int num_non_one = 0; @@ -485,7 +485,7 @@ //! Return cumulative dimensions. - dim_vector cumulative (void) const + dim_vector cumulative () const { int nd = ndims (); dim_vector retval = alloc (nd); @@ -513,7 +513,7 @@ friend OCTAVE_API bool operator == (const dim_vector& a, const dim_vector& b); - OCTAVE_API Array as_array (void) const; + OCTAVE_API Array as_array () const; }; inline bool diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/fCColVector.cc --- a/liboctave/array/fCColVector.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/fCColVector.cc Tue Jan 24 17:19:44 2023 -0800 @@ -198,19 +198,19 @@ } FloatComplexRowVector -FloatComplexColumnVector::hermitian (void) const +FloatComplexColumnVector::hermitian () const { return MArray::hermitian (std::conj); } FloatComplexRowVector -FloatComplexColumnVector::transpose (void) const +FloatComplexColumnVector::transpose () const { return MArray::transpose (); } FloatColumnVector -FloatComplexColumnVector::abs (void) const +FloatComplexColumnVector::abs () const { return do_mx_unary_map (*this); } @@ -421,7 +421,7 @@ // other operations FloatComplex -FloatComplexColumnVector::min (void) const +FloatComplexColumnVector::min () const { octave_idx_type len = numel (); if (len == 0) @@ -441,7 +441,7 @@ } FloatComplex -FloatComplexColumnVector::max (void) const +FloatComplexColumnVector::max () const { octave_idx_type len = numel (); if (len == 0) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/fCColVector.h --- a/liboctave/array/fCColVector.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/fCColVector.h Tue Jan 24 17:19:44 2023 -0800 @@ -40,7 +40,7 @@ public: - FloatComplexColumnVector (void) + FloatComplexColumnVector () : MArray (dim_vector (0, 1)) { } explicit FloatComplexColumnVector (octave_idx_type n) @@ -90,8 +90,8 @@ OCTAVE_API FloatComplexColumnVector stack (const FloatComplexColumnVector& a) const; - OCTAVE_API FloatComplexRowVector hermitian (void) const; - OCTAVE_API FloatComplexRowVector transpose (void) const; + OCTAVE_API FloatComplexRowVector hermitian () const; + OCTAVE_API FloatComplexRowVector transpose () const; friend OCTAVE_API FloatComplexColumnVector OCTAVE_API conj (const FloatComplexColumnVector& a); @@ -137,10 +137,10 @@ // other operations - OCTAVE_API FloatComplex min (void) const; - OCTAVE_API FloatComplex max (void) const; + OCTAVE_API FloatComplex min () const; + OCTAVE_API FloatComplex max () const; - OCTAVE_API FloatColumnVector abs (void) const; + OCTAVE_API FloatColumnVector abs () const; // i/o diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/fCDiagMatrix.cc --- a/liboctave/array/fCDiagMatrix.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/fCDiagMatrix.cc Tue Jan 24 17:19:44 2023 -0800 @@ -209,7 +209,7 @@ } FloatDiagMatrix -FloatComplexDiagMatrix::abs (void) const +FloatComplexDiagMatrix::abs () const { return FloatDiagMatrix (extract_diag ().abs (), rows (), columns ()); } @@ -305,7 +305,7 @@ } FloatComplexDiagMatrix -FloatComplexDiagMatrix::inverse (void) const +FloatComplexDiagMatrix::inverse () const { octave_idx_type info; return inverse (info); @@ -358,7 +358,7 @@ } bool -FloatComplexDiagMatrix::all_elements_are_real (void) const +FloatComplexDiagMatrix::all_elements_are_real () const { return mx_inline_all_real (length (), data ()); } @@ -474,7 +474,7 @@ // other operations FloatComplexDET -FloatComplexDiagMatrix::determinant (void) const +FloatComplexDiagMatrix::determinant () const { FloatComplexDET det (1.0f); if (rows () != cols ()) @@ -488,7 +488,7 @@ } float -FloatComplexDiagMatrix::rcond (void) const +FloatComplexDiagMatrix::rcond () const { FloatColumnVector av = extract_diag (0).map (std::abs); float amx = av.max (); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/fCDiagMatrix.h --- a/liboctave/array/fCDiagMatrix.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/fCDiagMatrix.h Tue Jan 24 17:19:44 2023 -0800 @@ -48,13 +48,13 @@ typedef FloatComplex complex_elt_type; typedef FloatComplex element_type; - FloatComplexDiagMatrix (void) = default; + FloatComplexDiagMatrix () = default; FloatComplexDiagMatrix (const FloatComplexDiagMatrix& a) = default; FloatComplexDiagMatrix& operator = (const FloatComplexDiagMatrix& a) = default; - ~FloatComplexDiagMatrix (void) = default; + ~FloatComplexDiagMatrix () = default; FloatComplexDiagMatrix (octave_idx_type r, octave_idx_type c) @@ -105,11 +105,11 @@ OCTAVE_API FloatComplexDiagMatrix& fill (const FloatComplexRowVector& a, octave_idx_type beg); - FloatComplexDiagMatrix hermitian (void) const + FloatComplexDiagMatrix hermitian () const { return MDiagArray2::hermitian (std::conj); } - FloatComplexDiagMatrix transpose (void) const + FloatComplexDiagMatrix transpose () const { return MDiagArray2::transpose (); } - OCTAVE_API FloatDiagMatrix abs (void) const; + OCTAVE_API FloatDiagMatrix abs () const; friend OCTAVE_API FloatComplexDiagMatrix conj (const FloatComplexDiagMatrix& a); @@ -129,10 +129,10 @@ OCTAVE_API FloatComplexColumnVector column (char *s) const; OCTAVE_API FloatComplexDiagMatrix inverse (octave_idx_type& info) const; - OCTAVE_API FloatComplexDiagMatrix inverse (void) const; + OCTAVE_API FloatComplexDiagMatrix inverse () const; OCTAVE_API FloatComplexDiagMatrix pseudo_inverse (float tol = 0.0f) const; - OCTAVE_API bool all_elements_are_real (void) const; + OCTAVE_API bool all_elements_are_real () const; // diagonal matrix by diagonal matrix -> diagonal matrix operations @@ -144,8 +144,8 @@ FloatComplexColumnVector extract_diag (octave_idx_type k = 0) const { return MDiagArray2::extract_diag (k); } - OCTAVE_API FloatComplexDET determinant (void) const; - OCTAVE_API float rcond (void) const; + OCTAVE_API FloatComplexDET determinant () const; + OCTAVE_API float rcond () const; // i/o diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/fCMatrix.cc --- a/liboctave/array/fCMatrix.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/fCMatrix.cc Tue Jan 24 17:19:44 2023 -0800 @@ -171,7 +171,7 @@ } bool -FloatComplexMatrix::ishermitian (void) const +FloatComplexMatrix::ishermitian () const { octave_idx_type nr = rows (); octave_idx_type nc = cols (); @@ -737,7 +737,7 @@ } FloatComplexMatrix -FloatComplexMatrix::inverse (void) const +FloatComplexMatrix::inverse () const { octave_idx_type info; float rcon; @@ -1045,7 +1045,7 @@ #if defined (HAVE_FFTW) FloatComplexMatrix -FloatComplexMatrix::fourier (void) const +FloatComplexMatrix::fourier () const { std::size_t nr = rows (); std::size_t nc = cols (); @@ -1074,7 +1074,7 @@ } FloatComplexMatrix -FloatComplexMatrix::ifourier (void) const +FloatComplexMatrix::ifourier () const { std::size_t nr = rows (); std::size_t nc = cols (); @@ -1103,7 +1103,7 @@ } FloatComplexMatrix -FloatComplexMatrix::fourier2d (void) const +FloatComplexMatrix::fourier2d () const { dim_vector dv (rows (), cols ()); @@ -1117,7 +1117,7 @@ } FloatComplexMatrix -FloatComplexMatrix::ifourier2d (void) const +FloatComplexMatrix::ifourier2d () const { dim_vector dv (rows (), cols ()); @@ -1133,7 +1133,7 @@ #else FloatComplexMatrix -FloatComplexMatrix::fourier (void) const +FloatComplexMatrix::fourier () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -1142,7 +1142,7 @@ } FloatComplexMatrix -FloatComplexMatrix::ifourier (void) const +FloatComplexMatrix::ifourier () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -1151,7 +1151,7 @@ } FloatComplexMatrix -FloatComplexMatrix::fourier2d (void) const +FloatComplexMatrix::fourier2d () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -1160,7 +1160,7 @@ } FloatComplexMatrix -FloatComplexMatrix::ifourier2d (void) const +FloatComplexMatrix::ifourier2d () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -1171,7 +1171,7 @@ #endif FloatComplexDET -FloatComplexMatrix::determinant (void) const +FloatComplexMatrix::determinant () const { octave_idx_type info; float rcon; @@ -1350,7 +1350,7 @@ } float -FloatComplexMatrix::rcond (void) const +FloatComplexMatrix::rcond () const { MatrixType mattype (*this); return rcond (mattype); @@ -2849,7 +2849,7 @@ return FloatComplexNDArray::sumsq (dim); } -FloatMatrix FloatComplexMatrix::abs (void) const +FloatMatrix FloatComplexMatrix::abs () const { return FloatComplexNDArray::abs (); } @@ -2915,7 +2915,7 @@ } FloatComplexColumnVector -FloatComplexMatrix::row_min (void) const +FloatComplexMatrix::row_min () const { Array dummy_idx; return row_min (dummy_idx); @@ -2990,7 +2990,7 @@ } FloatComplexColumnVector -FloatComplexMatrix::row_max (void) const +FloatComplexMatrix::row_max () const { Array dummy_idx; return row_max (dummy_idx); @@ -3065,7 +3065,7 @@ } FloatComplexRowVector -FloatComplexMatrix::column_min (void) const +FloatComplexMatrix::column_min () const { Array dummy_idx; return column_min (dummy_idx); @@ -3140,7 +3140,7 @@ } FloatComplexRowVector -FloatComplexMatrix::column_max (void) const +FloatComplexMatrix::column_max () const { Array dummy_idx; return column_max (dummy_idx); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/fCMatrix.h --- a/liboctave/array/fCMatrix.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/fCMatrix.h Tue Jan 24 17:19:44 2023 -0800 @@ -60,13 +60,13 @@ typedef void (*solve_singularity_handler) (float rcon); - FloatComplexMatrix (void) = default; + FloatComplexMatrix () = default; FloatComplexMatrix (const FloatComplexMatrix& a) = default; FloatComplexMatrix& operator = (const FloatComplexMatrix& a) = default; - ~FloatComplexMatrix (void) = default; + ~FloatComplexMatrix () = default; FloatComplexMatrix (octave_idx_type r, octave_idx_type c) : FloatComplexNDArray (dim_vector (r, c)) { } @@ -120,7 +120,7 @@ OCTAVE_API bool operator == (const FloatComplexMatrix& a) const; OCTAVE_API bool operator != (const FloatComplexMatrix& a) const; - OCTAVE_API bool ishermitian (void) const; + OCTAVE_API bool ishermitian () const; // destructive insert/delete/reorder operations @@ -175,9 +175,9 @@ OCTAVE_API FloatComplexMatrix stack (const FloatComplexColumnVector& a) const; OCTAVE_API FloatComplexMatrix stack (const FloatComplexDiagMatrix& a) const; - FloatComplexMatrix hermitian (void) const + FloatComplexMatrix hermitian () const { return MArray::hermitian (std::conj); } - FloatComplexMatrix transpose (void) const + FloatComplexMatrix transpose () const { return MArray::transpose (); } friend OCTAVE_API FloatComplexMatrix conj (const FloatComplexMatrix& a); @@ -212,7 +212,7 @@ float& rcon, bool force, bool calc_cond) const; public: - OCTAVE_API FloatComplexMatrix inverse (void) const; + OCTAVE_API FloatComplexMatrix inverse () const; OCTAVE_API FloatComplexMatrix inverse (octave_idx_type& info) const; OCTAVE_API FloatComplexMatrix inverse (octave_idx_type& info, float& rcon, bool force = false, @@ -227,13 +227,13 @@ OCTAVE_API FloatComplexMatrix pseudo_inverse (float tol = 0.0) const; - OCTAVE_API FloatComplexMatrix fourier (void) const; - OCTAVE_API FloatComplexMatrix ifourier (void) const; + OCTAVE_API FloatComplexMatrix fourier () const; + OCTAVE_API FloatComplexMatrix ifourier () const; - OCTAVE_API FloatComplexMatrix fourier2d (void) const; - OCTAVE_API FloatComplexMatrix ifourier2d (void) const; + OCTAVE_API FloatComplexMatrix fourier2d () const; + OCTAVE_API FloatComplexMatrix ifourier2d () const; - OCTAVE_API FloatComplexDET determinant (void) const; + OCTAVE_API FloatComplexDET determinant () const; OCTAVE_API FloatComplexDET determinant (octave_idx_type& info) const; OCTAVE_API FloatComplexDET determinant (octave_idx_type& info, float& rcon, @@ -242,7 +242,7 @@ determinant (MatrixType& mattype, octave_idx_type& info, float& rcon, bool calc_cond = true) const; - OCTAVE_API float rcond (void) const; + OCTAVE_API float rcond () const; OCTAVE_API float rcond (MatrixType& mattype) const; private: @@ -426,7 +426,7 @@ // unary operations - OCTAVE_API boolMatrix operator ! (void) const; + OCTAVE_API boolMatrix operator ! () const; // other operations @@ -438,7 +438,7 @@ OCTAVE_API FloatComplexMatrix prod (int dim = -1) const; OCTAVE_API FloatComplexMatrix sum (int dim = -1) const; OCTAVE_API FloatComplexMatrix sumsq (int dim = -1) const; - OCTAVE_API FloatMatrix abs (void) const; + OCTAVE_API FloatMatrix abs () const; OCTAVE_API FloatComplexMatrix diag (octave_idx_type k = 0) const; @@ -448,16 +448,16 @@ OCTAVE_API bool row_is_real_only (octave_idx_type) const; OCTAVE_API bool column_is_real_only (octave_idx_type) const; - OCTAVE_API FloatComplexColumnVector row_min (void) const; - OCTAVE_API FloatComplexColumnVector row_max (void) const; + OCTAVE_API FloatComplexColumnVector row_min () const; + OCTAVE_API FloatComplexColumnVector row_max () const; OCTAVE_API FloatComplexColumnVector row_min (Array& index) const; OCTAVE_API FloatComplexColumnVector row_max (Array& index) const; - OCTAVE_API FloatComplexRowVector column_min (void) const; - OCTAVE_API FloatComplexRowVector column_max (void) const; + OCTAVE_API FloatComplexRowVector column_min () const; + OCTAVE_API FloatComplexRowVector column_max () const; OCTAVE_API FloatComplexRowVector column_min (Array& index) const; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/fCNDArray.cc --- a/liboctave/array/fCNDArray.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/fCNDArray.cc Tue Jan 24 17:19:44 2023 -0800 @@ -117,7 +117,7 @@ } FloatComplexNDArray -FloatComplexNDArray::fourier2d (void) const +FloatComplexNDArray::fourier2d () const { dim_vector dv = dims (); if (dv.ndims () < 2) @@ -137,7 +137,7 @@ } FloatComplexNDArray -FloatComplexNDArray::ifourier2d (void) const +FloatComplexNDArray::ifourier2d () const { dim_vector dv = dims (); if (dv.ndims () < 2) @@ -157,7 +157,7 @@ } FloatComplexNDArray -FloatComplexNDArray::fourierNd (void) const +FloatComplexNDArray::fourierNd () const { dim_vector dv = dims (); int rank = dv.ndims (); @@ -172,7 +172,7 @@ } FloatComplexNDArray -FloatComplexNDArray::ifourierNd (void) const +FloatComplexNDArray::ifourierNd () const { dim_vector dv = dims (); int rank = dv.ndims (); @@ -211,7 +211,7 @@ } FloatComplexNDArray -FloatComplexNDArray::fourier2d (void) const +FloatComplexNDArray::fourier2d () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -220,7 +220,7 @@ } FloatComplexNDArray -FloatComplexNDArray::ifourier2d (void) const +FloatComplexNDArray::ifourier2d () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -229,7 +229,7 @@ } FloatComplexNDArray -FloatComplexNDArray::fourierNd (void) const +FloatComplexNDArray::fourierNd () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -238,7 +238,7 @@ } FloatComplexNDArray -FloatComplexNDArray::ifourierNd (void) const +FloatComplexNDArray::ifourierNd () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -251,7 +251,7 @@ // unary operations boolNDArray -FloatComplexNDArray::operator ! (void) const +FloatComplexNDArray::operator ! () const { if (any_element_is_nan ()) octave::err_nan_to_logical_conversion (); @@ -262,13 +262,13 @@ // FIXME: this is not quite the right thing. bool -FloatComplexNDArray::any_element_is_nan (void) const +FloatComplexNDArray::any_element_is_nan () const { return do_mx_check (*this, mx_inline_any_nan); } bool -FloatComplexNDArray::any_element_is_inf_or_nan (void) const +FloatComplexNDArray::any_element_is_inf_or_nan () const { return ! do_mx_check (*this, mx_inline_all_finite); } @@ -276,7 +276,7 @@ // Return true if no elements have imaginary components. bool -FloatComplexNDArray::all_elements_are_real (void) const +FloatComplexNDArray::all_elements_are_real () const { return do_mx_check (*this, mx_inline_all_real); } @@ -337,7 +337,7 @@ } bool -FloatComplexNDArray::too_large_for_float (void) const +FloatComplexNDArray::too_large_for_float () const { return false; } @@ -487,25 +487,25 @@ } FloatNDArray -FloatComplexNDArray::abs (void) const +FloatComplexNDArray::abs () const { return do_mx_unary_map (*this); } boolNDArray -FloatComplexNDArray::isnan (void) const +FloatComplexNDArray::isnan () const { return do_mx_unary_map (*this); } boolNDArray -FloatComplexNDArray::isinf (void) const +FloatComplexNDArray::isinf () const { return do_mx_unary_map (*this); } boolNDArray -FloatComplexNDArray::isfinite (void) const +FloatComplexNDArray::isfinite () const { return do_mx_unary_map (*this); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/fCNDArray.h --- a/liboctave/array/fCNDArray.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/fCNDArray.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,7 +39,7 @@ { public: - FloatComplexNDArray (void) : MArray () { } + FloatComplexNDArray () : MArray () { } FloatComplexNDArray (const dim_vector& dv) : MArray (dv) { } @@ -65,15 +65,15 @@ // unary operations - OCTAVE_API boolNDArray operator ! (void) const; + OCTAVE_API boolNDArray operator ! () const; // FIXME: this is not quite the right thing. - OCTAVE_API bool any_element_is_nan (void) const; - OCTAVE_API bool any_element_is_inf_or_nan (void) const; - OCTAVE_API bool all_elements_are_real (void) const; + OCTAVE_API bool any_element_is_nan () const; + OCTAVE_API bool any_element_is_inf_or_nan () const; + OCTAVE_API bool all_elements_are_real () const; OCTAVE_API bool all_integers (float& max_val, float& min_val) const; - OCTAVE_API bool too_large_for_float (void) const; + OCTAVE_API bool too_large_for_float () const; OCTAVE_API boolNDArray all (int dim = -1) const; OCTAVE_API boolNDArray any (int dim = -1) const; @@ -114,23 +114,23 @@ OCTAVE_API FloatComplexNDArray& insert (const FloatComplexNDArray& a, const Array& ra_idx); - OCTAVE_API FloatNDArray abs (void) const; - OCTAVE_API boolNDArray isnan (void) const; - OCTAVE_API boolNDArray isinf (void) const; - OCTAVE_API boolNDArray isfinite (void) const; + OCTAVE_API FloatNDArray abs () const; + OCTAVE_API boolNDArray isnan () const; + OCTAVE_API boolNDArray isinf () const; + OCTAVE_API boolNDArray isfinite () const; friend OCTAVE_API FloatComplexNDArray conj (const FloatComplexNDArray& a); OCTAVE_API FloatComplexNDArray fourier (int dim = 1) const; OCTAVE_API FloatComplexNDArray ifourier (int dim = 1) const; - OCTAVE_API FloatComplexNDArray fourier2d (void) const; - OCTAVE_API FloatComplexNDArray ifourier2d (void) const; + OCTAVE_API FloatComplexNDArray fourier2d () const; + OCTAVE_API FloatComplexNDArray ifourier2d () const; - OCTAVE_API FloatComplexNDArray fourierNd (void) const; - OCTAVE_API FloatComplexNDArray ifourierNd (void) const; + OCTAVE_API FloatComplexNDArray fourierNd () const; + OCTAVE_API FloatComplexNDArray ifourierNd () const; - FloatComplexNDArray squeeze (void) const + FloatComplexNDArray squeeze () const { return MArray::squeeze (); } static OCTAVE_API void @@ -147,7 +147,7 @@ friend OCTAVE_API std::istream& operator >> (std::istream& is, FloatComplexNDArray& a); - // bool all_elements_are_real (void) const; + // bool all_elements_are_real () const; // bool all_integers (float& max_val, float& min_val) const; OCTAVE_API FloatComplexNDArray diag (octave_idx_type k = 0) const; @@ -155,7 +155,7 @@ OCTAVE_API FloatComplexNDArray diag (octave_idx_type m, octave_idx_type n) const; - FloatComplexNDArray& changesign (void) + FloatComplexNDArray& changesign () { MArray::changesign (); return *this; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/fCRowVector.cc --- a/liboctave/array/fCRowVector.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/fCRowVector.cc Tue Jan 24 17:19:44 2023 -0800 @@ -194,13 +194,13 @@ } FloatComplexColumnVector -FloatComplexRowVector::hermitian (void) const +FloatComplexRowVector::hermitian () const { return MArray::hermitian (std::conj); } FloatComplexColumnVector -FloatComplexRowVector::transpose (void) const +FloatComplexRowVector::transpose () const { return MArray::transpose (); } @@ -324,7 +324,7 @@ // other operations FloatComplex -FloatComplexRowVector::min (void) const +FloatComplexRowVector::min () const { octave_idx_type len = numel (); if (len == 0) @@ -344,7 +344,7 @@ } FloatComplex -FloatComplexRowVector::max (void) const +FloatComplexRowVector::max () const { octave_idx_type len = numel (); if (len == 0) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/fCRowVector.h --- a/liboctave/array/fCRowVector.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/fCRowVector.h Tue Jan 24 17:19:44 2023 -0800 @@ -40,7 +40,7 @@ public: - FloatComplexRowVector (void) + FloatComplexRowVector () : MArray (dim_vector (1, 0)) { } explicit FloatComplexRowVector (octave_idx_type n) @@ -91,8 +91,8 @@ OCTAVE_API FloatComplexRowVector append (const FloatComplexRowVector& a) const; - OCTAVE_API FloatComplexColumnVector hermitian (void) const; - OCTAVE_API FloatComplexColumnVector transpose (void) const; + OCTAVE_API FloatComplexColumnVector hermitian () const; + OCTAVE_API FloatComplexColumnVector transpose () const; friend OCTAVE_API FloatComplexRowVector conj (const FloatComplexRowVector& a); @@ -120,8 +120,8 @@ // other operations - OCTAVE_API FloatComplex min (void) const; - OCTAVE_API FloatComplex max (void) const; + OCTAVE_API FloatComplex min () const; + OCTAVE_API FloatComplex max () const; // i/o diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/fColVector.cc --- a/liboctave/array/fColVector.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/fColVector.cc Tue Jan 24 17:19:44 2023 -0800 @@ -122,13 +122,13 @@ } FloatRowVector -FloatColumnVector::transpose (void) const +FloatColumnVector::transpose () const { return MArray::transpose (); } FloatColumnVector -FloatColumnVector::abs (void) const +FloatColumnVector::abs () const { return do_mx_unary_map (*this); } @@ -242,7 +242,7 @@ // other operations float -FloatColumnVector::min (void) const +FloatColumnVector::min () const { octave_idx_type len = numel (); if (len == 0) @@ -258,7 +258,7 @@ } float -FloatColumnVector::max (void) const +FloatColumnVector::max () const { octave_idx_type len = numel (); if (len == 0) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/fColVector.h --- a/liboctave/array/fColVector.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/fColVector.h Tue Jan 24 17:19:44 2023 -0800 @@ -37,7 +37,7 @@ { public: - FloatColumnVector (void) : MArray (dim_vector (0, 1)) { } + FloatColumnVector () : MArray (dim_vector (0, 1)) { } explicit FloatColumnVector (octave_idx_type n) : MArray (dim_vector (n, 1)) { } @@ -76,7 +76,7 @@ OCTAVE_API FloatColumnVector stack (const FloatColumnVector& a) const; - OCTAVE_API FloatRowVector transpose (void) const; + OCTAVE_API FloatRowVector transpose () const; friend OCTAVE_API FloatColumnVector real (const FloatComplexColumnVector& a); friend OCTAVE_API FloatColumnVector imag (const FloatComplexColumnVector& a); @@ -101,10 +101,10 @@ // other operations - OCTAVE_API float min (void) const; - OCTAVE_API float max (void) const; + OCTAVE_API float min () const; + OCTAVE_API float max () const; - OCTAVE_API FloatColumnVector abs (void) const; + OCTAVE_API FloatColumnVector abs () const; // i/o diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/fDiagMatrix.cc --- a/liboctave/array/fDiagMatrix.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/fDiagMatrix.cc Tue Jan 24 17:19:44 2023 -0800 @@ -125,7 +125,7 @@ } FloatDiagMatrix -FloatDiagMatrix::abs (void) const +FloatDiagMatrix::abs () const { return FloatDiagMatrix (extract_diag ().abs (), rows (), columns ()); } @@ -224,7 +224,7 @@ } FloatDiagMatrix -FloatDiagMatrix::inverse (void) const +FloatDiagMatrix::inverse () const { octave_idx_type info; return inverse (info); @@ -306,7 +306,7 @@ // other operations FloatDET -FloatDiagMatrix::determinant (void) const +FloatDiagMatrix::determinant () const { FloatDET det (1.0f); if (rows () != cols ()) @@ -320,7 +320,7 @@ } float -FloatDiagMatrix::rcond (void) const +FloatDiagMatrix::rcond () const { FloatColumnVector av = extract_diag (0).map (fabsf); float amx = av.max (); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/fDiagMatrix.h --- a/liboctave/array/fDiagMatrix.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/fDiagMatrix.h Tue Jan 24 17:19:44 2023 -0800 @@ -42,13 +42,13 @@ typedef FloatMatrix full_matrix_type; - FloatDiagMatrix (void) = default; + FloatDiagMatrix () = default; FloatDiagMatrix (const FloatDiagMatrix& a) = default; FloatDiagMatrix& operator = (const FloatDiagMatrix& a) = default; - ~FloatDiagMatrix (void) = default; + ~FloatDiagMatrix () = default; FloatDiagMatrix (octave_idx_type r, octave_idx_type c) : MDiagArray2 (r, c) { } @@ -79,10 +79,10 @@ OCTAVE_API FloatDiagMatrix& fill (const FloatRowVector& a, octave_idx_type beg); - FloatDiagMatrix transpose (void) const + FloatDiagMatrix transpose () const { return MDiagArray2::transpose (); } - OCTAVE_API FloatDiagMatrix abs (void) const; + OCTAVE_API FloatDiagMatrix abs () const; friend OCTAVE_API FloatDiagMatrix real (const FloatComplexDiagMatrix& a); friend OCTAVE_API FloatDiagMatrix imag (const FloatComplexDiagMatrix& a); @@ -101,7 +101,7 @@ OCTAVE_API FloatColumnVector column (octave_idx_type i) const; OCTAVE_API FloatColumnVector column (char *s) const; - OCTAVE_API FloatDiagMatrix inverse (void) const; + OCTAVE_API FloatDiagMatrix inverse () const; OCTAVE_API FloatDiagMatrix inverse (octave_idx_type& info) const; OCTAVE_API FloatDiagMatrix pseudo_inverse (float tol = 0.0f) const; @@ -110,8 +110,8 @@ FloatColumnVector extract_diag (octave_idx_type k = 0) const { return MDiagArray2::extract_diag (k); } - OCTAVE_API FloatDET determinant (void) const; - OCTAVE_API float rcond (void) const; + OCTAVE_API FloatDET determinant () const; + OCTAVE_API float rcond () const; // i/o diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/fMatrix.cc --- a/liboctave/array/fMatrix.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/fMatrix.cc Tue Jan 24 17:19:44 2023 -0800 @@ -135,7 +135,7 @@ } bool -FloatMatrix::issymmetric (void) const +FloatMatrix::issymmetric () const { if (issquare () && rows () > 0) { @@ -454,7 +454,7 @@ } FloatMatrix -FloatMatrix::inverse (void) const +FloatMatrix::inverse () const { octave_idx_type info; float rcon; @@ -737,7 +737,7 @@ #if defined (HAVE_FFTW) FloatComplexMatrix -FloatMatrix::fourier (void) const +FloatMatrix::fourier () const { std::size_t nr = rows (); std::size_t nc = cols (); @@ -766,7 +766,7 @@ } FloatComplexMatrix -FloatMatrix::ifourier (void) const +FloatMatrix::ifourier () const { std::size_t nr = rows (); std::size_t nc = cols (); @@ -796,7 +796,7 @@ } FloatComplexMatrix -FloatMatrix::fourier2d (void) const +FloatMatrix::fourier2d () const { dim_vector dv (rows (), cols ()); @@ -808,7 +808,7 @@ } FloatComplexMatrix -FloatMatrix::ifourier2d (void) const +FloatMatrix::ifourier2d () const { dim_vector dv (rows (), cols ()); @@ -823,7 +823,7 @@ #else FloatComplexMatrix -FloatMatrix::fourier (void) const +FloatMatrix::fourier () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -832,7 +832,7 @@ } FloatComplexMatrix -FloatMatrix::ifourier (void) const +FloatMatrix::ifourier () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -841,7 +841,7 @@ } FloatComplexMatrix -FloatMatrix::fourier2d (void) const +FloatMatrix::fourier2d () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -850,7 +850,7 @@ } FloatComplexMatrix -FloatMatrix::ifourier2d (void) const +FloatMatrix::ifourier2d () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -861,7 +861,7 @@ #endif FloatDET -FloatMatrix::determinant (void) const +FloatMatrix::determinant () const { octave_idx_type info; float rcon; @@ -1035,7 +1035,7 @@ } float -FloatMatrix::rcond (void) const +FloatMatrix::rcond () const { MatrixType mattype (*this); return rcond (mattype); @@ -2408,7 +2408,7 @@ } FloatMatrix -FloatMatrix::abs (void) const +FloatMatrix::abs () const { return FloatNDArray::abs (); } @@ -2436,7 +2436,7 @@ } FloatColumnVector -FloatMatrix::row_min (void) const +FloatMatrix::row_min () const { Array dummy_idx; return row_min (dummy_idx); @@ -2491,7 +2491,7 @@ } FloatColumnVector -FloatMatrix::row_max (void) const +FloatMatrix::row_max () const { Array dummy_idx; return row_max (dummy_idx); @@ -2546,7 +2546,7 @@ } FloatRowVector -FloatMatrix::column_min (void) const +FloatMatrix::column_min () const { Array dummy_idx; return column_min (dummy_idx); @@ -2601,7 +2601,7 @@ } FloatRowVector -FloatMatrix::column_max (void) const +FloatMatrix::column_max () const { Array dummy_idx; return column_max (dummy_idx); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/fMatrix.h --- a/liboctave/array/fMatrix.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/fMatrix.h Tue Jan 24 17:19:44 2023 -0800 @@ -59,13 +59,13 @@ typedef void (*solve_singularity_handler) (float rcon); - FloatMatrix (void) = default; + FloatMatrix () = default; FloatMatrix (const FloatMatrix& a) = default; FloatMatrix& operator = (const FloatMatrix& a) = default; - ~FloatMatrix (void) = default; + ~FloatMatrix () = default; FloatMatrix (octave_idx_type r, octave_idx_type c) : FloatNDArray (dim_vector (r, c)) { } @@ -103,7 +103,7 @@ OCTAVE_API bool operator == (const FloatMatrix& a) const; OCTAVE_API bool operator != (const FloatMatrix& a) const; - OCTAVE_API bool issymmetric (void) const; + OCTAVE_API bool issymmetric () const; // destructive insert/delete/reorder operations @@ -136,8 +136,8 @@ friend class FloatComplexMatrix; - FloatMatrix hermitian (void) const { return MArray::transpose (); } - FloatMatrix transpose (void) const { return MArray::transpose (); } + FloatMatrix hermitian () const { return MArray::transpose (); } + FloatMatrix transpose () const { return MArray::transpose (); } // resize is the destructive equivalent for this one @@ -168,7 +168,7 @@ float& rcon, bool force, bool calc_cond) const; public: - OCTAVE_API FloatMatrix inverse (void) const; + OCTAVE_API FloatMatrix inverse () const; OCTAVE_API FloatMatrix inverse (octave_idx_type& info) const; OCTAVE_API FloatMatrix inverse (octave_idx_type& info, float& rcon, bool force = false, @@ -183,13 +183,13 @@ OCTAVE_API FloatMatrix pseudo_inverse (float tol = 0.0) const; - OCTAVE_API FloatComplexMatrix fourier (void) const; - OCTAVE_API FloatComplexMatrix ifourier (void) const; + OCTAVE_API FloatComplexMatrix fourier () const; + OCTAVE_API FloatComplexMatrix ifourier () const; - OCTAVE_API FloatComplexMatrix fourier2d (void) const; - OCTAVE_API FloatComplexMatrix ifourier2d (void) const; + OCTAVE_API FloatComplexMatrix fourier2d () const; + OCTAVE_API FloatComplexMatrix ifourier2d () const; - OCTAVE_API FloatDET determinant (void) const; + OCTAVE_API FloatDET determinant () const; OCTAVE_API FloatDET determinant (octave_idx_type& info) const; OCTAVE_API FloatDET determinant (octave_idx_type& info, float& rcon, @@ -198,7 +198,7 @@ determinant (MatrixType& mattype, octave_idx_type& info, float& rcon, bool calc_cond = true) const; - OCTAVE_API float rcond (void) const; + OCTAVE_API float rcond () const; OCTAVE_API float rcond (MatrixType& mattype) const; private: @@ -374,20 +374,20 @@ OCTAVE_API FloatMatrix prod (int dim = -1) const; OCTAVE_API FloatMatrix sum (int dim = -1) const; OCTAVE_API FloatMatrix sumsq (int dim = -1) const; - OCTAVE_API FloatMatrix abs (void) const; + OCTAVE_API FloatMatrix abs () const; OCTAVE_API FloatMatrix diag (octave_idx_type k = 0) const; OCTAVE_API FloatDiagMatrix diag (octave_idx_type m, octave_idx_type n) const; - OCTAVE_API FloatColumnVector row_min (void) const; - OCTAVE_API FloatColumnVector row_max (void) const; + OCTAVE_API FloatColumnVector row_min () const; + OCTAVE_API FloatColumnVector row_max () const; OCTAVE_API FloatColumnVector row_min (Array& index) const; OCTAVE_API FloatColumnVector row_max (Array& index) const; - OCTAVE_API FloatRowVector column_min (void) const; - OCTAVE_API FloatRowVector column_max (void) const; + OCTAVE_API FloatRowVector column_min () const; + OCTAVE_API FloatRowVector column_max () const; OCTAVE_API FloatRowVector column_min (Array& index) const; OCTAVE_API FloatRowVector column_max (Array& index) const; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/fNDArray.cc --- a/liboctave/array/fNDArray.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/fNDArray.cc Tue Jan 24 17:19:44 2023 -0800 @@ -116,7 +116,7 @@ } FloatComplexNDArray -FloatNDArray::fourier2d (void) const +FloatNDArray::fourier2d () const { dim_vector dv = dims (); if (dv.ndims () < 2) @@ -136,7 +136,7 @@ } FloatComplexNDArray -FloatNDArray::ifourier2d (void) const +FloatNDArray::ifourier2d () const { dim_vector dv = dims (); if (dv.ndims () < 2) @@ -155,7 +155,7 @@ } FloatComplexNDArray -FloatNDArray::fourierNd (void) const +FloatNDArray::fourierNd () const { dim_vector dv = dims (); int rank = dv.ndims (); @@ -170,7 +170,7 @@ } FloatComplexNDArray -FloatNDArray::ifourierNd (void) const +FloatNDArray::ifourierNd () const { dim_vector dv = dims (); int rank = dv.ndims (); @@ -209,7 +209,7 @@ } FloatComplexNDArray -FloatNDArray::fourier2d (void) const +FloatNDArray::fourier2d () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -218,7 +218,7 @@ } FloatComplexNDArray -FloatNDArray::ifourier2d (void) const +FloatNDArray::ifourier2d () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -227,7 +227,7 @@ } FloatComplexNDArray -FloatNDArray::fourierNd (void) const +FloatNDArray::fourierNd () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -236,7 +236,7 @@ } FloatComplexNDArray -FloatNDArray::ifourierNd (void) const +FloatNDArray::ifourierNd () const { (*current_liboctave_error_handler) ("support for FFTW was unavailable or disabled when liboctave was built"); @@ -249,7 +249,7 @@ // unary operations boolNDArray -FloatNDArray::operator ! (void) const +FloatNDArray::operator ! () const { if (any_element_is_nan ()) octave::err_nan_to_logical_conversion (); @@ -272,31 +272,31 @@ } bool -FloatNDArray::any_element_is_nan (void) const +FloatNDArray::any_element_is_nan () const { return do_mx_check (*this, mx_inline_any_nan); } bool -FloatNDArray::any_element_is_inf_or_nan (void) const +FloatNDArray::any_element_is_inf_or_nan () const { return ! do_mx_check (*this, mx_inline_all_finite); } bool -FloatNDArray::any_element_not_one_or_zero (void) const +FloatNDArray::any_element_not_one_or_zero () const { return ! test_all (octave::is_one_or_zero); } bool -FloatNDArray::all_elements_are_zero (void) const +FloatNDArray::all_elements_are_zero () const { return test_all (octave::is_zero); } bool -FloatNDArray::all_elements_are_int_or_inf_or_nan (void) const +FloatNDArray::all_elements_are_int_or_inf_or_nan () const { return test_all (octave::is_int_or_inf_or_nan); } @@ -335,13 +335,13 @@ } bool -FloatNDArray::all_integers (void) const +FloatNDArray::all_integers () const { return test_all (octave::math::isinteger); } bool -FloatNDArray::too_large_for_float (void) const +FloatNDArray::too_large_for_float () const { return false; } @@ -535,25 +535,25 @@ } FloatNDArray -FloatNDArray::abs (void) const +FloatNDArray::abs () const { return do_mx_unary_map (*this); } boolNDArray -FloatNDArray::isnan (void) const +FloatNDArray::isnan () const { return do_mx_unary_map (*this); } boolNDArray -FloatNDArray::isinf (void) const +FloatNDArray::isinf () const { return do_mx_unary_map (*this); } boolNDArray -FloatNDArray::isfinite (void) const +FloatNDArray::isfinite () const { return do_mx_unary_map (*this); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/fNDArray.h --- a/liboctave/array/fNDArray.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/fNDArray.h Tue Jan 24 17:19:44 2023 -0800 @@ -40,7 +40,7 @@ { public: - FloatNDArray (void) : MArray () { } + FloatNDArray () : MArray () { } FloatNDArray (const dim_vector& dv) : MArray (dv) { } @@ -68,18 +68,18 @@ // unary operations - OCTAVE_API boolNDArray operator ! (void) const; + OCTAVE_API boolNDArray operator ! () const; OCTAVE_API bool any_element_is_negative (bool = false) const; OCTAVE_API bool any_element_is_positive (bool = false) const; - OCTAVE_API bool any_element_is_nan (void) const; - OCTAVE_API bool any_element_is_inf_or_nan (void) const; - OCTAVE_API bool any_element_not_one_or_zero (void) const; - OCTAVE_API bool all_elements_are_zero (void) const; - OCTAVE_API bool all_elements_are_int_or_inf_or_nan (void) const; + OCTAVE_API bool any_element_is_nan () const; + OCTAVE_API bool any_element_is_inf_or_nan () const; + OCTAVE_API bool any_element_not_one_or_zero () const; + OCTAVE_API bool all_elements_are_zero () const; + OCTAVE_API bool all_elements_are_int_or_inf_or_nan () const; OCTAVE_API bool all_integers (float& max_val, float& min_val) const; - OCTAVE_API bool all_integers (void) const; - OCTAVE_API bool too_large_for_float (void) const; + OCTAVE_API bool all_integers () const; + OCTAVE_API bool too_large_for_float () const; // FIXME: this is not quite the right thing. @@ -121,26 +121,26 @@ OCTAVE_API FloatNDArray& insert (const FloatNDArray& a, const Array& ra_idx); - OCTAVE_API FloatNDArray abs (void) const; - OCTAVE_API boolNDArray isnan (void) const; - OCTAVE_API boolNDArray isinf (void) const; - OCTAVE_API boolNDArray isfinite (void) const; + OCTAVE_API FloatNDArray abs () const; + OCTAVE_API boolNDArray isnan () const; + OCTAVE_API boolNDArray isinf () const; + OCTAVE_API boolNDArray isfinite () const; OCTAVE_API FloatComplexNDArray fourier (int dim = 1) const; OCTAVE_API FloatComplexNDArray ifourier (int dim = 1) const; - OCTAVE_API FloatComplexNDArray fourier2d (void) const; - OCTAVE_API FloatComplexNDArray ifourier2d (void) const; + OCTAVE_API FloatComplexNDArray fourier2d () const; + OCTAVE_API FloatComplexNDArray ifourier2d () const; - OCTAVE_API FloatComplexNDArray fourierNd (void) const; - OCTAVE_API FloatComplexNDArray ifourierNd (void) const; + OCTAVE_API FloatComplexNDArray fourierNd () const; + OCTAVE_API FloatComplexNDArray ifourierNd () const; friend OCTAVE_API FloatNDArray real (const FloatComplexNDArray& a); friend OCTAVE_API FloatNDArray imag (const FloatComplexNDArray& a); friend class FloatComplexNDArray; - FloatNDArray squeeze (void) const { return MArray::squeeze (); } + FloatNDArray squeeze () const { return MArray::squeeze (); } static OCTAVE_API void increment_index (Array& ra_idx, @@ -160,7 +160,7 @@ OCTAVE_API FloatNDArray diag (octave_idx_type m, octave_idx_type n) const; - FloatNDArray& changesign (void) + FloatNDArray& changesign () { MArray::changesign (); return *this; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/fRowVector.cc --- a/liboctave/array/fRowVector.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/fRowVector.cc Tue Jan 24 17:19:44 2023 -0800 @@ -123,7 +123,7 @@ } FloatColumnVector -FloatRowVector::transpose (void) const +FloatRowVector::transpose () const { return MArray::transpose (); } @@ -204,7 +204,7 @@ // other operations float -FloatRowVector::min (void) const +FloatRowVector::min () const { octave_idx_type len = numel (); if (len == 0) @@ -220,7 +220,7 @@ } float -FloatRowVector::max (void) const +FloatRowVector::max () const { octave_idx_type len = numel (); if (len == 0) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/fRowVector.h --- a/liboctave/array/fRowVector.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/fRowVector.h Tue Jan 24 17:19:44 2023 -0800 @@ -37,7 +37,7 @@ { public: - FloatRowVector (void) : MArray (dim_vector (1, 0)) { } + FloatRowVector () : MArray (dim_vector (1, 0)) { } explicit FloatRowVector (octave_idx_type n) : MArray (dim_vector (1, n)) { } @@ -74,7 +74,7 @@ OCTAVE_API FloatRowVector append (const FloatRowVector& a) const; - OCTAVE_API FloatColumnVector transpose (void) const; + OCTAVE_API FloatColumnVector transpose () const; friend OCTAVE_API FloatRowVector real (const FloatComplexRowVector& a); friend OCTAVE_API FloatRowVector imag (const FloatComplexRowVector& a); @@ -94,8 +94,8 @@ // other operations - OCTAVE_API float min (void) const; - OCTAVE_API float max (void) const; + OCTAVE_API float min () const; + OCTAVE_API float max () const; // i/o diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/idx-vector.cc --- a/liboctave/array/idx-vector.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/idx-vector.cc Tue Jan 24 17:19:44 2023 -0800 @@ -44,24 +44,24 @@ OCTAVE_BEGIN_NAMESPACE(octave) -OCTAVE_NORETURN static void err_invalid_range (void) +OCTAVE_NORETURN static void err_invalid_range () { (*current_liboctave_error_handler) ("invalid range used as index"); } -OCTAVE_NORETURN static void err_index_out_of_range (void) +OCTAVE_NORETURN static void err_index_out_of_range () { (*current_liboctave_error_handler) ("internal error: idx_vector index out of range"); } -idx_vector::idx_vector_rep *idx_vector::nil_rep (void) +idx_vector::idx_vector_rep *idx_vector::nil_rep () { static idx_vector_rep ivr; return &ivr; } -Array idx_vector::idx_base_rep::as_array (void) +Array idx_vector::idx_base_rep::as_array () { (*current_liboctave_error_handler) ("internal error: as_array not allowed for this index class"); @@ -191,13 +191,13 @@ return os; } -range idx_vector::idx_range_rep::unconvert (void) const +range idx_vector::idx_range_rep::unconvert () const { return range::make_n_element_range (static_cast (m_start+1), static_cast (m_step), m_len); } -Array idx_vector::idx_range_rep::as_array (void) +Array idx_vector::idx_range_rep::as_array () { Array retval (dim_vector (1, m_len)); for (octave_idx_type i = 0; i < m_len; i++) @@ -279,12 +279,12 @@ return os << m_data; } -double idx_vector::idx_scalar_rep::unconvert (void) const +double idx_vector::idx_scalar_rep::unconvert () const { return m_data + 1; } -Array idx_vector::idx_scalar_rep::as_array (void) +Array idx_vector::idx_scalar_rep::as_array () { return Array (dim_vector (1, 1), m_data); } @@ -414,7 +414,7 @@ } } -idx_vector::idx_vector_rep::~idx_vector_rep (void) +idx_vector::idx_vector_rep::~idx_vector_rep () { if (m_aowner) delete m_aowner; @@ -581,7 +581,7 @@ return os; } -Array idx_vector::idx_vector_rep::unconvert (void) const +Array idx_vector::idx_vector_rep::unconvert () const { Array retval (m_orig_dims); for (octave_idx_type i = 0; i < m_len; i++) @@ -589,7 +589,7 @@ return retval; } -Array idx_vector::idx_vector_rep::as_array (void) +Array idx_vector::idx_vector_rep::as_array () { if (m_aowner) return *m_aowner; @@ -645,7 +645,7 @@ m_data = bnda.data (); } -idx_vector::idx_mask_rep::~idx_mask_rep (void) +idx_vector::idx_mask_rep::~idx_mask_rep () { if (m_aowner) delete m_aowner; @@ -693,7 +693,7 @@ return os; } -Array idx_vector::idx_mask_rep::unconvert (void) const +Array idx_vector::idx_mask_rep::unconvert () const { if (m_aowner) return *m_aowner; @@ -706,7 +706,7 @@ } } -Array idx_vector::idx_mask_rep::as_array (void) +Array idx_vector::idx_mask_rep::as_array () { if (m_aowner) return m_aowner->find ().reshape (m_orig_dims); @@ -967,7 +967,7 @@ return res; } -octave_idx_type idx_vector::increment (void) const +octave_idx_type idx_vector::increment () const { octave_idx_type retval = 0; @@ -996,7 +996,7 @@ return retval; } -const octave_idx_type *idx_vector::raw (void) +const octave_idx_type *idx_vector::raw () { if (m_rep->idx_class () != class_vector) *this = idx_vector (as_array (), extent (0)); @@ -1157,7 +1157,7 @@ return retval; } -idx_vector idx_vector::unmask (void) const +idx_vector idx_vector::unmask () const { if (idx_class () == class_mask) { @@ -1224,12 +1224,12 @@ } } -Array idx_vector::as_array (void) const +Array idx_vector::as_array () const { return m_rep->as_array (); } -bool idx_vector::isvector (void) const +bool idx_vector::isvector () const { return idx_class () != class_vector || orig_dimensions ().isvector (); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/idx-vector.h --- a/liboctave/array/idx-vector.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/idx-vector.h Tue Jan 24 17:19:44 2023 -0800 @@ -78,7 +78,7 @@ { public: - idx_base_rep (void) : m_count (1) { } + idx_base_rep () : m_count (1) { } // No copying! @@ -86,7 +86,7 @@ idx_base_rep& operator = (const idx_base_rep&) = delete; - virtual ~idx_base_rep (void) = default; + virtual ~idx_base_rep () = default; // Non-range-checking element query. virtual octave_idx_type xelem (octave_idx_type i) const = 0; @@ -101,7 +101,7 @@ virtual octave_idx_type extent (octave_idx_type n) const = 0; // Index class. - virtual idx_class_type idx_class (void) const { return class_invalid; } + virtual idx_class_type idx_class () const { return class_invalid; } // Sorts, maybe uniqifies, and returns a clone object pointer. virtual idx_base_rep * sort_uniq_clone (bool uniq = false) = 0; @@ -112,12 +112,12 @@ virtual bool is_colon_equiv (octave_idx_type) const { return false; } // The original dimensions of object (used when subscribing by matrices). - virtual dim_vector orig_dimensions (void) const { return dim_vector (); } + virtual dim_vector orig_dimensions () const { return dim_vector (); } // i/o virtual std::ostream& print (std::ostream& os) const = 0; - virtual Array as_array (void); + virtual Array as_array (); refcount m_count; }; @@ -127,7 +127,7 @@ { public: - idx_colon_rep (void) = default; + idx_colon_rep () = default; OCTAVE_API idx_colon_rep (char c); @@ -145,7 +145,7 @@ octave_idx_type extent (octave_idx_type n) const { return n; } - idx_class_type idx_class (void) const { return class_colon; } + idx_class_type idx_class () const { return class_colon; } idx_base_rep * sort_uniq_clone (bool = false) { m_count++; return this; } @@ -165,7 +165,7 @@ { public: - idx_range_rep (void) = delete; + idx_range_rep () = delete; idx_range_rep (octave_idx_type start, octave_idx_type len, octave_idx_type step, direct) @@ -196,7 +196,7 @@ return m_len ? std::max (n, m_start + 1 + (m_step < 0 ? 0 : m_step * (m_len - 1))) : n; } - idx_class_type idx_class (void) const { return class_range; } + idx_class_type idx_class () const { return class_range; } OCTAVE_API idx_base_rep * sort_uniq_clone (bool uniq = false); @@ -205,18 +205,18 @@ bool is_colon_equiv (octave_idx_type n) const { return m_start == 0 && m_step == 1 && m_len == n; } - dim_vector orig_dimensions (void) const + dim_vector orig_dimensions () const { return dim_vector (1, m_len); } - octave_idx_type get_start (void) const { return m_start; } + octave_idx_type get_start () const { return m_start; } - octave_idx_type get_step (void) const { return m_step; } + octave_idx_type get_step () const { return m_step; } OCTAVE_API std::ostream& print (std::ostream& os) const; - OCTAVE_API range unconvert (void) const; + OCTAVE_API range unconvert () const; - OCTAVE_API Array as_array (void); + OCTAVE_API Array as_array (); private: @@ -228,7 +228,7 @@ { public: - idx_scalar_rep (void) = delete; + idx_scalar_rep () = delete; idx_scalar_rep (octave_idx_type i, direct) : idx_base_rep (), m_data (i) { } @@ -253,7 +253,7 @@ octave_idx_type extent (octave_idx_type n) const { return std::max (n, m_data + 1); } - idx_class_type idx_class (void) const { return class_scalar; } + idx_class_type idx_class () const { return class_scalar; } idx_base_rep * sort_uniq_clone (bool = false) { m_count++; return this; } @@ -263,15 +263,15 @@ bool is_colon_equiv (octave_idx_type n) const { return n == 1 && m_data == 0; } - dim_vector orig_dimensions (void) const { return dim_vector (1, 1); } + dim_vector orig_dimensions () const { return dim_vector (1, 1); } - octave_idx_type get_data (void) const { return m_data; } + octave_idx_type get_data () const { return m_data; } OCTAVE_API std::ostream& print (std::ostream& os) const; - OCTAVE_API double unconvert (void) const; + OCTAVE_API double unconvert () const; - OCTAVE_API Array as_array (void); + OCTAVE_API Array as_array (); private: @@ -283,7 +283,7 @@ { public: - idx_vector_rep (void) + idx_vector_rep () : m_data (nullptr), m_len (0), m_ext (0), m_aowner (nullptr), m_orig_dims () { } // Direct constructor. @@ -314,7 +314,7 @@ idx_vector_rep& operator = (const idx_vector_rep& idx) = delete; - ~idx_vector_rep (void); + ~idx_vector_rep (); octave_idx_type xelem (octave_idx_type i) const { return m_data[i]; } @@ -325,21 +325,21 @@ octave_idx_type extent (octave_idx_type n) const { return std::max (n, m_ext); } - idx_class_type idx_class (void) const { return class_vector; } + idx_class_type idx_class () const { return class_vector; } idx_base_rep * sort_uniq_clone (bool uniq = false); OCTAVE_API idx_base_rep * sort_idx (Array&); - dim_vector orig_dimensions (void) const { return m_orig_dims; } + dim_vector orig_dimensions () const { return m_orig_dims; } - const octave_idx_type * get_data (void) const { return m_data; } + const octave_idx_type * get_data () const { return m_data; } OCTAVE_API std::ostream& print (std::ostream& os) const; - OCTAVE_API Array unconvert (void) const; + OCTAVE_API Array unconvert () const; - OCTAVE_API Array as_array (void); + OCTAVE_API Array as_array (); private: @@ -364,7 +364,7 @@ { public: - idx_mask_rep (void) = delete; + idx_mask_rep () = delete; // Direct constructor. idx_mask_rep (bool *data, octave_idx_type len, @@ -383,7 +383,7 @@ idx_mask_rep& operator = (const idx_mask_rep& idx) = delete; - OCTAVE_API ~idx_mask_rep (void); + OCTAVE_API ~idx_mask_rep (); octave_idx_type xelem (octave_idx_type i) const; @@ -394,25 +394,25 @@ octave_idx_type extent (octave_idx_type n) const { return std::max (n, m_ext); } - idx_class_type idx_class (void) const { return class_mask; } + idx_class_type idx_class () const { return class_mask; } idx_base_rep * sort_uniq_clone (bool = false) { m_count++; return this; } OCTAVE_API idx_base_rep * sort_idx (Array&); - dim_vector orig_dimensions (void) const { return m_orig_dims; } + dim_vector orig_dimensions () const { return m_orig_dims; } bool is_colon_equiv (octave_idx_type n) const { return m_len == n && m_ext == n; } - const bool * get_data (void) const { return m_data; } + const bool * get_data () const { return m_data; } OCTAVE_API std::ostream& print (std::ostream& os) const; - OCTAVE_API Array unconvert (void) const; + OCTAVE_API Array unconvert () const; - OCTAVE_API Array as_array (void); + OCTAVE_API Array as_array (); private: @@ -441,12 +441,12 @@ // The shared empty vector representation (for fast default // constructor). - static OCTAVE_API idx_vector_rep * nil_rep (void); + static OCTAVE_API idx_vector_rep * nil_rep (); public: // Fast empty constructor. - idx_vector (void) : m_rep (nil_rep ()) { m_rep->m_count++; } + idx_vector () : m_rep (nil_rep ()) { m_rep->m_count++; } // Zero-based constructors (for use from C++). idx_vector (octave_idx_type i) : m_rep (new idx_scalar_rep (i)) { } @@ -514,7 +514,7 @@ idx_vector (const idx_vector& a) : m_rep (a.m_rep) { m_rep->m_count++; } - ~idx_vector (void) + ~idx_vector () { if (--m_rep->m_count == 0 && m_rep != nil_rep ()) delete m_rep; @@ -533,7 +533,7 @@ return *this; } - idx_class_type idx_class (void) const { return m_rep->idx_class (); } + idx_class_type idx_class () const { return m_rep->idx_class (); } octave_idx_type length (octave_idx_type n = 0) const { return m_rep->length (n); } @@ -552,15 +552,15 @@ // FIXME: idx_vector objects are either created successfully or an // error is thrown, so this method no longer makes sense. - operator bool (void) const { return true; } + operator bool () const { return true; } - bool is_colon (void) const + bool is_colon () const { return m_rep->idx_class () == class_colon; } - bool is_scalar (void) const + bool is_scalar () const { return m_rep->idx_class () == class_scalar; } - bool is_range (void) const + bool is_range () const { return m_rep->idx_class () == class_range; } bool is_colon_equiv (octave_idx_type n) const @@ -572,15 +572,15 @@ idx_vector sorted (Array& sidx) const { return idx_vector (m_rep->sort_idx (sidx)); } - dim_vector orig_dimensions (void) const { return m_rep->orig_dimensions (); } + dim_vector orig_dimensions () const { return m_rep->orig_dimensions (); } - octave_idx_type orig_rows (void) const + octave_idx_type orig_rows () const { return orig_dimensions () (0); } - octave_idx_type orig_columns (void) const + octave_idx_type orig_columns () const { return orig_dimensions () (1); } - int orig_empty (void) const + int orig_empty () const { return (! is_colon () && orig_dimensions ().any_zero ()); } // i/o @@ -976,7 +976,7 @@ // Returns the increment for ranges and colon, 0 for scalars and empty // vectors, 1st difference otherwise. - OCTAVE_API octave_idx_type increment (void) const; + OCTAVE_API octave_idx_type increment () const; OCTAVE_API idx_vector complement (octave_idx_type n) const; @@ -991,20 +991,20 @@ OCTAVE_API void copy_data (octave_idx_type *data) const; // If the index is a mask, convert it to index vector. - OCTAVE_API idx_vector unmask (void) const; + OCTAVE_API idx_vector unmask () const; // Unconverts the index to a scalar, Range, double array or a mask. OCTAVE_API void unconvert (idx_class_type& iclass, double& scalar, range& range, Array& array, Array& mask) const; - OCTAVE_API Array as_array (void) const; + OCTAVE_API Array as_array () const; // Raw pointer to index array. This is non-const because it may be // necessary to mutate the index. - const OCTAVE_API octave_idx_type * raw (void); + const OCTAVE_API octave_idx_type * raw (); - OCTAVE_API bool isvector (void) const; + OCTAVE_API bool isvector () const; // FIXME: these are here for compatibility. They should be removed // when no longer in use. @@ -1021,9 +1021,9 @@ void sort (bool uniq = false) { *this = sorted (uniq); } - OCTAVE_API octave_idx_type ones_count (void) const; + OCTAVE_API octave_idx_type ones_count () const; - octave_idx_type max (void) const { return extent (1) - 1; } + octave_idx_type max () const { return extent (1) - 1; } private: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/intNDArray.cc --- a/liboctave/array/intNDArray.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/intNDArray.cc Tue Jan 24 17:19:44 2023 -0800 @@ -36,7 +36,7 @@ template boolNDArray -intNDArray::operator ! (void) const +intNDArray::operator ! () const { boolNDArray b (this->dims ()); @@ -48,7 +48,7 @@ template bool -intNDArray::any_element_not_one_or_zero (void) const +intNDArray::any_element_not_one_or_zero () const { octave_idx_type nel = this->numel (); @@ -180,7 +180,7 @@ template intNDArray -intNDArray::abs (void) const +intNDArray::abs () const { octave_idx_type nel = this->numel (); intNDArray ret (this->dims ()); @@ -196,7 +196,7 @@ template intNDArray -intNDArray::signum (void) const +intNDArray::signum () const { octave_idx_type nel = this->numel (); intNDArray ret (this->dims ()); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/array/intNDArray.h --- a/liboctave/array/intNDArray.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/array/intNDArray.h Tue Jan 24 17:19:44 2023 -0800 @@ -41,13 +41,13 @@ using typename MArray::element_type; - intNDArray (void) = default; + intNDArray () = default; intNDArray (const intNDArray& a) = default; intNDArray& operator = (const intNDArray& a) = default; - ~intNDArray (void) = default; + ~intNDArray () = default; intNDArray (T val) : MArray (dim_vector (1, 1), val) { } @@ -65,16 +65,16 @@ template intNDArray (const intNDArray& a) : MArray (a) { } - OCTAVE_API boolNDArray operator ! (void) const; + OCTAVE_API boolNDArray operator ! () const; - bool any_element_is_nan (void) const { return false; } - OCTAVE_API bool any_element_not_one_or_zero (void) const; + bool any_element_is_nan () const { return false; } + OCTAVE_API bool any_element_not_one_or_zero () const; OCTAVE_API intNDArray diag (octave_idx_type k = 0) const; OCTAVE_API intNDArray diag (octave_idx_type m, octave_idx_type n) const; - intNDArray& changesign (void) + intNDArray& changesign () { MArray::changesign (); return *this; @@ -106,13 +106,13 @@ OCTAVE_API intNDArray diff (octave_idx_type order = 1, int dim = -1) const; - OCTAVE_API intNDArray abs (void) const; - OCTAVE_API intNDArray signum (void) const; + OCTAVE_API intNDArray abs () const; + OCTAVE_API intNDArray signum () const; - intNDArray squeeze (void) const + intNDArray squeeze () const { return intNDArray (MArray::squeeze ()); } - intNDArray transpose (void) const + intNDArray transpose () const { return intNDArray (MArray::transpose ()); } OCTAVE_API intNDArray diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/liboctave-build-info.h --- a/liboctave/liboctave-build-info.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/liboctave-build-info.h Tue Jan 24 17:19:44 2023 -0800 @@ -30,6 +30,6 @@ #include -extern OCTAVE_API std::string liboctave_hg_id (void); +extern OCTAVE_API std::string liboctave_hg_id (); #endif diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/liboctave-build-info.in.cc --- a/liboctave/liboctave-build-info.in.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/liboctave-build-info.in.cc Tue Jan 24 17:19:44 2023 -0800 @@ -32,7 +32,7 @@ #include "liboctave-build-info.h" std::string -liboctave_hg_id (void) +liboctave_hg_id () { return "%OCTAVE_HG_ID%"; } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/CollocWt.cc --- a/liboctave/numeric/CollocWt.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/CollocWt.cc Tue Jan 24 17:19:44 2023 -0800 @@ -402,7 +402,7 @@ return *this; } -void CollocWt::init (void) +void CollocWt::init () { // Check for possible errors. diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/CollocWt.h --- a/liboctave/numeric/CollocWt.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/CollocWt.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,7 +39,7 @@ { public: - CollocWt (void) + CollocWt () : m_n (0), m_inc_left (0), m_inc_right (0), m_lb (0.0), m_rb (1.0), m_alpha (0.0), m_beta (0.0), m_r (), m_q (), m_A (), m_B (), m_initialized (false) @@ -77,7 +77,7 @@ CollocWt& operator = (const CollocWt& a) = default; - ~CollocWt (void) = default; + ~CollocWt () = default; CollocWt& resize (octave_idx_type nc) { @@ -86,14 +86,14 @@ return *this; } - CollocWt& add_left (void) + CollocWt& add_left () { m_inc_left = 1; m_initialized = false; return *this; } - CollocWt& delete_left (void) + CollocWt& delete_left () { m_inc_left = 0; m_initialized = false; @@ -102,14 +102,14 @@ CollocWt& set_left (double val); - CollocWt& add_right (void) + CollocWt& add_right () { m_inc_right = 1; m_initialized = false; return *this; } - CollocWt& delete_right (void) + CollocWt& delete_right () { m_inc_right = 0; m_initialized = false; @@ -132,20 +132,20 @@ return *this; } - octave_idx_type ncol (void) const { return m_n; } + octave_idx_type ncol () const { return m_n; } - octave_idx_type left_included (void) const { return m_inc_left; } - octave_idx_type right_included (void) const { return m_inc_right; } + octave_idx_type left_included () const { return m_inc_left; } + octave_idx_type right_included () const { return m_inc_right; } - double left (void) const { return m_lb; } - double right (void) const { return m_rb; } + double left () const { return m_lb; } + double right () const { return m_rb; } - double width (void) const { return m_rb - m_lb; } + double width () const { return m_rb - m_lb; } - double alpha (void) const { return m_alpha; } - double beta (void) const { return m_beta; } + double alpha () const { return m_alpha; } + double beta () const { return m_beta; } - ColumnVector roots (void) + ColumnVector roots () { if (! m_initialized) init (); @@ -153,7 +153,7 @@ return m_r; } - ColumnVector quad (void) + ColumnVector quad () { if (! m_initialized) init (); @@ -161,9 +161,9 @@ return m_q; } - ColumnVector quad_weights (void) { return quad (); } + ColumnVector quad_weights () { return quad (); } - Matrix first (void) + Matrix first () { if (! m_initialized) init (); @@ -171,7 +171,7 @@ return m_A; } - Matrix second (void) + Matrix second () { if (! m_initialized) init (); @@ -202,7 +202,7 @@ bool m_initialized; - void init (void); + void init (); void error (const char *msg); }; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/DAE.h --- a/liboctave/numeric/DAE.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/DAE.h Tue Jan 24 17:19:44 2023 -0800 @@ -37,7 +37,7 @@ { public: - DAE (void) + DAE () : base_diff_alg_eqn (), DAEFunc () { } DAE (const ColumnVector& xx, double tt, DAEFunc& f) @@ -60,7 +60,7 @@ return *this; } - virtual ~DAE (void) = default; + virtual ~DAE () = default; }; #endif diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/DAEFunc.h --- a/liboctave/numeric/DAEFunc.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/DAEFunc.h Tue Jan 24 17:19:44 2023 -0800 @@ -47,7 +47,7 @@ const ColumnVector& xdot, double t, double cj); - DAEFunc (void) + DAEFunc () : m_fcn (nullptr), m_jac (nullptr), m_reset (true) { } DAEFunc (DAERHSFunc f) @@ -70,9 +70,9 @@ return *this; } - virtual ~DAEFunc (void) = default; + virtual ~DAEFunc () = default; - DAERHSFunc function (void) const { return m_fcn; } + DAERHSFunc function () const { return m_fcn; } DAEFunc& set_function (DAERHSFunc f) { @@ -81,7 +81,7 @@ return *this; } - DAEJacFunc jacobian_function (void) const { return m_jac; } + DAEJacFunc jacobian_function () const { return m_jac; } DAEFunc& set_jacobian_function (DAEJacFunc j) { diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/DAERT.h --- a/liboctave/numeric/DAERT.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/DAERT.h Tue Jan 24 17:19:44 2023 -0800 @@ -37,7 +37,7 @@ { public: - DAERT (void) + DAERT () : base_diff_alg_eqn (), DAERTFunc () { } DAERT (const ColumnVector& xx, double tt, DAERTFunc& f) @@ -61,7 +61,7 @@ return *this; } - virtual ~DAERT (void) = default; + virtual ~DAERT () = default; void initialize (const ColumnVector& xx, const ColumnVector& xxdot, double tt) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/DAERTFunc.h --- a/liboctave/numeric/DAERTFunc.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/DAERTFunc.h Tue Jan 24 17:19:44 2023 -0800 @@ -37,7 +37,7 @@ typedef ColumnVector (*DAERTConstrFunc) (const ColumnVector& x, double t); - DAERTFunc (void) + DAERTFunc () : DAEFunc (), m_constr (nullptr), m_reset (true) { } DAERTFunc (DAERHSFunc f) @@ -66,9 +66,9 @@ return *this; } - virtual ~DAERTFunc (void) = default; + virtual ~DAERTFunc () = default; - DAERTConstrFunc constraint_function (void) const { return m_constr; } + DAERTConstrFunc constraint_function () const { return m_constr; } DAERTFunc& set_constraint_function (DAERTConstrFunc cf) { diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/DASPK.cc --- a/liboctave/numeric/DASPK.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/DASPK.cc Tue Jan 24 17:19:44 2023 -0800 @@ -692,7 +692,7 @@ } std::string -DASPK::error_message (void) const +DASPK::error_message () const { std::string retval; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/DASPK.h --- a/liboctave/numeric/DASPK.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/DASPK.h Tue Jan 24 17:19:44 2023 -0800 @@ -41,7 +41,7 @@ { public: - DASPK (void) + DASPK () : DAE (), DASPK_options (), m_initialized (false), m_liw (0), m_lrw (0), m_info (), m_iwork (), m_rwork (), m_abs_tol (), m_rel_tol () { } @@ -56,7 +56,7 @@ m_liw (0), m_lrw (0), m_info (), m_iwork (), m_rwork (), m_abs_tol (), m_rel_tol () { } - ~DASPK (void) = default; + ~DASPK () = default; ColumnVector do_integrate (double t); @@ -69,7 +69,7 @@ Matrix integrate (const ColumnVector& tout, Matrix& xdot_out, const ColumnVector& tcrit); - std::string error_message (void) const; + std::string error_message () const; private: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/DASRT.cc --- a/liboctave/numeric/DASRT.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/DASRT.cc Tue Jan 24 17:19:44 2023 -0800 @@ -551,7 +551,7 @@ } std::string -DASRT::error_message (void) const +DASRT::error_message () const { std::string retval; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/DASRT.h --- a/liboctave/numeric/DASRT.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/DASRT.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,7 +39,7 @@ { public: - DASRT_result (void) + DASRT_result () : m_x (), m_xdot (), m_t () { } DASRT_result (const Matrix& x, const Matrix& xdot, const ColumnVector& t) @@ -59,11 +59,11 @@ return *this; } - ~DASRT_result (void) = default; + ~DASRT_result () = default; - Matrix state (void) const { return m_x; } - Matrix deriv (void) const { return m_xdot; } - ColumnVector times (void) const { return m_t; } + Matrix state () const { return m_x; } + Matrix deriv () const { return m_xdot; } + ColumnVector times () const { return m_t; } private: @@ -78,7 +78,7 @@ { public: - DASRT (void) + DASRT () : DAERT (), DASRT_options (), m_initialized (false), m_liw (0), m_lrw (0), m_ng (0), m_info (), m_iwork (), m_jroot (), m_rwork (), m_abs_tol (), m_rel_tol () @@ -97,14 +97,14 @@ m_rwork (), m_abs_tol (), m_rel_tol () { } - ~DASRT (void) = default; + ~DASRT () = default; DASRT_result integrate (const ColumnVector& tout); DASRT_result integrate (const ColumnVector& tout, const ColumnVector& tcrit); - std::string error_message (void) const; + std::string error_message () const; private: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/DASSL.cc --- a/liboctave/numeric/DASSL.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/DASSL.cc Tue Jan 24 17:19:44 2023 -0800 @@ -499,7 +499,7 @@ } std::string -DASSL::error_message (void) const +DASSL::error_message () const { std::string retval; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/DASSL.h --- a/liboctave/numeric/DASSL.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/DASSL.h Tue Jan 24 17:19:44 2023 -0800 @@ -41,7 +41,7 @@ { public: - DASSL (void) + DASSL () : DAE (), DASSL_options (), m_initialized (false), m_liw (0), m_lrw (0), m_info (), m_iwork (), m_rwork (), m_abs_tol (), m_rel_tol () { } @@ -56,7 +56,7 @@ m_liw (0), m_lrw (0), m_info (), m_iwork (), m_rwork (), m_abs_tol (), m_rel_tol () { } - ~DASSL (void) = default; + ~DASSL () = default; ColumnVector do_integrate (double t); @@ -69,7 +69,7 @@ Matrix integrate (const ColumnVector& tout, Matrix& xdot_out, const ColumnVector& tcrit); - std::string error_message (void) const; + std::string error_message () const; private: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/DET.h --- a/liboctave/numeric/DET.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/DET.h Tue Jan 24 17:19:44 2023 -0800 @@ -66,8 +66,8 @@ return *this; } - T coef (void) const { return m_c2; } - int exp (void) const { return m_e2; } + T coef () const { return m_c2; } + int exp () const { return m_e2; } T value () const { return m_c2 * static_cast (std::ldexp (1.0, m_e2)); } operator T () const { return value (); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/EIG.h --- a/liboctave/numeric/EIG.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/EIG.h Tue Jan 24 17:19:44 2023 -0800 @@ -44,7 +44,7 @@ public: - EIG (void) : m_lambda (), m_v (), m_w () { } + EIG () : m_lambda (), m_v (), m_w () { } EIG (const Matrix& a, bool calc_rev = true, bool calc_lev = true, bool balance = true) @@ -116,11 +116,11 @@ return *this; } - ~EIG (void) = default; + ~EIG () = default; - ComplexColumnVector eigenvalues (void) const { return m_lambda; } - ComplexMatrix right_eigenvectors (void) const { return m_v; } - ComplexMatrix left_eigenvectors (void) const { return m_w; } + ComplexColumnVector eigenvalues () const { return m_lambda; } + ComplexMatrix right_eigenvectors () const { return m_v; } + ComplexMatrix left_eigenvectors () const { return m_w; } friend std::ostream& operator << (std::ostream& os, const EIG& a); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/LSODE.cc --- a/liboctave/numeric/LSODE.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/LSODE.cc Tue Jan 24 17:19:44 2023 -0800 @@ -348,7 +348,7 @@ } std::string -LSODE::error_message (void) const +LSODE::error_message () const { std::string retval; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/LSODE.h --- a/liboctave/numeric/LSODE.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/LSODE.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,7 +39,7 @@ { public: - LSODE (void) + LSODE () : ODE (), LSODE_options (), m_initialized (false), m_method_flag (0), m_itask (0), m_iopt (0), m_itol (0), m_liw (0), m_lrw (0), m_iwork (), m_rwork (), m_rel_tol (0.0), m_abs_tol () { } @@ -49,7 +49,7 @@ m_method_flag (0), m_itask (0), m_iopt (0), m_itol (0), m_liw (0), m_lrw (0), m_iwork (), m_rwork (), m_rel_tol (0.0), m_abs_tol () { } - ~LSODE (void) = default; + ~LSODE () = default; ColumnVector do_integrate (double t); @@ -57,7 +57,7 @@ Matrix do_integrate (const ColumnVector& tout, const ColumnVector& tcrit); - std::string error_message (void) const; + std::string error_message () const; private: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/ODE.h --- a/liboctave/numeric/ODE.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/ODE.h Tue Jan 24 17:19:44 2023 -0800 @@ -37,7 +37,7 @@ { public: - ODE (void) + ODE () : base_diff_eqn (), ODEFunc () { } ODE (const ColumnVector& s, double tm, const ODEFunc& f) @@ -56,7 +56,7 @@ return *this; } - virtual ~ODE (void) = default; + virtual ~ODE () = default; // Derived classes must provide functions to actually do the // integration. diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/ODEFunc.h --- a/liboctave/numeric/ODEFunc.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/ODEFunc.h Tue Jan 24 17:19:44 2023 -0800 @@ -38,7 +38,7 @@ typedef ColumnVector (*ODERHSFunc) (const ColumnVector&, double); typedef Matrix (*ODEJacFunc) (const ColumnVector&, double); - ODEFunc (void) + ODEFunc () : m_fcn (nullptr), m_jac (nullptr), m_reset (true) { } ODEFunc (ODERHSFunc f) @@ -61,9 +61,9 @@ return *this; } - virtual ~ODEFunc (void) = default; + virtual ~ODEFunc () = default; - ODERHSFunc function (void) const { return m_fcn; } + ODERHSFunc function () const { return m_fcn; } ODEFunc& set_function (ODERHSFunc f) { @@ -72,7 +72,7 @@ return *this; } - ODEJacFunc jacobian_function (void) const { return m_jac; } + ODEJacFunc jacobian_function () const { return m_jac; } ODEFunc& set_jacobian_function (ODEJacFunc j) { diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/ODES.h --- a/liboctave/numeric/ODES.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/ODES.h Tue Jan 24 17:19:44 2023 -0800 @@ -36,7 +36,7 @@ { public: - ODES (void) + ODES () : base_diff_eqn (), ODESFunc (), m_xdot (), m_theta () { } ODES (const ColumnVector& s, double tm, ODESFunc& f) @@ -65,9 +65,9 @@ return *this; } - ~ODES (void) = default; + ~ODES () = default; - ColumnVector parameter_vector (void) { return m_theta; } + ColumnVector parameter_vector () { return m_theta; } OCTAVE_API void initialize (const ColumnVector& x, double t); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/ODESFunc.h --- a/liboctave/numeric/ODESFunc.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/ODESFunc.h Tue Jan 24 17:19:44 2023 -0800 @@ -52,7 +52,7 @@ typedef Matrix (*ODES_jsub) (const ColumnVector& x, double, const ColumnVector& theta); - ODESFunc (void) + ODESFunc () : m_fsub (nullptr), m_bsub (nullptr), m_jsub (nullptr) { } ODESFunc (ODES_fsub f) @@ -78,9 +78,9 @@ return *this; } - virtual ~ODESFunc (void) = default; + virtual ~ODESFunc () = default; - ODES_fsub fsub_function (void) const { return m_fsub; } + ODES_fsub fsub_function () const { return m_fsub; } ODESFunc& set_fsub_function (ODES_fsub f) { @@ -88,7 +88,7 @@ return *this; } - ODES_bsub bsub_function (void) const { return m_bsub; } + ODES_bsub bsub_function () const { return m_bsub; } ODESFunc& set_bsub_function (ODES_bsub b) { @@ -96,7 +96,7 @@ return *this; } - ODES_jsub jsub_function (void) const { return m_jsub; } + ODES_jsub jsub_function () const { return m_jsub; } ODESFunc& set_jsub_function (ODES_jsub j) { diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/Quad.h --- a/liboctave/numeric/Quad.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/Quad.h Tue Jan 24 17:19:44 2023 -0800 @@ -48,16 +48,16 @@ Quad (float_integrand_fcn fcn) : Quad_options (), m_f (), m_ff (fcn) { } - virtual ~Quad (void) = default; + virtual ~Quad () = default; - virtual double integrate (void) + virtual double integrate () { octave_idx_type ier, neval; double abserr; return do_integrate (ier, neval, abserr); } - virtual float float_integrate (void) + virtual float float_integrate () { octave_idx_type ier, neval; float abserr; @@ -137,7 +137,7 @@ : Quad (fcn), m_lower_limit (0.0), m_upper_limit (1.0), m_singularities (sing) { } - ~DefQuad (void) = default; + ~DefQuad () = default; double do_integrate (octave_idx_type& ier, octave_idx_type& neval, double& abserr); @@ -167,7 +167,7 @@ IndefQuad (integrand_fcn fcn, double b, IntegralType t) : Quad (fcn), m_bound (b), m_type (t) { } - ~IndefQuad (void) = default; + ~IndefQuad () = default; double do_integrate (octave_idx_type& ier, octave_idx_type& neval, double& abserr); @@ -204,7 +204,7 @@ : Quad (fcn), m_lower_limit (0.0), m_upper_limit (1.0), m_singularities (sing) { } - ~FloatDefQuad (void) = default; + ~FloatDefQuad () = default; OCTAVE_NORETURN double do_integrate (octave_idx_type& ier, octave_idx_type& neval, double& abserr); @@ -234,7 +234,7 @@ FloatIndefQuad (float_integrand_fcn fcn, double b, IntegralType t) : Quad (fcn), m_bound (b), m_type (t) { } - ~FloatIndefQuad (void) = default; + ~FloatIndefQuad () = default; OCTAVE_NORETURN double do_integrate (octave_idx_type& ier, octave_idx_type& neval, double& abserr); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/aepbalance.cc --- a/liboctave/numeric/aepbalance.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/aepbalance.cc Tue Jan 24 17:19:44 2023 -0800 @@ -74,7 +74,7 @@ template <> OCTAVE_API Matrix -aepbalance::balancing_matrix (void) const +aepbalance::balancing_matrix () const { F77_INT n = to_f77_int (m_balanced_mat.rows ()); @@ -126,7 +126,7 @@ template <> OCTAVE_API FloatMatrix -aepbalance::balancing_matrix (void) const +aepbalance::balancing_matrix () const { F77_INT n = to_f77_int (m_balanced_mat.rows ()); @@ -179,7 +179,7 @@ template <> OCTAVE_API ComplexMatrix -aepbalance::balancing_matrix (void) const +aepbalance::balancing_matrix () const { F77_INT n = to_f77_int (m_balanced_mat.rows ()); @@ -233,7 +233,7 @@ template <> OCTAVE_API FloatComplexMatrix -aepbalance::balancing_matrix (void) const +aepbalance::balancing_matrix () const { F77_INT n = to_f77_int (m_balanced_mat.rows ()); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/aepbalance.h --- a/liboctave/numeric/aepbalance.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/aepbalance.h Tue Jan 24 17:19:44 2023 -0800 @@ -42,7 +42,7 @@ typedef typename MT::real_column_vector_type VT; - aepbalance (void) : m_balanced_mat (), m_scale (), m_ilo (), m_ihi (), m_job () { } + aepbalance () : m_balanced_mat (), m_scale (), m_ilo (), m_ihi (), m_job () { } OCTAVE_API aepbalance (const MT& a, bool noperm = false, bool noscal = false); @@ -65,16 +65,16 @@ return *this; } - virtual ~aepbalance (void) = default; + virtual ~aepbalance () = default; - OCTAVE_API MT balancing_matrix (void) const; + OCTAVE_API MT balancing_matrix () const; - MT balanced_matrix (void) const + MT balanced_matrix () const { return m_balanced_mat; } - VT permuting_vector (void) const + VT permuting_vector () const { octave_idx_type n = m_balanced_mat.rows (); @@ -98,7 +98,7 @@ return pv; } - VT scaling_vector (void) const + VT scaling_vector () const { octave_idx_type n = m_balanced_mat.rows (); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/base-dae.h --- a/liboctave/numeric/base-dae.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/base-dae.h Tue Jan 24 17:19:44 2023 -0800 @@ -35,7 +35,7 @@ { public: - base_diff_alg_eqn (void) + base_diff_alg_eqn () : base_diff_eqn (), m_xdot () { } base_diff_alg_eqn (const ColumnVector& xx, double tt) @@ -48,7 +48,7 @@ base_diff_alg_eqn (const base_diff_alg_eqn& a) : base_diff_eqn (a), m_xdot (a.m_xdot) { } - virtual ~base_diff_alg_eqn (void) = default; + virtual ~base_diff_alg_eqn () = default; base_diff_alg_eqn& operator = (const base_diff_alg_eqn& a) { @@ -73,7 +73,7 @@ m_xdot = xdot0; } - ColumnVector state_derivative (void) { return m_xdot; } + ColumnVector state_derivative () { return m_xdot; } protected: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/base-de.h --- a/liboctave/numeric/base-de.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/base-de.h Tue Jan 24 17:19:44 2023 -0800 @@ -37,7 +37,7 @@ { public: - base_diff_eqn (void) + base_diff_eqn () : m_x (), m_t (0.0), m_stop_time (0.0), m_stop_time_set (false), m_restart (true), m_integration_error (false), m_istate (0) { } @@ -49,7 +49,7 @@ : m_x (a.m_x), m_t (a.m_t), m_stop_time (0.0), m_stop_time_set (false), m_restart (true), m_integration_error (false), m_istate (0) { } - virtual ~base_diff_eqn (void) = default; + virtual ~base_diff_eqn () = default; base_diff_eqn& operator = (const base_diff_eqn& a) { @@ -76,11 +76,11 @@ force_restart (); } - octave_idx_type size (void) const { return m_x.numel (); } + octave_idx_type size () const { return m_x.numel (); } - ColumnVector state (void) const { return m_x; } + ColumnVector state () const { return m_x; } - double time (void) const { return m_t; } + double time () const { return m_t; } void set_stop_time (double tt) { @@ -89,19 +89,19 @@ force_restart (); } - void clear_stop_time (void) + void clear_stop_time () { m_stop_time_set = false; force_restart (); } - virtual void force_restart (void) { m_restart = true; } + virtual void force_restart () { m_restart = true; } - bool integration_ok (void) const { return ! m_integration_error; } + bool integration_ok () const { return ! m_integration_error; } - octave_idx_type integration_state (void) const { return m_istate; } + octave_idx_type integration_state () const { return m_istate; } - virtual std::string error_message (void) const = 0; + virtual std::string error_message () const = 0; protected: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/chol.cc --- a/liboctave/numeric/chol.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/chol.cc Tue Jan 24 17:19:44 2023 -0800 @@ -247,7 +247,7 @@ // Compute the inverse of a matrix using the Cholesky factorization. template T -chol::inverse (void) const +chol::inverse () const { return chol2inv_internal (m_chol_mat, m_is_upper); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/chol.h --- a/liboctave/numeric/chol.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/chol.h Tue Jan 24 17:19:44 2023 -0800 @@ -41,7 +41,7 @@ typedef typename T::column_vector_type VT; typedef typename T::real_elt_type COND_T; - chol (void) : m_chol_mat (), m_rcond (0), m_is_upper (true) { } + chol () : m_chol_mat (), m_rcond (0), m_is_upper (true) { } chol (const T& a, bool upper = true, bool calc_cond = false) : m_chol_mat (), m_rcond (0) @@ -71,12 +71,12 @@ return *this; } - T chol_matrix (void) const { return m_chol_mat; } + T chol_matrix () const { return m_chol_mat; } - COND_T rcond (void) const { return m_rcond; } + COND_T rcond () const { return m_rcond; } // Compute the inverse of a matrix using the Cholesky factorization. - OCTAVE_API T inverse (void) const; + OCTAVE_API T inverse () const; OCTAVE_API void set (const T& R); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/eigs-base.cc --- a/liboctave/numeric/eigs-base.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/eigs-base.cc Tue Jan 24 17:19:44 2023 -0800 @@ -52,7 +52,7 @@ #if defined (HAVE_ARPACK) static void -warn_convergence (void) +warn_convergence () { (*current_liboctave_warning_with_id_handler) ("Octave:convergence", diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/fEIG.h --- a/liboctave/numeric/fEIG.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/fEIG.h Tue Jan 24 17:19:44 2023 -0800 @@ -44,7 +44,7 @@ public: - FloatEIG (void) : m_lambda (), m_v (), m_w () { } + FloatEIG () : m_lambda (), m_v (), m_w () { } FloatEIG (const FloatMatrix& a, bool calc_rev = true, bool calc_lev = true, bool balance = true) @@ -116,11 +116,11 @@ return *this; } - ~FloatEIG (void) = default; + ~FloatEIG () = default; - FloatComplexColumnVector eigenvalues (void) const { return m_lambda; } - FloatComplexMatrix right_eigenvectors (void) const { return m_v; } - FloatComplexMatrix left_eigenvectors (void) const { return m_w; } + FloatComplexColumnVector eigenvalues () const { return m_lambda; } + FloatComplexMatrix right_eigenvectors () const { return m_v; } + FloatComplexMatrix left_eigenvectors () const { return m_w; } friend std::ostream& operator << (std::ostream& os, const FloatEIG& a); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/gepbalance.h --- a/liboctave/numeric/gepbalance.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/gepbalance.h Tue Jan 24 17:19:44 2023 -0800 @@ -42,7 +42,7 @@ typedef typename T::real_matrix_type RT; - gepbalance (void) + gepbalance () : m_balanced_mat (), m_balanced_mat2 (), m_balancing_mat (), m_balancing_mat2 () { } @@ -74,15 +74,15 @@ return *this; } - ~gepbalance (void) = default; + ~gepbalance () = default; - T balanced_matrix (void) const { return m_balanced_mat; } + T balanced_matrix () const { return m_balanced_mat; } - T balanced_matrix2 (void) const { return m_balanced_mat2; } + T balanced_matrix2 () const { return m_balanced_mat2; } - RT balancing_matrix (void) const { return m_balancing_mat; } + RT balancing_matrix () const { return m_balancing_mat; } - RT balancing_matrix2 (void) const { return m_balancing_mat2; } + RT balancing_matrix2 () const { return m_balancing_mat2; } private: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/gsvd.cc --- a/liboctave/numeric/gsvd.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/gsvd.cc Tue Jan 24 17:19:44 2023 -0800 @@ -53,7 +53,7 @@ #define xSTRINGIZE(x) #x #define STRINGIZE(x) xSTRINGIZE(x) -static void initialize_gsvd (void) +static void initialize_gsvd () { if (gsvd_initialized) return; @@ -436,7 +436,7 @@ template T -gsvd::left_singular_matrix_A (void) const +gsvd::left_singular_matrix_A () const { if (m_type == gsvd::Type::sigma_only) (*current_liboctave_error_handler) @@ -447,7 +447,7 @@ template T -gsvd::left_singular_matrix_B (void) const +gsvd::left_singular_matrix_B () const { if (m_type == gsvd::Type::sigma_only) (*current_liboctave_error_handler) @@ -458,7 +458,7 @@ template T -gsvd::right_singular_matrix (void) const +gsvd::right_singular_matrix () const { if (m_type == gsvd::Type::sigma_only) (*current_liboctave_error_handler) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/gsvd.h --- a/liboctave/numeric/gsvd.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/gsvd.h Tue Jan 24 17:19:44 2023 -0800 @@ -46,7 +46,7 @@ sigma_only }; - gsvd (void) : m_sigmaA (), m_sigmaB (), m_left_smA (), m_left_smB (), m_right_sm () + gsvd () : m_sigmaA (), m_sigmaB (), m_left_smA (), m_left_smB (), m_right_sm () { } gsvd (const T& a, const T& b, @@ -73,18 +73,18 @@ return *this; } - ~gsvd (void) = default; + ~gsvd () = default; typename T::real_matrix_type - singular_values_A (void) const { return m_sigmaA; } + singular_values_A () const { return m_sigmaA; } typename T::real_matrix_type - singular_values_B (void) const { return m_sigmaB; } + singular_values_B () const { return m_sigmaB; } - T left_singular_matrix_A (void) const; - T left_singular_matrix_B (void) const; + T left_singular_matrix_A () const; + T left_singular_matrix_B () const; - T right_singular_matrix (void) const; + T right_singular_matrix () const; private: typedef typename T::value_type P; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/hess.h --- a/liboctave/numeric/hess.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/hess.h Tue Jan 24 17:19:44 2023 -0800 @@ -40,7 +40,7 @@ { public: - hess (void) + hess () : m_hess_mat (), m_unitary_hess_mat () { } @@ -71,11 +71,11 @@ return *this; } - ~hess (void) = default; + ~hess () = default; - T hess_matrix (void) const { return m_hess_mat; } + T hess_matrix () const { return m_hess_mat; } - T unitary_hess_matrix (void) const { return m_unitary_hess_mat; } + T unitary_hess_matrix () const { return m_unitary_hess_mat; } private: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/lu.cc --- a/liboctave/numeric/lu.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/lu.cc Tue Jan 24 17:19:44 2023 -0800 @@ -65,14 +65,14 @@ template bool -lu::packed (void) const +lu::packed () const { return m_L.dims () == dim_vector (); } template void -lu::unpack (void) +lu::unpack () { if (packed ()) { @@ -93,7 +93,7 @@ template T -lu::L (void) const +lu::L () const { if (packed ()) { @@ -120,7 +120,7 @@ template T -lu::U (void) const +lu::U () const { if (packed ()) { @@ -144,7 +144,7 @@ template T -lu::Y (void) const +lu::Y () const { if (! packed ()) (*current_liboctave_error_handler) @@ -155,7 +155,7 @@ template Array -lu::getp (void) const +lu::getp () const { if (packed ()) { @@ -186,14 +186,14 @@ template PermMatrix -lu::P (void) const +lu::P () const { return PermMatrix (getp (), false); } template ColumnVector -lu::P_vec (void) const +lu::P_vec () const { octave_idx_type a_nr = m_a_fact.rows (); @@ -209,7 +209,7 @@ template bool -lu::regular (void) const +lu::regular () const { bool retval = true; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/lu.h --- a/liboctave/numeric/lu.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/lu.h Tue Jan 24 17:19:44 2023 -0800 @@ -45,7 +45,7 @@ typedef typename T::column_vector_type VT; typedef typename T::element_type ELT_T; - lu (void) + lu () : m_a_fact (), m_L (), m_ipvt () { } OCTAVE_API lu (const T& a); @@ -67,23 +67,23 @@ return *this; } - virtual ~lu (void) = default; + virtual ~lu () = default; - OCTAVE_API bool packed (void) const; + OCTAVE_API bool packed () const; - OCTAVE_API void unpack (void); + OCTAVE_API void unpack (); - OCTAVE_API T L (void) const; + OCTAVE_API T L () const; - OCTAVE_API T U (void) const; + OCTAVE_API T U () const; - OCTAVE_API T Y (void) const; + OCTAVE_API T Y () const; - OCTAVE_API PermMatrix P (void) const; + OCTAVE_API PermMatrix P () const; - OCTAVE_API ColumnVector P_vec (void) const; + OCTAVE_API ColumnVector P_vec () const; - OCTAVE_API bool regular (void) const; + OCTAVE_API bool regular () const; OCTAVE_API void update (const VT& u, const VT& v); @@ -97,7 +97,7 @@ // The result of getp is passed to other Octave Matrix functions, // so we use octave_idx_type. - OCTAVE_API Array getp (void) const; + OCTAVE_API Array getp () const; T m_a_fact; T m_L; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/oct-fftw.cc --- a/liboctave/numeric/oct-fftw.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/oct-fftw.cc Tue Jan 24 17:19:44 2023 -0800 @@ -65,7 +65,7 @@ // Note that it is profitable to store the FFTW3 plans, for small FFTs. -fftw_planner::fftw_planner (void) +fftw_planner::fftw_planner () : m_meth (ESTIMATE), m_rplan (nullptr), m_rd (0), m_rs (0), m_rr (0), m_rh (0), m_rn (), m_rsimd_align (false), m_nthreads (1) { @@ -97,7 +97,7 @@ fftw_import_system_wisdom (); } -fftw_planner::~fftw_planner (void) +fftw_planner::~fftw_planner () { fftw_plan *plan_p; @@ -115,7 +115,7 @@ } bool -fftw_planner::instance_ok (void) +fftw_planner::instance_ok () { bool retval = true; @@ -395,7 +395,7 @@ } fftw_planner::FftwMethod -fftw_planner::do_method (void) +fftw_planner::do_method () { return m_meth; } @@ -427,7 +427,7 @@ float_fftw_planner *float_fftw_planner::s_instance = nullptr; -float_fftw_planner::float_fftw_planner (void) +float_fftw_planner::float_fftw_planner () : m_meth (ESTIMATE), m_rplan (nullptr), m_rd (0), m_rs (0), m_rr (0), m_rh (0), m_rn (), m_rsimd_align (false), m_nthreads (1) { @@ -454,7 +454,7 @@ fftwf_import_system_wisdom (); } -float_fftw_planner::~float_fftw_planner (void) +float_fftw_planner::~float_fftw_planner () { fftwf_plan *plan_p; @@ -472,7 +472,7 @@ } bool -float_fftw_planner::instance_ok (void) +float_fftw_planner::instance_ok () { bool retval = true; @@ -750,7 +750,7 @@ } float_fftw_planner::FftwMethod -float_fftw_planner::do_method (void) +float_fftw_planner::do_method () { return m_meth; } @@ -1135,7 +1135,7 @@ #endif std::string -fftw_version (void) +fftw_version () { #if defined (HAVE_FFTW) return ::fftw_version; @@ -1145,7 +1145,7 @@ } std::string -fftwf_version (void) +fftwf_version () { #if defined (HAVE_FFTW) return ::fftwf_version; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/oct-fftw.h --- a/liboctave/numeric/oct-fftw.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/oct-fftw.h Tue Jan 24 17:19:44 2023 -0800 @@ -43,7 +43,7 @@ { protected: - fftw_planner (void); + fftw_planner (); public: @@ -53,7 +53,7 @@ fftw_planner& operator = (const fftw_planner&) = delete; - ~fftw_planner (void); + ~fftw_planner (); enum FftwMethod { @@ -65,7 +65,7 @@ HYBRID }; - static bool instance_ok (void); + static bool instance_ok (); static void * create_plan (int dir, const int rank, const dim_vector& dims, @@ -90,7 +90,7 @@ : nullptr; } - static FftwMethod method (void) + static FftwMethod method () { static FftwMethod dummy; @@ -106,7 +106,7 @@ static void threads (int nt); - static int threads (void) + static int threads () { return instance_ok () ? s_instance->m_nthreads : 0; } @@ -115,7 +115,7 @@ static fftw_planner *s_instance; - static void cleanup_instance (void) + static void cleanup_instance () { delete s_instance; s_instance = nullptr; } void * @@ -129,7 +129,7 @@ octave_idx_type howmany, octave_idx_type stride, octave_idx_type dist, const double *in, Complex *out); - FftwMethod do_method (void); + FftwMethod do_method (); FftwMethod do_method (FftwMethod meth); @@ -189,7 +189,7 @@ { protected: - float_fftw_planner (void); + float_fftw_planner (); public: @@ -200,7 +200,7 @@ float_fftw_planner& operator = (const float_fftw_planner&) = delete; - ~float_fftw_planner (void); + ~float_fftw_planner (); enum FftwMethod { @@ -212,7 +212,7 @@ HYBRID }; - static bool instance_ok (void); + static bool instance_ok (); static void * create_plan (int dir, const int rank, const dim_vector& dims, @@ -237,7 +237,7 @@ : nullptr; } - static FftwMethod method (void) + static FftwMethod method () { static FftwMethod dummy; @@ -253,7 +253,7 @@ static void threads (int nt); - static int threads (void) + static int threads () { return instance_ok () ? s_instance->m_nthreads : 0; } @@ -262,7 +262,7 @@ static float_fftw_planner *s_instance; - static void cleanup_instance (void) + static void cleanup_instance () { delete s_instance; s_instance = nullptr; } void * @@ -276,7 +276,7 @@ octave_idx_type howmany, octave_idx_type stride, octave_idx_type dist, const float *in, FloatComplex *out); - FftwMethod do_method (void); + FftwMethod do_method (); FftwMethod do_method (FftwMethod meth); @@ -336,7 +336,7 @@ { public: - fftw (void) = delete; + fftw () = delete; // No copying. @@ -378,8 +378,8 @@ const dim_vector&); }; -extern OCTAVE_API std::string fftw_version (void); -extern OCTAVE_API std::string fftwf_version (void); +extern OCTAVE_API std::string fftw_version (); +extern OCTAVE_API std::string fftwf_version (); OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/oct-rand.cc --- a/liboctave/numeric/oct-rand.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/oct-rand.cc Tue Jan 24 17:19:44 2023 -0800 @@ -50,7 +50,7 @@ rand *rand::m_instance = nullptr; -rand::rand (void) +rand::rand () : m_current_distribution (uniform_dist), m_use_old_generators (false), m_rand_states () { @@ -59,7 +59,7 @@ initialize_mersenne_twister (); } -bool rand::instance_ok (void) +bool rand::instance_ok () { bool retval = true; @@ -72,7 +72,7 @@ return retval; } -double rand::do_seed (void) +double rand::do_seed () { union d2i { double d; int32_t i[2]; }; union d2i u; @@ -135,7 +135,7 @@ F77_FUNC (setsd, SETSD) (i0, i1); } -void rand::do_reset (void) +void rand::do_reset () { m_use_old_generators = true; initialize_ranlib_generators (); @@ -187,7 +187,7 @@ m_rand_states[old_dist] = saved_state; } -std::string rand::do_distribution (void) +std::string rand::do_distribution () { std::string retval; @@ -255,35 +255,35 @@ } } -void rand::do_uniform_distribution (void) +void rand::do_uniform_distribution () { switch_to_generator (uniform_dist); F77_FUNC (setcgn, SETCGN) (uniform_dist); } -void rand::do_normal_distribution (void) +void rand::do_normal_distribution () { switch_to_generator (normal_dist); F77_FUNC (setcgn, SETCGN) (normal_dist); } -void rand::do_exponential_distribution (void) +void rand::do_exponential_distribution () { switch_to_generator (expon_dist); F77_FUNC (setcgn, SETCGN) (expon_dist); } -void rand::do_poisson_distribution (void) +void rand::do_poisson_distribution () { switch_to_generator (poisson_dist); F77_FUNC (setcgn, SETCGN) (poisson_dist); } -void rand::do_gamma_distribution (void) +void rand::do_gamma_distribution () { switch_to_generator (gamma_dist); @@ -291,7 +291,7 @@ } template <> -OCTAVE_API double rand::uniform (void) +OCTAVE_API double rand::uniform () { double retval; @@ -304,7 +304,7 @@ } template <> -OCTAVE_API double rand::normal (void) +OCTAVE_API double rand::normal () { double retval; @@ -317,7 +317,7 @@ } template <> -OCTAVE_API double rand::exponential (void) +OCTAVE_API double rand::exponential () { double retval; @@ -370,7 +370,7 @@ } template <> -OCTAVE_API float rand::uniform (void) +OCTAVE_API float rand::uniform () { float retval; @@ -383,7 +383,7 @@ } template <> -OCTAVE_API float rand::normal (void) +OCTAVE_API float rand::normal () { float retval; @@ -396,7 +396,7 @@ } template <> -OCTAVE_API float rand::exponential (void) +OCTAVE_API float rand::exponential () { float retval; @@ -549,7 +549,7 @@ // technique used below will cycle monthly, but it does seem to // work ok to give fairly different seeds each time Octave starts. -void rand::initialize_ranlib_generators (void) +void rand::initialize_ranlib_generators () { sys::localtime tm; int stored_distribution = m_current_distribution; @@ -569,7 +569,7 @@ F77_FUNC (setcgn, SETCGN) (stored_distribution); } -void rand::initialize_mersenne_twister (void) +void rand::initialize_mersenne_twister () { uint32NDArray s; @@ -598,7 +598,7 @@ set_internal_state (m_rand_states[m_current_distribution]); } -uint32NDArray rand::get_internal_state (void) +uint32NDArray rand::get_internal_state () { uint32NDArray s (dim_vector (MT_N + 1, 1)); @@ -607,7 +607,7 @@ return s; } -void rand::save_state (void) +void rand::save_state () { m_rand_states[m_current_distribution] = get_internal_state ();; } @@ -664,21 +664,21 @@ { case uniform_dist: if (m_use_old_generators) - std::generate_n (v, len, [](void) { double x; F77_FUNC (dgenunf, DGENUNF) (0.0, 1.0, x); return x; }); + std::generate_n (v, len, []() { double x; F77_FUNC (dgenunf, DGENUNF) (0.0, 1.0, x); return x; }); else rand_uniform (len, v); break; case normal_dist: if (m_use_old_generators) - std::generate_n (v, len, [](void) { double x; F77_FUNC (dgennor, DGENNOR) (0.0, 1.0, x); return x; }); + std::generate_n (v, len, []() { double x; F77_FUNC (dgennor, DGENNOR) (0.0, 1.0, x); return x; }); else rand_normal (len, v); break; case expon_dist: if (m_use_old_generators) - std::generate_n (v, len, [](void) { double x; F77_FUNC (dgenexp, DGENEXP) (1.0, x); return x; }); + std::generate_n (v, len, []() { double x; F77_FUNC (dgenexp, DGENEXP) (1.0, x); return x; }); else rand_exponential (len, v); break; @@ -693,7 +693,7 @@ // workaround bug in ignpoi, by calling with different Mu double tmp; F77_FUNC (dignpoi, DIGNPOI) (a + 1, tmp); - std::generate_n (v, len, [a](void) { double x; F77_FUNC (dignpoi, DIGNPOI) (a, x); return x; }); + std::generate_n (v, len, [a]() { double x; F77_FUNC (dignpoi, DIGNPOI) (a, x); return x; }); } } else @@ -706,7 +706,7 @@ if (a <= 0.0 || ! math::isfinite (a)) std::fill_n (v, len, numeric_limits::NaN ()); else - std::generate_n (v, len, [a](void) { double x; F77_FUNC (dgengam, DGENGAM) (1.0, a, x); return x; }); + std::generate_n (v, len, [a]() { double x; F77_FUNC (dgengam, DGENGAM) (1.0, a, x); return x; }); } else rand_gamma (a, len, v); @@ -732,21 +732,21 @@ { case uniform_dist: if (m_use_old_generators) - std::generate_n (v, len, [](void) { float x; F77_FUNC (fgenunf, FGENUNF) (0.0f, 1.0f, x); return x; }); + std::generate_n (v, len, []() { float x; F77_FUNC (fgenunf, FGENUNF) (0.0f, 1.0f, x); return x; }); else rand_uniform (len, v); break; case normal_dist: if (m_use_old_generators) - std::generate_n (v, len, [](void) { float x; F77_FUNC (fgennor, FGENNOR) (0.0f, 1.0f, x); return x; }); + std::generate_n (v, len, []() { float x; F77_FUNC (fgennor, FGENNOR) (0.0f, 1.0f, x); return x; }); else rand_normal (len, v); break; case expon_dist: if (m_use_old_generators) - std::generate_n (v, len, [](void) { float x; F77_FUNC (fgenexp, FGENEXP) (1.0f, x); return x; }); + std::generate_n (v, len, []() { float x; F77_FUNC (fgenexp, FGENEXP) (1.0f, x); return x; }); else rand_exponential (len, v); break; @@ -761,7 +761,7 @@ // workaround bug in ignpoi, by calling with different Mu float tmp; F77_FUNC (fignpoi, FIGNPOI) (a + 1, tmp); - std::generate_n (v, len, [a](void) { float x; F77_FUNC (fignpoi, FIGNPOI) (a, x); return x; }); + std::generate_n (v, len, [a]() { float x; F77_FUNC (fignpoi, FIGNPOI) (a, x); return x; }); } } else @@ -774,7 +774,7 @@ if (a <= 0.0f || ! math::isfinite (a)) std::fill_n (v, len, numeric_limits::NaN ()); else - std::generate_n (v, len, [a](void) { float x; F77_FUNC (fgengam, FGENGAM) (1.0f, a, x); return x; }); + std::generate_n (v, len, [a]() { float x; F77_FUNC (fgengam, FGENGAM) (1.0f, a, x); return x; }); } else rand_gamma (a, len, v); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/oct-rand.h --- a/liboctave/numeric/oct-rand.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/oct-rand.h Tue Jan 24 17:19:44 2023 -0800 @@ -45,16 +45,16 @@ { protected: - OCTAVE_API rand (void); + OCTAVE_API rand (); public: - ~rand (void) = default; + ~rand () = default; - static bool instance_ok (void); + static bool instance_ok (); // Return the current seed. - static double seed (void) + static double seed () { return (instance_ok () ? m_instance->do_seed () : numeric_limits::NaN ()); @@ -68,7 +68,7 @@ } // Reset the seed. - static void reset (void) + static void reset () { if (instance_ok ()) m_instance->do_reset (); @@ -96,7 +96,7 @@ } // Return the current distribution. - static std::string distribution (void) + static std::string distribution () { return instance_ok () ? m_instance->do_distribution () : ""; } @@ -109,31 +109,31 @@ m_instance->do_distribution (d); } - static void uniform_distribution (void) + static void uniform_distribution () { if (instance_ok ()) m_instance->do_uniform_distribution (); } - static void normal_distribution (void) + static void normal_distribution () { if (instance_ok ()) m_instance->do_normal_distribution (); } - static void exponential_distribution (void) + static void exponential_distribution () { if (instance_ok ()) m_instance->do_exponential_distribution (); } - static void poisson_distribution (void) + static void poisson_distribution () { if (instance_ok ()) m_instance->do_poisson_distribution (); } - static void gamma_distribution (void) + static void gamma_distribution () { if (instance_ok ()) m_instance->do_gamma_distribution (); @@ -184,7 +184,7 @@ static rand *m_instance; - static void cleanup_instance (void) + static void cleanup_instance () { delete m_instance; m_instance = nullptr; } enum @@ -208,7 +208,7 @@ std::map m_rand_states; // Return the current seed. - OCTAVE_API double do_seed (void); + OCTAVE_API double do_seed (); // Set the seed. OCTAVE_API void do_seed (double s); @@ -226,30 +226,30 @@ OCTAVE_API void do_reset (const std::string& d); // Return the current distribution. - OCTAVE_API std::string do_distribution (void); + OCTAVE_API std::string do_distribution (); // Set the current distribution. May be either "uniform" (the // default), "normal", "exponential", "poisson", or "gamma". OCTAVE_API void do_distribution (const std::string& d); - OCTAVE_API void do_uniform_distribution (void); + OCTAVE_API void do_uniform_distribution (); - OCTAVE_API void do_normal_distribution (void); + OCTAVE_API void do_normal_distribution (); - OCTAVE_API void do_exponential_distribution (void); + OCTAVE_API void do_exponential_distribution (); - OCTAVE_API void do_poisson_distribution (void); + OCTAVE_API void do_poisson_distribution (); - OCTAVE_API void do_gamma_distribution (void); + OCTAVE_API void do_gamma_distribution (); // The following templates only make sense for double and float // types. - template OCTAVE_API T uniform (void); + template OCTAVE_API T uniform (); - template OCTAVE_API T normal (void); + template OCTAVE_API T normal (); - template OCTAVE_API T exponential (void); + template OCTAVE_API T exponential (); template OCTAVE_API T poisson (T a); @@ -273,13 +273,13 @@ // Some helper functions. - OCTAVE_API void initialize_ranlib_generators (void); + OCTAVE_API void initialize_ranlib_generators (); - OCTAVE_API void initialize_mersenne_twister (void); + OCTAVE_API void initialize_mersenne_twister (); - OCTAVE_API uint32NDArray get_internal_state (void); + OCTAVE_API uint32NDArray get_internal_state (); - OCTAVE_API void save_state (void); + OCTAVE_API void save_state (); OCTAVE_API int get_dist_id (const std::string& d); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/oct-spparms.cc --- a/liboctave/numeric/oct-spparms.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/oct-spparms.cc Tue Jan 24 17:19:44 2023 -0800 @@ -39,7 +39,7 @@ sparse_params *sparse_params::s_instance = nullptr; -bool sparse_params::instance_ok (void) +bool sparse_params::instance_ok () { bool retval = true; @@ -52,24 +52,24 @@ return retval; } -void sparse_params::defaults (void) +void sparse_params::defaults () { if (instance_ok ()) s_instance->do_defaults (); } -void sparse_params::tight (void) +void sparse_params::tight () { if (instance_ok ()) s_instance->do_tight (); } -string_vector sparse_params::get_keys (void) +string_vector sparse_params::get_keys () { return instance_ok () ? s_instance->do_get_keys () : string_vector (); } -ColumnVector sparse_params::get_vals (void) +ColumnVector sparse_params::get_vals () { return instance_ok () ? s_instance->do_get_vals () : ColumnVector (); } @@ -90,7 +90,7 @@ ? s_instance->do_get_key (key) : numeric_limits::NaN ()); } -double sparse_params::get_bandden (void) +double sparse_params::get_bandden () { return instance_ok () ? s_instance->do_get_bandden () : 0.0; } @@ -101,7 +101,7 @@ s_instance->do_print_info (os, prefix); } -void sparse_params::do_defaults (void) +void sparse_params::do_defaults () { m_params(0) = 0; // spumoni m_params(1) = 1; // ths_rel @@ -118,7 +118,7 @@ m_params(12) = 0.001; // sym_tol } -void sparse_params::do_tight (void) +void sparse_params::do_tight () { m_params(0) = 0; // spumoni m_params(1) = 1; // ths_rel @@ -135,7 +135,7 @@ m_params(12) = 0.001; // sym_tol } -void sparse_params::init_keys (void) +void sparse_params::init_keys () { m_keys(0) = "spumoni"; m_keys(1) = "ths_rel"; @@ -152,7 +152,7 @@ m_keys(12) = "sym_tol"; } -double sparse_params::do_get_bandden (void) +double sparse_params::do_get_bandden () { return m_params(10); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/oct-spparms.h --- a/liboctave/numeric/oct-spparms.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/oct-spparms.h Tue Jan 24 17:19:44 2023 -0800 @@ -43,7 +43,7 @@ { protected: - sparse_params (void) + sparse_params () : m_params (OCTAVE_SPARSE_CONTROLS_SIZE), m_keys (OCTAVE_SPARSE_CONTROLS_SIZE) { @@ -57,17 +57,17 @@ sparse_params& operator = (const sparse_params&) = default; - ~sparse_params (void) = default; + ~sparse_params () = default; - static bool instance_ok (void); + static bool instance_ok (); - static void defaults (void); + static void defaults (); - static void tight (void); + static void tight (); - static string_vector get_keys (void); + static string_vector get_keys (); - static ColumnVector get_vals (void); + static ColumnVector get_vals (); static bool set_vals (const Array& vals); @@ -75,7 +75,7 @@ static double get_key (const std::string& key); - static double get_bandden (void); + static double get_bandden (); static void print_info (std::ostream& os, const std::string& prefix); @@ -87,19 +87,19 @@ static sparse_params *s_instance; - static void cleanup_instance (void) + static void cleanup_instance () { delete s_instance; s_instance = nullptr; } - void do_defaults (void); + void do_defaults (); - void do_tight (void); + void do_tight (); - string_vector do_get_keys (void) const { return m_keys; } + string_vector do_get_keys () const { return m_keys; } - ColumnVector do_get_vals (void) const { return m_params; } + ColumnVector do_get_vals () const { return m_params; } bool do_set_vals (const Array& vals); @@ -107,11 +107,11 @@ double do_get_key (const std::string& key); - double do_get_bandden (void); + double do_get_bandden (); void do_print_info (std::ostream& os, const std::string& prefix) const; - void init_keys (void); + void init_keys (); }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/qr.cc --- a/liboctave/numeric/qr.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/qr.cc Tue Jan 24 17:19:44 2023 -0800 @@ -70,7 +70,7 @@ template typename qr::type -qr::get_type (void) const +qr::get_type () const { type retval; @@ -86,7 +86,7 @@ template bool -qr::regular (void) const +qr::regular () const { bool retval = true; @@ -109,7 +109,7 @@ // Replacement update methods. void -warn_qrupdate_once (void) +warn_qrupdate_once () { static bool warned = false; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/qr.h --- a/liboctave/numeric/qr.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/qr.h Tue Jan 24 17:19:44 2023 -0800 @@ -51,7 +51,7 @@ economy }; - qr (void) : m_q (), m_r () { } + qr () : m_q (), m_r () { } qr (const T& a, type qr_type = qr::std) : m_q (), m_r () @@ -74,15 +74,15 @@ return *this; } - virtual ~qr (void) = default; + virtual ~qr () = default; - T Q (void) const { return m_q; } + T Q () const { return m_q; } - T R (void) const { return m_r; } + T R () const { return m_r; } - OCTAVE_API type get_type (void) const; + OCTAVE_API type get_type () const; - OCTAVE_API bool regular (void) const; + OCTAVE_API bool regular () const; OCTAVE_API void init (const T& a, type qr_type); @@ -113,7 +113,7 @@ form (octave_idx_type n, T& afact, ELT_T *tau, type qr_type); }; -extern OCTAVE_API void warn_qrupdate_once (void); +extern OCTAVE_API void warn_qrupdate_once (); OCTAVE_END_NAMESPACE(math) OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/qrp.cc --- a/liboctave/numeric/qrp.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/qrp.cc Tue Jan 24 17:19:44 2023 -0800 @@ -113,7 +113,7 @@ template <> OCTAVE_API RowVector -qrp::Pvec (void) const +qrp::Pvec () const { Array pa (m_p.col_perm_vec ()); RowVector pv (MArray (pa) + 1.0); @@ -184,7 +184,7 @@ template <> OCTAVE_API FloatRowVector -qrp::Pvec (void) const +qrp::Pvec () const { Array pa (m_p.col_perm_vec ()); FloatRowVector pv (MArray (pa) + 1.0f); @@ -263,7 +263,7 @@ template <> OCTAVE_API RowVector -qrp::Pvec (void) const +qrp::Pvec () const { Array pa (m_p.col_perm_vec ()); RowVector pv (MArray (pa) + 1.0); @@ -342,7 +342,7 @@ template <> OCTAVE_API FloatRowVector -qrp::Pvec (void) const +qrp::Pvec () const { Array pa (m_p.col_perm_vec ()); FloatRowVector pv (MArray (pa) + 1.0f); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/qrp.h --- a/liboctave/numeric/qrp.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/qrp.h Tue Jan 24 17:19:44 2023 -0800 @@ -45,7 +45,7 @@ typedef typename qr::type type; - qrp (void) : qr (), m_p () { } + qrp () : qr (), m_p () { } OCTAVE_API qrp (const T&, type = qr::std); @@ -62,13 +62,13 @@ return *this; } - ~qrp (void) = default; + ~qrp () = default; OCTAVE_API void init (const T&, type = qr::std); - PermMatrix P (void) const { return m_p; } + PermMatrix P () const { return m_p; } - OCTAVE_API RV_T Pvec (void) const; + OCTAVE_API RV_T Pvec () const; private: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/randmtzig.cc --- a/liboctave/numeric/randmtzig.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/randmtzig.cc Tue Jan 24 17:19:44 2023 -0800 @@ -121,7 +121,7 @@ === Mersenne Twister === random initial state: - void init_mersenne_twister (void) + void init_mersenne_twister () // 32-bit initial state: void init_mersenne_twister (uint32_t s) @@ -135,18 +135,18 @@ // restores state from array void set_mersenne_twister_state (uint32_t save[MT_N+1]) - static uint32_t randmt (void) returns 32-bit unsigned int + static uint32_t randmt () returns 32-bit unsigned int === inline generators === - static uint32_t randi32 (void) returns 32-bit unsigned int - static uint64_t randi53 (void) returns 53-bit unsigned int - static uint64_t randi54 (void) returns 54-bit unsigned int - static float randu24 (void) returns 24-bit uniform in (0,1) - static double randu53 (void) returns 53-bit uniform in (0,1) + static uint32_t randi32 () returns 32-bit unsigned int + static uint64_t randi53 () returns 53-bit unsigned int + static uint64_t randi54 () returns 54-bit unsigned int + static float randu24 () returns 24-bit uniform in (0,1) + static double randu53 () returns 53-bit uniform in (0,1) - double rand_uniform (void) returns M-bit uniform in (0,1) - double rand_normal (void) returns M-bit standard normal - double rand_exponential (void) returns N-bit standard exponential + double rand_uniform () returns M-bit uniform in (0,1) + double rand_normal () returns M-bit standard normal + double rand_exponential () returns N-bit standard exponential === Array generators === void rand_uniform (octave_idx_type, double []) @@ -257,7 +257,7 @@ initf = 1; } -void init_mersenne_twister (void) +void init_mersenne_twister () { uint32_t entropy[MT_N]; int n = 0; @@ -321,7 +321,7 @@ save[MT_N] = left; } -static void next_state (void) +static void next_state () { uint32_t *p = state; int j; @@ -346,7 +346,7 @@ } /* generates a random number on [0,0xffffffff]-interval */ -static uint32_t randmt (void) +static uint32_t randmt () { uint32_t y; @@ -366,7 +366,7 @@ /* Select which 32 bit generator to use */ #define randi32 randmt -static uint64_t randi53 (void) +static uint64_t randi53 () { const uint32_t lo = randi32 (); const uint32_t hi = randi32 () & 0x1FFFFF; @@ -381,7 +381,7 @@ #endif } -static uint64_t randi54 (void) +static uint64_t randi54 () { const uint32_t lo = randi32 (); const uint32_t hi = randi32 () & 0x3FFFFF; @@ -397,7 +397,7 @@ } /* generates a random number on (0,1)-real-interval */ -static float randu24 (void) +static float randu24 () { uint32_t i; @@ -411,7 +411,7 @@ } /* generates a random number on (0,1) with 53-bit resolution */ -static double randu53 (void) +static double randu53 () { int32_t a, b; @@ -428,7 +428,7 @@ /* Determine mantissa for uniform doubles */ template <> OCTAVE_API double -rand_uniform (void) +rand_uniform () { return randu53 (); } @@ -436,7 +436,7 @@ /* Determine mantissa for uniform floats */ template <> OCTAVE_API float -rand_uniform (void) +rand_uniform () { return randu24 (); } @@ -503,7 +503,7 @@ so I'm not going to try and optimize further. */ -void create_ziggurat_tables (void) +void create_ziggurat_tables () { int i; double x, x1; @@ -582,7 +582,7 @@ */ -template <> OCTAVE_API double rand_normal (void) +template <> OCTAVE_API double rand_normal () { if (initt) create_ziggurat_tables (); @@ -646,7 +646,7 @@ } } -template <> OCTAVE_API double rand_exponential (void) +template <> OCTAVE_API double rand_exponential () { if (initt) create_ziggurat_tables (); @@ -674,17 +674,17 @@ template <> OCTAVE_API void rand_uniform (octave_idx_type n, double *p) { - std::generate_n (p, n, [](void) { return rand_uniform (); }); + std::generate_n (p, n, []() { return rand_uniform (); }); } template <> OCTAVE_API void rand_normal (octave_idx_type n, double *p) { - std::generate_n (p, n, [](void) { return rand_normal (); }); + std::generate_n (p, n, []() { return rand_normal (); }); } template <> OCTAVE_API void rand_exponential (octave_idx_type n, double *p) { - std::generate_n (p, n, [](void) { return rand_exponential (); }); + std::generate_n (p, n, []() { return rand_exponential (); }); } #undef ZIGINT @@ -706,7 +706,7 @@ static ZIGINT fke[ZIGGURAT_TABLE_SIZE]; static float fwe[ZIGGURAT_TABLE_SIZE], ffe[ZIGGURAT_TABLE_SIZE]; -static void create_ziggurat_float_tables (void) +static void create_ziggurat_float_tables () { int i; float x, x1; @@ -784,7 +784,7 @@ * distribution is exp(-0.5*x*x) */ -template <> OCTAVE_API float rand_normal (void) +template <> OCTAVE_API float rand_normal () { if (inittf) create_ziggurat_float_tables (); @@ -824,7 +824,7 @@ } } -template <> OCTAVE_API float rand_exponential (void) +template <> OCTAVE_API float rand_exponential () { if (inittf) create_ziggurat_float_tables (); @@ -852,17 +852,17 @@ template <> OCTAVE_API void rand_uniform (octave_idx_type n, float *p) { - std::generate_n (p, n, [](void) { return rand_uniform (); }); + std::generate_n (p, n, []() { return rand_uniform (); }); } template <> OCTAVE_API void rand_normal (octave_idx_type n, float *p) { - std::generate_n (p, n, [](void) { return rand_normal (); }); + std::generate_n (p, n, []() { return rand_normal (); }); } template <> OCTAVE_API void rand_exponential (octave_idx_type n, float *p) { - std::generate_n (p, n, [](void) { return rand_exponential (); }); + std::generate_n (p, n, []() { return rand_exponential (); }); } OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/randmtzig.h --- a/liboctave/numeric/randmtzig.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/randmtzig.h Tue Jan 24 17:19:44 2023 -0800 @@ -75,7 +75,7 @@ // Mersenne Twister. -extern OCTAVE_API void init_mersenne_twister (void); +extern OCTAVE_API void init_mersenne_twister (); extern OCTAVE_API void init_mersenne_twister (const uint32_t seed); extern OCTAVE_API void init_mersenne_twister (const uint32_t *init_key, const int key_length); @@ -83,22 +83,22 @@ extern OCTAVE_API void set_mersenne_twister_state (const uint32_t *save); extern OCTAVE_API void get_mersenne_twister_state (uint32_t *save); -template OCTAVE_API T rand_uniform (void); -template OCTAVE_API T rand_normal (void); -template OCTAVE_API T rand_exponential (void); +template OCTAVE_API T rand_uniform (); +template OCTAVE_API T rand_normal (); +template OCTAVE_API T rand_exponential (); template OCTAVE_API void rand_uniform (octave_idx_type n, T *p); template OCTAVE_API void rand_normal (octave_idx_type n, T *p); template OCTAVE_API void rand_exponential (octave_idx_type n, T *p); -template <> OCTAVE_API double rand_uniform (void); -template <> OCTAVE_API double rand_normal (void); -template <> OCTAVE_API double rand_exponential (void); +template <> OCTAVE_API double rand_uniform (); +template <> OCTAVE_API double rand_normal (); +template <> OCTAVE_API double rand_exponential (); -template <> OCTAVE_API float rand_uniform (void); -template <> OCTAVE_API float rand_normal (void); -template <> OCTAVE_API float rand_exponential (void); +template <> OCTAVE_API float rand_uniform (); +template <> OCTAVE_API float rand_normal (); +template <> OCTAVE_API float rand_exponential (); template <> OCTAVE_API void rand_uniform (octave_idx_type n, double *p); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/schur.h --- a/liboctave/numeric/schur.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/schur.h Tue Jan 24 17:19:44 2023 -0800 @@ -47,7 +47,7 @@ { public: - schur (void) : m_schur_mat (), m_unitary_schur_mat () { } + schur () : m_schur_mat (), m_unitary_schur_mat () { } schur (const T& a, const std::string& ord, bool calc_unitary = true) : m_schur_mat (), m_unitary_schur_mat () @@ -84,11 +84,11 @@ return *this; } - ~schur (void) = default; + ~schur () = default; - T schur_matrix (void) const { return m_schur_mat; } + T schur_matrix () const { return m_schur_mat; } - T unitary_schur_matrix (void) const { return m_unitary_schur_mat; } + T unitary_schur_matrix () const { return m_unitary_schur_mat; } protected: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/sparse-chol.cc --- a/liboctave/numeric/sparse-chol.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/sparse-chol.cc Tue Jan 24 17:19:44 2023 -0800 @@ -50,7 +50,7 @@ { public: - sparse_chol_rep (void) + sparse_chol_rep () : m_is_pd (false), m_minor_p (0), m_perm (), m_rcond (0) #if defined (HAVE_CHOLMOD) , m_L (nullptr), m_common () @@ -82,7 +82,7 @@ sparse_chol_rep& operator = (const sparse_chol_rep&) = delete; - ~sparse_chol_rep (void) + ~sparse_chol_rep () { #if defined (HAVE_CHOLMOD) if (m_L) @@ -93,13 +93,13 @@ } #if defined (HAVE_CHOLMOD) - cholmod_sparse * L (void) const + cholmod_sparse * L () const { return m_L; } #endif - octave_idx_type P (void) const + octave_idx_type P () const { #if defined (HAVE_CHOLMOD) return (m_minor_p == static_cast (m_L->ncol) ? @@ -109,13 +109,13 @@ #endif } - RowVector perm (void) const { return m_perm + 1; } + RowVector perm () const { return m_perm + 1; } - SparseMatrix Q (void) const; + SparseMatrix Q () const; - bool is_positive_definite (void) const { return m_is_pd; } + bool is_positive_definite () const { return m_is_pd; } - double rcond (void) const { return m_rcond; } + double rcond () const { return m_rcond; } private: @@ -186,18 +186,18 @@ // Must provide a specialization for this function. template int -get_xtype (void); +get_xtype (); template <> inline int -get_xtype (void) +get_xtype () { return CHOLMOD_REAL; } template <> inline int -get_xtype (void) +get_xtype () { return CHOLMOD_COMPLEX; } @@ -352,7 +352,7 @@ template SparseMatrix -sparse_chol::sparse_chol_rep::Q (void) const +sparse_chol::sparse_chol_rep::Q () const { #if defined (HAVE_CHOLMOD) @@ -378,7 +378,7 @@ } template -sparse_chol::sparse_chol (void) +sparse_chol::sparse_chol () : m_rep (new typename sparse_chol::sparse_chol_rep ()) { } @@ -414,7 +414,7 @@ template chol_type -sparse_chol::L (void) const +sparse_chol::L () const { #if defined (HAVE_CHOLMOD) @@ -445,42 +445,42 @@ template octave_idx_type -sparse_chol::P (void) const +sparse_chol::P () const { return m_rep->P (); } template RowVector -sparse_chol::perm (void) const +sparse_chol::perm () const { return m_rep->perm (); } template SparseMatrix -sparse_chol::Q (void) const +sparse_chol::Q () const { return m_rep->Q (); } template bool -sparse_chol::is_positive_definite (void) const +sparse_chol::is_positive_definite () const { return m_rep->is_positive_definite (); } template double -sparse_chol::rcond (void) const +sparse_chol::rcond () const { return m_rep->rcond (); } template chol_type -sparse_chol::inverse (void) const +sparse_chol::inverse () const { chol_type retval; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/sparse-chol.h --- a/liboctave/numeric/sparse-chol.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/sparse-chol.h Tue Jan 24 17:19:44 2023 -0800 @@ -50,7 +50,7 @@ { public: - sparse_chol (void); + sparse_chol (); sparse_chol (const chol_type& a, bool natural, bool force); @@ -63,26 +63,26 @@ sparse_chol (const sparse_chol& a) = default; - virtual ~sparse_chol (void) = default; + virtual ~sparse_chol () = default; sparse_chol& operator = (const sparse_chol& a) = default; - chol_type L (void) const; + chol_type L () const; - chol_type R (void) const { return L ().hermitian (); } + chol_type R () const { return L ().hermitian (); } - octave_idx_type P (void) const; + octave_idx_type P () const; - RowVector perm (void) const; + RowVector perm () const; - SparseMatrix Q (void) const; + SparseMatrix Q () const; - bool is_positive_definite (void) const; + bool is_positive_definite () const; - double rcond (void) const; + double rcond () const; - chol_type inverse (void) const; + chol_type inverse () const; protected: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/sparse-lu.cc --- a/liboctave/numeric/sparse-lu.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/sparse-lu.cc Tue Jan 24 17:19:44 2023 -0800 @@ -863,7 +863,7 @@ template lu_type -sparse_lu::Y (void) const +sparse_lu::Y () const { octave_idx_type nr = m_L.rows (); octave_idx_type nz = m_L.cols (); @@ -900,7 +900,7 @@ template SparseMatrix -sparse_lu::Pr (void) const +sparse_lu::Pr () const { octave_idx_type nr = m_L.rows (); @@ -920,7 +920,7 @@ template ColumnVector -sparse_lu::Pr_vec (void) const +sparse_lu::Pr_vec () const { octave_idx_type nr = m_L.rows (); @@ -934,14 +934,14 @@ template PermMatrix -sparse_lu::Pr_mat (void) const +sparse_lu::Pr_mat () const { return PermMatrix (m_P, false); } template SparseMatrix -sparse_lu::Pc (void) const +sparse_lu::Pc () const { octave_idx_type nc = m_U.cols (); @@ -961,7 +961,7 @@ template ColumnVector -sparse_lu::Pc_vec (void) const +sparse_lu::Pc_vec () const { octave_idx_type nc = m_U.cols (); @@ -975,7 +975,7 @@ template PermMatrix -sparse_lu::Pc_mat (void) const +sparse_lu::Pc_mat () const { return PermMatrix (m_Q, true); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/sparse-lu.h --- a/liboctave/numeric/sparse-lu.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/sparse-lu.h Tue Jan 24 17:19:44 2023 -0800 @@ -52,7 +52,7 @@ typedef typename lu_type::element_type lu_elt_type; - sparse_lu (void) + sparse_lu () : m_L (), m_U (), m_R (), m_cond (0), m_P (), m_Q () { } OCTAVE_API @@ -84,33 +84,33 @@ return *this; } - virtual ~sparse_lu (void) = default; + virtual ~sparse_lu () = default; - lu_type L (void) const { return m_L; } + lu_type L () const { return m_L; } - lu_type U (void) const { return m_U; } + lu_type U () const { return m_U; } - SparseMatrix R (void) const { return m_R; } + SparseMatrix R () const { return m_R; } - OCTAVE_API lu_type Y (void) const; + OCTAVE_API lu_type Y () const; - OCTAVE_API SparseMatrix Pc (void) const; + OCTAVE_API SparseMatrix Pc () const; - OCTAVE_API SparseMatrix Pr (void) const; + OCTAVE_API SparseMatrix Pr () const; - OCTAVE_API ColumnVector Pc_vec (void) const; + OCTAVE_API ColumnVector Pc_vec () const; - OCTAVE_API ColumnVector Pr_vec (void) const; + OCTAVE_API ColumnVector Pr_vec () const; - OCTAVE_API PermMatrix Pc_mat (void) const; + OCTAVE_API PermMatrix Pc_mat () const; - OCTAVE_API PermMatrix Pr_mat (void) const; + OCTAVE_API PermMatrix Pr_mat () const; - const octave_idx_type * row_perm (void) const { return m_P.data (); } + const octave_idx_type * row_perm () const { return m_P.data (); } - const octave_idx_type * col_perm (void) const { return m_Q.data (); } + const octave_idx_type * col_perm () const { return m_Q.data (); } - double rcond (void) const { return m_cond; } + double rcond () const { return m_cond; } protected: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/sparse-qr.cc --- a/liboctave/numeric/sparse-qr.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/sparse-qr.cc Tue Jan 24 17:19:44 2023 -0800 @@ -81,9 +81,9 @@ sparse_qr_rep& operator = (const sparse_qr_rep&) = delete; - ~sparse_qr_rep (void); - - bool ok (void) const + ~sparse_qr_rep (); + + bool ok () const { #if (defined (HAVE_SPQR) && defined (HAVE_CHOLMOD)) return (m_H && m_Htau && m_HPinv && m_R && m_E); @@ -94,13 +94,13 @@ #endif } - SPARSE_T V (void) const; - - ColumnVector Pinv (void) const; - - ColumnVector P (void) const; - - ColumnVector E (void) const; + SPARSE_T V () const; + + ColumnVector Pinv () const; + + ColumnVector P () const; + + ColumnVector E () const; SPARSE_T R (bool econ) const; @@ -149,7 +149,7 @@ template ColumnVector -sparse_qr::sparse_qr_rep::Pinv (void) const +sparse_qr::sparse_qr_rep::Pinv () const { #if defined (HAVE_CXSPARSE) @@ -169,7 +169,7 @@ template ColumnVector -sparse_qr::sparse_qr_rep::P (void) const +sparse_qr::sparse_qr_rep::P () const { #if (defined (HAVE_SPQR) && defined (HAVE_CHOLMOD)) @@ -199,7 +199,7 @@ template ColumnVector -sparse_qr::sparse_qr_rep::E (void) const +sparse_qr::sparse_qr_rep::E () const { #if (defined (HAVE_SPQR) && defined (HAVE_CHOLMOD)) @@ -570,7 +570,7 @@ #endif template <> -sparse_qr::sparse_qr_rep::~sparse_qr_rep (void) +sparse_qr::sparse_qr_rep::~sparse_qr_rep () { #if (defined (HAVE_SPQR) && defined (HAVE_CHOLMOD)) @@ -591,7 +591,7 @@ template <> SparseMatrix -sparse_qr::sparse_qr_rep::V (void) const +sparse_qr::sparse_qr_rep::V () const { #if (defined (HAVE_SPQR) && defined (HAVE_CHOLMOD)) @@ -1507,7 +1507,7 @@ #endif template <> -sparse_qr::sparse_qr_rep::~sparse_qr_rep (void) +sparse_qr::sparse_qr_rep::~sparse_qr_rep () { #if (defined (HAVE_SPQR) && defined (HAVE_CHOLMOD)) @@ -1528,7 +1528,7 @@ template <> SparseComplexMatrix -sparse_qr::sparse_qr_rep::V (void) const +sparse_qr::sparse_qr_rep::V () const { #if defined (HAVE_CXSPARSE) // Drop zeros from V and sort @@ -2675,7 +2675,7 @@ } template -sparse_qr::sparse_qr (void) +sparse_qr::sparse_qr () : m_rep (new sparse_qr_rep (SPARSE_T (), 0)) { } @@ -2686,35 +2686,35 @@ template bool -sparse_qr::ok (void) const +sparse_qr::ok () const { return m_rep->ok (); } template SPARSE_T -sparse_qr::V (void) const +sparse_qr::V () const { return m_rep->V (); } template ColumnVector -sparse_qr::Pinv (void) const +sparse_qr::Pinv () const { return m_rep->P (); } template ColumnVector -sparse_qr::P (void) const +sparse_qr::P () const { return m_rep->P (); } template ColumnVector -sparse_qr::E (void) const +sparse_qr::E () const { return m_rep->E(); } @@ -2722,7 +2722,7 @@ template SparseMatrix -sparse_qr::E_MAT (void) const +sparse_qr::E_MAT () const { ColumnVector perm = m_rep->E (); octave_idx_type nrows = perm.rows (); @@ -3226,11 +3226,11 @@ //explicit instantiations of member function E_MAT template OCTAVE_API SparseMatrix -sparse_qr::E_MAT (void) const; +sparse_qr::E_MAT () const; template OCTAVE_API SparseMatrix -sparse_qr::E_MAT (void) const; +sparse_qr::E_MAT () const; template template @@ -3250,33 +3250,33 @@ // Explicitly instantiate all member functions -template OCTAVE_API sparse_qr::sparse_qr (void); +template OCTAVE_API sparse_qr::sparse_qr (); template OCTAVE_API sparse_qr::sparse_qr (const SparseMatrix& a, int order); -template OCTAVE_API bool sparse_qr::ok (void) const; -template OCTAVE_API ColumnVector sparse_qr::E (void) const; -template OCTAVE_API SparseMatrix sparse_qr::V (void) const; -template OCTAVE_API ColumnVector sparse_qr::Pinv (void) const; -template OCTAVE_API ColumnVector sparse_qr::P (void) const; +template OCTAVE_API bool sparse_qr::ok () const; +template OCTAVE_API ColumnVector sparse_qr::E () const; +template OCTAVE_API SparseMatrix sparse_qr::V () const; +template OCTAVE_API ColumnVector sparse_qr::Pinv () const; +template OCTAVE_API ColumnVector sparse_qr::P () const; template OCTAVE_API SparseMatrix sparse_qr::R (bool econ) const; template OCTAVE_API Matrix sparse_qr::C (const Matrix& b, bool econ) const; template OCTAVE_API Matrix sparse_qr::Q (bool econ) const; -template OCTAVE_API sparse_qr::sparse_qr (void); +template OCTAVE_API sparse_qr::sparse_qr (); template OCTAVE_API sparse_qr::sparse_qr (const SparseComplexMatrix& a, int order); -template OCTAVE_API bool sparse_qr::ok (void) const; +template OCTAVE_API bool sparse_qr::ok () const; template OCTAVE_API ColumnVector -sparse_qr::E (void) const; +sparse_qr::E () const; template OCTAVE_API SparseComplexMatrix -sparse_qr::V (void) const; +sparse_qr::V () const; template OCTAVE_API ColumnVector -sparse_qr::Pinv (void) const; +sparse_qr::Pinv () const; template OCTAVE_API ColumnVector -sparse_qr::P (void) const; +sparse_qr::P () const; template OCTAVE_API SparseComplexMatrix sparse_qr::R (bool econ) const; template OCTAVE_API ComplexMatrix diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/sparse-qr.h --- a/liboctave/numeric/sparse-qr.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/sparse-qr.h Tue Jan 24 17:19:44 2023 -0800 @@ -49,7 +49,7 @@ { public: - OCTAVE_API sparse_qr (void); + OCTAVE_API sparse_qr (); #if (defined (HAVE_SPQR) && defined (HAVE_CHOLMOD)) // order = 7 selects SPQR default ordering @@ -60,22 +60,22 @@ sparse_qr (const sparse_qr& a) = default; - ~sparse_qr (void) = default; + ~sparse_qr () = default; sparse_qr& operator = (const sparse_qr& a) = default; - OCTAVE_API bool ok (void) const; + OCTAVE_API bool ok () const; - OCTAVE_API ColumnVector E (void) const; + OCTAVE_API ColumnVector E () const; // constructs permutation matrix from permutation vector rep -> E() OCTAVE_API SparseMatrix E_MAT () const; - OCTAVE_API SPARSE_T V (void) const; + OCTAVE_API SPARSE_T V () const; - OCTAVE_API ColumnVector Pinv (void) const; + OCTAVE_API ColumnVector Pinv () const; - OCTAVE_API ColumnVector P (void) const; + OCTAVE_API ColumnVector P () const; OCTAVE_API SPARSE_T R (bool econ = false) const; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/svd.cc --- a/liboctave/numeric/svd.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/svd.cc Tue Jan 24 17:19:44 2023 -0800 @@ -307,7 +307,7 @@ template T -svd::left_singular_matrix (void) const +svd::left_singular_matrix () const { if (m_type == svd::Type::sigma_only) (*current_liboctave_error_handler) @@ -318,7 +318,7 @@ template T -svd::right_singular_matrix (void) const +svd::right_singular_matrix () const { if (m_type == svd::Type::sigma_only) (*current_liboctave_error_handler) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/numeric/svd.h --- a/liboctave/numeric/svd.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/numeric/svd.h Tue Jan 24 17:19:44 2023 -0800 @@ -57,7 +57,7 @@ GEJSV }; - svd (void) + svd () : m_type (), m_driver (), m_left_sm (), m_sigma (), m_right_sm () { } @@ -83,13 +83,13 @@ return *this; } - ~svd (void) = default; + ~svd () = default; - T left_singular_matrix (void) const; + T left_singular_matrix () const; - DM_T singular_values (void) const { return m_sigma; } + DM_T singular_values () const { return m_sigma; } - T right_singular_matrix (void) const; + T right_singular_matrix () const; private: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/child-list.cc --- a/liboctave/system/child-list.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/child-list.cc Tue Jan 24 17:19:44 2023 -0800 @@ -42,7 +42,7 @@ m_list.append (child (pid, f)); } -void child_list::reap (void) +void child_list::reap () { // Mark the record for PID invalid. @@ -70,7 +70,7 @@ // Wait on our children and record any changes in their status. -bool child_list::wait (void) +bool child_list::wait () { bool retval = false; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/child-list.h --- a/liboctave/system/child-list.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/child-list.h Tue Jan 24 17:19:44 2023 -0800 @@ -56,7 +56,7 @@ child& operator = (const child&) = default; - ~child (void) = default; + ~child () = default; // The process ID of this child. pid_t m_pid; @@ -76,15 +76,15 @@ { public: - child_list (void) { } + child_list () { } void insert (pid_t pid, child::child_event_handler f); void remove (pid_t pid); - void reap (void); + void reap (); - bool wait (void); + bool wait (); private: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/dir-ops.cc --- a/liboctave/system/dir-ops.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/dir-ops.cc Tue Jan 24 17:19:44 2023 -0800 @@ -70,7 +70,7 @@ } string_vector -dir_entry::read (void) +dir_entry::read () { string_vector retval; @@ -90,7 +90,7 @@ } bool -dir_entry::close (void) +dir_entry::close () { bool retval = true; @@ -105,7 +105,7 @@ } unsigned int -dir_entry::max_name_length (void) +dir_entry::max_name_length () { return octave_name_max_wrapper (); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/dir-ops.h --- a/liboctave/system/dir-ops.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/dir-ops.h Tue Jan 24 17:19:44 2023 -0800 @@ -73,21 +73,21 @@ return *this; } - ~dir_entry (void) { close (); } + ~dir_entry () { close (); } bool open (const std::string& = ""); - string_vector read (void); + string_vector read (); - bool close (void); + bool close (); - bool ok (void) const { return m_dir && ! m_fail; } + bool ok () const { return m_dir && ! m_fail; } operator bool () const { return ok (); } - std::string error (void) const { return ok () ? "" : m_errmsg; } + std::string error () const { return ok () ? "" : m_errmsg; } - static unsigned int max_name_length (void); + static unsigned int max_name_length (); private: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/file-ops.cc --- a/liboctave/system/file-ops.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/file-ops.cc Tue Jan 24 17:19:44 2023 -0800 @@ -219,7 +219,7 @@ OCTAVE_BEGIN_NAMESPACE(file_ops) -char dev_sep_char (void) +char dev_sep_char () { #if (defined (OCTAVE_HAVE_WINDOWS_FILESYSTEM) && ! defined (OCTAVE_HAVE_POSIX_FILESYSTEM)) return ':'; @@ -228,7 +228,7 @@ #endif } -char dir_sep_char (void) +char dir_sep_char () { #if (defined (OCTAVE_HAVE_WINDOWS_FILESYSTEM) && ! defined (OCTAVE_HAVE_POSIX_FILESYSTEM)) return '\\'; @@ -237,7 +237,7 @@ #endif } -std::string dir_sep_str (void) +std::string dir_sep_str () { #if (defined (OCTAVE_HAVE_WINDOWS_FILESYSTEM) && ! defined (OCTAVE_HAVE_POSIX_FILESYSTEM)) return R"(\)"; @@ -246,7 +246,7 @@ #endif } -std::string dir_sep_chars (void) +std::string dir_sep_chars () { #if defined (OCTAVE_HAVE_WINDOWS_FILESYSTEM) return R"(/\)"; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/file-ops.h --- a/liboctave/system/file-ops.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/file-ops.h Tue Jan 24 17:19:44 2023 -0800 @@ -75,15 +75,15 @@ // text which identified this tilde starter in LEN, excluding the // tilde itself. -extern OCTAVE_API char dev_sep_char (void); +extern OCTAVE_API char dev_sep_char (); extern OCTAVE_API bool is_dev_sep (char c); -extern OCTAVE_API char dir_sep_char (void); +extern OCTAVE_API char dir_sep_char (); -extern OCTAVE_API std::string dir_sep_str (void); +extern OCTAVE_API std::string dir_sep_str (); -extern OCTAVE_API std::string dir_sep_chars (void); +extern OCTAVE_API std::string dir_sep_chars (); extern OCTAVE_API bool is_dir_sep (char c); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/file-stat.cc --- a/liboctave/system/file-stat.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/file-stat.cc Tue Jan 24 17:19:44 2023 -0800 @@ -50,43 +50,43 @@ // initialized, they should throw an exception. bool -base_file_stat::is_blk (void) const +base_file_stat::is_blk () const { return exists () && is_blk (m_mode); } bool -base_file_stat::is_chr (void) const +base_file_stat::is_chr () const { return exists () && is_chr (m_mode); } bool -base_file_stat::is_dir (void) const +base_file_stat::is_dir () const { return exists () && is_dir (m_mode); } bool -base_file_stat::is_fifo (void) const +base_file_stat::is_fifo () const { return exists () && is_fifo (m_mode); } bool -base_file_stat::is_lnk (void) const +base_file_stat::is_lnk () const { return exists () && is_lnk (m_mode); } bool -base_file_stat::is_reg (void) const +base_file_stat::is_reg () const { return exists () && is_reg (m_mode); } bool -base_file_stat::is_sock (void) const +base_file_stat::is_sock () const { return exists () && is_sock (m_mode); } @@ -134,25 +134,25 @@ } bool -base_file_stat::have_struct_stat_st_rdev (void) +base_file_stat::have_struct_stat_st_rdev () { return ::octave_have_struct_stat_st_rdev (); } bool -base_file_stat::have_struct_stat_st_blksize (void) +base_file_stat::have_struct_stat_st_blksize () { return octave_have_struct_stat_st_blksize (); } bool -base_file_stat::have_struct_stat_st_blocks (void) +base_file_stat::have_struct_stat_st_blocks () { return octave_have_struct_stat_st_blocks (); } std::string -base_file_stat::mode_as_string (void) const +base_file_stat::mode_as_string () const { char buf[12]; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/file-stat.h --- a/liboctave/system/file-stat.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/file-stat.h Tue Jan 24 17:19:44 2023 -0800 @@ -44,7 +44,7 @@ { public: - base_file_stat (void) + base_file_stat () : m_initialized (false), m_fail (false), m_errmsg (), m_mode (), m_ino (), m_dev (), m_nlink (), m_uid (), m_gid (), m_size (), m_atime (), m_mtime (), m_ctime (), m_rdev (), @@ -86,7 +86,7 @@ // The minimum difference in file time stamp values. // FIXME: This value should come from the filesystem itself. // How can we get that info? - sys::time time_resolution (void) const + sys::time time_resolution () const { static sys::time resolution (1.0); return resolution; @@ -97,13 +97,13 @@ // should all return 0 (or the equivalent, for the given object) // which is likely not meaningful. - bool is_blk (void) const; - bool is_chr (void) const; - bool is_dir (void) const; - bool is_fifo (void) const; - bool is_lnk (void) const; - bool is_reg (void) const; - bool is_sock (void) const; + bool is_blk () const; + bool is_chr () const; + bool is_dir () const; + bool is_fifo () const; + bool is_lnk () const; + bool is_reg () const; + bool is_sock () const; static bool is_blk (mode_t mode); static bool is_chr (mode_t mode); @@ -113,40 +113,40 @@ static bool is_reg (mode_t mode); static bool is_sock (mode_t mode); - static bool have_struct_stat_st_rdev (void); - static bool have_struct_stat_st_blksize (void); - static bool have_struct_stat_st_blocks (void); + static bool have_struct_stat_st_rdev (); + static bool have_struct_stat_st_blksize (); + static bool have_struct_stat_st_blocks (); - ino_t ino (void) const { return m_ino; } - dev_t dev (void) const { return m_dev; } + ino_t ino () const { return m_ino; } + dev_t dev () const { return m_dev; } - nlink_t nlink (void) const { return m_nlink; } + nlink_t nlink () const { return m_nlink; } - uid_t uid (void) const { return m_uid; } - gid_t gid (void) const { return m_gid; } + uid_t uid () const { return m_uid; } + gid_t gid () const { return m_gid; } - off_t size (void) const { return m_size; } + off_t size () const { return m_size; } - sys::time atime (void) const { return m_atime; } - sys::time mtime (void) const { return m_mtime; } - sys::time ctime (void) const { return m_ctime; } + sys::time atime () const { return m_atime; } + sys::time mtime () const { return m_mtime; } + sys::time ctime () const { return m_ctime; } - dev_t rdev (void) const { return m_rdev; } + dev_t rdev () const { return m_rdev; } - long blksize (void) const { return m_blksize; } - long blocks (void) const { return m_blocks; } + long blksize () const { return m_blksize; } + long blocks () const { return m_blocks; } - mode_t mode (void) const { return m_mode; } + mode_t mode () const { return m_mode; } - std::string mode_as_string (void) const; + std::string mode_as_string () const; - bool ok (void) const { return m_initialized && ! m_fail; } + bool ok () const { return m_initialized && ! m_fail; } operator bool () const { return ok (); } - bool exists (void) const { return ok (); } + bool exists () const { return ok (); } - std::string error (void) const { return ok () ? "" : m_errmsg; } + std::string error () const { return ok () ? "" : m_errmsg; } // Has the file referenced by this object been modified since TIME? bool is_newer (const sys::time& time) const { return m_mtime > time; } @@ -157,7 +157,7 @@ protected: - virtual ~base_file_stat (void) = default; + virtual ~base_file_stat () = default; // TRUE means we have already called stat. bool m_initialized; @@ -237,7 +237,7 @@ // This destructor must remain as an empty destructor defined in the // cpp file rather than in the header file (bug #50234). - ~file_stat (void); + ~file_stat (); void get_stats (bool force = false) { @@ -295,7 +295,7 @@ return *this; } - ~file_fstat (void) = default; + ~file_fstat () = default; void get_stats (bool force = false) { diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/lo-sysdep.cc --- a/liboctave/system/lo-sysdep.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/lo-sysdep.cc Tue Jan 24 17:19:44 2023 -0800 @@ -68,7 +68,7 @@ } std::string -getcwd (void) +getcwd () { std::string retval; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/lo-sysdep.h --- a/liboctave/system/lo-sysdep.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/lo-sysdep.h Tue Jan 24 17:19:44 2023 -0800 @@ -43,7 +43,7 @@ extern OCTAVE_API int system (const std::string& cmd_str); -extern OCTAVE_API std::string getcwd (void); +extern OCTAVE_API std::string getcwd (); extern OCTAVE_API int chdir (const std::string&); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/lo-sysinfo.cc --- a/liboctave/system/lo-sysinfo.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/lo-sysinfo.cc Tue Jan 24 17:19:44 2023 -0800 @@ -42,7 +42,7 @@ OCTAVE_BEGIN_NAMESPACE(sys) -std::string blas_version (void) +std::string blas_version () { dynamic_library dyn_libs (""); @@ -73,7 +73,7 @@ } // OpenBLAS - typedef char *(*open_fcn_type) (void); + typedef char *(*open_fcn_type) (); open_fcn_type open_f_ptr = reinterpret_cast (dyn_libs.search ("openblas_get_config")); @@ -160,7 +160,7 @@ return retval; } -std::string lapack_version (void) +std::string lapack_version () { std::string retval = "unknown LAPACK"; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/lo-sysinfo.h --- a/liboctave/system/lo-sysinfo.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/lo-sysinfo.h Tue Jan 24 17:19:44 2023 -0800 @@ -34,9 +34,9 @@ OCTAVE_BEGIN_NAMESPACE(sys) -extern OCTAVE_API std::string blas_version (void); +extern OCTAVE_API std::string blas_version (); -extern OCTAVE_API std::string lapack_version (void); +extern OCTAVE_API std::string lapack_version (); OCTAVE_END_NAMESPACE(sys) OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/mach-info.cc --- a/liboctave/system/mach-info.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/mach-info.cc Tue Jan 24 17:19:44 2023 -0800 @@ -42,7 +42,7 @@ OCTAVE_BEGIN_NAMESPACE(mach_info) -static float_format get_float_format (void) +static float_format get_float_format () { switch (octave_get_float_format ()) { @@ -57,26 +57,26 @@ } } -static bool is_big_endian (void) +static bool is_big_endian () { return octave_is_big_endian (); } -float_format native_float_format (void) +float_format native_float_format () { static float_format fmt = get_float_format (); return fmt; } -bool words_big_endian (void) +bool words_big_endian () { static bool big_endian = is_big_endian (); return big_endian; } -bool words_little_endian (void) +bool words_little_endian () { static bool little_endian = ! is_big_endian (); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/mach-info.h --- a/liboctave/system/mach-info.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/mach-info.h Tue Jan 24 17:19:44 2023 -0800 @@ -44,11 +44,11 @@ flt_fmt_ieee_big_endian = 2, }; -OCTAVE_API float_format native_float_format (void); +OCTAVE_API float_format native_float_format (); -OCTAVE_API bool words_big_endian (void); +OCTAVE_API bool words_big_endian (); -OCTAVE_API bool words_little_endian (void); +OCTAVE_API bool words_little_endian (); OCTAVE_API float_format string_to_float_format (const std::string&); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/oct-env.cc --- a/liboctave/system/oct-env.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/oct-env.cc Tue Jan 24 17:19:44 2023 -0800 @@ -69,7 +69,7 @@ OCTAVE_BEGIN_NAMESPACE(sys) -env::env (void) +env::env () : m_follow_symbolic_links (true), m_verbatim_pwd (true), m_current_directory (), m_prog_name (), m_prog_invocation_name (), m_user_name (), m_host_name () @@ -86,7 +86,7 @@ env *env::m_instance = nullptr; bool -env::instance_ok (void) +env::instance_ok () { bool retval = true; @@ -170,14 +170,14 @@ } std::string -env::get_program_name (void) +env::get_program_name () { return (instance_ok ()) ? m_instance->m_prog_name : ""; } std::string -env::get_program_invocation_name (void) +env::get_program_invocation_name () { return (instance_ok ()) ? m_instance->m_prog_invocation_name : ""; @@ -191,21 +191,21 @@ } std::string -env::get_user_name (void) +env::get_user_name () { return (instance_ok ()) ? m_instance->do_get_user_name () : ""; } std::string -env::get_host_name (void) +env::get_host_name () { return (instance_ok ()) ? m_instance->do_get_host_name () : ""; } std::string -env::do_get_temp_directory (void) const +env::do_get_temp_directory () const { std::string tempd = do_getenv ("TMPDIR"); @@ -246,7 +246,7 @@ } std::string -env::do_get_user_config_directory (void) +env::do_get_user_config_directory () { std::string cfg_dir; @@ -267,7 +267,7 @@ } std::string -env::do_get_user_data_directory (void) +env::do_get_user_data_directory () { std::string data_dir; @@ -306,7 +306,7 @@ } bool -env::have_x11_display (void) +env::have_x11_display () { std::string display = getenv ("DISPLAY"); @@ -518,7 +518,7 @@ // Return a string which is the current working directory. std::string -env::do_getcwd (void) +env::do_getcwd () { if (! m_follow_symbolic_links) m_current_directory = ""; @@ -533,7 +533,7 @@ // running. std::string -env::do_get_home_directory (void) +env::do_get_home_directory () { std::string hd = do_getenv ("HOME"); @@ -560,7 +560,7 @@ } std::string -env::do_get_user_name (void) +env::do_get_user_name () { if (m_user_name.empty ()) { @@ -573,7 +573,7 @@ } std::string -env::do_get_host_name (void) +env::do_get_host_name () { if (m_host_name.empty ()) { diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/oct-env.h --- a/liboctave/system/oct-env.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/oct-env.h Tue Jan 24 17:19:44 2023 -0800 @@ -40,7 +40,7 @@ { protected: - env (void); + env (); public: @@ -62,29 +62,29 @@ make_absolute (const std::string& s, const std::string& dot_path = get_current_directory ()); - static std::string get_current_directory (void); + static std::string get_current_directory (); - static std::string get_home_directory (void); + static std::string get_home_directory (); - static std::string get_temp_directory (void); + static std::string get_temp_directory (); - static std::string get_user_config_directory (void); + static std::string get_user_config_directory (); - static std::string get_user_data_directory (void); + static std::string get_user_data_directory (); - static std::string get_program_name (void); + static std::string get_program_name (); - static std::string get_program_invocation_name (void); + static std::string get_program_invocation_name (); - static std::string get_user_name (void); + static std::string get_user_name (); - static std::string get_host_name (void); + static std::string get_host_name (); static std::string getenv (const std::string& name); static void putenv (const std::string& name, const std::string& value); - static bool have_x11_display (void); + static bool have_x11_display (); static bool chdir (const std::string& newdir); @@ -92,7 +92,7 @@ private: - static bool instance_ok (void); + static bool instance_ok (); std::string do_polite_directory_format (const std::string& name); @@ -105,19 +105,19 @@ std::string do_make_absolute (const std::string& s, const std::string& dot_path) const; - std::string do_getcwd (void); + std::string do_getcwd (); - std::string do_get_home_directory (void); + std::string do_get_home_directory (); - std::string do_get_temp_directory (void) const; + std::string do_get_temp_directory () const; - std::string do_get_user_config_directory (void); + std::string do_get_user_config_directory (); - std::string do_get_user_data_directory (void); + std::string do_get_user_data_directory (); - std::string do_get_user_name (void); + std::string do_get_user_name (); - std::string do_get_host_name (void); + std::string do_get_host_name (); std::string do_getenv (const std::string& name) const; @@ -136,7 +136,7 @@ // The real thing. static env *m_instance; - static void cleanup_instance (void) + static void cleanup_instance () { delete m_instance; m_instance = nullptr; } // TRUE means follow symbolic links that point to directories just diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/oct-group.cc --- a/liboctave/system/oct-group.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/oct-group.cc Tue Jan 24 17:19:44 2023 -0800 @@ -42,7 +42,7 @@ OCTAVE_NORETURN static void -err_invalid (void) +err_invalid () { (*current_liboctave_error_handler) ("invalid group object"); } @@ -52,7 +52,7 @@ OCTAVE_BEGIN_NAMESPACE(sys) std::string -group::name (void) const +group::name () const { if (! ok ()) err_invalid (); @@ -61,7 +61,7 @@ } std::string -group::passwd (void) const +group::passwd () const { if (! ok ()) err_invalid (); @@ -70,7 +70,7 @@ } gid_t -group::gid (void) const +group::gid () const { if (! ok ()) err_invalid (); @@ -79,7 +79,7 @@ } string_vector -group::mem (void) const +group::mem () const { if (! ok ()) err_invalid (); @@ -88,7 +88,7 @@ } group -group::getgrent (void) +group::getgrent () { std::string msg; return getgrent (msg); @@ -149,7 +149,7 @@ } int -group::setgrent (void) +group::setgrent () { std::string msg; return setgrent (msg); @@ -169,7 +169,7 @@ } int -group::endgrent (void) +group::endgrent () { std::string msg; return endgrent (msg); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/oct-group.h --- a/liboctave/system/oct-group.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/oct-group.h Tue Jan 24 17:19:44 2023 -0800 @@ -44,7 +44,7 @@ { public: - group (void) + group () : m_name (), m_passwd (), m_gid (0), m_mem (), m_valid (false) { } @@ -67,19 +67,19 @@ return *this; } - std::string name (void) const; + std::string name () const; - std::string passwd (void) const; + std::string passwd () const; - gid_t gid (void) const; + gid_t gid () const; - string_vector mem (void) const; + string_vector mem () const; - bool ok (void) const { return m_valid; } + bool ok () const { return m_valid; } operator bool () const { return ok (); } - static group getgrent (void); + static group getgrent (); static group getgrent (std::string& msg); static group getgrgid (gid_t gid); @@ -88,10 +88,10 @@ static group getgrnam (const std::string& nm); static group getgrnam (const std::string& nm, std::string& msg); - static int setgrent (void); + static int setgrent (); static int setgrent (std::string& msg); - static int endgrent (void); + static int endgrent (); static int endgrent (std::string& msg); private: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/oct-password.cc --- a/liboctave/system/oct-password.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/oct-password.cc Tue Jan 24 17:19:44 2023 -0800 @@ -41,7 +41,7 @@ OCTAVE_NORETURN static void -err_invalid (void) +err_invalid () { (*current_liboctave_error_handler) ("invalid password object"); } @@ -51,7 +51,7 @@ OCTAVE_BEGIN_NAMESPACE(sys) std::string -password::name (void) const +password::name () const { if (! ok ()) err_invalid (); @@ -60,7 +60,7 @@ } std::string -password::passwd (void) const +password::passwd () const { if (! ok ()) err_invalid (); @@ -69,7 +69,7 @@ } uid_t -password::uid (void) const +password::uid () const { if (! ok ()) err_invalid (); @@ -78,7 +78,7 @@ } gid_t -password::gid (void) const +password::gid () const { if (! ok ()) err_invalid (); @@ -87,7 +87,7 @@ } std::string -password::gecos (void) const +password::gecos () const { if (! ok ()) err_invalid (); @@ -96,7 +96,7 @@ } std::string -password::dir (void) const +password::dir () const { if (! ok ()) err_invalid (); @@ -105,7 +105,7 @@ } std::string -password::shell (void) const +password::shell () const { if (! ok ()) err_invalid (); @@ -114,7 +114,7 @@ } password -password::getpwent (void) +password::getpwent () { std::string msg; return getpwent (msg); @@ -175,7 +175,7 @@ } int -password::setpwent (void) +password::setpwent () { std::string msg; return setpwent (msg); @@ -195,7 +195,7 @@ } int -password::endpwent (void) +password::endpwent () { std::string msg; return endpwent (msg); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/oct-password.h --- a/liboctave/system/oct-password.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/oct-password.h Tue Jan 24 17:19:44 2023 -0800 @@ -42,7 +42,7 @@ { public: - password (void) + password () : m_name (), m_passwd (), m_uid (0), m_gid (0), m_gecos (), m_dir (), m_shell (), m_valid (false) { } @@ -70,27 +70,27 @@ return *this; } - ~password (void) = default; + ~password () = default; - std::string name (void) const; + std::string name () const; - std::string passwd (void) const; + std::string passwd () const; - uid_t uid (void) const; + uid_t uid () const; - gid_t gid (void) const; + gid_t gid () const; - std::string gecos (void) const; + std::string gecos () const; - std::string dir (void) const; + std::string dir () const; - std::string shell (void) const; + std::string shell () const; - bool ok (void) const { return m_valid; } + bool ok () const { return m_valid; } operator bool () const { return ok (); } - static password getpwent (void); + static password getpwent (); static password getpwent (std::string& msg); static password getpwuid (uid_t uid); @@ -99,10 +99,10 @@ static password getpwnam (const std::string& nm); static password getpwnam (const std::string& nm, std::string& msg); - static int setpwent (void); + static int setpwent (); static int setpwent (std::string& msg); - static int endpwent (void); + static int endpwent (); static int endpwent (std::string& msg); private: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/oct-syscalls.cc --- a/liboctave/system/oct-syscalls.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/oct-syscalls.cc Tue Jan 24 17:19:44 2023 -0800 @@ -146,37 +146,37 @@ } pid_t -getpid (void) +getpid () { return octave_getpid_wrapper (); } pid_t -getppid (void) +getppid () { return octave_getppid_wrapper (); } gid_t -getgid (void) +getgid () { return octave_getgid_wrapper (); } gid_t -getegid (void) +getegid () { return octave_getegid_wrapper (); } uid_t -getuid (void) +getuid () { return octave_getuid_wrapper (); } uid_t -geteuid (void) +geteuid () { return octave_geteuid_wrapper (); } @@ -226,7 +226,7 @@ } int -wcontinue (void) +wcontinue () { return octave_wcontinue_wrapper (); } @@ -268,7 +268,7 @@ } int -wnohang (void) +wnohang () { return octave_wnohang_wrapper (); } @@ -286,7 +286,7 @@ } int -wuntraced (void) +wuntraced () { return octave_wuntraced_wrapper (); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/oct-syscalls.h --- a/liboctave/system/oct-syscalls.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/oct-syscalls.h Tue Jan 24 17:19:44 2023 -0800 @@ -51,17 +51,17 @@ extern OCTAVE_API pid_t getpgrp (std::string&); -extern OCTAVE_API pid_t getpid (void); +extern OCTAVE_API pid_t getpid (); -extern OCTAVE_API pid_t getppid (void); +extern OCTAVE_API pid_t getppid (); -extern OCTAVE_API gid_t getgid (void); +extern OCTAVE_API gid_t getgid (); -extern OCTAVE_API gid_t getegid (void); +extern OCTAVE_API gid_t getegid (); -extern OCTAVE_API uid_t getuid (void); +extern OCTAVE_API uid_t getuid (); -extern OCTAVE_API uid_t geteuid (void); +extern OCTAVE_API uid_t geteuid (); extern OCTAVE_API int pipe (int *); extern OCTAVE_API int pipe (int *, std::string&); @@ -69,7 +69,7 @@ extern OCTAVE_API pid_t waitpid (pid_t, int *status, int); extern OCTAVE_API pid_t waitpid (pid_t, int *status, int, std::string&); -extern OCTAVE_API int wcontinue (void); +extern OCTAVE_API int wcontinue (); extern OCTAVE_API int wcoredump (int status); @@ -83,13 +83,13 @@ extern OCTAVE_API int wexitstatus (int status); -extern OCTAVE_API int wnohang (void); +extern OCTAVE_API int wnohang (); extern OCTAVE_API int wstopsig (int status); extern OCTAVE_API int wtermsig (int status); -extern OCTAVE_API int wuntraced (void); +extern OCTAVE_API int wuntraced (); extern OCTAVE_API int kill (pid_t, int); extern OCTAVE_API int kill (pid_t, int, std::string&); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/oct-time.cc --- a/liboctave/system/oct-time.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/oct-time.cc Tue Jan 24 17:19:44 2023 -0800 @@ -94,7 +94,7 @@ } std::string -time::ctime (void) const +time::ctime () const { return localtime (*this).asctime (); } @@ -111,7 +111,7 @@ } void -time::stamp (void) +time::stamp () { time_t ot_unix_time; octave_gettimeofday_wrapper (&ot_unix_time, &m_ot_usec); @@ -346,7 +346,7 @@ } void -cpu_time::stamp (void) +cpu_time::stamp () { time_t usr_sec, sys_sec; octave_cpu_time (&usr_sec, &sys_sec, &m_usr_usec, &m_sys_usec); @@ -355,7 +355,7 @@ } void -resource_usage::stamp (void) +resource_usage::stamp () { time_t usr_sec, sys_sec; long usr_usec, sys_usec; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/oct-time.h --- a/liboctave/system/oct-time.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/oct-time.h Tue Jan 24 17:19:44 2023 -0800 @@ -52,7 +52,7 @@ { public: - time (void) + time () : m_ot_unix_time (0), m_ot_usec (0) { stamp (); } time (OCTAVE_TIME_T t) @@ -98,20 +98,20 @@ return *this; } - ~time (void) = default; + ~time () = default; - OCTAVE_API void stamp (void); + OCTAVE_API void stamp (); - double double_value (void) const + double double_value () const { return as_double (m_ot_unix_time, m_ot_usec); } - OCTAVE_TIME_T unix_time (void) const { return m_ot_unix_time; } + OCTAVE_TIME_T unix_time () const { return m_ot_unix_time; } - long usec (void) const { return m_ot_usec; } + long usec () const { return m_ot_usec; } - OCTAVE_API std::string ctime (void) const; + OCTAVE_API std::string ctime () const; friend OCTAVE_API std::ostream& operator << (std::ostream& os, const time& ot); @@ -186,7 +186,7 @@ { public: - base_tm (void) + base_tm () : m_usec (0), m_sec (0), m_min (0), m_hour (0), m_mday (0), m_mon (0), m_year (0), m_wday (0), m_yday (0), m_isdst (0), m_gmtoff (0), m_zone ("unknown") @@ -220,20 +220,20 @@ return *this; } - virtual ~base_tm (void) = default; + virtual ~base_tm () = default; - int usec (void) const { return m_usec; } - int sec (void) const { return m_sec; } - int min (void) const { return m_min; } - int hour (void) const { return m_hour; } - int mday (void) const { return m_mday; } - int mon (void) const { return m_mon; } - int year (void) const { return m_year; } - int wday (void) const { return m_wday; } - int yday (void) const { return m_yday; } - int isdst (void) const { return m_isdst; } - long gmtoff (void) const { return m_gmtoff; } - std::string zone (void) const { return m_zone; } + int usec () const { return m_usec; } + int sec () const { return m_sec; } + int min () const { return m_min; } + int hour () const { return m_hour; } + int mday () const { return m_mday; } + int mon () const { return m_mon; } + int year () const { return m_year; } + int wday () const { return m_wday; } + int yday () const { return m_yday; } + int isdst () const { return m_isdst; } + long gmtoff () const { return m_gmtoff; } + std::string zone () const { return m_zone; } OCTAVE_API base_tm& usec (int v); OCTAVE_API base_tm& sec (int v); @@ -250,7 +250,7 @@ OCTAVE_API std::string strftime (const std::string& fmt) const; - std::string asctime (void) const + std::string asctime () const { return strftime ("%a %b %d %H:%M:%S %Y\n"); } protected: @@ -299,7 +299,7 @@ { public: - localtime (void) + localtime () : base_tm () { init (time ()); } localtime (const time& ot) @@ -314,7 +314,7 @@ return *this; } - ~localtime (void) = default; + ~localtime () = default; private: @@ -326,7 +326,7 @@ { public: - gmtime (void) + gmtime () : base_tm () { init (time ()); } gmtime (const time& ot) @@ -338,7 +338,7 @@ return *this; } - ~gmtime (void) = default; + ~gmtime () = default; private: @@ -366,9 +366,9 @@ return *this; } - int characters_converted (void) const { return m_nchars; } + int characters_converted () const { return m_nchars; } - ~strptime (void) = default; + ~strptime () = default; private: @@ -384,7 +384,7 @@ friend class resource_usage; - cpu_time (void) + cpu_time () : m_usr_sec (0), m_sys_sec (0), m_usr_usec (0), m_sys_usec (0) { stamp (); @@ -408,23 +408,23 @@ return *this; } - OCTAVE_API void stamp (void); + OCTAVE_API void stamp (); - double user (void) const + double user () const { return as_double (m_usr_sec, m_usr_usec); } - double system (void) const + double system () const { return as_double (m_sys_sec, m_sys_usec); } - OCTAVE_TIME_T user_sec (void) const { return m_usr_sec; } - long user_usec (void) const { return m_usr_usec; } + OCTAVE_TIME_T user_sec () const { return m_usr_sec; } + long user_usec () const { return m_usr_usec; } - OCTAVE_TIME_T system_sec (void) const { return m_sys_sec; } - long system_usec (void) const { return m_sys_usec; } + OCTAVE_TIME_T system_sec () const { return m_sys_sec; } + long system_usec () const { return m_sys_usec; } private: @@ -445,7 +445,7 @@ { public: - resource_usage (void) + resource_usage () : m_cpu (), m_maxrss (0), m_ixrss (0), m_idrss (0), m_isrss (0), m_minflt (0), m_majflt (0), m_nswap (0), m_inblock (0), m_oublock (0), m_msgsnd (0), m_msgrcv (0), @@ -490,24 +490,24 @@ return *this; } - OCTAVE_API void stamp (void); + OCTAVE_API void stamp (); - cpu_time cpu (void) const { return m_cpu; } + cpu_time cpu () const { return m_cpu; } - long maxrss (void) const { return m_maxrss; } - long ixrss (void) const { return m_ixrss; } - long idrss (void) const { return m_idrss; } - long isrss (void) const { return m_isrss; } - long minflt (void) const { return m_minflt; } - long majflt (void) const { return m_majflt; } - long nswap (void) const { return m_nswap; } - long inblock (void) const { return m_inblock; } - long oublock (void) const { return m_oublock; } - long msgsnd (void) const { return m_msgsnd; } - long msgrcv (void) const { return m_msgrcv; } - long nsignals (void) const { return m_nsignals; } - long nvcsw (void) const { return m_nvcsw; } - long nivcsw (void) const { return m_nivcsw; } + long maxrss () const { return m_maxrss; } + long ixrss () const { return m_ixrss; } + long idrss () const { return m_idrss; } + long isrss () const { return m_isrss; } + long minflt () const { return m_minflt; } + long majflt () const { return m_majflt; } + long nswap () const { return m_nswap; } + long inblock () const { return m_inblock; } + long oublock () const { return m_oublock; } + long msgsnd () const { return m_msgsnd; } + long msgrcv () const { return m_msgrcv; } + long nsignals () const { return m_nsignals; } + long nvcsw () const { return m_nvcsw; } + long nivcsw () const { return m_nivcsw; } private: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/oct-uname.cc --- a/liboctave/system/oct-uname.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/oct-uname.cc Tue Jan 24 17:19:44 2023 -0800 @@ -38,7 +38,7 @@ OCTAVE_BEGIN_NAMESPACE(sys) void -uname::init (void) +uname::init () { char *sysname, *nodename, *release, *version, *machine; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/system/oct-uname.h --- a/liboctave/system/oct-uname.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/system/oct-uname.h Tue Jan 24 17:19:44 2023 -0800 @@ -40,7 +40,7 @@ { public: - uname (void) + uname () : m_sysname ("unknown"), m_nodename ("unknown"), m_release ("unknown"), m_version ("unknown"), m_machine ("unknown"), @@ -71,16 +71,16 @@ return *this; } - ~uname (void) = default; + ~uname () = default; - std::string sysname (void) const { return m_sysname; } - std::string nodename (void) const { return m_nodename; } - std::string release (void) const { return m_release; } - std::string version (void) const { return m_version; } - std::string machine (void) const { return m_machine; } + std::string sysname () const { return m_sysname; } + std::string nodename () const { return m_nodename; } + std::string release () const { return m_release; } + std::string version () const { return m_version; } + std::string machine () const { return m_machine; } - std::string message (void) const { return m_errmsg; } - int error (void) const { return m_errno; } + std::string message () const { return m_errmsg; } + int error () const { return m_errno; } private: @@ -93,7 +93,7 @@ std::string m_errmsg; int m_errno; - void init (void); + void init (); }; OCTAVE_END_NAMESPACE(sys) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/action-container.h --- a/liboctave/util/action-container.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/action-container.h Tue Jan 24 17:19:44 2023 -0800 @@ -52,7 +52,7 @@ friend class action_container; - elem (void) { } + elem () { } // No copying! @@ -60,12 +60,12 @@ elem& operator = (const elem&) = delete; - virtual ~elem (void) = default; + virtual ~elem () = default; - virtual void run (void) { } + virtual void run () { } }; - // An element that merely runs a void (*)(void) function. + // An element that merely runs a void (*)() function. class fcn_elem : public elem { @@ -79,11 +79,11 @@ : m_fcn (std::bind (fcn, args...)) { } - void run (void) { m_fcn (); } + void run () { m_fcn (); } private: - std::function m_fcn; + std::function m_fcn; }; // An element that stores arbitrary variable, and restores it. @@ -102,7 +102,7 @@ restore_var_elem& operator = (const restore_var_elem&) = delete; - void run (void) { *m_ptr = m_val; } + void run () { *m_ptr = m_val; } private: @@ -125,14 +125,14 @@ delete_ptr_elem operator = (const delete_ptr_elem&) = delete; - void run (void) { delete m_ptr; } + void run () { delete m_ptr; } private: T *m_ptr; }; - action_container (void) { } + action_container () { } // No copying! @@ -140,7 +140,7 @@ action_container& operator = (const action_container&) = delete; - virtual ~action_container (void) = default; + virtual ~action_container () = default; template void add (F&& fcn, Args&& ... args) @@ -193,15 +193,15 @@ add_action (new restore_var_elem (var, val)); } - operator bool (void) const { return ! empty (); } + operator bool () const { return ! empty (); } - virtual void run_first (void) = 0; + virtual void run_first () = 0; OCTAVE_API void run (std::size_t num); - void run (void) { run (size ()); } + void run () { run (size ()); } - virtual void discard_first (void) = 0; + virtual void discard_first () = 0; void discard (std::size_t num) { @@ -212,11 +212,11 @@ discard_first (); } - void discard (void) { discard (size ()); } + void discard () { discard (size ()); } - virtual std::size_t size (void) const = 0; + virtual std::size_t size () const = 0; - bool empty (void) const { return size () == 0; } + bool empty () const { return size () == 0; } protected: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/base-list.h --- a/liboctave/util/base-list.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/base-list.h Tue Jan 24 17:19:44 2023 -0800 @@ -47,10 +47,10 @@ typedef typename std::list::const_reverse_iterator const_reverse_iterator; - bool empty (void) const { return m_lst.empty (); } + bool empty () const { return m_lst.empty (); } - std::size_t size (void) const { return m_lst.size (); } - std::size_t length (void) const { return size (); } + std::size_t size () const { return m_lst.size (); } + std::size_t length () const { return size (); } iterator erase (iterator pos) { return m_lst.erase (pos); } @@ -60,38 +60,38 @@ m_lst.remove_if (pred); } - void clear (void) { m_lst.clear (); } + void clear () { m_lst.clear (); } - iterator begin (void) { return iterator (m_lst.begin ()); } - const_iterator begin (void) const { return const_iterator (m_lst.begin ()); } + iterator begin () { return iterator (m_lst.begin ()); } + const_iterator begin () const { return const_iterator (m_lst.begin ()); } - iterator end (void) { return iterator (m_lst.end ()); } - const_iterator end (void) const { return const_iterator (m_lst.end ()); } + iterator end () { return iterator (m_lst.end ()); } + const_iterator end () const { return const_iterator (m_lst.end ()); } - reverse_iterator rbegin (void) { return reverse_iterator (m_lst.rbegin ()); } - const_reverse_iterator rbegin (void) const + reverse_iterator rbegin () { return reverse_iterator (m_lst.rbegin ()); } + const_reverse_iterator rbegin () const { return const_reverse_iterator (m_lst.rbegin ()); } - reverse_iterator rend (void) { return reverse_iterator (m_lst.rend ()); } - const_reverse_iterator rend (void) const + reverse_iterator rend () { return reverse_iterator (m_lst.rend ()); } + const_reverse_iterator rend () const { return const_reverse_iterator (m_lst.rend ()); } - elt_type& front (void) { return m_lst.front (); } - elt_type& back (void) { return m_lst.back (); } + elt_type& front () { return m_lst.front (); } + elt_type& back () { return m_lst.back (); } - const elt_type& front (void) const { return m_lst.front (); } - const elt_type& back (void) const { return m_lst.back (); } + const elt_type& front () const { return m_lst.front (); } + const elt_type& back () const { return m_lst.back (); } void push_front (const elt_type& s) { m_lst.push_front (s); } void push_back (const elt_type& s) { m_lst.push_back (s); } - void pop_front (void) { m_lst.pop_front (); } - void pop_back (void) { m_lst.pop_back (); } + void pop_front () { m_lst.pop_front (); } + void pop_back () { m_lst.pop_back (); } // For backward compatibility. void append (const elt_type& s) { m_lst.push_back (s); } - base_list (void) = default; + base_list () = default; base_list (const std::list& l) : m_lst (l) { } @@ -99,7 +99,7 @@ base_list& operator = (const base_list& bl) = default; - virtual ~base_list (void) = default; + virtual ~base_list () = default; protected: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/caseless-str.h --- a/liboctave/util/caseless-str.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/caseless-str.h Tue Jan 24 17:19:44 2023 -0800 @@ -38,7 +38,7 @@ typedef std::string::iterator iterator; typedef std::string::const_iterator const_iterator; - caseless_str (void) = default; + caseless_str () = default; caseless_str (const std::string& s) : std::string (s) { } caseless_str (const char *s) : std::string (s) { } @@ -47,7 +47,7 @@ caseless_str& operator = (const caseless_str&) = default; - ~caseless_str (void) = default; + ~caseless_str () = default; bool operator < (const std::string& s) const { diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/cmd-edit.cc --- a/liboctave/util/cmd-edit.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/cmd-edit.cc Tue Jan 24 17:19:44 2023 -0800 @@ -81,9 +81,9 @@ typedef command_editor::completion_fcn completion_fcn; - gnu_readline (void); + gnu_readline (); - ~gnu_readline (void) = default; + ~gnu_readline () = default; void do_set_name (const std::string& n); @@ -91,27 +91,27 @@ void do_set_input_stream (FILE *f); - FILE * do_get_input_stream (void); + FILE * do_get_input_stream (); void do_set_output_stream (FILE *f); - FILE * do_get_output_stream (void); + FILE * do_get_output_stream (); - void do_redisplay (void); + void do_redisplay (); - int do_terminal_rows (void); + int do_terminal_rows (); - int do_terminal_cols (void); + int do_terminal_cols (); void do_clear_screen (bool skip_redisplay); - void do_resize_terminal (void); + void do_resize_terminal (); void do_set_screen_size (int ht, int wd); - std::string newline_chars (void); + std::string newline_chars (); - void do_restore_terminal_state (void); + void do_restore_terminal_state (); void do_blink_matching_paren (bool flag); @@ -139,56 +139,56 @@ void do_set_user_accept_line_function (user_accept_line_fcn f); - completion_fcn do_get_completion_function (void) const; + completion_fcn do_get_completion_function () const; - quoting_fcn do_get_quoting_function (void) const; + quoting_fcn do_get_quoting_function () const; - dequoting_fcn do_get_dequoting_function (void) const; + dequoting_fcn do_get_dequoting_function () const; - char_is_quoted_fcn do_get_char_is_quoted_function (void) const; + char_is_quoted_fcn do_get_char_is_quoted_function () const; - user_accept_line_fcn do_get_user_accept_line_function (void) const; + user_accept_line_fcn do_get_user_accept_line_function () const; string_vector do_generate_filename_completions (const std::string& text); - std::string do_get_line_buffer (void) const; + std::string do_get_line_buffer () const; - std::string do_get_current_line (void) const; + std::string do_get_current_line () const; char do_get_prev_char (int) const; void do_replace_line (const std::string& text, bool clear_undo); - void do_kill_full_line (void); + void do_kill_full_line (); void do_insert_text (const std::string& text); - void do_newline (void); + void do_newline (); - void do_accept_line (void); + void do_accept_line (); - bool do_undo (void); + bool do_undo (); - void do_clear_undo_list (void); + void do_clear_undo_list (); void set_startup_hook (startup_hook_fcn f); - void restore_startup_hook (void); + void restore_startup_hook (); void set_pre_input_hook (pre_input_hook_fcn f); - void restore_pre_input_hook (void); + void restore_pre_input_hook (); void set_event_hook (event_hook_fcn f); - void restore_event_hook (void); + void restore_event_hook (); - void do_restore_event_hook (void); + void do_restore_event_hook (); void do_read_init_file (const std::string& file); - void do_re_read_init_file (void); + void do_re_read_init_file (); bool do_filename_completion_desired (bool); @@ -198,7 +198,7 @@ void do_interrupt (bool); - void do_handle_interrupt_signal (void); + void do_handle_interrupt_signal (); static int operate_and_get_next (int, int); @@ -305,7 +305,7 @@ } FILE * -gnu_readline::do_get_input_stream (void) +gnu_readline::do_get_input_stream () { return ::octave_rl_get_input_stream (); } @@ -317,13 +317,13 @@ } FILE * -gnu_readline::do_get_output_stream (void) +gnu_readline::do_get_output_stream () { return ::octave_rl_get_output_stream (); } void -gnu_readline::do_redisplay (void) +gnu_readline::do_redisplay () { ::octave_rl_redisplay (); } @@ -335,7 +335,7 @@ // us. int -gnu_readline::do_terminal_rows (void) +gnu_readline::do_terminal_rows () { int sh = ::octave_rl_screen_height (); @@ -343,7 +343,7 @@ } int -gnu_readline::do_terminal_cols (void) +gnu_readline::do_terminal_cols () { int sw = ::octave_rl_screen_width (); @@ -357,7 +357,7 @@ } void -gnu_readline::do_resize_terminal (void) +gnu_readline::do_resize_terminal () { ::octave_rl_resize_terminal (); } @@ -369,13 +369,13 @@ } std::string -gnu_readline::newline_chars (void) +gnu_readline::newline_chars () { return "\r\n"; } void -gnu_readline::do_restore_terminal_state (void) +gnu_readline::do_restore_terminal_state () { ::octave_rl_restore_terminal_state (); } @@ -490,31 +490,31 @@ } gnu_readline::completion_fcn -gnu_readline::do_get_completion_function (void) const +gnu_readline::do_get_completion_function () const { return m_completion_function; } gnu_readline::quoting_fcn -gnu_readline::do_get_quoting_function (void) const +gnu_readline::do_get_quoting_function () const { return m_quoting_function; } gnu_readline::dequoting_fcn -gnu_readline::do_get_dequoting_function (void) const +gnu_readline::do_get_dequoting_function () const { return m_dequoting_function; } gnu_readline::char_is_quoted_fcn -gnu_readline::do_get_char_is_quoted_function (void) const +gnu_readline::do_get_char_is_quoted_function () const { return m_char_is_quoted_function; } gnu_readline::user_accept_line_fcn -gnu_readline::do_get_user_accept_line_function (void) const +gnu_readline::do_get_user_accept_line_function () const { return user_accept_line_function; } @@ -634,13 +634,13 @@ } std::string -gnu_readline::do_get_line_buffer (void) const +gnu_readline::do_get_line_buffer () const { return ::octave_rl_line_buffer (); } std::string -gnu_readline::do_get_current_line (void) const +gnu_readline::do_get_current_line () const { std::string retval; char *buf = ::octave_rl_copy_line (); @@ -667,7 +667,7 @@ } void -gnu_readline::do_kill_full_line (void) +gnu_readline::do_kill_full_line () { ::octave_rl_kill_full_line (); } @@ -679,19 +679,19 @@ } void -gnu_readline::do_newline (void) +gnu_readline::do_newline () { ::octave_rl_newline (1, '\n'); } void -gnu_readline::do_accept_line (void) +gnu_readline::do_accept_line () { command_accept_line (1, '\n'); } bool -gnu_readline::do_undo (void) +gnu_readline::do_undo () { return ::octave_rl_do_undo (); } @@ -712,7 +712,7 @@ } void -gnu_readline::restore_startup_hook (void) +gnu_readline::restore_startup_hook () { ::octave_rl_set_startup_hook (m_previous_startup_hook); } @@ -727,7 +727,7 @@ } void -gnu_readline::restore_pre_input_hook (void) +gnu_readline::restore_pre_input_hook () { ::octave_rl_set_pre_input_hook (m_previous_pre_input_hook); } @@ -741,7 +741,7 @@ } void -gnu_readline::restore_event_hook (void) +gnu_readline::restore_event_hook () { ::octave_rl_set_event_hook (m_previous_event_hook); } @@ -753,7 +753,7 @@ } void -gnu_readline::do_re_read_init_file (void) +gnu_readline::do_re_read_init_file () { ::octave_rl_re_read_init_file (); } @@ -783,7 +783,7 @@ } void -gnu_readline::do_handle_interrupt_signal (void) +gnu_readline::do_handle_interrupt_signal () { octave_signal_caught = 0; octave_interrupt_state = 0; @@ -933,7 +933,7 @@ { public: - default_command_editor (void) + default_command_editor () : command_editor (), m_input_stream (stdin), m_output_stream (stdout) { } // No copying! @@ -942,35 +942,35 @@ default_command_editor& operator = (const default_command_editor&) = delete; - ~default_command_editor (void) = default; + ~default_command_editor () = default; std::string do_readline (const std::string& prompt, bool& eof); void do_set_input_stream (FILE *f); - FILE * do_get_input_stream (void); + FILE * do_get_input_stream (); void do_set_output_stream (FILE *f); - FILE * do_get_output_stream (void); + FILE * do_get_output_stream (); string_vector do_generate_filename_completions (const std::string& text); - std::string do_get_line_buffer (void) const; + std::string do_get_line_buffer () const; - std::string do_get_current_line (void) const; + std::string do_get_current_line () const; char do_get_prev_char (int) const; void do_replace_line (const std::string& text, bool clear_undo); - void do_kill_full_line (void); + void do_kill_full_line (); void do_insert_text (const std::string& text); - void do_newline (void); + void do_newline (); - void do_accept_line (void); + void do_accept_line (); private: @@ -995,7 +995,7 @@ } FILE * -default_command_editor::do_get_input_stream (void) +default_command_editor::do_get_input_stream () { return m_input_stream; } @@ -1007,7 +1007,7 @@ } FILE * -default_command_editor::do_get_output_stream (void) +default_command_editor::do_get_output_stream () { return m_output_stream; } @@ -1020,13 +1020,13 @@ } std::string -default_command_editor::do_get_line_buffer (void) const +default_command_editor::do_get_line_buffer () const { return ""; } std::string -default_command_editor::do_get_current_line (void) const +default_command_editor::do_get_current_line () const { // FIXME return ""; @@ -1045,7 +1045,7 @@ } void -default_command_editor::do_kill_full_line (void) +default_command_editor::do_kill_full_line () { // FIXME } @@ -1057,19 +1057,19 @@ } void -default_command_editor::do_newline (void) +default_command_editor::do_newline () { // FIXME } void -default_command_editor::do_accept_line (void) +default_command_editor::do_accept_line () { // FIXME } bool -command_editor::instance_ok (void) +command_editor::instance_ok () { bool retval = true; @@ -1093,7 +1093,7 @@ } void -command_editor::make_command_editor (void) +command_editor::make_command_editor () { #if defined (USE_READLINE) s_instance = new gnu_readline (); @@ -1103,7 +1103,7 @@ } void -command_editor::force_default_editor (void) +command_editor::force_default_editor () { delete s_instance; s_instance = new default_command_editor (); @@ -1117,13 +1117,13 @@ } int -command_editor::insert_initial_input (void) +command_editor::insert_initial_input () { return instance_ok () ? s_instance->do_insert_initial_input () : 0; } int -command_editor::startup_handler (void) +command_editor::startup_handler () { // Iterate over a copy of the set to avoid problems if a hook // function attempts to remove itself from the startup_hook_set. @@ -1140,7 +1140,7 @@ } int -command_editor::pre_input_handler (void) +command_editor::pre_input_handler () { // Iterate over copy of the set to avoid problems if a hook function // attempts to remove itself from the pre_input_hook_set. @@ -1157,7 +1157,7 @@ } int -command_editor::event_handler (void) +command_editor::event_handler () { if (octave_interrupt_state) handle_interrupt_signal (); @@ -1216,7 +1216,7 @@ } FILE * -command_editor::get_input_stream (void) +command_editor::get_input_stream () { return instance_ok () ? s_instance->do_get_input_stream () : nullptr; } @@ -1229,26 +1229,26 @@ } FILE * -command_editor::get_output_stream (void) +command_editor::get_output_stream () { return instance_ok () ? s_instance->do_get_output_stream () : nullptr; } void -command_editor::redisplay (void) +command_editor::redisplay () { if (instance_ok ()) s_instance->do_redisplay (); } int -command_editor::terminal_rows (void) +command_editor::terminal_rows () { return instance_ok () ? s_instance->do_terminal_rows () : -1; } int -command_editor::terminal_cols (void) +command_editor::terminal_cols () { return instance_ok () ? s_instance->do_terminal_cols () : -1; } @@ -1261,7 +1261,7 @@ } void -command_editor::resize_terminal (void) +command_editor::resize_terminal () { if (instance_ok ()) s_instance->do_resize_terminal (); @@ -1281,7 +1281,7 @@ } int -command_editor::current_command_number (void) +command_editor::current_command_number () { return instance_ok () ? s_instance->m_command_number : 0; } @@ -1294,14 +1294,14 @@ } void -command_editor::increment_current_command_number (void) +command_editor::increment_current_command_number () { if (instance_ok ()) s_instance->m_command_number++; } void -command_editor::restore_terminal_state (void) +command_editor::restore_terminal_state () { if (instance_ok ()) s_instance->do_restore_terminal_state (); @@ -1398,32 +1398,32 @@ } command_editor::completion_fcn -command_editor::get_completion_function (void) +command_editor::get_completion_function () { return instance_ok () ? s_instance->do_get_completion_function () : nullptr; } command_editor::quoting_fcn -command_editor::get_quoting_function (void) +command_editor::get_quoting_function () { return instance_ok () ? s_instance->do_get_quoting_function () : nullptr; } command_editor::dequoting_fcn -command_editor::get_dequoting_function (void) +command_editor::get_dequoting_function () { return instance_ok () ? s_instance->do_get_dequoting_function () : nullptr; } command_editor::char_is_quoted_fcn -command_editor::get_char_is_quoted_function (void) +command_editor::get_char_is_quoted_function () { return (instance_ok () ? s_instance->do_get_char_is_quoted_function () : nullptr); } command_editor::user_accept_line_fcn -command_editor::get_user_accept_line_function (void) +command_editor::get_user_accept_line_function () { return (instance_ok () ? s_instance->do_get_user_accept_line_function () : nullptr); @@ -1438,13 +1438,13 @@ } std::string -command_editor::get_line_buffer (void) +command_editor::get_line_buffer () { return instance_ok () ? s_instance->do_get_line_buffer () : ""; } std::string -command_editor::get_current_line (void) +command_editor::get_current_line () { return instance_ok () ? s_instance->do_get_current_line () : ""; } @@ -1465,7 +1465,7 @@ } void -command_editor::kill_full_line (void) +command_editor::kill_full_line () { if (instance_ok ()) s_instance->do_kill_full_line (); @@ -1479,27 +1479,27 @@ } void -command_editor::newline (void) +command_editor::newline () { if (instance_ok ()) s_instance->do_newline (); } void -command_editor::accept_line (void) +command_editor::accept_line () { if (instance_ok ()) s_instance->do_accept_line (); } bool -command_editor::undo (void) +command_editor::undo () { return instance_ok () ? s_instance->do_undo () : false; } void -command_editor::clear_undo_list (void) +command_editor::clear_undo_list () { if (instance_ok ()) s_instance->do_clear_undo_list (); @@ -1578,7 +1578,7 @@ } void -command_editor::run_event_hooks (void) +command_editor::run_event_hooks () { event_handler (); } @@ -1595,7 +1595,7 @@ } void -command_editor::re_read_init_file (void) +command_editor::re_read_init_file () { if (instance_ok ()) s_instance->do_re_read_init_file (); @@ -1649,13 +1649,13 @@ } bool -command_editor::event_loop_interrupted (void) +command_editor::event_loop_interrupted () { return instance_ok () ? s_instance->do_event_loop_interrupted () : false; } void -command_editor::handle_interrupt_signal (void) +command_editor::handle_interrupt_signal () { if (instance_ok ()) s_instance->do_handle_interrupt_signal (); @@ -1915,7 +1915,7 @@ } int -command_editor::do_insert_initial_input (void) +command_editor::do_insert_initial_input () { std::string input = m_initial_input; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/cmd-edit.h --- a/liboctave/util/cmd-edit.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/cmd-edit.h Tue Jan 24 17:19:44 2023 -0800 @@ -43,18 +43,18 @@ { protected: - command_editor (void) + command_editor () : m_command_number (1), m_rows (24), m_cols (80), m_interrupted (false), m_interrupt_event_loop (false), m_initial_input () { } public: - typedef int (*startup_hook_fcn) (void); + typedef int (*startup_hook_fcn) (); - typedef int (*pre_input_hook_fcn) (void); + typedef int (*pre_input_hook_fcn) (); - typedef int (*event_hook_fcn) (void); + typedef int (*event_hook_fcn) (); typedef std::string (*completion_fcn) (const std::string&, int); @@ -74,7 +74,7 @@ command_editor& operator = (const command_editor&) = delete; - virtual ~command_editor (void) = default; + virtual ~command_editor () = default; static void set_name (const std::string& n); @@ -84,27 +84,27 @@ static void set_input_stream (FILE *f); - static FILE * get_input_stream (void); + static FILE * get_input_stream (); static void set_output_stream (FILE *f); - static FILE * get_output_stream (void); + static FILE * get_output_stream (); - static void redisplay (void); + static void redisplay (); - static int terminal_rows (void); + static int terminal_rows (); - static int terminal_cols (void); + static int terminal_cols (); static void clear_screen (bool skip_redisplay = false); - static void resize_terminal (void); + static void resize_terminal (); static void set_screen_size (int ht, int wd); static std::string decode_prompt_string (const std::string& s); - static void restore_terminal_state (void); + static void restore_terminal_state (); static void blink_matching_paren (bool flag); @@ -132,38 +132,38 @@ static void set_user_accept_line_function (user_accept_line_fcn f); - static completion_fcn get_completion_function (void); + static completion_fcn get_completion_function (); - static quoting_fcn get_quoting_function (void); + static quoting_fcn get_quoting_function (); - static dequoting_fcn get_dequoting_function (void); + static dequoting_fcn get_dequoting_function (); - static char_is_quoted_fcn get_char_is_quoted_function (void); + static char_is_quoted_fcn get_char_is_quoted_function (); - static user_accept_line_fcn get_user_accept_line_function (void); + static user_accept_line_fcn get_user_accept_line_function (); static string_vector generate_filename_completions (const std::string& text); - static std::string get_line_buffer (void); + static std::string get_line_buffer (); - static std::string get_current_line (void); + static std::string get_current_line (); static char get_prev_char (int); static void replace_line (const std::string& text, bool clear_undo = true); - static void kill_full_line (void); + static void kill_full_line (); static void insert_text (const std::string& text); - static void newline (void); + static void newline (); - static void accept_line (void); + static void accept_line (); - static bool undo (void); + static bool undo (); - static void clear_undo_list (void); + static void clear_undo_list (); static void add_startup_hook (startup_hook_fcn f); @@ -177,11 +177,11 @@ static void remove_event_hook (event_hook_fcn f); - static void run_event_hooks (void); + static void run_event_hooks (); static void read_init_file (const std::string& file = ""); - static void re_read_init_file (void); + static void re_read_init_file (); static bool filename_completion_desired (bool); @@ -193,39 +193,39 @@ static void interrupt_event_loop (bool flag = true); - static bool event_loop_interrupted (void); + static bool event_loop_interrupted (); - static int current_command_number (void); + static int current_command_number (); static void reset_current_command_number (int n); - static void increment_current_command_number (void); + static void increment_current_command_number (); - static void force_default_editor (void); + static void force_default_editor (); static void set_initial_input (const std::string& text); - static int insert_initial_input (void); + static int insert_initial_input (); private: - static bool instance_ok (void); + static bool instance_ok (); - static void make_command_editor (void); + static void make_command_editor (); - static int startup_handler (void); + static int startup_handler (); - static int pre_input_handler (void); + static int pre_input_handler (); - static int event_handler (void); + static int event_handler (); - static void cleanup_instance (void) + static void cleanup_instance () { delete s_instance; s_instance = nullptr; } - static void handle_interrupt_signal (void); + static void handle_interrupt_signal (); //-------- @@ -254,21 +254,21 @@ virtual void do_set_input_stream (FILE *) = 0; - virtual FILE * do_get_input_stream (void) = 0; + virtual FILE * do_get_input_stream () = 0; virtual void do_set_output_stream (FILE *) = 0; - virtual FILE * do_get_output_stream (void) = 0; + virtual FILE * do_get_output_stream () = 0; - virtual void do_redisplay (void) { } + virtual void do_redisplay () { } - virtual int do_terminal_rows (void) { return m_rows; } + virtual int do_terminal_rows () { return m_rows; } - virtual int do_terminal_cols (void) { return m_cols; } + virtual int do_terminal_cols () { return m_cols; } virtual void do_clear_screen (bool) { } - virtual void do_resize_terminal (void) { } + virtual void do_resize_terminal () { } virtual void do_set_screen_size (int ht, int wd) { @@ -278,9 +278,9 @@ virtual std::string do_decode_prompt_string (const std::string&); - virtual std::string newline_chars (void) { return "\n"; } + virtual std::string newline_chars () { return "\n"; } - virtual void do_restore_terminal_state (void) { } + virtual void do_restore_terminal_state () { } virtual void do_blink_matching_paren (bool) { } @@ -310,60 +310,60 @@ virtual void do_set_user_accept_line_function (user_accept_line_fcn) { } - virtual completion_fcn do_get_completion_function (void) const + virtual completion_fcn do_get_completion_function () const { return nullptr; } - virtual quoting_fcn do_get_quoting_function (void) const + virtual quoting_fcn do_get_quoting_function () const { return nullptr; } - virtual dequoting_fcn do_get_dequoting_function (void) const + virtual dequoting_fcn do_get_dequoting_function () const { return nullptr; } - virtual char_is_quoted_fcn do_get_char_is_quoted_function (void) const + virtual char_is_quoted_fcn do_get_char_is_quoted_function () const { return nullptr; } - virtual user_accept_line_fcn do_get_user_accept_line_function (void) const + virtual user_accept_line_fcn do_get_user_accept_line_function () const { return nullptr; } virtual string_vector do_generate_filename_completions (const std::string& text) = 0; - virtual std::string do_get_line_buffer (void) const = 0; + virtual std::string do_get_line_buffer () const = 0; - virtual std::string do_get_current_line (void) const = 0; + virtual std::string do_get_current_line () const = 0; virtual char do_get_prev_char (int) const = 0; virtual void do_replace_line (const std::string& text, bool clear_undo) = 0; - virtual void do_kill_full_line (void) = 0; + virtual void do_kill_full_line () = 0; virtual void do_insert_text (const std::string& text) = 0; - virtual void do_newline (void) = 0; + virtual void do_newline () = 0; - virtual void do_accept_line (void) = 0; + virtual void do_accept_line () = 0; - virtual bool do_undo (void) { return false; } + virtual bool do_undo () { return false; } - virtual void do_clear_undo_list (void) { } + virtual void do_clear_undo_list () { } virtual void set_startup_hook (startup_hook_fcn) { } - virtual void restore_startup_hook (void) { } + virtual void restore_startup_hook () { } virtual void set_pre_input_hook (pre_input_hook_fcn) { } - virtual void restore_pre_input_hook (void) { } + virtual void restore_pre_input_hook () { } virtual void set_event_hook (event_hook_fcn) { } - virtual void restore_event_hook (void) { } + virtual void restore_event_hook () { } virtual void do_read_init_file (const std::string&) { } - virtual void do_re_read_init_file (void) { } + virtual void do_re_read_init_file () { } virtual bool do_filename_completion_desired (bool) { return false; } @@ -373,14 +373,14 @@ virtual void do_interrupt (bool) { } - virtual void do_handle_interrupt_signal (void) { } + virtual void do_handle_interrupt_signal () { } void do_interrupt_event_loop (bool arg) { m_interrupt_event_loop = arg; } - bool do_event_loop_interrupted (void) const + bool do_event_loop_interrupted () const { return m_interrupt_event_loop; } - int do_insert_initial_input (void); + int do_insert_initial_input (); int read_octal (const std::string& s); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/cmd-hist.cc --- a/liboctave/util/cmd-hist.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/cmd-hist.cc Tue Jan 24 17:19:44 2023 -0800 @@ -61,40 +61,40 @@ { public: - gnu_history (void) + gnu_history () : command_history (), mark (0) { } - ~gnu_history (void) = default; + ~gnu_history () = default; void do_process_histcontrol (const std::string&); - std::string do_histcontrol (void) const; + std::string do_histcontrol () const; bool do_add (const std::string&); void do_remove (int); - void do_clear (void); + void do_clear (); - int do_where (void) const; + int do_where () const; - int do_length (void) const; + int do_length () const; - int do_max_input_history (void) const; + int do_max_input_history () const; - int do_base (void) const; + int do_base () const; - int do_current_number (void) const; + int do_current_number () const; void do_stifle (int); - int do_unstifle (void); + int do_unstifle (); - int do_is_stifled (void) const; + int do_is_stifled () const; void do_set_mark (int); - int do_goto_mark (void); + int do_goto_mark (); void do_read (const std::string&, bool); @@ -160,7 +160,7 @@ } std::string -gnu_history::do_histcontrol (void) const +gnu_history::do_histcontrol () const { // FIXME: instead of reconstructing this value, should we just save // the string we were given when constructing the command_history object? @@ -217,37 +217,37 @@ } void -gnu_history::do_clear (void) +gnu_history::do_clear () { ::octave_clear_history (); } int -gnu_history::do_where (void) const +gnu_history::do_where () const { return ::octave_where_history (); } int -gnu_history::do_length (void) const +gnu_history::do_length () const { return ::octave_history_length (); } int -gnu_history::do_max_input_history (void) const +gnu_history::do_max_input_history () const { return ::octave_max_input_history (); } int -gnu_history::do_base (void) const +gnu_history::do_base () const { return ::octave_history_base (); } int -gnu_history::do_current_number (void) const +gnu_history::do_current_number () const { return m_size > 0 ? do_base () + do_where () : -1; } @@ -259,13 +259,13 @@ } int -gnu_history::do_unstifle (void) +gnu_history::do_unstifle () { return ::octave_unstifle_history (); } int -gnu_history::do_is_stifled (void) const +gnu_history::do_is_stifled () const { return ::octave_history_is_stifled (); } @@ -277,7 +277,7 @@ } int -gnu_history::do_goto_mark (void) +gnu_history::do_goto_mark () { if (mark) { @@ -512,7 +512,7 @@ #endif bool -command_history::instance_ok (void) +command_history::instance_ok () { bool retval = true; @@ -532,7 +532,7 @@ } void -command_history::make_command_history (void) +command_history::make_command_history () { #if defined (USE_READLINE) s_instance = new gnu_history (); @@ -551,7 +551,7 @@ } bool -command_history::is_initialized (void) +command_history::is_initialized () { // We just want to check the status of an existing instance, not // create one. @@ -570,7 +570,7 @@ } std::string -command_history::file (void) +command_history::file () { return instance_ok () ? s_instance->do_file () : ""; } @@ -583,7 +583,7 @@ } std::string -command_history::histcontrol (void) +command_history::histcontrol () { return instance_ok () ? s_instance->do_histcontrol () : ""; } @@ -596,7 +596,7 @@ } int -command_history::size (void) +command_history::size () { return instance_ok () ? s_instance->do_size () : 0; } @@ -609,7 +609,7 @@ } bool -command_history::ignoring_entries (void) +command_history::ignoring_entries () { return instance_ok () ? s_instance->do_ignoring_entries () : false; } @@ -630,38 +630,38 @@ } void -command_history::clear (void) +command_history::clear () { if (instance_ok ()) s_instance->do_clear (); } int -command_history::where (void) +command_history::where () { return instance_ok () ? s_instance->do_where () : 0; } int -command_history::length (void) +command_history::length () { return instance_ok () ? s_instance->do_length () : 0; } int -command_history::max_input_history (void) +command_history::max_input_history () { return instance_ok () ? s_instance->do_max_input_history () : 0; } int -command_history::base (void) +command_history::base () { return instance_ok () ? s_instance->do_base () : 0; } int -command_history::current_number (void) +command_history::current_number () { return instance_ok () ? s_instance->do_current_number () : 0; } @@ -674,13 +674,13 @@ } int -command_history::unstifle (void) +command_history::unstifle () { return instance_ok () ? s_instance->do_unstifle () : 0; } int -command_history::is_stifled (void) +command_history::is_stifled () { return instance_ok () ? s_instance->do_is_stifled () : 0; } @@ -693,7 +693,7 @@ } int -command_history::goto_mark (void) +command_history::goto_mark () { return instance_ok () ? s_instance->do_goto_mark () : 0; } @@ -793,7 +793,7 @@ } bool -command_history::do_is_initialized (void) const +command_history::do_is_initialized () const { return m_initialized; } @@ -805,7 +805,7 @@ } std::string -command_history::do_file (void) +command_history::do_file () { return m_file; } @@ -817,7 +817,7 @@ } int -command_history::do_size (void) const +command_history::do_size () const { return m_size; } @@ -829,7 +829,7 @@ } bool -command_history::do_ignoring_entries (void) const +command_history::do_ignoring_entries () const { return m_ignoring_additions; } @@ -845,35 +845,35 @@ { } void -command_history::do_clear (void) +command_history::do_clear () { } int -command_history::do_where (void) const +command_history::do_where () const { return 0; } int -command_history::do_length (void) const +command_history::do_length () const { return 0; } int -command_history::do_max_input_history (void) const +command_history::do_max_input_history () const { return 0; } int -command_history::do_base (void) const +command_history::do_base () const { return 0; } int -command_history::do_current_number (void) const +command_history::do_current_number () const { return m_size > 0 ? do_base () + do_where () : -1; } @@ -883,13 +883,13 @@ { } int -command_history::do_unstifle (void) +command_history::do_unstifle () { return -1; } int -command_history::do_is_stifled (void) const +command_history::do_is_stifled () const { return 0; } @@ -899,7 +899,7 @@ { } int -command_history::do_goto_mark (void) +command_history::do_goto_mark () { return 0; } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/cmd-hist.h --- a/liboctave/util/cmd-hist.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/cmd-hist.h Tue Jan 24 17:19:44 2023 -0800 @@ -40,7 +40,7 @@ { protected: - command_history (void) + command_history () : m_initialized (false), m_ignoring_additions (false), m_history_control (0), m_lines_in_file (0), m_lines_this_session (0), m_file (), m_size (-1) @@ -54,56 +54,56 @@ command_history& operator = (const command_history&) = delete; - virtual ~command_history (void) = default; + virtual ~command_history () = default; static void initialize (bool, const std::string&, int, const std::string&); - static bool is_initialized (void); + static bool is_initialized (); static void set_file (const std::string&); - static std::string file (void); + static std::string file (); static void process_histcontrol (const std::string&); - static std::string histcontrol (void); + static std::string histcontrol (); static void set_size (int); - static int size (void); + static int size (); static void ignore_entries (bool = true); - static bool ignoring_entries (void); + static bool ignoring_entries (); static bool add (const std::string&); static void remove (int); - static void clear (void); + static void clear (); - static int where (void); + static int where (); - static int length (void); + static int length (); - static int max_input_history (void); + static int max_input_history (); - static int base (void); + static int base (); - static int current_number (void); + static int current_number (); static void stifle (int); - static int unstifle (void); + static int unstifle (); - static int is_stifled (void); + static int is_stifled (); static void set_mark (int n); // Gag. This declaration has to match the Function typedef in // readline.h. - static int goto_mark (void); + static int goto_mark (); static void read (bool = true); @@ -130,14 +130,14 @@ private: - static bool instance_ok (void); + static bool instance_ok (); - static void make_command_history (void); + static void make_command_history (); // The real thing. static command_history *s_instance; - static void cleanup_instance (void) + static void cleanup_instance () { delete s_instance; s_instance = nullptr; @@ -151,50 +151,50 @@ virtual void do_set_file (const std::string&); - virtual std::string do_file (void); + virtual std::string do_file (); virtual void do_process_histcontrol (const std::string&); - virtual std::string do_histcontrol (void) const { return ""; } + virtual std::string do_histcontrol () const { return ""; } virtual void do_initialize (bool, const std::string&, int, const std::string&); - virtual bool do_is_initialized (void) const; + virtual bool do_is_initialized () const; virtual void do_set_size (int); - virtual int do_size (void) const; + virtual int do_size () const; virtual void do_ignore_entries (bool); - virtual bool do_ignoring_entries (void) const; + virtual bool do_ignoring_entries () const; virtual bool do_add (const std::string&); virtual void do_remove (int); - virtual void do_clear (void); + virtual void do_clear (); - virtual int do_where (void) const; + virtual int do_where () const; - virtual int do_length (void) const; + virtual int do_length () const; - virtual int do_max_input_history (void) const; + virtual int do_max_input_history () const; - virtual int do_base (void) const; + virtual int do_base () const; - virtual int do_current_number (void) const; + virtual int do_current_number () const; virtual void do_stifle (int); - virtual int do_unstifle (void); + virtual int do_unstifle (); - virtual int do_is_stifled (void) const; + virtual int do_is_stifled () const; virtual void do_set_mark (int); - virtual int do_goto_mark (void); + virtual int do_goto_mark (); virtual void do_read (const std::string&, bool); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/data-conv.cc --- a/liboctave/util/data-conv.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/data-conv.cc Tue Jan 24 17:19:44 2023 -0800 @@ -616,7 +616,7 @@ OCTAVE_NORETURN static void -err_unrecognized_float_fmt (void) +err_unrecognized_float_fmt () { (*current_liboctave_error_handler) ("unrecognized floating point format requested"); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/file-info.h --- a/liboctave/util/file-info.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/file-info.h Tue Jan 24 17:19:44 2023 -0800 @@ -41,7 +41,7 @@ { public: - file_info (void) + file_info () : m_file_buf (), m_offsets (), m_timestamp (static_cast (0)) { } @@ -60,22 +60,22 @@ file_info& operator = (const file_info&) = default; - ~file_info (void) = default; + ~file_info () = default; OCTAVE_API std::string get_line (std::size_t line) const; OCTAVE_API std::deque get_lines (std::size_t line, std::size_t num_lines) const; - std::size_t num_lines (void) const { return m_offsets.size (); } + std::size_t num_lines () const { return m_offsets.size (); } - std::string text (void) const { return m_file_buf; } + std::string text () const { return m_file_buf; } - std::vector line_offsets (void) const { return m_offsets; } + std::vector line_offsets () const { return m_offsets; } - sys::time timestamp (void) const { return m_timestamp; } + sys::time timestamp () const { return m_timestamp; } - std::size_t size (void) const { return m_file_buf.length (); } + std::size_t size () const { return m_file_buf.length (); } private: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/glob-match.cc --- a/liboctave/util/glob-match.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/glob-match.cc Tue Jan 24 17:19:44 2023 -0800 @@ -38,7 +38,7 @@ } string_vector -glob_match::glob (void) const +glob_match::glob () const { return octave::sys::glob (m_pat); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/glob-match.h --- a/liboctave/util/glob-match.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/glob-match.h Tue Jan 24 17:19:44 2023 -0800 @@ -60,7 +60,7 @@ glob_match& operator = (const glob_match& gm) = default; - ~glob_match (void) = default; + ~glob_match () = default; void set_pattern (const std::string& p) { m_pat = p; } @@ -83,7 +83,7 @@ // We forward to glob_internal here to avoid problems with gnulib's // glob.h defining glob to be rpl_glob. - string_vector glob (void) const; + string_vector glob () const; private: diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/kpse.cc --- a/liboctave/util/kpse.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/kpse.cc Tue Jan 24 17:19:44 2023 -0800 @@ -92,7 +92,7 @@ unsigned int kpse_debug = 0; void -kpse_path_iterator::set_end (void) +kpse_path_iterator::set_end () { m_e = m_b + 1; @@ -111,7 +111,7 @@ } void -kpse_path_iterator::next (void) +kpse_path_iterator::next () { m_b = m_e + 1; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/kpse.h --- a/liboctave/util/kpse.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/kpse.h Tue Jan 24 17:19:44 2023 -0800 @@ -50,7 +50,7 @@ kpse_path_iterator& operator = (const kpse_path_iterator&) = delete; - ~kpse_path_iterator (void) = default; + ~kpse_path_iterator () = default; kpse_path_iterator operator ++ (int) { @@ -59,7 +59,7 @@ return retval; } - std::string operator * (void) { return m_path.substr (m_b, m_e-m_b); } + std::string operator * () { return m_path.substr (m_b, m_e-m_b); } bool operator != (const std::size_t sz) { return m_b != sz; } @@ -70,8 +70,8 @@ std::size_t m_e; std::size_t m_len; - void set_end (void); - void next (void); + void set_end (); + void next (); }; extern unsigned int kpse_debug; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/lo-array-errwarn.cc --- a/liboctave/util/lo-array-errwarn.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/lo-array-errwarn.cc Tue Jan 24 17:19:44 2023 -0800 @@ -54,14 +54,14 @@ static const char *warning_id_singular_matrix = "Octave:singular-matrix"; void -err_nan_to_logical_conversion (void) +err_nan_to_logical_conversion () { (*current_liboctave_error_handler) ("invalid conversion from NaN to logical"); } void -err_nan_to_character_conversion (void) +err_nan_to_character_conversion () { (*current_liboctave_error_handler) ("invalid conversion from NaN to character"); @@ -124,7 +124,7 @@ // offending one, e.g., (), (,_), or (_,,...[x5]...) std::string -index_exception::expression (void) const +index_exception::expression () const { std::ostringstream buf; @@ -179,7 +179,7 @@ update_message (); } - void update_message (void) + void update_message () { static std::string exp = std::to_string (std::numeric_limits::digits); @@ -190,7 +190,7 @@ } // ID of error to throw - const char * err_id (void) const + const char * err_id () const { return error_id_invalid_index; } @@ -247,7 +247,7 @@ update_message (); } - void update_message (void) + void update_message () { set_message (expression () + ": out of bound " + std::to_string (m_extent) @@ -255,7 +255,7 @@ } // ID of error to throw. - const char * err_id (void) const + const char * err_id () const { return error_id_index_out_of_bounds; } @@ -278,7 +278,7 @@ } void -err_invalid_resize (void) +err_invalid_resize () { (*current_liboctave_error_with_id_handler) ("Octave:invalid-resize", diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/lo-array-errwarn.h --- a/liboctave/util/lo-array-errwarn.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/lo-array-errwarn.h Tue Jan 24 17:19:44 2023 -0800 @@ -52,13 +52,13 @@ set_message (expression ()); } - ~index_exception (void) = default; + ~index_exception () = default; // ID of error to throw. - virtual const char * err_id (void) const = 0; + virtual const char * err_id () const = 0; // By default, update message to show the erroneous index expression. - virtual void update_message (void) { set_message (expression ()); } + virtual void update_message () { set_message (expression ()); } // Position of error: dimension in error, and number of dimensions. void set_pos (octave_idx_type nd_arg, octave_idx_type dim_arg) @@ -96,7 +96,7 @@ protected: // Show what's wrong, e.g., A(-1,_), A(0+1i). - OCTAVE_API std::string expression (void) const; + OCTAVE_API std::string expression () const; // Number of dimensions of indexed object. octave_idx_type m_nd; @@ -109,10 +109,10 @@ }; OCTAVE_NORETURN extern OCTAVE_API void -err_nan_to_logical_conversion (void); +err_nan_to_logical_conversion (); OCTAVE_NORETURN extern OCTAVE_API void -err_nan_to_character_conversion (void); +err_nan_to_character_conversion (); OCTAVE_NORETURN extern OCTAVE_API void err_nonconformant (const char *op, octave_idx_type op1_len, @@ -151,7 +151,7 @@ const std::string& var = ""); OCTAVE_NORETURN extern OCTAVE_API void -err_invalid_resize (void); +err_invalid_resize (); extern OCTAVE_API void warn_singular_matrix (double rcond = 0.0); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/lo-hash.cc --- a/liboctave/util/lo-hash.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/lo-hash.cc Tue Jan 24 17:19:44 2023 -0800 @@ -57,14 +57,14 @@ return buf.str (); } -int md2_digest_size (void) { return octave_md2_digest_size (); } -int md4_digest_size (void) { return octave_md4_digest_size (); } -int md5_digest_size (void) { return octave_md5_digest_size (); } -int sha1_digest_size (void) { return octave_sha1_digest_size (); } -int sha224_digest_size (void) { return octave_sha224_digest_size (); } -int sha256_digest_size (void) { return octave_sha256_digest_size (); } -int sha384_digest_size (void) { return octave_sha384_digest_size (); } -int sha512_digest_size (void) { return octave_sha512_digest_size (); } +int md2_digest_size () { return octave_md2_digest_size (); } +int md4_digest_size () { return octave_md4_digest_size (); } +int md5_digest_size () { return octave_md5_digest_size (); } +int sha1_digest_size () { return octave_sha1_digest_size (); } +int sha224_digest_size () { return octave_sha224_digest_size (); } +int sha256_digest_size () { return octave_sha256_digest_size (); } +int sha384_digest_size () { return octave_sha384_digest_size (); } +int sha512_digest_size () { return octave_sha512_digest_size (); } std::string md2_hash (const std::string& str) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/lo-hash.h --- a/liboctave/util/lo-hash.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/lo-hash.h Tue Jan 24 17:19:44 2023 -0800 @@ -39,14 +39,14 @@ OCTAVE_API std::string hash (hash_fptr hash_fcn, const std::string& str, int result_buf_len); -OCTAVE_API int md2_digest_size (void); -OCTAVE_API int md4_digest_size (void); -OCTAVE_API int md5_digest_size (void); -OCTAVE_API int sha1_digest_size (void); -OCTAVE_API int sha224_digest_size (void); -OCTAVE_API int sha256_digest_size (void); -OCTAVE_API int sha384_digest_size (void); -OCTAVE_API int sha512_digest_size (void); +OCTAVE_API int md2_digest_size (); +OCTAVE_API int md4_digest_size (); +OCTAVE_API int md5_digest_size (); +OCTAVE_API int sha1_digest_size (); +OCTAVE_API int sha224_digest_size (); +OCTAVE_API int sha256_digest_size (); +OCTAVE_API int sha384_digest_size (); +OCTAVE_API int sha512_digest_size (); OCTAVE_API std::string md2_hash (const std::string& str); OCTAVE_API std::string md4_hash (const std::string& str); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/lo-ieee.cc --- a/liboctave/util/lo-ieee.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/lo-ieee.cc Tue Jan 24 17:19:44 2023 -0800 @@ -65,7 +65,7 @@ } double -lo_ieee_inf_value (void) +lo_ieee_inf_value () { octave_ieee_init (); @@ -73,7 +73,7 @@ } double -lo_ieee_na_value (void) +lo_ieee_na_value () { octave_ieee_init (); @@ -81,7 +81,7 @@ } double -lo_ieee_nan_value (void) +lo_ieee_nan_value () { octave_ieee_init (); @@ -97,7 +97,7 @@ } float -lo_ieee_float_inf_value (void) +lo_ieee_float_inf_value () { octave_ieee_init (); @@ -105,7 +105,7 @@ } float -lo_ieee_float_na_value (void) +lo_ieee_float_na_value () { octave_ieee_init (); @@ -113,7 +113,7 @@ } float -lo_ieee_float_nan_value (void) +lo_ieee_float_nan_value () { octave_ieee_init (); @@ -121,7 +121,7 @@ } void -octave_ieee_init (void) +octave_ieee_init () { static bool initialized = false; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/lo-ieee.h --- a/liboctave/util/lo-ieee.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/lo-ieee.h Tue Jan 24 17:19:44 2023 -0800 @@ -129,27 +129,27 @@ struct numeric_limits { public: - static T NA (void) { return static_cast (0); } - static T NaN (void) { return static_cast (0); } - static T Inf (void) { return static_cast (0); } + static T NA () { return static_cast (0); } + static T NaN () { return static_cast (0); } + static T Inf () { return static_cast (0); } }; template <> struct numeric_limits { public: - static double NA (void) { return octave_NA; } - static double NaN (void) { return octave_NaN; } - static double Inf (void) { return octave_Inf; } + static double NA () { return octave_NA; } + static double NaN () { return octave_NaN; } + static double Inf () { return octave_Inf; } }; template <> struct numeric_limits { public: - static float NA (void) { return octave_Float_NA; } - static float NaN (void) { return octave_Float_NaN; } - static float Inf (void) { return octave_Float_Inf; } + static float NA () { return octave_Float_NA; } + static float NaN () { return octave_Float_NaN; } + static float Inf () { return octave_Float_Inf; } }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/lo-regexp.cc --- a/liboctave/util/lo-regexp.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/lo-regexp.cc Tue Jan 24 17:19:44 2023 -0800 @@ -112,13 +112,13 @@ // the user doesn't want. void -regexp::free (void) +regexp::free () { octave_pcre_code_free (static_cast (m_code)); } void -regexp::compile_internal (void) +regexp::compile_internal () { // If we had a previously compiled pattern, release it. free (); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/lo-regexp.h --- a/liboctave/util/lo-regexp.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/lo-regexp.h Tue Jan 24 17:19:44 2023 -0800 @@ -61,7 +61,7 @@ regexp& operator = (const regexp& rx) = default; - ~regexp (void) { free (); } + ~regexp () { free (); } void compile (const std::string& pat, const regexp::opts& opt = regexp::opts ()) @@ -125,7 +125,7 @@ { public: - opts (void) + opts () : m_case_insensitive (false), m_dotexceptnewline (false), m_emptymatch (false), m_freespacing (false), m_lineanchors (false), m_once (false) { } @@ -134,7 +134,7 @@ opts& operator = (const opts&) = default; - ~opts (void) = default; + ~opts () = default; void case_insensitive (bool val) { m_case_insensitive = val; } void dotexceptnewline (bool val) { m_dotexceptnewline = val; } @@ -143,12 +143,12 @@ void lineanchors (bool val) { m_lineanchors = val; } void once (bool val) { m_once = val; } - bool case_insensitive (void) const { return m_case_insensitive; } - bool dotexceptnewline (void) const { return m_dotexceptnewline; } - bool emptymatch (void) const { return m_emptymatch; } - bool freespacing (void) const { return m_freespacing; } - bool lineanchors (void) const { return m_lineanchors; } - bool once (void) const { return m_once; } + bool case_insensitive () const { return m_case_insensitive; } + bool dotexceptnewline () const { return m_dotexceptnewline; } + bool emptymatch () const { return m_emptymatch; } + bool freespacing () const { return m_freespacing; } + bool lineanchors () const { return m_lineanchors; } + bool once () const { return m_once; } private: @@ -175,12 +175,12 @@ match_element& operator = (const match_element&) = default; - std::string match_string (void) const { return m_match_string; } - string_vector named_tokens (void) const { return m_named_tokens; } - string_vector tokens (void) const { return m_tokens; } - Matrix token_extents (void) const { return m_token_extents; } - double start (void) const { return m_start; } - double end (void) const { return m_end; } + std::string match_string () const { return m_match_string; } + string_vector named_tokens () const { return m_named_tokens; } + string_vector tokens () const { return m_tokens; } + Matrix token_extents () const { return m_token_extents; } + double start () const { return m_start; } + double end () const { return m_end; } private: @@ -200,7 +200,7 @@ { public: - match_data (void) + match_data () : base_list (), m_named_pats () { } @@ -212,9 +212,9 @@ match_data& operator = (const match_data&) = default; - ~match_data (void) = default; + ~match_data () = default; - string_vector named_patterns (void) const { return m_named_pats; } + string_vector named_patterns () const { return m_named_pats; } private: @@ -236,9 +236,9 @@ Array m_named_idx; std::string m_who; - void free (void); + void free (); - void compile_internal (void); + void compile_internal (); }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/oct-inttypes.cc --- a/liboctave/util/oct-inttypes.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/oct-inttypes.cc Tue Jan 24 17:19:44 2023 -0800 @@ -42,7 +42,7 @@ #define DEFINE_OCTAVE_INT_TYPENAME(TYPE, TYPENAME) \ template <> \ OCTAVE_API const char * \ - octave_int::type_name (void) { return TYPENAME; } + octave_int::type_name () { return TYPENAME; } DEFINE_OCTAVE_INT_TYPENAME (int8_t, "int8") DEFINE_OCTAVE_INT_TYPENAME (int16_t, "int16") diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/oct-inttypes.h --- a/liboctave/util/oct-inttypes.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/oct-inttypes.h Tue Jan 24 17:19:44 2023 -0800 @@ -346,8 +346,8 @@ { public: - static T min_val (void) { return std::numeric_limits::min (); } - static T max_val (void) { return std::numeric_limits::max (); } + static T min_val () { return std::numeric_limits::min (); } + static T max_val () { return std::numeric_limits::max (); } // Convert integer value. @@ -787,7 +787,7 @@ typedef T val_type; - octave_int (void) : m_ival () { } + octave_int () : m_ival () { } octave_int (T i) : m_ival (i) { } @@ -827,26 +827,26 @@ octave_int& operator = (const octave_int&) = default; - ~octave_int (void) = default; + ~octave_int () = default; - T value (void) const { return m_ival; } + T value () const { return m_ival; } - const unsigned char * iptr (void) const + const unsigned char * iptr () const { return reinterpret_cast (& m_ival); } - bool operator ! (void) const { return ! m_ival; } + bool operator ! () const { return ! m_ival; } - bool bool_value (void) const { return static_cast (value ()); } + bool bool_value () const { return static_cast (value ()); } - char char_value (void) const { return static_cast (value ()); } + char char_value () const { return static_cast (value ()); } - double double_value (void) const { return static_cast (value ()); } + double double_value () const { return static_cast (value ()); } - float float_value (void) const { return static_cast (value ()); } + float float_value () const { return static_cast (value ()); } - operator T (void) const { return value (); } + operator T () const { return value (); } octave_int operator + () const { return *this; } @@ -864,7 +864,7 @@ #undef OCTAVE_INT_UN_OP - octave_int operator ~ (void) const + octave_int operator ~ () const { T bitinv = ~ m_ival; return bitinv; @@ -895,12 +895,12 @@ #undef OCTAVE_INT_BIN_OP - static octave_int min (void) { return std::numeric_limits::min (); } - static octave_int max (void) { return std::numeric_limits::max (); } + static octave_int min () { return std::numeric_limits::min (); } + static octave_int max () { return std::numeric_limits::max (); } - static int nbits (void) { return std::numeric_limits::digits; } + static int nbits () { return std::numeric_limits::digits; } - static int byte_size (void) { return sizeof (T); } + static int byte_size () { return sizeof (T); } static const OCTAVE_API char * type_name (); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/oct-mutex.cc --- a/liboctave/util/oct-mutex.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/oct-mutex.cc Tue Jan 24 17:19:44 2023 -0800 @@ -39,19 +39,19 @@ OCTAVE_BEGIN_NAMESPACE(octave) void -base_mutex::lock (void) +base_mutex::lock () { (*current_liboctave_error_handler) ("mutex not supported on this platform"); } void -base_mutex::unlock (void) +base_mutex::unlock () { (*current_liboctave_error_handler) ("mutex not supported on this platform"); } bool -base_mutex::try_lock (void) +base_mutex::try_lock () { (*current_liboctave_error_handler) ("mutex not supported on this platform"); @@ -64,28 +64,28 @@ w32_mutex : public base_mutex { public: - w32_mutex (void) + w32_mutex () : base_mutex () { InitializeCriticalSection (&cs); } - ~w32_mutex (void) + ~w32_mutex () { DeleteCriticalSection (&cs); } - void lock (void) + void lock () { EnterCriticalSection (&cs); } - void unlock (void) + void unlock () { LeaveCriticalSection (&cs); } - bool try_lock (void) + bool try_lock () { return (TryEnterCriticalSection (&cs) != 0); } @@ -97,13 +97,13 @@ static DWORD thread_id = 0; void -thread::init (void) +thread::init () { thread_id = GetCurrentThreadId (); } bool -thread::is_thread (void) +thread::is_thread () { return (GetCurrentThreadId () == thread_id); } @@ -114,7 +114,7 @@ pthread_mutex : public base_mutex { public: - pthread_mutex (void) + pthread_mutex () : base_mutex (), m_pm () { pthread_mutexattr_t attr; @@ -125,22 +125,22 @@ pthread_mutexattr_destroy (&attr); } - ~pthread_mutex (void) + ~pthread_mutex () { pthread_mutex_destroy (&m_pm); } - void lock (void) + void lock () { pthread_mutex_lock (&m_pm); } - void unlock (void) + void unlock () { pthread_mutex_unlock (&m_pm); } - bool try_lock (void) + bool try_lock () { return (pthread_mutex_trylock (&m_pm) == 0); } @@ -152,13 +152,13 @@ static pthread_t thread_id = 0; void -thread::init (void) +thread::init () { thread_id = pthread_self (); } bool -thread::is_thread (void) +thread::is_thread () { return (pthread_equal (thread_id, pthread_self ()) != 0); } @@ -166,7 +166,7 @@ #endif static base_mutex * -init_rep (void) +init_rep () { #if defined (OCTAVE_USE_WINDOWS_API) return new w32_mutex (); @@ -177,6 +177,6 @@ #endif } -mutex::mutex (void) : m_rep (init_rep ()) { } +mutex::mutex () : m_rep (init_rep ()) { } OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/oct-mutex.h --- a/liboctave/util/oct-mutex.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/oct-mutex.h Tue Jan 24 17:19:44 2023 -0800 @@ -41,15 +41,15 @@ public: friend class mutex; - base_mutex (void) = default; + base_mutex () = default; - virtual ~base_mutex (void) = default; + virtual ~base_mutex () = default; - virtual void lock (void); + virtual void lock (); - virtual void unlock (void); + virtual void unlock (); - virtual bool try_lock (void); + virtual bool try_lock (); }; class @@ -57,25 +57,25 @@ mutex { public: - mutex (void); + mutex (); mutex (const mutex& m) = default; - ~mutex (void) = default; + ~mutex () = default; mutex& operator = (const mutex& m) = default; - void lock (void) + void lock () { m_rep->lock (); } - void unlock (void) + void unlock () { m_rep->unlock (); } - bool try_lock (void) + bool try_lock () { return m_rep->try_lock (); } @@ -107,15 +107,15 @@ autolock& operator = (const autolock&) = delete; - ~autolock (void) + ~autolock () { if (m_lock_result) m_mutex.unlock (); } - bool ok (void) const { return m_lock_result; } + bool ok () const { return m_lock_result; } - operator bool (void) const { return ok (); } + operator bool () const { return ok (); } private: @@ -131,9 +131,9 @@ { public: - static void init (void); + static void init (); - static bool is_thread (void); + static bool is_thread (); }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/oct-refcount.h --- a/liboctave/util/oct-refcount.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/oct-refcount.h Tue Jan 24 17:19:44 2023 -0800 @@ -49,10 +49,10 @@ refcount& operator = (const refcount&) = delete; - ~refcount (void) = default; + ~refcount () = default; // Increment/Decrement. int is postfix. - count_type operator++ (void) + count_type operator++ () { return ++m_count; } @@ -62,7 +62,7 @@ return m_count++; } - count_type operator-- (void) + count_type operator-- () { return --m_count; } @@ -72,12 +72,12 @@ return m_count--; } - count_type value (void) const + count_type value () const { return m_count.load (); } - operator count_type (void) const + operator count_type () const { return value (); } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/oct-shlib.cc --- a/liboctave/util/oct-shlib.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/oct-shlib.cc Tue Jan 24 17:19:44 2023 -0800 @@ -62,12 +62,12 @@ std::list possibly_unreferenced_dynamic_libraries; -void dynamic_library::delete_later (void) +void dynamic_library::delete_later () { possibly_unreferenced_dynamic_libraries.push_back (*this); } -int release_unreferenced_dynamic_libraries (void) +int release_unreferenced_dynamic_libraries () { possibly_unreferenced_dynamic_libraries.clear (); @@ -87,14 +87,14 @@ } bool -dynamic_library::dynlib_rep::is_out_of_date (void) const +dynamic_library::dynlib_rep::is_out_of_date () const { sys::file_stat fs (m_file); return (fs && fs.is_newer (m_time_loaded)); } void -dynamic_library::dynlib_rep::fake_reload (void) +dynamic_library::dynlib_rep::fake_reload () { // We can't actually reload the library, but we'll pretend we did. sys::file_stat fs (m_file); @@ -127,7 +127,7 @@ } std::list -dynamic_library::dynlib_rep::function_names (void) const +dynamic_library::dynlib_rep::function_names () const { std::list retval; @@ -184,7 +184,7 @@ octave_dlopen_shlib& operator = (const octave_dlopen_shlib&) = delete; - ~octave_dlopen_shlib (void); + ~octave_dlopen_shlib (); void * search (const std::string& name, const dynamic_library::name_mangler& mangler @@ -194,7 +194,7 @@ // normally throw an exception, avoiding the construction of an invalid // library. Leave it here for possible future use. - bool is_open (void) const + bool is_open () const { return (m_search_all_loaded || m_library != nullptr); } @@ -246,7 +246,7 @@ } } -octave_dlopen_shlib::~octave_dlopen_shlib (void) +octave_dlopen_shlib::~octave_dlopen_shlib () { if (m_library) dlclose (m_library); @@ -290,7 +290,7 @@ octave_w32_shlib& operator = (const octave_w32_shlib&) = delete; - ~octave_w32_shlib (void); + ~octave_w32_shlib (); void * search (const std::string& name, const dynamic_library::name_mangler& mangler @@ -298,7 +298,7 @@ void * global_search (const std::string& sym_name); - bool is_open (void) const + bool is_open () const { return (m_search_all_loaded || m_handle != nullptr); } @@ -354,7 +354,7 @@ } } -octave_w32_shlib::~octave_w32_shlib (void) +octave_w32_shlib::~octave_w32_shlib () { if (m_handle) FreeLibrary (m_handle); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/oct-shlib.h --- a/liboctave/util/oct-shlib.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/oct-shlib.h Tue Jan 24 17:19:44 2023 -0800 @@ -49,7 +49,7 @@ { public: - dynlib_rep (void) + dynlib_rep () : m_count (1), m_fcn_names (), m_file (), m_time_loaded (OCTAVE_TIME_T ()), m_search_all_loaded (false) { } @@ -61,40 +61,40 @@ public: - virtual ~dynlib_rep (void) + virtual ~dynlib_rep () { s_instances.erase (m_file); } - virtual bool is_open (void) const + virtual bool is_open () const { return false; } virtual void * search (const std::string&, const name_mangler& = name_mangler ()) { return nullptr; } - OCTAVE_API bool is_out_of_date (void) const; + OCTAVE_API bool is_out_of_date () const; // This method will be overridden conditionally. static OCTAVE_API dynlib_rep * new_instance (const std::string& f); static OCTAVE_API dynlib_rep * get_instance (const std::string& f, bool fake); - sys::time time_loaded (void) const + sys::time time_loaded () const { return m_time_loaded; } - std::string file_name (void) const + std::string file_name () const { return m_file; } - std::size_t num_fcn_names (void) const { return m_fcn_names.size (); } + std::size_t num_fcn_names () const { return m_fcn_names.size (); } - OCTAVE_API std::list function_names (void) const; + OCTAVE_API std::list function_names () const; OCTAVE_API void add_fcn_name (const std::string&); OCTAVE_API bool remove_fcn_name (const std::string&); - void clear_fcn_names (void) { m_fcn_names.clear (); } + void clear_fcn_names () { m_fcn_names.clear (); } public: @@ -102,7 +102,7 @@ protected: - OCTAVE_API void fake_reload (void); + OCTAVE_API void fake_reload (); static OCTAVE_API std::map s_instances; @@ -122,18 +122,18 @@ public: - dynamic_library (void) : m_rep (&s_nil_rep) { m_rep->m_count++; } + dynamic_library () : m_rep (&s_nil_rep) { m_rep->m_count++; } dynamic_library (const std::string& f, bool fake = true) : m_rep (dynlib_rep::get_instance (f, fake)) { } - ~dynamic_library (void) + ~dynamic_library () { if (--m_rep->m_count == 0 && m_rep != &s_nil_rep) delete m_rep; } - OCTAVE_API void delete_later (void); + OCTAVE_API void delete_later (); dynamic_library (const dynamic_library& sl) : m_rep (sl.m_rep) @@ -163,7 +163,7 @@ void open (const std::string& f) { *this = dynamic_library (f); } - std::list close (void) + std::list close () { std::list removed_fcns = m_rep->function_names (); @@ -190,16 +190,16 @@ bool remove (const std::string& name) { return m_rep->remove_fcn_name (name); } - std::size_t number_of_functions_loaded (void) const + std::size_t number_of_functions_loaded () const { return m_rep->num_fcn_names (); } - bool is_out_of_date (void) const + bool is_out_of_date () const { return m_rep->is_out_of_date (); } - std::string file_name (void) const + std::string file_name () const { return m_rep->file_name (); } - sys::time time_loaded (void) const + sys::time time_loaded () const { return m_rep->time_loaded (); } private: @@ -210,7 +210,7 @@ // FIXME: Currently must return int so that it may be used as an // event_hook function. -OCTAVE_API int release_unreferenced_dynamic_libraries (void); +OCTAVE_API int release_unreferenced_dynamic_libraries (); OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/oct-sort.cc --- a/liboctave/util/oct-sort.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/oct-sort.cc Tue Jan 24 17:19:44 2023 -0800 @@ -119,7 +119,7 @@ #include "oct-locbuf.h" template -octave_sort::octave_sort (void) : +octave_sort::octave_sort () : m_compare (ascending_compare), m_ms (nullptr) { } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/oct-sort.h --- a/liboctave/util/oct-sort.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/oct-sort.h Tue Jan 24 17:19:44 2023 -0800 @@ -106,7 +106,7 @@ typedef std::function::type, typename ref_param::type)> compare_fcn_type; - octave_sort (void); + octave_sort (); octave_sort (const compare_fcn_type&); @@ -116,7 +116,7 @@ octave_sort& operator = (const octave_sort&) = delete; - ~octave_sort (void); + ~octave_sort (); void set_compare (const compare_fcn_type& comp) { m_compare = comp; } @@ -199,7 +199,7 @@ { public: - MergeState (void) + MergeState () : m_min_gallop (), m_a (nullptr), m_ia (nullptr), m_alloced (0), m_n (0) { reset (); } @@ -209,10 +209,10 @@ MergeState& operator = (const MergeState&) = delete; - ~MergeState (void) + ~MergeState () { delete [] m_a; delete [] m_ia; } - void reset (void) + void reset () { m_min_gallop = MIN_GALLOP; m_n = 0; } void getmem (octave_idx_type need); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/oct-sparse.cc --- a/liboctave/util/oct-sparse.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/oct-sparse.cc Tue Jan 24 17:19:44 2023 -0800 @@ -37,7 +37,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) static inline void -check_suitesparse_integer_size (void) +check_suitesparse_integer_size () { // FIXME: maybe it would be better to make this a configure check and // disable suitesparse if it fails? diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/octave-preserve-stream-state.h --- a/liboctave/util/octave-preserve-stream-state.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/octave-preserve-stream-state.h Tue Jan 24 17:19:44 2023 -0800 @@ -42,7 +42,7 @@ m_owidth (s.width ()), m_ofill (s.fill ()) { } - ~preserve_stream_state (void) + ~preserve_stream_state () { m_stream.flags (m_oflags); m_stream.precision (m_oprecision); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/pathsearch.cc --- a/liboctave/util/pathsearch.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/pathsearch.cc Tue Jan 24 17:19:44 2023 -0800 @@ -47,12 +47,12 @@ init (); } -std::list directory_path::elements (void) +std::list directory_path::elements () { return m_initialized ? m_path_elements : std::list (); } -std::list directory_path::all_directories (void) +std::list directory_path::all_directories () { std::list retval; @@ -97,7 +97,7 @@ : std::list ()); } -void directory_path::init (void) +void directory_path::init () { static bool octave_kpse_initialized = false; @@ -119,12 +119,12 @@ m_initialized = true; } -char directory_path::path_sep_char (void) +char directory_path::path_sep_char () { return SEPCHAR; } -std::string directory_path::path_sep_str (void) +std::string directory_path::path_sep_str () { return SEPCHAR_STR; } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/pathsearch.h --- a/liboctave/util/pathsearch.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/pathsearch.h Tue Jan 24 17:19:44 2023 -0800 @@ -45,7 +45,7 @@ directory_path& operator = (const directory_path&) = default; - ~directory_path (void) = default; + ~directory_path () = default; void set (const std::string& s) { @@ -54,9 +54,9 @@ init (); } - std::list elements (void); + std::list elements (); - std::list all_directories (void); + std::list all_directories (); std::string find_first (const std::string&); @@ -69,17 +69,17 @@ std::list find_all_first_of (const std::list& names); - void rehash (void) + void rehash () { m_initialized = false; init (); } - static char path_sep_char (void); + static char path_sep_char (); // static void path_sep_char (char c); - static std::string path_sep_str (void); + static std::string path_sep_str (); static bool is_path_sep (char c) { return c == path_sep_char (); } @@ -98,7 +98,7 @@ // The elements of the list. std::list m_path_elements; - void init (void); + void init (); }; OCTAVE_END_NAMESPACE(octave) diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/quit.cc --- a/liboctave/util/quit.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/quit.cc Tue Jan 24 17:19:44 2023 -0800 @@ -39,12 +39,12 @@ volatile sig_atomic_t octave_signal_caught = 0; -void (*octave_signal_hook) (void) = nullptr; -void (*octave_interrupt_hook) (void) = nullptr; +void (*octave_signal_hook) () = nullptr; +void (*octave_interrupt_hook) () = nullptr; OCTAVE_BEGIN_NAMESPACE(octave) -std::string execution_exception::stack_trace (void) const +std::string execution_exception::stack_trace () const { std::size_t nframes = m_stack_info.size (); @@ -98,7 +98,7 @@ OCTAVE_END_NAMESPACE(octave) void -octave_handle_signal (void) +octave_handle_signal () { if (octave_signal_hook) octave_signal_hook (); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/singleton-cleanup.cc --- a/liboctave/util/singleton-cleanup.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/singleton-cleanup.cc Tue Jan 24 17:19:44 2023 -0800 @@ -32,7 +32,7 @@ singleton_cleanup_list *singleton_cleanup_list::s_instance = nullptr; -singleton_cleanup_list::~singleton_cleanup_list (void) +singleton_cleanup_list::~singleton_cleanup_list () { for (fptr fcn : m_fcn_list) { @@ -41,7 +41,7 @@ } bool -singleton_cleanup_list::instance_ok (void) +singleton_cleanup_list::instance_ok () { bool retval = true; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/singleton-cleanup.h --- a/liboctave/util/singleton-cleanup.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/singleton-cleanup.h Tue Jan 24 17:19:44 2023 -0800 @@ -36,11 +36,11 @@ { protected: - singleton_cleanup_list (void) : m_fcn_list () { } + singleton_cleanup_list () : m_fcn_list () { } public: - typedef void (*fptr) (void); + typedef void (*fptr) (); // No copying! @@ -48,7 +48,7 @@ singleton_cleanup_list& operator = (const singleton_cleanup_list&) = delete; - ~singleton_cleanup_list (void); + ~singleton_cleanup_list (); static void add (fptr f) { @@ -56,7 +56,7 @@ s_instance->do_add (f); } - static void cleanup (void) + static void cleanup () { delete s_instance; s_instance = nullptr; @@ -66,9 +66,9 @@ static singleton_cleanup_list *s_instance; - static bool instance_ok (void); + static bool instance_ok (); - static void cleanup_instance (void) + static void cleanup_instance () { delete s_instance; s_instance = nullptr; diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/str-vec.cc --- a/liboctave/util/str-vec.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/str-vec.cc Tue Jan 24 17:19:44 2023 -0800 @@ -86,7 +86,7 @@ return *this; } string_vector& -string_vector::uniq (void) +string_vector::uniq () { octave_idx_type len = numel (); @@ -154,7 +154,7 @@ } char ** -string_vector::c_str_vec (void) const +string_vector::c_str_vec () const { octave_idx_type len = numel (); @@ -169,7 +169,7 @@ } std::list -string_vector::std_list (void) const +string_vector::std_list () const { octave_idx_type len = numel (); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/str-vec.h --- a/liboctave/util/str-vec.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/str-vec.h Tue Jan 24 17:19:44 2023 -0800 @@ -40,7 +40,7 @@ { public: - string_vector (void) = default; + string_vector () = default; explicit string_vector (octave_idx_type n) : m_data (dim_vector (n, 1)) { } @@ -72,11 +72,11 @@ string_vector& operator = (string_vector&&) = default; - ~string_vector (void) = default; + ~string_vector () = default; - bool empty (void) const { return numel () == 0; } + bool empty () const { return numel () == 0; } - octave_idx_type max_length (void) const + octave_idx_type max_length () const { octave_idx_type n = numel (); octave_idx_type longest = 0; @@ -97,9 +97,9 @@ m_data.resize (dim_vector (n, 1), rfv); } - octave_idx_type numel (void) const { return m_data.numel (); } + octave_idx_type numel () const { return m_data.numel (); } - bool isempty (void) const { return m_data.isempty (); } + bool isempty () const { return m_data.isempty (); } std::string& elem (octave_idx_type i) { return m_data.elem (i); } @@ -119,7 +119,7 @@ string_vector& sort (bool make_uniq = false); - string_vector& uniq (void); + string_vector& uniq (); string_vector& append (const std::string& s); @@ -127,9 +127,9 @@ std::string join (const std::string& sep = "") const; - char ** c_str_vec (void) const; + char ** c_str_vec () const; - std::list std_list (void) const; + std::list std_list () const; static void delete_c_str_vec (const char * const*); diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/unwind-prot.cc --- a/liboctave/util/unwind-prot.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/unwind-prot.cc Tue Jan 24 17:19:44 2023 -0800 @@ -33,7 +33,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) void -unwind_protect_safe::warn_unhandled_exception (void) const +unwind_protect_safe::warn_unhandled_exception () const { (*current_liboctave_warning_handler) ("unhandled exception in unwind_protect_safe handler. " @@ -42,7 +42,7 @@ } void -unwind_action_safe::warn_unhandled_exception (void) const +unwind_action_safe::warn_unhandled_exception () const { (*current_liboctave_warning_handler) ("unhandled exception in unwind_action_safe handler. " diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/unwind-prot.h --- a/liboctave/util/unwind-prot.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/unwind-prot.h Tue Jan 24 17:19:44 2023 -0800 @@ -43,7 +43,7 @@ { public: - unwind_protect (void) : m_lifo () { } + unwind_protect () : m_lifo () { } // No copying! @@ -55,11 +55,11 @@ // registered should be exception-safe. If you're not sure, see // unwind_protect_safe. - ~unwind_protect (void) { run (); } + ~unwind_protect () { run (); } - operator bool (void) const { return ! empty (); } + operator bool () const { return ! empty (); } - void run_first (void) + void run_first () { if (! empty ()) { @@ -70,7 +70,7 @@ } } - void discard_first (void) + void discard_first () { if (! empty ()) { @@ -80,7 +80,7 @@ } } - std::size_t size (void) const { return m_lifo.size (); } + std::size_t size () const { return m_lifo.size (); } protected: @@ -102,11 +102,11 @@ { private: - void warn_unhandled_exception (void) const; + void warn_unhandled_exception () const; public: - unwind_protect_safe (void) : unwind_protect () { } + unwind_protect_safe () : unwind_protect () { } // No copying! @@ -114,7 +114,7 @@ unwind_protect_safe& operator = (const unwind_protect_safe&) = delete; - ~unwind_protect_safe (void) + ~unwind_protect_safe () { while (! empty ()) { @@ -150,7 +150,7 @@ // // flexibility in calling forms (function pointer or lambda): // // unwind_action act1 (fcn, val); -// unwind_action act2 ([val] (void) { fcn (val); }); +// unwind_action act2 ([val] () { fcn (val); }); // } // // NOTE: Don't forget to provide a name for the unwind_action @@ -166,7 +166,7 @@ { public: - unwind_action (void) : m_fcn () { } + unwind_action () : m_fcn () { } // FIXME: Do we need to apply std::forward to the arguments to // std::bind here? @@ -182,7 +182,7 @@ unwind_action& operator = (const unwind_action&) = delete; - ~unwind_action (void) { run (); } + ~unwind_action () { run (); } // FIXME: Do we need to apply std::forward to the arguments to // std::bind here? @@ -193,12 +193,12 @@ m_fcn = std::bind (fcn, args...); } - void set (void) { m_fcn = nullptr; } + void set () { m_fcn = nullptr; } // Alias for set() which is clearer about programmer intention. - void discard (void) { set (); } + void discard () { set (); } - void run (void) + void run () { if (m_fcn) m_fcn (); @@ -209,7 +209,7 @@ private: - std::function m_fcn; + std::function m_fcn; }; // Like unwind_action, but this one will guard against the possibility @@ -220,11 +220,11 @@ { private: - void warn_unhandled_exception (void) const; + void warn_unhandled_exception () const; public: - unwind_action_safe (void) : m_fcn () { } + unwind_action_safe () : m_fcn () { } // FIXME: Do we need to apply std::forward to the arguments to // std::bind here? @@ -240,7 +240,7 @@ unwind_action_safe& operator = (const unwind_action_safe&) = delete; - ~unwind_action_safe (void) { run (); } + ~unwind_action_safe () { run (); } // FIXME: Do we need to apply std::forward to the arguments to // std::bind here? @@ -251,12 +251,12 @@ m_fcn = std::bind (fcn, args...); } - void set (void) { m_fcn = nullptr; } + void set () { m_fcn = nullptr; } // Alias for set() which is clearer about programmer intention. - void discard (void) { set (); } + void discard () { set (); } - void run (void) + void run () { try { @@ -274,7 +274,7 @@ private: - std::function m_fcn; + std::function m_fcn; }; // Reset a variable value at the end of the current scope when @@ -339,7 +339,7 @@ unwind_protect_var& operator = (const unwind_protect_var&) = delete; - ~unwind_protect_var (void) + ~unwind_protect_var () { m_ref = m_val; } diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/url-transfer.cc --- a/liboctave/util/url-transfer.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/url-transfer.cc Tue Jan 24 17:19:44 2023 -0800 @@ -48,7 +48,7 @@ OCTAVE_BEGIN_NAMESPACE(octave) -base_url_transfer::base_url_transfer (void) +base_url_transfer::base_url_transfer () : m_host_or_url (), m_valid (false), m_ftp (false), m_ascii_mode (false), m_ok (true), m_errmsg (), m_curr_istream (&std::cin), m_curr_ostream (&std::cout) @@ -289,7 +289,7 @@ { public: - curl_transfer (void) + curl_transfer () : base_url_transfer (), m_curl (curl_easy_init ()), m_errnum (), m_url (), m_userpwd () { @@ -358,13 +358,13 @@ curl_transfer& operator = (const curl_transfer&) = delete; - ~curl_transfer (void) + ~curl_transfer () { if (m_curl) curl_easy_cleanup (m_curl); } - void perform (void) + void perform () { m_errnum = curl_easy_perform (m_curl); @@ -375,7 +375,7 @@ } } - std::string lasterror (void) const + std::string lasterror () const { return std::string (curl_easy_strerror (m_errnum)); } @@ -396,13 +396,13 @@ return retval; } - void ascii (void) + void ascii () { m_ascii_mode = true; SETOPT (CURLOPT_TRANSFERTEXT, 1); } - void binary (void) + void binary () { m_ascii_mode = false; SETOPT (CURLOPT_TRANSFERTEXT, 0); @@ -483,7 +483,7 @@ SETOPT (CURLOPT_URL, m_url.c_str ()); } - void dir (void) + void dir () { m_url = "ftp://" + m_host_or_url + '/'; SETOPT (CURLOPT_URL, m_url.c_str ()); @@ -498,7 +498,7 @@ SETOPT (CURLOPT_URL, m_url.c_str ()); } - string_vector list (void) + string_vector list () { string_vector retval; @@ -593,7 +593,7 @@ cwd ('/' + path); } - std::string pwd (void) + std::string pwd () { std::string retval; @@ -918,7 +918,7 @@ # define REP_CLASS base_url_transfer #endif -url_transfer::url_transfer (void) : m_rep (new REP_CLASS ()) +url_transfer::url_transfer () : m_rep (new REP_CLASS ()) { } url_transfer::url_transfer (const std::string& host, const std::string& user, diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/util/url-transfer.h --- a/liboctave/util/url-transfer.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/util/url-transfer.h Tue Jan 24 17:19:44 2023 -0800 @@ -59,7 +59,7 @@ friend class url_transfer; - base_url_transfer (void); + base_url_transfer (); base_url_transfer (const std::string& host, const std::string& /* user_arg */, @@ -74,15 +74,15 @@ base_url_transfer& operator = (const base_url_transfer&) = delete; - virtual ~base_url_transfer (void) = default; + virtual ~base_url_transfer () = default; - bool is_valid (void) const { return m_valid; } + bool is_valid () const { return m_valid; } - bool good (void) const { return m_valid && m_ok; } + bool good () const { return m_valid && m_ok; } - virtual void perform (void) { } + virtual void perform () { } - virtual std::string lasterror (void) const { return m_errmsg; } + virtual std::string lasterror () const { return m_errmsg; } virtual std::ostream& set_ostream (std::ostream& /* os */) { @@ -94,13 +94,13 @@ return *m_curr_istream; } - virtual void ascii (void) { } + virtual void ascii () { } - virtual void binary (void) { } + virtual void binary () { } - bool is_ascii (void) const { return m_ascii_mode; } + bool is_ascii () const { return m_ascii_mode; } - bool is_binary (void) const { return ! m_ascii_mode; } + bool is_binary () const { return ! m_ascii_mode; } virtual void cwd (const std::string& /* path */) { } @@ -125,16 +125,16 @@ string_vector mput_directory (const std::string& base, const std::string& directory); - virtual void dir (void) { } + virtual void dir () { } - virtual string_vector list (void) { return string_vector (); } + virtual string_vector list () { return string_vector (); } virtual void get_fileinfo (const std::string& /* filename */, double& /* filesize */, OCTAVE_TIME_T& /* filetime */, bool& /* fileisdir */) { } - virtual std::string pwd (void) { return ""; } + virtual std::string pwd () { return ""; } virtual void http_get (const Array& /* param */) { } @@ -170,7 +170,7 @@ { public: - url_transfer (void); + url_transfer (); url_transfer (const std::string& host, const std::string& user, const std::string& passwd, std::ostream& os); @@ -181,13 +181,13 @@ url_transfer& operator = (const url_transfer&) = default; - ~url_transfer (void) = default; + ~url_transfer () = default; - bool is_valid (void) const { return m_rep->is_valid (); } + bool is_valid () const { return m_rep->is_valid (); } - bool good (void) const { return m_rep->good (); } + bool good () const { return m_rep->good (); } - std::string lasterror (void) const { return m_rep->lasterror (); } + std::string lasterror () const { return m_rep->lasterror (); } std::ostream& set_ostream (std::ostream& os) { @@ -199,13 +199,13 @@ return m_rep->set_istream (is); } - void ascii (void) { m_rep->ascii (); } + void ascii () { m_rep->ascii (); } - void binary (void) { m_rep->binary (); } + void binary () { m_rep->binary (); } - bool is_ascii (void) const { return m_rep->is_ascii (); } + bool is_ascii () const { return m_rep->is_ascii (); } - bool is_binary (void) const { return m_rep->is_binary (); } + bool is_binary () const { return m_rep->is_binary (); } void cwd (const std::string& path) { m_rep->cwd (path); } @@ -242,9 +242,9 @@ return m_rep->mput_directory (base, directory); } - void dir (void) { m_rep->dir (); } + void dir () { m_rep->dir (); } - string_vector list (void) { return m_rep->list (); } + string_vector list () { return m_rep->list (); } void get_fileinfo (const std::string& filename, double& filesize, OCTAVE_TIME_T& filetime, bool& fileisdir) @@ -252,7 +252,7 @@ m_rep->get_fileinfo (filename, filesize, filetime, fileisdir); } - std::string pwd (void) { return m_rep->pwd (); } + std::string pwd () { return m_rep->pwd (); } void http_get (const Array& param) { diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/version.cc --- a/liboctave/version.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/version.cc Tue Jan 24 17:19:44 2023 -0800 @@ -68,7 +68,7 @@ } std::string -octave_name_version_and_copyright (void) +octave_name_version_and_copyright () { // The GNU coding standards say that on the first line printed by // --version, the version number should follow the last space on the diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/version.in.h --- a/liboctave/version.in.h Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/version.in.h Tue Jan 24 17:19:44 2023 -0800 @@ -62,7 +62,7 @@ extern OCTAVE_API std::string octave_bugs_statement (bool html = false); -extern OCTAVE_API std::string octave_name_version_and_copyright (void); +extern OCTAVE_API std::string octave_name_version_and_copyright (); extern OCTAVE_API std::string octave_name_version_copyright_copying_and_warranty diff -r 1d1eff97670e -r 21f9b34eb893 liboctave/wrappers/cxx-signal-helpers.cc --- a/liboctave/wrappers/cxx-signal-helpers.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/liboctave/wrappers/cxx-signal-helpers.cc Tue Jan 24 17:19:44 2023 -0800 @@ -45,7 +45,7 @@ // The following pattern often used in C code to initialize a static // variable could possibly cause trouble in multi-threaded code: // -// TYPE * get_var (void) { +// TYPE * get_var () { // static bool initialized = false; // static TYPE *var; // if (! initialized) { @@ -57,14 +57,14 @@ // // Changing this code to // -// static TYPE *var = init_var (void); +// static TYPE *var = init_var (); // // doesn't work in C because the static variable can't be initialized by // a function call. So we have to do this job in C++. To avoid calling // new, initialize sigset_t rather than a pointer to allocated storage. static const sigset_t -init_async_signals (void) +init_async_signals () { sigset_t sigmask; @@ -148,7 +148,7 @@ #endif void -octave_block_async_signals (void) +octave_block_async_signals () { #if ! defined (__WIN32__) || defined (__CYGWIN__) pthread_sigmask (SIG_BLOCK, &async_signals, 0); @@ -156,7 +156,7 @@ } void -octave_unblock_async_signals (void) +octave_unblock_async_signals () { #if ! defined (__WIN32__) || defined (__CYGWIN__) pthread_sigmask (SIG_UNBLOCK, &async_signals, 0); diff -r 1d1eff97670e -r 21f9b34eb893 m4/acinclude.m4 --- a/m4/acinclude.m4 Tue Jan 24 16:17:31 2023 -0500 +++ b/m4/acinclude.m4 Tue Jan 24 17:19:44 2023 -0800 @@ -2232,7 +2232,7 @@ ]) if test $octave_cv_cxx_complex_reference_accessors = yes; then AC_DEFINE(HAVE_CXX_COMPLEX_REFERENCE_ACCESSORS, 1, - [Define to 1 if C++ complex class has T& real (void) and T& imag (void) methods.]) + [Define to 1 if C++ complex class has T& real () and T& imag () methods.]) fi ]) dnl diff -r 1d1eff97670e -r 21f9b34eb893 src/main-cli.cc --- a/src/main-cli.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/src/main-cli.cc Tue Jan 24 17:19:44 2023 -0800 @@ -52,7 +52,7 @@ #include "sysdep.h" static void -check_hg_versions (void) +check_hg_versions () { bool ok = true; diff -r 1d1eff97670e -r 21f9b34eb893 src/main-gui.cc --- a/src/main-gui.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/src/main-gui.cc Tue Jan 24 17:19:44 2023 -0800 @@ -55,7 +55,7 @@ #include "version.h" static void -check_hg_versions (void) +check_hg_versions () { bool ok = true; diff -r 1d1eff97670e -r 21f9b34eb893 src/main.in.cc --- a/src/main.in.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/src/main.in.cc Tue Jan 24 17:19:44 2023 -0800 @@ -111,7 +111,7 @@ } static void -install_signal_handlers (void) +install_signal_handlers () { // FIXME: do we need to handle and forward all the signals that Octave // handles, or is it sufficient to only forward things like SIGINT, @@ -169,7 +169,7 @@ } static std::string -get_octave_bindir (void) +get_octave_bindir () { // Accept value from the environment literally, but substitute // OCTAVE_HOME in the configuration value OCTAVE_BINDIR in case Octave @@ -183,7 +183,7 @@ } static std::string -get_octave_archlibdir (void) +get_octave_archlibdir () { // Accept value from the environment literally, but substitute // OCTAVE_HOME in the configuration value OCTAVE_ARCHLIBDIR in case diff -r 1d1eff97670e -r 21f9b34eb893 src/mkoctfile.in.cc --- a/src/mkoctfile.in.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/src/mkoctfile.in.cc Tue Jan 24 17:19:44 2023 -0800 @@ -603,7 +603,7 @@ } static std::string -get_temp_directory (void) +get_temp_directory () { std::string tempd; @@ -643,7 +643,7 @@ } static std::string -create_interleaved_complex_file (void) +create_interleaved_complex_file () { std::string tmpl = get_temp_directory () + "/oct-XXXXXX.c"; @@ -669,7 +669,7 @@ } static std::string -tmp_objfile_name (void) +tmp_objfile_name () { std::string tmpl = get_temp_directory () + "/oct-XXXXXX.o"; diff -r 1d1eff97670e -r 21f9b34eb893 src/octave-build-info.h --- a/src/octave-build-info.h Tue Jan 24 16:17:31 2023 -0500 +++ b/src/octave-build-info.h Tue Jan 24 17:19:44 2023 -0800 @@ -30,6 +30,6 @@ #include -extern std::string octave_hg_id (void); +extern std::string octave_hg_id (); #endif diff -r 1d1eff97670e -r 21f9b34eb893 src/octave-build-info.in.cc --- a/src/octave-build-info.in.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/src/octave-build-info.in.cc Tue Jan 24 17:19:44 2023 -0800 @@ -32,7 +32,7 @@ #include "octave-build-info.h" std::string -octave_hg_id (void) +octave_hg_id () { return "%OCTAVE_HG_ID%"; } diff -r 1d1eff97670e -r 21f9b34eb893 src/octave-config.in.cc --- a/src/octave-config.in.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/src/octave-config.in.cc Tue Jan 24 17:19:44 2023 -0800 @@ -99,7 +99,7 @@ "\n"; static void -initialize (void) +initialize () { set_octave_home (); diff -r 1d1eff97670e -r 21f9b34eb893 src/octave-svgconvert.cc --- a/src/octave-svgconvert.cc Tue Jan 24 16:17:31 2023 -0500 +++ b/src/octave-svgconvert.cc Tue Jan 24 17:19:44 2023 -0800 @@ -70,7 +70,7 @@ setWindow (sz.toRect ()); } - ~pdfpainter (void) { end (); } + ~pdfpainter () { end (); } private: QPrinter m_printer; @@ -147,21 +147,21 @@ class octave_polygon { public: - octave_polygon (void) + octave_polygon () { } octave_polygon (QPolygonF p) { m_polygons.push_back (p); } - ~octave_polygon (void) { } + ~octave_polygon () { } - int count (void) const + int count () const { return m_polygons.count (); } - void reset (void) + void reset () { m_polygons.clear (); } - QList reconstruct (void) + QList reconstruct () { if (m_polygons.isEmpty ()) return QList (); diff -r 1d1eff97670e -r 21f9b34eb893 src/shared-fcns.h --- a/src/shared-fcns.h Tue Jan 24 16:17:31 2023 -0500 +++ b/src/shared-fcns.h Tue Jan 24 17:19:44 2023 -0800 @@ -45,7 +45,7 @@ # endif static std::string -w32_get_octave_home (void) +w32_get_octave_home () { std::string retval; @@ -108,7 +108,7 @@ static std::string Voctave_exec_home; static void -set_octave_home (void) +set_octave_home () { std::string op = OCTAVE_PREFIX; std::string oep = OCTAVE_EXEC_PREFIX;