Re: probing GDB for MI versions

Felix Lee
2004-10-19T19:28:31Z

Bob Rossi <bob@brasko.net>:
> * *requires* a restart

there's no difference between running
gdb -print-stable-mi-version
and running
printf "quit\n" | gdb -interpreter=mi

> * requires printing the latest stable version even though GDB may not be
> even speaking that version

'gdb -interpreter=mi' should start the latest stable version, not
the latest version. so if mi5 is stable and mi6 is unstable,
you'd have to say '-interpreter=mi6' to get the unstable version.

> * says *nothing* about other versions that GDB supports

so print a list of versions. this was already mentioned a couple
times. there's no difference between running
gdb -print-all-mi-versions
and running
printf "info mi\nquit\n" | gdb -interpreter=mi

> * gives no way for a front end to determine if it is using a
> deprecated protocol.

this can be information in the list of versions.

> * puts the bug finding of the MI protocol on the users, even though the
> protocols have been deprecated.

this is a problem everywhere and difficult to solve in general.
the first thought most people will have is "maybe it's fixed in a
newer version", and it's pretty easy to try a newer gdb version.
also, assume that anyone who knows how to use gdb also knows how
to search for an answer with Google and/or file a bug report.

Bob, I think this discussion would have been finished a long time
ago if you had just submitted a patch for gdb that did what you
wanted. the first attempt might get some discussion and need
some modification before getting accepted, but that usually
doesn't take very long.

most of this argument has been about people saying basically,
"well, if I were doing it, I'd do it differently", which is just
quibbling for an issue as simple as this. gdb, like most
volunteer projects, never has enough manpower to do everything
that "should" be done. development is always about evolution in
response to demand.

the project is the sum of what people care about, and you care
the most about this issue. any patch you submit has an automatic
advantage over everyone else's lack of interest in working on
this issue, and the gdb people are usually happy to incorporate
anything that isn't egregiously bad.
--