14 class UponCopyPrinter {
16 UponCopyPrinter() =
default;
17 UponCopyPrinter(UponCopyPrinter &&) =
default;
18 UponCopyPrinter(
const UponCopyPrinter &) { std::cout <<
"Invoking copy c'tor!" << std::endl; }
21 using namespace ROOT::VecOps;
23 void vo001_AdoptOrOwnMemory()
30 RVec<UponCopyPrinter> v(3);
33 RVec<UponCopyPrinter> v2(v.data(), v.size());
36 std::cout << v.data() <<
" and " << v2.data() << std::endl;
43 v2.push_back(UponCopyPrinter());
46 std::cout << v.data() <<
" and " << v2.data() << std::endl;