From: Tom Tromey <tom@tromey.com>
To: Simon Marchi <simon.marchi@polymtl.ca>
Cc: Tom Tromey <tom@tromey.com>, gdb-patches@sourceware.org
Subject: Re: [PATCH] Remove cleanups from linespec.c
Date: Wed, 02 Jan 2019 23:39:00 -0000 [thread overview]
Message-ID: <87ftuawrxf.fsf@tromey.com> (raw)
In-Reply-To: <a26a05a1289dc619737a26e64711d299@polymtl.ca> (Simon Marchi's message of "Wed, 02 Jan 2019 15:31:17 -0500")
>>>>> "Simon" == Simon Marchi <simon.marchi@polymtl.ca> writes:
>> + gdb_assert (state->canonical_names[i].suffix != NULL);
>> + gdb::unique_xmalloc_ptr<char> holder
>> + (state->canonical_names[i].suffix);
>> + hold_names.push_back (std::move (holder));
Simon> emplace_back?
Thanks, that is much nicer.
Simon> I suppose that ideally, these strings would be owned and deleted by
Simon> the linespec_state structure itself?
Yeah, that's one of the several ways linespec could be improved.
I tried once to do a big cleanup of all this, which convinced me that
doing lots of tiny steps is a better approach :-)
Tom
prev parent reply other threads:[~2019-01-02 23:39 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-02 16:18 Tom Tromey
2019-01-02 20:31 ` Simon Marchi
2019-01-02 23:39 ` Tom Tromey [this message]
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=87ftuawrxf.fsf@tromey.com \
--to=tom@tromey.com \
--cc=gdb-patches@sourceware.org \
--cc=simon.marchi@polymtl.ca \
/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