This is the mail archive of the
gdb-patches@sourceware.cygnus.com
mailing list for the GDB project.
Re: Deprecating commands; Was: RFC: patch for ...
- To: Andrew Cagney <ac131313 at cygnus dot com>
- Subject: Re: Deprecating commands; Was: RFC: patch for ...
- From: Fernando Nasser <fnasser at cygnus dot com>
- Date: Wed, 16 Feb 2000 12:53:56 -0500
- CC: GDB Patches <gdb-patches at sourceware dot cygnus dot com>
- Organization: Red Hat , Inc. - Toronto
- References: <38AA23AF.34D2C08B@cygnus.com>
Andrew Cagney wrote:
>
> For what its worth,
>
> Something buried on my to-do / wish list is to extend GDB's command
> mechanism so that the user is advised that a command is deprecated the
> first time they use it:
>
> (gdb) othernames xyz
> warning: Command `othernames' is deprecated, use `set architecture
> abc'.
> (gdb) othernames zzz
> (gdb)
>
> Doing that opens up the possibility of moving GDB's CLI (command line
> interface) forward. One release would have a poorly chosen command
> deprecated. A follow on release could see it (ya!) removed.
>
> I don't think it is reasonable to simply drop a command (no matter what
> the results of a gdb@sourceware straw poll) without some sort of warning
> to the general public.
>
I agree with Andrew. He proposed the "deprecated" mechanism some time
ago and it went on our TODO list. Although I am the maintainer of the
command line interpreter and I agree with this feature, it was not done
because of the major work that we had to do for getting (part of) libgdb
out (and people were claiming for it).
If someone has the time to contribute with a patch we would appreciate.
If not, as soon as possible we will include this "deprecated" state so
we can have a graceful phasing out of "bad" commands.
Talking about "bad" commands, what can be worse that the "set"
overloading? It should only work for gdb control switches. The "set
var" should be name "assign". But who dares to change this after 15+
years...
--
Fernando Nasser
Red Hat - Toronto E-Mail: fnasser@cygnus.com
2323 Yonge Street, Suite #300 Tel: 416-482-2661 ext. 311
Toronto, Ontario M4P 2C9 Fax: 416-482-6299