all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: "João Távora" <joaotavora@gmail.com>
Cc: daniel@dpettersson.net, philipk@posteo.net, dmitry@gutov.dev,
	john@yates-sheets.org, krister.schuchardt@gmail.com,
	adam@alphapapa.net, emacs-devel@gnu.org
Subject: Re: [ELPA] New package: dape
Date: Wed, 06 Dec 2023 19:00:16 +0200	[thread overview]
Message-ID: <835y1b4673.fsf@gnu.org> (raw)
In-Reply-To: <CALDnm50c6SrmVtwLcX8bbQemFXk8AfvjY0zN0MyW3mHtQwUctg@mail.gmail.com> (message from João Távora on Wed, 6 Dec 2023 13:38:54 +0000)

> From: João Távora <joaotavora@gmail.com>
> Date: Wed, 6 Dec 2023 13:38:54 +0000
> Cc: daniel@dpettersson.net, philipk@posteo.net, dmitry@gutov.dev, 
> 	john@yates-sheets.org, krister.schuchardt@gmail.com, adam@alphapapa.net, 
> 	emacs-devel@gnu.org
> 
> As to "why we would want"... No idea... But imagine that dape.el ends
> up supporting a much nicer UI than gdb-mi.el?

If the gdb-mi UI needs improvement, I'd rather we improve it instead
of ditching it.  GDB/MI is _the_ official GDB way for GUI front-ends,
and will remain so for the years to come.  It will take the DAP
interface some time to get there, and even when it does, GDB/MI will
always integrate better with GDB, since it is being developed by the
GDB project, unlike DAP which is primarily modeled on "other
debuggers".

> More responsive, robust, great keybindings, etc.  Than I imagine
> some people would want to talk to GDB using that UI instead of
> gdb-mi.el's.

Only if we fail to keep gdb-mi up to the job.

> > > But that doesn't help when reusing the UI of gdb-mi.el to talk to non-gdb DAP debuggers.
> >
> > Like what?
> 
> Like a lot of non-GDB debuggers these days talk DAP.  Here's a
> big list: https://microsoft.github.io/debug-adapter-protocol/implementors/adapters/

I know the list.  I was asking which of them we'd need to support, and
why?

> > IOW, I don't see why someone would want to reuse gdb-mi's code if we
> > only need to reuse the few UI parts of it.  It sounds like more
> > trouble than worth it.
> 
> I don't know gdb-mi.el very well, but if it has code for displaying
> and interacting with lists of threads, local variables, registers,
> breakpoints, displaying assembly, then IMO it could well make sense
> to lift that interface to something that both gdb-mi.el and dape.el
> could use.  That's less code for us to maintain and potential
> improvements to that liften code would benefit both extensions.

What gdb-mi has is code that parses the GDB/MI output and shows the
results.  Factoring out the display part out of that will leave you
with mostly trivial stuff.  For example, the display part of showing
the threads in a program is gdb-table-add-row and a couple of simple
subroutines, whereas the function that handles threads display is
built around code specific to GDB/MI output and structures into which
that output is parsed, and relies on thread info provided by GDB; see
gdb-thread-list-handler-custom.

> As you know, Eglot uses this approach: it tries to add as little UI
> as possible and reuse existing things in Emacs.

Eglot started from LSP and provides only features supported by LSP.
gdb-mi started from GDB/MI and supports only that protocol.  A better
analogy for this discussion is how easy will it be to move Eglot to a
completely different protocol, and on top of that a protocol that is
not based on JSON but on some other structured output.

Moreover, where Eglot plugs itself into Emacs editing features, a
debugging package has no features to plug itself into, because
debugging is very different from editing programs.

> I personally wouldn't write it off as "more trouble than it's
> worth", without a more or less thorough analysis of the similarities
> and differences between these UIs.

Which UIs are we talking about here?



  reply	other threads:[~2023-12-06 17:00 UTC|newest]

Thread overview: 49+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-13 10:35 [ELPA] New package: dape Daniel Pettersson
2023-10-13 12:24 ` Philip Kaludercic
2023-10-14 12:28   ` Daniel Pettersson
2023-10-14 14:54     ` Philip Kaludercic
2023-10-15 13:50       ` James Thomas
2023-10-15 14:12         ` Philip Kaludercic
2023-10-15 17:24           ` John Yates
2023-10-18 21:54       ` Daniel Pettersson
2023-10-19  2:08         ` Adam Porter
2023-10-19 10:52           ` Krister Schuchardt
2023-10-19 11:06             ` Dmitry Gutov
2023-10-20 14:53               ` John Yates
2023-11-01 19:13                 ` Dmitry Gutov
2023-11-02 14:42                   ` João Távora
2023-11-04  9:51                     ` Daniel Pettersson
2023-11-04 10:00                       ` Philip Kaludercic
2023-11-23  6:10                         ` Philip Kaludercic
2023-12-05  8:41                           ` Philip Kaludercic
2023-12-05  9:18                             ` João Távora
2023-12-05 10:59                               ` Philip Kaludercic
2023-12-05 11:29                                 ` João Távora
2023-12-06  3:57                                   ` Richard Stallman
2023-12-06 10:09                                   ` Daniel Pettersson
2023-12-06 12:30                                     ` Eli Zaretskii
2023-12-06 12:56                                       ` João Távora
2023-12-06 13:08                                         ` Eli Zaretskii
2023-12-06 13:38                                           ` João Távora
2023-12-06 17:00                                             ` Eli Zaretskii [this message]
2023-12-06 23:03                                               ` João Távora
2023-12-06 23:55                                               ` Daniel Pettersson
2023-12-07  7:13                                                 ` Eli Zaretskii
2023-11-04 13:46                       ` Adam Porter
2023-11-04 14:01                         ` Eli Zaretskii
2023-11-04 14:24                           ` Philip Kaludercic
2023-11-04 15:06                             ` Adam Porter
2023-11-04 15:27                               ` Philip Kaludercic
2023-11-04 14:53                           ` Adam Porter
2023-11-04 15:14                             ` Eli Zaretskii
2023-11-04 19:15                               ` Adam Porter
2023-11-04 23:21                       ` João Távora
2023-11-07 10:19                         ` Daniel Pettersson
2023-11-07 10:40                           ` João Távora
2023-11-08  8:31                             ` Daniel Pettersson
2023-10-19 15:12         ` Philip Kaludercic
2023-10-19 17:50         ` Björn Bidar
2023-11-01 16:50         ` Philip Kaludercic
2023-10-15 13:55 ` Mauro Aranda
2023-10-17 20:39   ` Daniel Pettersson
2023-10-20  5:49 ` Milan Glacier

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

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

  git send-email \
    --in-reply-to=835y1b4673.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=adam@alphapapa.net \
    --cc=daniel@dpettersson.net \
    --cc=dmitry@gutov.dev \
    --cc=emacs-devel@gnu.org \
    --cc=joaotavora@gmail.com \
    --cc=john@yates-sheets.org \
    --cc=krister.schuchardt@gmail.com \
    --cc=philipk@posteo.net \
    /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 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.