fork(2) download
  1. #include <stdio.h>
  2. #include <vector>
  3. #include <string>
  4.  
  5. struct t_obj
  6. {
  7. std::vector<std::string> strings;
  8. };
  9.  
  10. int main()
  11. {
  12. std::vector<t_obj> objects;
  13.  
  14. objects.push_back(t_obj());
  15.  
  16. t_obj& o = objects.back();
  17.  
  18. objects.push_back(t_obj());
  19.  
  20. o = objects.back();
  21. return 0;
  22. }
Success #stdin #stdout 0s 2816KB
stdin
Standard input is empty
stdout
Standard output is empty