diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2012-07-27 13:50:02 -0700 |
---|---|---|
committer | Paul Eggert <eggert@cs.ucla.edu> | 2012-07-27 13:50:02 -0700 |
commit | c20fdd9eb75e484e12382494e4fb8931c753361b (patch) | |
tree | 16ac14d6583363cb4f1bec13ec313960d48c4725 /src/.gdbinit | |
parent | cc436baac4522c48cd083a20f9e6a653f58e331f (diff) | |
download | emacs-c20fdd9eb75e484e12382494e4fb8931c753361b.tar.gz |
Adjust GDB to reflect pvec_type changes.
* .gdbinit (xvectype, xpr, xbacktrace): Adjust to reflect the
2012-07-04 changes to pseudovector representation. Problem
reported by Eli Zaretskii in <http://bugs.gnu.org/1995-05-30T23:07:27Z!kwzh@gnu.org#30>.
Diffstat (limited to 'src/.gdbinit')
-rw-r--r-- | src/.gdbinit | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/src/.gdbinit b/src/.gdbinit index 25b555b8540..620ca63a0d6 100644 --- a/src/.gdbinit +++ b/src/.gdbinit @@ -653,7 +653,11 @@ end define xvectype xgetptr $ set $size = ((struct Lisp_Vector *) $ptr)->header.size - output ($size & PSEUDOVECTOR_FLAG) ? (enum pvec_type) ($size & PVEC_TYPE_MASK) : $size & ~ARRAY_MARK_FLAG + if ($size & PSEUDOVECTOR_FLAG) + output (enum pvec_type) (($size & PVEC_TYPE_MASK) >> PSEUDOVECTOR_SIZE_BITS) + else + output $size & ~ARRAY_MARK_FLAG + end echo \n end document xvectype @@ -992,7 +996,7 @@ define xpr if $type == Lisp_Vectorlike set $size = ((struct Lisp_Vector *) $ptr)->header.size if ($size & PSEUDOVECTOR_FLAG) - set $vec = (enum pvec_type) ($size & PVEC_TYPE_MASK) + set $vec = (enum pvec_type) (($size & PVEC_TYPE_MASK) >> PSEUDOVECTOR_SIZE_BITS) if $vec == PVEC_NORMAL_VECTOR xvector end @@ -1127,7 +1131,11 @@ define xbacktrace if $type == Lisp_Vectorlike xgetptr (*$bt->function) set $size = ((struct Lisp_Vector *) $ptr)->header.size - output ($size & PSEUDOVECTOR_FLAG) ? (enum pvec_type) ($size & PVEC_TYPE_MASK) : $size & ~ARRAY_MARK_FLAG + if ($size & PSEUDOVECTOR_FLAG) + output (enum pvec_type) (($size & PVEC_TYPE_MASK) >> PSEUDOVECTOR_SIZE_BITS) + else + output $size & ~ARRAY_MARK_FLAG + end else printf "Lisp type %d", $type end |