From: Beman Dawes (bdawes_at_[hidden])
Date: 2005-04-27 17:41:51
"Gennadiy Rozental" <gennadiy.rozental_at_[hidden]> wrote in message
>> 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
>> 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
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk