
AMDG Lance.Diduck@ubs.com wrote:
Steven Watanabe wrote:
As I understand it, if I have a List that exists for the duration of
the program, and I am often
adding and removing elements, then the memory for the elements will
just build up until the List is destroyed. In fact, with some implementations of std::list will support this behavior with a suitable allocator. See pg 31 of http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2007/n2486.pdf for an example. So the idea has been around for some time -- an allocator could allocate live objects and not just raw memory.
I understand that, and I can see that it may make lists run faster. /depending on the circumstances/. This is a useful idea and I would support a boost submission. I just wanted to point out that it is not a panacea for all memory problems. In Christ, Steven Watanabe