This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [patch] Tweak output of -var-info-path-expression
- From: Tom Tromey <tromey at redhat dot com>
- To: Marc Khouzam <marc dot khouzam at ericsson dot com>
- Cc: "'gdb-patches\ at sourceware dot org'" <gdb-patches at sourceware dot org>
- Date: Wed, 10 Aug 2011 08:46:49 -0600
- Subject: Re: [patch] Tweak output of -var-info-path-expression
- References: <F7CE05678329534C957159168FA70DEC5784D50AC1@EUSAACMS0703.eamcs.ericsson.se>
>>>>> "Marc" == Marc Khouzam <marc.khouzam@ericsson.com> writes:
Marc> I'd like to re-submit a workaround I posted about a year ago,
Marc> but never followed through with.
Marc> So, here is the patch with a test. The test fails with
Marc> the current HEAD (gets the syntax error) and succeeds with
Marc> the patch applied. I've also had to update other tests
Marc> to match the change.
I think it is reasonable, just a few nits in the patch.
Marc> Index: gdb/testsuite/gdb.mi/gdb11912.cc
Jan has asked that new tests be given descriptive names instead of PR
numbers.
Marc> +if $verbose>1 then {
Marc> + send_user "var-info-path-expression returned $cmd_output\n"
Marc> + send_user "Using $path for data-evaluate-expression\n"
Marc> +}
Just use the verbose command with the level as an argument, like:
verbose "var-info-path-expression returned $cmd_output" 2
(Note no \n as well.)
Marc> + When we are in the scope of the base class or of one
Marc> + of its children, the type field name will be interpreted
Marc> + as a constructor, if it exists. Therefore, we must
Marc> + indicate that the name is a class name by using the
Marc> + 'class' keyword. */
I'd like this comment to have a reference to the PR, either the URL or
"PR mi/11912".
Tom