3 ms·
Yes it would copy, unless you used an explicit std::move(). This is why most of the time you're better off just passing things around by value, and making your
by nly 10y ago
Yes it would copy, unless you used an explicit std::move(). This is why most of the time you're better off just passing things around by value, and making your classes cheap to move (by, force example, making use of pointers (smart or otherwise)).
This results in less code and more manageable semantics.