In C++03 it is impossible to return an object of a class having a private non-defined copy constructor by value:
struct A { A(int x) { ... } private: A(A con
The above code is still ill-formed in C++11. But you could add a public move constructor to A and then it would be legal:
A
struct A { A(int x) {} A(A&&); private: A(A const&); }; A f() { return A(10); // Ok! }