This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
[Bug symtab/14441] Need to support DW_TAG_rvalue_reference_type
- From: "jwakely.gcc at gmail dot com" <sourceware-bugzilla at sourceware dot org>
- To: gdb-prs at sourceware dot org
- Date: Sun, 16 Nov 2014 17:38:32 +0000
- Subject: [Bug symtab/14441] Need to support DW_TAG_rvalue_reference_type
- Auto-submitted: auto-generated
- References: <bug-14441-4717 at http dot sourceware dot org/bugzilla/>
https://sourceware.org/bugzilla/show_bug.cgi?id=14441
--- Comment #6 from Jonathan Wakely <jwakely.gcc at gmail dot com> ---
I can live with printing rvalue refs as <unknown type in /dev/shm/a.out, CU
0x0, DIE 0x4b> but the fact you're unable to do anything with them is a much
bigger problem:
struct A { int i; };
int f(A&& a)
{
return a.i;
}
int main()
{
return f( A() );
}
Reading symbols from ./a.out...done.
(gdb) start
Temporary breakpoint 1 at 0x4005de: file rv.cc, line 10.
Starting program: /tmp/a.out
Temporary breakpoint 1, main () at rv.cc:10
(gdb) step
f(A&&) (a=<unknown type in /tmp/a.out, CU 0x0, DIE 0x7f>) at rv.cc:5
(gdb) p a.i
Attempt to extract a component of a value that is not a structure.
This makes it almost impossible to debug functions taking rvalues, such as move
constructors and move assignment operators.
And sometimes move constructors are really hard to get right and need to be
debugged (e.g. std::stringstream is giving me major headaches)
--
You are receiving this mail because:
You are on the CC list for the bug.