This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH: gdb/mi + doco] -var-update


On Fri, Jun 17, 2005 at 01:08:58PM +0200, Eli Zaretskii wrote:
> > Date: Thu, 16 Jun 2005 23:43:29 -0400
> > From: Daniel Jacobowitz <drow@false.org>
> > Cc: Bob Rossi <bob@brasko.net>, gdb-patches@sources.redhat.com
> > 
> > I don't remember the entire outcome of your discussion with Eli
> 
> My opinion (which Nick eventually accepted, IIRC) is here:
> 
>    http://sourceware.org/ml/gdb-patches/2005-02/msg00204.html
> 
> > but I find the idea of having --with-values sometimes and
> > --all-values other times a bit confusing.  I went trying to figure
> > out which meant what and that's when I noticed this problem.
> 
> If you have suggestions for better names for these options, please say
> what they are.  Alternatively, if you are saying that the manual patch
> doesn't explain them well enough, please point out the unclear text.

The latest manual patch Nick posted was so mangled that I couldn't work
out what the new text was.

Before the patch -stack-list-locals takes --no-values, --all-values, and
--simple-values.  -var-list-children takes --no-values and
--all-values.

After the patch -stack-list-locals takes --no-values, --all-values, and
--simple-values.  -var-list-children takes --no-values and
--with-values.  -var-update takes --no-values and --with-values.

So, we still have --all-values, we've introduced --with-values, and
we've made an incompatible change.  I think that, other than the
incompatible change, I don't have a big problem with this - they are
different commands, they can take different options.  But consistency
would be nice.

I do see that you OK'd the incompatible change:
  http://sourceware.org/ml/gdb-patches/2005-02/msg00232.html

I'm less comfortable with that than you and Nick are; we shipped GDB
6.3 with -var-list-children --all-values, and it's even in the manual.

Your original objection was:
> Also, I find the choice of "--all-values" unfortunate.  The opposite
> of "--no-values" is something like "--with-values" or
> "--print-values", not "--all-values".

Could you elaborate?  I think that --all-values is a reasonable option;
especially since --simple-values would be a reasonable extension here
also.  It causes the values for objects other than
structs/arrays/unions to be printed.

Would you be happier with -var-update --all-values if -var-update
--simple-values also worked?

-- 
Daniel Jacobowitz
CodeSourcery, LLC


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]