U++ framework
Do not panic. Ask here before giving up.

Home » U++ Library support » U++ Core » Vcont.h and Vcont.hpp Change required
Re: Vcont.h and Vcont.hpp Change required [message #56801 is a reply to message #56760] Sat, 17 April 2021 06:13 Go to previous message
mirek is currently offline  mirek
Messages: 14291
Registered: November 2005
Ultimate Member
Well, I believe this would allow

Vector<Vector<int>> vv;
Vector<int> v;
....
vv.Add(v);


with silent deep copy performed. This is something we want to avoid. We want you to be explicit and either use

vv.Add(pick(v));


or

vv.Add(clone(v));



Add(const T&) variant is reserved for types with full copy semantics (e.g. int or String).

Mirek
 
Read Message
Read Message
Previous Topic: build with clang-mingw on Linux is broken
Next Topic: Any Example of Inverse a Matrix in U++?
Goto Forum:
  


Current Time: Sun Sep 06 13:57:01 GMT+2 2026

Total time taken to generate the page: 0.00572 seconds