This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH v2 13/24] Make "print" and "compile print" support -OPT options
- From: Pedro Alves <palves at redhat dot com>
- To: Tom Tromey <tom at tromey dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Tue, 4 Jun 2019 22:59:17 +0100
- Subject: Re: [PATCH v2 13/24] Make "print" and "compile print" support -OPT options
- References: <20190530195333.20448-1-palves@redhat.com> <20190530195333.20448-14-palves@redhat.com> <87zhmylblr.fsf@tromey.com>
On 6/3/19 8:20 PM, Tom Tromey wrote:
>>>>>> "Pedro" == Pedro Alves <palves@redhat.com> writes:
>
> Pedro> This patch adds support for "print -option optval --", etc.
> Pedro> Likewise for "compile print".
>
> Pedro> We'll get:
>
> Pedro> (gdb) help print
> Pedro> Print value of expression EXP.
> Pedro> Usage: print [[OPTION]... --] [/FMT] [EXP]
>
> Pedro> Options:
> Pedro> -address [on|off]
> Pedro> Set printing of addresses.
>
> Pedro> -array [on|off]
> Pedro> Set pretty formatting of arrays.
> [...]
> Pedro> -null-stop [on|off]
> Pedro> Set printing of char arrays to stop at first null char.
>
> I assume -null-stop is out-dented due to a cut-and-paste error with the
> email, but I wanted to double-check that there isn't a bug here.
Indeed, there's no bug here. Noticed this in the v1 submission but forgot
to fix it for v2... Sorry about that.
>
>
> Pedro> I want to highlight the comment above about "--".
> [...]
>
> I think this approach makes sense, and it addresses the one thing that
> made me hesitate about this idea.
Awesome, that's great to hear.
Thanks,
Pedro Alves