From: Keith Seitz <keiths@redhat.com>
To: Simon Marchi <simon.marchi@ericsson.com>, gdb-patches@sourceware.org
Subject: Re: [PATCH] Fix use-after-move in compile/compile-cplus-types.c
Date: Mon, 17 Sep 2018 15:25:00 -0000 [thread overview]
Message-ID: <539a8428-a038-aeb7-0a1c-edbe99cda98d@redhat.com> (raw)
In-Reply-To: <20180917135203.10368-1-simon.marchi@ericsson.com>
On 09/17/2018 06:52 AM, Simon Marchi wrote:
> Patch
>
> d82b3862f12 ("compile: Remove non-const reference parameters")
>
> introduced a regression in compile/compile-cplus-types.c. The new_scope
> variable in compile_cplus_instance::enter_scope is used after it was
> std::moved. This patch fixes it by referring to the back of the vector
> where it was moved instead.
>
> gdb/ChangeLog:
>
> * compile/compile-cplus-types.c
> (compile_cplus_instance::enter_scope): Don't use new_scope after
> std::move.
That LGTM. [Although I would have used a const reference to it everywhere, but
six of one, ...]
Keith
PS. Reminder: IANAM, but you are. So please approve your patch. :-)
next prev parent reply other threads:[~2018-09-17 15:25 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-08-30 16:47 [PATCH] compile: Remove non-const reference parameters Simon Marchi
2018-08-30 21:57 ` Keith Seitz
2018-08-31 14:41 ` Tom Tromey
2018-09-06 10:27 ` Simon Marchi
2018-09-06 12:43 ` Tom Tromey
2018-09-06 12:49 ` Simon Marchi
2018-09-17 6:32 ` Tom Tromey
2018-09-17 13:29 ` Keith Seitz
2018-09-17 13:52 ` [PATCH] Fix use-after-move in compile/compile-cplus-types.c Simon Marchi
2018-09-17 15:25 ` Keith Seitz [this message]
2018-09-17 17:10 ` 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=539a8428-a038-aeb7-0a1c-edbe99cda98d@redhat.com \
--to=keiths@redhat.com \
--cc=gdb-patches@sourceware.org \
--cc=simon.marchi@ericsson.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