This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/39050] New: [c++0x] rvalue reference & copy construction issue
- From: "s dot gesemann at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 31 Jan 2009 21:03:07 -0000
- Subject: [Bug c++/39050] New: [c++0x] rvalue reference & copy construction issue
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
Consider:
struct S {
private:
S(const S&); // no copy-c'tor
};
S && ref();
void f(S);
void g() {
f(ref());
}
This compiles using
g++ -c -std=c++0x test.cpp
where in fact the compiler should complain about the copy-c'tor not being
public.
--
Summary: [c++0x] rvalue reference & copy construction issue
Product: gcc
Version: 4.3.2
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: s dot gesemann at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39050