@@ -914,17 +914,17 @@ HAS-CHILDREN should be t when this node has children."
914914 return buffer
915915 finally return nil ))
916916
917- (defmacro gdb--simple-get-buffer (type update-func name important &rest body )
917+ (defmacro gdb--simple-get-buffer (type update-func name important hidden &rest body )
918918 " Simple buffer creator/fetcher, for buffers that should be unique in a session."
919919 (declare (indent defun ) (debug (sexp sexp body)))
920920 (unless (memq type gdb--buffer-types) (error " Type %s does not exist " (symbol-name type)))
921921 `(defun ,(intern (concat (symbol-name type) " -get-buffer" )) (session)
922922 ,(concat " Creator and fetcher of buffer with type `" (symbol-name type) " '" )
923923 (cond ((gdb--get-buffer-with-type session ', type ))
924- (t (let ((buffer (generate-new-buffer " *GDB Temporary Name*" )))
924+ (t (let ((buffer (generate-new-buffer " *GDB Temporary Name*" )))
925925 (push buffer (gdb--session-buffers session))
926926 (with-current-buffer buffer
927- (gdb--rename-buffer , name (gdb--session-debuggee-path session))
927+ (gdb--rename-buffer , name , hidden (gdb--session-debuggee-path session))
928928 (setq gdb--buffer-info (make-gdb--buffer-info :session session :type ', type
929929 :update-func #' , update-func ))
930930 ,@body
@@ -960,9 +960,9 @@ HAS-CHILDREN should be t when this node has children."
960960 (setf (gdb--session-buffers-to-update session) nil
961961 (gdb--session-buffer-types-to-update session) nil ))))
962962
963- (defmacro gdb--rename-buffer (&optional specific-str debuggee-path )
963+ (defmacro gdb--rename-buffer (&optional specific-str hidden debuggee-path )
964964 `(save-match-data
965- (rename-buffer (concat ,(concat " *GDB" (when specific-str (concat " : " specific-str)))
965+ (rename-buffer (concat ,(concat ( and hidden " " ) " *GDB" (when specific-str (concat " : " specific-str)))
966966 (when , debuggee-path (concat " - " (file-name-nondirectory , debuggee-path )))
967967 " *" )
968968 t )))
@@ -1127,7 +1127,7 @@ HAS-CHILDREN should be t when this node has children."
11271127 (setq-local comint-preoutput-filter-functions '(gdb--output-filter))
11281128 (setq-local completion-at-point-functions '(gdb--comint-completion-at-point)))
11291129
1130- (gdb--simple-get-buffer gdb--comint ignore " Comint" t
1130+ (gdb--simple-get-buffer gdb--comint ignore " Comint" t t
11311131 (setq gdb--omit-console-output nil )
11321132 (gdb-comint-mode)
11331133 (let ((process-connection-type nil ))
@@ -1317,7 +1317,7 @@ stopped thread before running the command. If FORCE-STOPPED is
13171317 " Major mode for interacting with the inferior."
13181318 :syntax-table nil :abbrev-table nil )
13191319
1320- (gdb--simple-get-buffer gdb--inferior-io ignore " Inferior I/O" t
1320+ (gdb--simple-get-buffer gdb--inferior-io ignore " Inferior I/O" t nil
13211321 (gdb-inferior-io-mode )
13221322 (gdb--inferior-io-initialization))
13231323
@@ -1399,7 +1399,7 @@ stopped thread before running the command. If FORCE-STOPPED is
13991399 (buffer-disable-undo )
14001400 (font-lock-mode -1 ))
14011401
1402- (gdb--simple-get-buffer gdb--threads gdb--threads-update " Threads" nil
1402+ (gdb--simple-get-buffer gdb--threads gdb--threads-update " Threads" nil t
14031403 (gdb-threads-mode ))
14041404
14051405(defun gdb--threads-update ()
@@ -1448,7 +1448,7 @@ stopped thread before running the command. If FORCE-STOPPED is
14481448 (buffer-disable-undo )
14491449 (font-lock-mode -1 ))
14501450
1451- (gdb--simple-get-buffer gdb--frames gdb--frames-update " Stack Frames" nil
1451+ (gdb--simple-get-buffer gdb--frames gdb--frames-update " Stack Frames" nil t
14521452 (gdb-frames-mode ))
14531453
14541454(defun gdb--frames-update ()
@@ -1494,7 +1494,7 @@ stopped thread before running the command. If FORCE-STOPPED is
14941494 (buffer-disable-undo )
14951495 (font-lock-mode -1 ))
14961496
1497- (gdb--simple-get-buffer gdb--breakpoints gdb--breakpoints-update " Breakpoints" nil
1497+ (gdb--simple-get-buffer gdb--breakpoints gdb--breakpoints-update " Breakpoints" nil t
14981498 (gdb-breakpoints-mode ))
14991499
15001500(defun gdb--breakpoints-update ()
@@ -1542,7 +1542,7 @@ stopped thread before running the command. If FORCE-STOPPED is
15421542 (buffer-disable-undo )
15431543 (font-lock-mode -1 ))
15441544
1545- (gdb--simple-get-buffer gdb--variables gdb--variables-update " Variables" nil
1545+ (gdb--simple-get-buffer gdb--variables gdb--variables-update " Variables" nil t
15461546 (gdb-variables-mode))
15471547
15481548(defun gdb--variables-update ()
@@ -1585,7 +1585,7 @@ stopped thread before running the command. If FORCE-STOPPED is
15851585 (buffer-disable-undo )
15861586 (font-lock-mode -1 ))
15871587
1588- (gdb--simple-get-buffer gdb--watchers gdb--watchers-update " Watchers" nil
1588+ (gdb--simple-get-buffer gdb--watchers gdb--watchers-update " Watchers" nil t
15891589 (gdb-watchers-mode))
15901590
15911591(defun gdb--watcher-toggle-chilren ()
@@ -1689,7 +1689,7 @@ stopped thread before running the command. If FORCE-STOPPED is
16891689 (buffer-disable-undo )
16901690 (font-lock-mode -1 ))
16911691
1692- (gdb--simple-get-buffer gdb--registers gdb--registers-update " Registers" nil
1692+ (gdb--simple-get-buffer gdb--registers gdb--registers-update " Registers" nil t
16931693 (gdb-registers-mode ))
16941694
16951695(defun gdb--registers-update ()
@@ -1743,7 +1743,7 @@ stopped thread before running the command. If FORCE-STOPPED is
17431743 (setq-local buffer-read-only t )
17441744 (buffer-disable-undo ))
17451745
1746- (gdb--simple-get-buffer gdb--disassembly gdb--disassembly-update " Disassembly" nil
1746+ (gdb--simple-get-buffer gdb--disassembly gdb--disassembly-update " Disassembly" nil t
17471747 (gdb-disassembly-mode )
17481748 (setf (gdb--buffer-info-data gdb--buffer-info) (make-gdb--disassembly-data))
17491749 (gdb--disassembly-fetch (gdb--session-selected-frame session)))
0 commit comments