mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2025-01-15 17:00:26 +00:00
(gdb-var-set-format): Set the output format
of watch expressions (only works fully with GDB 6.7 or later).
This commit is contained in:
parent
ca8fef4410
commit
b3dac3299c
@ -881,11 +881,23 @@ type_changed=\".*?\".*?}")
|
|||||||
(setq gdb-pending-triggers
|
(setq gdb-pending-triggers
|
||||||
(delq 'gdb-var-update gdb-pending-triggers)))
|
(delq 'gdb-var-update gdb-pending-triggers)))
|
||||||
|
|
||||||
|
(defun gdb-var-set-format (format)
|
||||||
|
"Set the output format for a variable displayed in the speedbar."
|
||||||
|
(let* ((var (nth (- (count-lines (point-min) (point)) 2) gdb-var-list))
|
||||||
|
(varnum (car var)))
|
||||||
|
(gdb-enqueue-input
|
||||||
|
(list
|
||||||
|
(if (eq (buffer-local-value 'gud-minor-mode gud-comint-buffer) 'gdba)
|
||||||
|
(concat "server interpreter mi \"-var-set-format "
|
||||||
|
varnum " " format "\"\n")
|
||||||
|
(concat "-var-set-format " varnum " " format "\n"))
|
||||||
|
'ignore))
|
||||||
|
(gdb-var-update-1)))
|
||||||
|
|
||||||
(defun gdb-var-delete-1 (varnum)
|
(defun gdb-var-delete-1 (varnum)
|
||||||
(gdb-enqueue-input
|
(gdb-enqueue-input
|
||||||
(list
|
(list
|
||||||
(if (eq (buffer-local-value 'gud-minor-mode gud-comint-buffer)
|
(if (eq (buffer-local-value 'gud-minor-mode gud-comint-buffer) 'gdba)
|
||||||
'gdba)
|
|
||||||
(concat "server interpreter mi \"-var-delete " varnum "\"\n")
|
(concat "server interpreter mi \"-var-delete " varnum "\"\n")
|
||||||
(concat "-var-delete " varnum "\n"))
|
(concat "-var-delete " varnum "\n"))
|
||||||
'ignore))
|
'ignore))
|
||||||
|
Loading…
Reference in New Issue
Block a user