From: Simon Marchi <simon.marchi@polymtl.ca>
To: Kevin Buettner <kevinb@redhat.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [PATCH 2/4] Define gdb.Value(bufobj, type) constructor
Date: Tue, 19 Feb 2019 02:41:00 -0000 [thread overview]
Message-ID: <7d6aac0f626a0c5f75108978b3b9a589@polymtl.ca> (raw)
In-Reply-To: <20190218080636.02e3847f@f29-4.lan>
On 2019-02-18 10:06, Kevin Buettner wrote:
> +/* Convert a python object OBJ with type TYPE to a gdb value. The
> + python object in question must conform to the python buffer
> + protocol. On success, return the converted value, otherwise
> + nullptr. */
> +
> +static struct value *
> +convert_buffer_and_type_to_value (PyObject *obj, struct type *type)
> +{
> + Py_buffer_up buffer_up;
> + Py_buffer py_buf;
> +
> + if (PyObject_CheckBuffer (obj)
> + && PyObject_GetBuffer (obj, &py_buf, PyBUF_SIMPLE) == 0)
> + {
> + /* Got a buffer, py_buf, out of obj. Cause it to released
> + when it goes out of scope. */
Seems to be missing a "be" in "Cause it to be released".
Simon
next prev parent reply other threads:[~2019-02-19 2:41 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20190218075816.6f67f3d9@f29-4.lan>
2019-02-18 15:03 ` [PATCH 1/4] Define unique_ptr specialization for Py_buffer Kevin Buettner
2019-02-18 15:06 ` [PATCH 2/4] Define gdb.Value(bufobj, type) constructor Kevin Buettner
2019-02-18 22:46 ` Tom Tromey
2019-02-19 0:57 ` Kevin Buettner
2019-02-19 15:19 ` Tom Tromey
2019-02-19 15:28 ` Ulrich Weigand
2019-02-19 2:41 ` Simon Marchi [this message]
2019-02-18 15:07 ` [PATCH 3/4] Add tests for " Kevin Buettner
2019-02-19 2:46 ` Simon Marchi
2019-02-18 15:09 ` [PATCH 4/4] Document two argument form of gdb.Value constructor Kevin Buettner
2019-02-18 16:13 ` Eli Zaretskii
2019-02-18 17:25 ` Kevin Buettner
2019-02-18 17:45 ` Eli Zaretskii
2019-02-19 2:48 ` [PATCH 0/4] Define gdb.Value(val, type) constructor Simon Marchi
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=7d6aac0f626a0c5f75108978b3b9a589@polymtl.ca \
--to=simon.marchi@polymtl.ca \
--cc=gdb-patches@sourceware.org \
--cc=kevinb@redhat.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