# HG changeset patch # User Rik # Date 1318435618 25200 # Node ID a2144dbc2f3a0efb2ae42cc6241856dbb78d4397 # Parent f81fcceb394cb69babb39cd4e575198ecc2d2f04 gdbinit: Add documentation for macros. Add alias for new show_octave_dbstack command. * gdbinit: Add documentation for macros. Add alias for new show_octave_dbstack command. diff --git a/etc/gdbinit b/etc/gdbinit --- a/etc/gdbinit +++ b/etc/gdbinit @@ -1,5 +1,6 @@ ## Helpful macros for debugging Octave. +############################################################ ## Display a dim-vector object. define display-dims @@ -11,6 +12,12 @@ dont-repeat end +document display-dims +Usage: display-dims DIM_VECTOR +Display the contents of an Octave dimension vector. +end + +############################################################ ## Display a dense array object. define display-dense-array @@ -26,6 +33,15 @@ dont-repeat end +document display-dense-array +Usage: display-dense-array ARRAY +Display the contents of an ordinary, i.e., dense Octave array. + +See also [display-sparse-array] for showing the contents +of sparse Octave arrays. +end + +############################################################ ## Display a sparse array object. define display-sparse-array @@ -46,3 +62,28 @@ echo \n dont-repeat end + +document display-sparse-array +Usage: display-sparse-array SPARSE_ARRAY +Display the contents of a sparse Octave array. + +See also [display-dense-array] for showing the contents +of ordinary Octave arrays. +end + +############################################################ + +## Display Octave debugging stack + +define show-octave-dbstack + call show_octave_dbstack +end + +document show-octave-dbstack +Usage: show-octave-dbstack +Display the contents of the current Octave debugging stack. + +This is the function stack that the Octave interpreter is processing +and will be different from the C++ stack being debugged with gdb. +end +