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: Fernando Nasser <fnasser at cygnus dot com>
- Subject: Re: Deprecating commands; Was: RFC: patch for ...
- From: jtc at redback dot com (J.T. Conklin)
- Date: 16 Feb 2000 11:21:35 -0800
- Cc: GDB Patches <gdb-patches at sourceware dot cygnus dot com>
- References: <38AA23AF.34D2C08B@cygnus.com> <38AAE434.E3B21500@cygnus.com>
- Reply-To: jtc at redback dot com
>>>>> "Fernando" == Fernando Nasser <fnasser@cygnus.com> writes:
Fernando> Talking about "bad" commands, what can be worse that the
Fernando> "set" overloading? It should only work for gdb control
Fernando> switches. The "set var" should be name "assign". But who
Fernando> dares to change this after 15+ years...
If we were to have a different command for setting variables, I'd pick
"write" over "assign". However I see this in much the same way as the
BASIC "LET" keyword --- a useless bit of syntactic sugar. I'd prefer
being able to set program variables directly:
(gdb) print x
$1 = 3
(gdb) x = 4
but I suspect that would require a major overhaul of the command
parser.
Another issue is that "set" is used to assign convienence variables
and GDB's internal variables. I see some merit in actually merging
these so that scripts can access the values. There are some issues
that may make it difficult to do. For example, many set commands do
extra error checking that simply setting a convienence variable would
not; GBD's scripting language has only a global identifier namespace;
etc. Nevertheless, I'd love to be able to do this.
--jtc
--
J.T. Conklin
RedBack Networks