This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH 6/6] NEWS: Mention "set listsize 0"/"set listsize -1" behavior change.
- From: Pedro Alves <palves at redhat dot com>
- To: Eli Zaretskii <eliz at gnu dot org>
- Cc: gdb-patches at sourceware dot org
- Date: Wed, 27 Mar 2013 20:07:51 +0000
- Subject: Re: [PATCH 6/6] NEWS: Mention "set listsize 0"/"set listsize -1" behavior change.
- References: <20130321182902 dot 3180 dot 72398 dot stgit at brno dot lan> <20130321182944 dot 3180 dot 80401 dot stgit at brno dot lan> <83vc8ky478 dot fsf at gnu dot org> <514B5B60 dot 3070204 at redhat dot com>
On 03/21/2013 07:11 PM, Pedro Alves wrote:
> On 03/21/2013 06:53 PM, Eli Zaretskii wrote:
>
>> This entry is OK, but I wonder whether it would be better to keep 0 as
>> unlimited, and use -1 to disable. This way, we kill 2 birds with one
>> stone:
>>
>> . keep compatibility with old behavior
>
> Yeah, I initially thought of suggesting to revert the original
> patch that changed this. But, given the back and forth over time
> in the values accepted for "unlimited", we can't really say there's
> one real true old behavior. Witness the confusion in the testsuite,
> even. (Also, "unlimited" has been broken in the tree that way for
> over 7 months, and nobody noticed. Granted, not in a release.) The
> current 0 really meaning 0 at least makes sense for new users.
> For those reasons, I'm okay with one last behavior change and
> sticking with the new current behavior going forward, which is
> also now documented in the manual for roughly 7 months now too.
You know what? After going through all these commands that
take "0" to mean unlimited this week, I've changed my mind.
Doing a web search for "set listsize 0" finds hits of people
with that in gdbinit files. So I'm now thinking of reverting
to the exact old behavior in 7.6, ...
>> . keep compatibility with other settings which use zero for
>> "unlimited"
>
> I don't think unfortunately there's a real standard. Some
> commands choose 0, others choose -1.
>
> I'm finishing a patch that makes literal "set listsize unlimited"
> (same for other commands) actually work, so that over time
> these "was it -1 or was it 0?" confusions end up largely
> being a thing of the past.
... getting this into mainline, and only after going back to
considering whether to change "set listsize"'s behavior.
I'll post a new series.
--
Pedro Alves