Thursday, December 2, 2010

Shrink-to-fit

Shrink-to-fit - Minimize the capacity of a container just enough to hold existing range: std::vector(v).swap(v);

Reference: http://en.wikibooks.org/wiki/More_C%2B%2B_Idioms

No comments:

Post a Comment