--- Comment #4 from dgregor at gcc dot gnu dot org 2008-09-24 20:20 ---
GCC is doing the right thing here. In this constructor:
Thing2(Thing2&& o) : Thing(o) { }
the parameter "o" is treated as an lvalue, because it has a name. Using
std::move(o) to treat it as an rvalue.
Similarly,
--- Comment #3 from s_gccbugzilla at nedprod dot com 2008-06-08 17:19
---
Created an attachment (id=15733)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=15733&action=view)
Failing
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36461
--- Comment #2 from s_gccbugzilla at nedprod dot com 2008-06-08 17:19
---
This problem actually seems to be one of subclassing: child class rvalue
constructors invoke base class lvalue constructors!!!
I have attached an example. As is, it compiles and works. If however you throw
a Thin
--- Comment #1 from s_gccbugzilla at nedprod dot com 2008-06-08 17:07
---
Created an attachment (id=15732)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=15732&action=view)
Test Case
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36461