This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/34022] C++0x: rvalue references and std::forward() broken with built-in types
- From: "dgregor at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 18 Nov 2007 14:15:02 -0000
- Subject: [Bug c++/34022] C++0x: rvalue references and std::forward() broken with built-in types
- References: <bug-34022-13491@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #4 from dgregor at gcc dot gnu dot org 2007-11-18 14:15 -------
On further reading into the standard, I believe GCC is doing the right thing.
8.5.3p5 is very specific in saying that one can only bind a reference to an
rvalue if the type of the rvalue is of class type. Otherwise, a temporary is
being created.
If this isn't what Howard intended or expected, we need to bring this to the
committee.
--
dgregor at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |SUSPENDED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34022