From: Tom Tromey <tromey@redhat.com>
To: Jan Kratochvil <jan.kratochvil@redhat.com>
Cc: gdb-patches@sourceware.org, Jonathan Wakely <jwakely.gcc@gmail.com>
Subject: Re: [patch] Support C++11 rvalue (move constructor)
Date: Mon, 14 Oct 2013 16:10:00 -0000 [thread overview]
Message-ID: <87fvs33kb7.fsf@fleche.redhat.com> (raw)
In-Reply-To: <20131012152836.GA9438@host2.jankratochvil.net> (Jan Kratochvil's message of "Sat, 12 Oct 2013 17:28:36 +0200")
CCing Jonathan Wakely.
Jan> currently one cannot debug C++11 move constructors, one gets:
This is PR 14441. Also see the thread:
https://sourceware.org/ml/gdb/2012-10/msg00108.html
I think Jonathan started a branch for this...
Jan> Therefore there is a KFAIL in the testcase for it. I do not think
Jan> GDB needs to handle && differently - except for displaying &&
Jan> instead of &.
Is that also true for inferior calls?
I didn't look.
Jan> or to add new main_type::flag_ref_is_rvalue valid only for
Jan> TYPE_CODE_REF but that is sure not a clean implementation.
If the semantics of the two kinds of references are sufficiently
similar, then I don't think it is actually so bad.
Jan> (2) One would need to add type.rvalue_reference_type (besides
Jan> type.reference_type) to prevent leaks of types. This would mean
Jan> increasing the current sizeof (struct type) 40 -> 48. The proper
Jan> solution is to rather implement reference counting or garbage
Jan> collecting of types and merge struct type into struct main_type.
Maybe the size increase isn't that important.
Alternatively maybe it can be handled like qualifiers.
Jan> Anyway currently I find the patch below as a good enough hack as currently
Jan> I find it a bit blocker when using C++11.
It seems reasonable to me -- an improvement, and not blocking any future
improvements.
Tom
next prev parent reply other threads:[~2013-10-14 16:10 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-12 15:28 Jan Kratochvil
2013-10-14 16:10 ` Tom Tromey [this message]
2013-10-14 17:34 ` Jonathan Wakely
2013-10-14 17:57 ` Jan Kratochvil
2013-10-14 18:18 ` Tom Tromey
2013-10-16 13:32 ` Jan Kratochvil
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=87fvs33kb7.fsf@fleche.redhat.com \
--to=tromey@redhat.com \
--cc=gdb-patches@sourceware.org \
--cc=jan.kratochvil@redhat.com \
--cc=jwakely.gcc@gmail.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