
"Gennadiy Rozental" <gennadiy.rozental@thomson.com> wrote in message news:d4ooik$f0h$1@sea.gmane.org...
you're analogy with vector<string> don't quite fit IMO. assigning vector<string> might be quite efficient with very few heap-allocations taking place; assigning ptr_vector<Foo> would cost the same as copy-construction + deallocation.
IMO no performance point could justify omitting assignment operator. If I need vector<ptr_vector<Foo> > - it's my decision and I will deal with performance penalties.
I agree very much with Gennadiy and others who argue that performance concerns should not cause an otherwise useful operation to be omitted. Some programs know in advance that they will never see large (in relation to processor speed or memory) numbers of elements in a particular container. The main considerations are convenience and functionality, not performance. "Premature optimization is the root of all evil." Hoare, Knuth --Beman