News for hackers. Stuff that matters.
Re:C++: Return value optimization vs. std::move by TheCoelacanth on Monday July 20, 2015 @02:42PM (#9918090)
A copy constructor that cannot be elided is a broken copy constructor.
Re:C++: Return value optimization vs. std::move by ExpiredLink on Monday July 20, 2015 @05:49PM (#9919337)
This may be true for simple structs but is definitely wrong as a general statement. Compilers cannot anticipate semantics.
Re:C++: Return value optimization vs. std::move by TheCoelacanth on Tuesday July 21, 2015 @09:56AM (#9922256)
It is true for all copy constructors in C++ since the standard allows compilers to perform copy elision.