From: Andrew Burgess <andrew.burgess@embecosm.com>
To: George Barrett <bob@bob131.so>
Cc: gdb-patches@sourceware.org
Subject: Re: [PATCH v3 1/3] Guile: improved rvalue reference support
Date: Wed, 28 Apr 2021 17:54:28 +0100 [thread overview]
Message-ID: <20210428165428.GA2364578@embecosm.com> (raw)
In-Reply-To: <ws-_58dlja58hxs7_7nfxdpf-edz.sod4/tt56v&u48h70-.h_wk@mail.bob131.so>
* George Barrett via Gdb-patches <gdb-patches@sourceware.org> [2021-04-29 02:27:26 +1000]:
> Adds a couple of missing bits to the Guile API to make C++11 rvalue
> reference values and types usable from Guile scripts.
>
> gdb/ChangeLog:
>
> 2021-04-29 George Barrett <bob@bob131.so>
>
> * guile/scm-type.c (type_integer_constants): Add binding for
> TYPE_CODE_RVALUE_REF.
> * guile/scm-value.c (gdbscm_value_referenced_value): Handle
> dereferencing of rvalue references.
> * NEWS (Guile API): Note improvements in rvalue reference
> support.
>
> gdb/doc/ChangeLog:
>
> 2021-04-29 George Barrett <bob@bob131.so>
>
> * guile.texi (Types In Guile): Add documentation for
> TYPE_CODE_RVALUE_REF.
Looks good to me.
Thanks,
Andrew
> ---
> gdb/NEWS | 7 +++++++
> gdb/doc/guile.texi | 3 +++
> gdb/guile/scm-type.c | 1 +
> gdb/guile/scm-value.c | 1 +
> 4 files changed, 12 insertions(+)
>
> diff --git a/gdb/NEWS b/gdb/NEWS
> index 6550ea352ac..9c76df8b6d5 100644
> --- a/gdb/NEWS
> +++ b/gdb/NEWS
> @@ -185,6 +185,13 @@ QMemTags
> Request the remote to store the specified allocation tags to the requested
> memory range.
>
> +* Guile API
> +
> + ** Improved support for rvalue reference values:
> + TYPE_CODE_RVALUE_REF is now exported as part of the API and the
> + value-referenced-value procedure now handles rvalue reference
> + values.
> +
> *** Changes in GDB 10
>
> * There are new feature names for ARC targets: "org.gnu.gdb.arc.core"
> diff --git a/gdb/doc/guile.texi b/gdb/doc/guile.texi
> index 762a82a08c5..c7904574002 100644
> --- a/gdb/doc/guile.texi
> +++ b/gdb/doc/guile.texi
> @@ -1268,6 +1268,9 @@ A pointer-to-member.
> @item TYPE_CODE_REF
> A reference type.
>
> +@item TYPE_CODE_RVALUE_REF
> +A C@t{++}11 rvalue reference type.
> +
> @item TYPE_CODE_CHAR
> A character type.
>
> diff --git a/gdb/guile/scm-type.c b/gdb/guile/scm-type.c
> index 8d9c2c5f9a4..d65102b01c7 100644
> --- a/gdb/guile/scm-type.c
> +++ b/gdb/guile/scm-type.c
> @@ -1318,6 +1318,7 @@ static const scheme_integer_constant type_integer_constants[] =
> X (TYPE_CODE_METHODPTR),
> X (TYPE_CODE_MEMBERPTR),
> X (TYPE_CODE_REF),
> + X (TYPE_CODE_RVALUE_REF),
> X (TYPE_CODE_CHAR),
> X (TYPE_CODE_BOOL),
> X (TYPE_CODE_COMPLEX),
> diff --git a/gdb/guile/scm-value.c b/gdb/guile/scm-value.c
> index 59995169cd0..f50e8b5b46c 100644
> --- a/gdb/guile/scm-value.c
> +++ b/gdb/guile/scm-value.c
> @@ -476,6 +476,7 @@ gdbscm_value_referenced_value (SCM self)
> res_val = value_ind (value);
> break;
> case TYPE_CODE_REF:
> + case TYPE_CODE_RVALUE_REF:
> res_val = coerce_ref (value);
> break;
> default:
> --
> 2.30.2
next prev parent reply other threads:[~2021-04-28 16:54 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-28 16:27 [PATCH v3 0/3] Guile: add value-{reference,const}-value George Barrett via Gdb-patches
2021-04-28 16:27 ` [PATCH v3 1/3] Guile: improved rvalue reference support George Barrett via Gdb-patches
2021-04-28 16:38 ` Eli Zaretskii via Gdb-patches
2021-04-28 16:54 ` Andrew Burgess [this message]
2021-04-28 16:27 ` [PATCH v3 2/3] Guile: add {r,}value-reference-value George Barrett via Gdb-patches
2021-04-28 16:40 ` Eli Zaretskii via Gdb-patches
2021-04-28 16:59 ` Andrew Burgess
2021-04-28 17:11 ` George Barrett via Gdb-patches
2021-04-28 16:27 ` [PATCH v3 3/3] Guile: add value-const-value George Barrett via Gdb-patches
2021-04-28 16:39 ` Eli Zaretskii via Gdb-patches
2021-04-28 17:00 ` Andrew Burgess
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=20210428165428.GA2364578@embecosm.com \
--to=andrew.burgess@embecosm.com \
--cc=bob@bob131.so \
--cc=gdb-patches@sourceware.org \
/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