This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFAv2 1/6] New cli-utils.h/.c function extract_info_print_args
- From: Philippe Waroquiers <philippe dot waroquiers at skynet dot be>
- To: Tom Tromey <tom at tromey dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Tue, 25 Sep 2018 06:37:08 +0200
- Subject: Re: [RFAv2 1/6] New cli-utils.h/.c function extract_info_print_args
- References: <20180826165359.1600-1-philippe.waroquiers@skynet.be> <20180826165359.1600-2-philippe.waroquiers@skynet.be> <878t3yu8vv.fsf@tromey.com> <1537733790.3924.13.camel@skynet.be> <87tvmfniwi.fsf@tromey.com>
On Mon, 2018-09-24 at 07:07 -0600, Tom Tromey wrote:
> Maybe it is too late to fix the "mem" command. I am not sure. I do
> know that back when I approved a similar change to "disasssemble" (I
> thought I'd written that! But the history shows not), there were
> complaints -- we broke people's workarounds for the bad parsing
> behavior. On the other hand, "disasssemble" is probably used a lot more
> than "mem".
>
> Philippe> So, it looks possible to have extract_arg behaviour replaced by
> Philippe> extract_arg_maybe_quoted behaviour.
> Philippe> If you agree with the above analysis, I will work on that in a separate
> Philippe> patch series.
>
> One idea might be to upgrade the calls where it seems reasonable and
> then leave the legacy behavior for the ones where it is not... perhaps
> at the end, renaming extract_arg so that the name makes it clear that it
> shouldn't be used in new code.
>
> What do you think of that? It's not necessary for you to do all the
> work involved.
Yes, that sounds a reasonable approach.
No problem for me to work on that, and give a proposal
'change to new behavior' or 'keep legacy behavior' for each
extract_arg call (it might take a week or 2, as gdb is
an evening/week-end activity).
Once the analysis of which calls are reasonable to change is done,
the code
changes should be pretty small.
Philippe