From: Joel Brobecker <brobecker@adacore.com>
To: Tom Tromey <tom@tromey.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [RFA] Handle var_zuinteger and var_zuinteger_unlimited from Python
Date: Wed, 02 May 2018 16:25:00 -0000 [thread overview]
Message-ID: <20180502162459.pj4jzejpwopne32b@adacore.com> (raw)
In-Reply-To: <87wowm59hu.fsf@tromey.com>
> Yeah, that bit is really unclear in the patch, but clearer (IMO) in the
> code:
>
> case var_uinteger:
> if (l == 0)
> l = UINT_MAX;
> /* Fall through. */
> case var_zuinteger:
> ok = (l >= 0 && l <= UINT_MAX);
> break;
That's also how I ended up reviewing the patch :).
> Joel> One thought: How about testing the value of the setting after setting
> Joel> its value to -1?
>
> I've added a test like so:
>
> gdb_test "python print(gdb.parameter('test-$kind'))" "-1" \
> "check that PARAM_ZUINTEGER value is -1 after setting"
Looks good!
Thanks Tom,
--
Joel
next prev parent reply other threads:[~2018-05-02 16:25 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-04-26 22:20 Tom Tromey
2018-04-27 6:36 ` Eli Zaretskii
2018-05-02 16:01 ` Tom Tromey
2018-05-02 16:06 ` Tom Tromey
2018-05-02 16:26 ` Eli Zaretskii
2018-05-02 16:31 ` Tom Tromey
2018-04-30 21:52 ` Joel Brobecker
2018-05-02 16:05 ` Tom Tromey
2018-05-02 16:25 ` Joel Brobecker [this message]
2018-05-02 18:16 ` Pedro Alves
2018-05-02 21:07 ` Tom Tromey
2018-05-02 21:37 ` Pedro Alves
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180502162459.pj4jzejpwopne32b@adacore.com \
--to=brobecker@adacore.com \
--cc=gdb-patches@sourceware.org \
--cc=tom@tromey.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox