First marking this as pushed ( as I pushed this but forgot to mark it as so )
On 04/02/12 16:00, Michael Stahl wrote:
[...]
hi Noel,

a further improvement would be to replace boost::ptr_vector with
std::vector: our various String classes (at least the 4 most popular
ones) effectively are already smart pointers to an array and can be
stored directly in STL containers, so wrapping them in _another_ pointer
is just, errm, pointless
I suppose you save lots of String copies but.... presumably if the String implementation really is 'smart' ( which iirc it is ) then it only points to the existing string and doesn't actually create a 'new' copy of that. I wonder why the orig implementation didn't store objects ( or didn't List ever support that ) or was it influenced by a heap vs stack concern ( that probably is irrelevant these days ) Anyway, won't do any harm leaving it as it is or perhaps someone will go the extra step and change it.

Noel
_______________________________________________
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice

Reply via email to