all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#64186: Patch: Suppress deprecated '-gdb-set target-async' warning message in gdb-mi.el
@ 2023-06-20  2:21 Wang Diancheng
  2023-06-20  7:24 ` Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors
  0 siblings, 1 reply; 33+ messages in thread
From: Wang Diancheng @ 2023-06-20  2:21 UTC (permalink / raw)
  To: 64186

[-- Attachment #1: Type: text/plain, Size: 309 bytes --]

Hi,

The command "-gdb-set target-async" is deprecated since gdb 7.7, It is
annoyed that there is a message "Warning: 'set target-async', an alias for
the command 'set mi-async', is deprecated. Use 'set mi-async'." when gdb
buffer is ready for command. Following is a patch to suppress that
warning.

Thanks.

[-- Attachment #2: gdb-mi-suppress-target-async-warning.patch --]
[-- Type: text/x-patch, Size: 760 bytes --]

diff --git a/lisp/progmodes/gdb-mi.el b/lisp/progmodes/gdb-mi.el
index 4428fa72c78..f51b53c2eb3 100644
--- a/lisp/progmodes/gdb-mi.el
+++ b/lisp/progmodes/gdb-mi.el
@@ -1143,9 +1143,14 @@ gdb-non-stop-handler
 	(setq gdb-non-stop nil)
 	(setq gdb-supports-non-stop nil))
     (setq gdb-supports-non-stop t)
-    (gdb-input "-gdb-set target-async 1" 'ignore)
+    (gdb-input "-gdb-set mi-async 1" 'gdb-set-mi-async-handler)
     (gdb-input "-list-target-features" 'gdb-check-target-async)))
 
+(defun gdb-set-mi-async-handler()
+  (goto-char (point-min))
+  (if (re-search-forward "No symbol" nil t)
+    (gdb-input "-gdb-set target-async 1" 'ignore)))
+
 (defun gdb-check-target-async ()
   (goto-char (point-min))
   (unless (re-search-forward "async" nil t)

^ permalink raw reply related	[flat|nested] 33+ messages in thread

end of thread, other threads:[~2023-07-13  6:26 UTC | newest]

Thread overview: 33+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-06-20  2:21 bug#64186: Patch: Suppress deprecated '-gdb-set target-async' warning message in gdb-mi.el Wang Diancheng
2023-06-20  7:24 ` Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-06-20  9:25   ` Wang Diancheng
2023-06-20  9:43     ` Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-06-20 11:55     ` Eli Zaretskii
2023-06-21  6:49       ` Wang Diancheng
2023-06-21 13:12         ` Eli Zaretskii
2023-06-28  3:51           ` Wang Diancheng
2023-06-29  6:09             ` Eli Zaretskii
2023-06-30  7:08               ` Wang Diancheng
2023-07-06  7:10                 ` Eli Zaretskii
2023-04-25 19:18                   ` bug#63084: 30.0.50; gud: set breakpoint while program is running tatrics
2023-04-26  6:10                     ` Eli Zaretskii
2023-04-26  8:48                       ` TatriX
2023-04-26  9:44                         ` Eli Zaretskii
2023-04-26 11:19                           ` Eli Zaretskii
2023-04-26 11:49                             ` TatriX
2023-05-05  5:52                             ` Eli Zaretskii
2023-05-05  5:53                           ` Eli Zaretskii
2023-05-05  7:15                             ` TatriX
2023-05-06 11:43                               ` Eli Zaretskii
2023-05-27 21:22                                 ` TatriX
2023-05-28  5:28                                   ` Eli Zaretskii
2023-05-28 21:10                                     ` TatriX
2023-05-29 11:45                                       ` Eli Zaretskii
     [not found]                     ` <handler.63084.D64186.168862741914107.notifdone@debbugs.gnu.org>
2023-07-11  7:31                       ` bug#63084: closed (Re: bug#64186: Patch: Suppress deprecated '-gdb-set target-async' warning message in gdb-mi.el) TatriX
2023-07-11 12:24                         ` Eli Zaretskii
2023-07-11 15:30                           ` TatriX
2023-07-11 15:56                             ` Eli Zaretskii
2023-07-11 17:49                               ` TatriX
2023-07-13  6:26                                 ` Eli Zaretskii
2023-07-07  6:25                   ` bug#64186: Patch: Suppress deprecated '-gdb-set target-async' warning message in gdb-mi.el Wang Diancheng
2023-07-07  6:42                     ` Eli Zaretskii

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.