On Sat, Dec 20, 2014 at 01:43:53PM -0500, al davis wrote: > There are lots of such copies in the current implementation. > Every time the map is accessed, either in or out, something is > copied and something is deleted.
std::map<X,Y>::operator[](const&X) returns a Y&, which acts more or less like a Y* here. thus, no copy is involved when accessing existant entry (speaking of c++98). FWIW, in c++11, not even upon creating a new pair (accessing a nonexisting map element) the copy constructor of Y is called. they did a great job in avoiding unnecessary copies, which they are totally aware of. i'm not fully convinced that the current implementation calls more copies than it should. but sure, i might be missing something. cheers felix PS: i am still not against removal of the WAVE copy constructor, anyway, we should better not try to reinvent stl :) _______________________________________________ Gnucap-devel mailing list [email protected] https://lists.gnu.org/mailman/listinfo/gnucap-devel
