unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Manuel Giraud <manuel@ledu-giraud.fr>,
	Stefan Monnier <monnier@iro.umontreal.ca>
Cc: 62858@debbugs.gnu.org
Subject: bug#62858: 30.0.50; Typo in gdb-mi.el
Date: Sat, 15 Apr 2023 17:14:47 +0300	[thread overview]
Message-ID: <838retcjvs.fsf@gnu.org> (raw)
In-Reply-To: <87ttxhs2x0.fsf@ledu-giraud.fr> (bug-gnu-emacs@gnu.org)

> Date: Sat, 15 Apr 2023 15:14:35 +0200
> From:  Manuel Giraud via "Bug reports for GNU Emacs,
>  the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
> 
> I do not think that it generates a bug but while browsing "gdb-mi.el", I
> noticed the following at line 2409:
> --8<---------------cut here---------------start------------->8---
>     ("=" . (("thread-created" . (gdb-thread-created . atomic))
>             ("thread-selected" . (gdb-thread-selected . atomic))
>             ("thread-existed" . (gdb-ignored-notification . atomic))
> --8<---------------cut here---------------end--------------->8---
> 
> Should it not be "thread-exited"?  There is no reference to
> "thread-existed" in the GDB info.

You are right.  But I think the snafu here is even more than just a
typo.  This code was introduced in commit 6ff2c8f1f, where Stefan
(CC'ed) took a patch by Jean-Philippe Gravel and improved it.  But as
part of that change, Stefan made this typo, and also made
gdb-thread-exited a function that no one calls, which was not what
happened with the original code.

So I think we need to fix that with the patch below.

Stefan, any comments?

diff --git a/lisp/progmodes/gdb-mi.el b/lisp/progmodes/gdb-mi.el
index 8db1672..27f04e0 100644
--- a/lisp/progmodes/gdb-mi.el
+++ b/lisp/progmodes/gdb-mi.el
@@ -2406,7 +2406,7 @@ gdbmi-bnf-result-state-configs
     ("+" . ())
     ("=" . (("thread-created" . (gdb-thread-created . atomic))
             ("thread-selected" . (gdb-thread-selected . atomic))
-            ("thread-existed" . (gdb-ignored-notification . atomic))
+            ("thread-exited" . (gdb-thread-exited . atomic))
             ('default . (gdb-ignored-notification . atomic)))))
   "Alist of alists, mapping the type and class of message to a handler function.
 Handler functions are all flagged as either `progressive' or `atomic'.





  reply	other threads:[~2023-04-15 14:14 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-15 13:14 bug#62858: 30.0.50; Typo in gdb-mi.el Manuel Giraud via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-04-15 14:14 ` Eli Zaretskii [this message]
2023-04-15 18:19   ` Manuel Giraud via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-04-15 18:35     ` Eli Zaretskii
2023-04-15 19:42       ` Manuel Giraud via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-04-18 11:37   ` Eli Zaretskii
2023-09-05 23:54     ` Stefan Kangas

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=838retcjvs.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=62858@debbugs.gnu.org \
    --cc=manuel@ledu-giraud.fr \
    --cc=monnier@iro.umontreal.ca \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).