
OvermindDL1 escribió:
On Sun, Feb 21, 2010 at 4:44 PM, Andrey Semashev <andrey.semashev@gmail.com> wrote:
On 21.02.2010 23:59, Slawomir Lisznianski wrote:
http://svn.boost.org/svn/boost/sandbox/tokenmap/libs/tokenmap/doc/html/index...
[...]
Specifically, when a new element is inserted into the tokenmap, an apparently random key is returned back to the caller which uniquely maps to the stored element. The returned key can later be used in a very efficient lookup.
[...]
How is it different from having an iterator or a pointer to the inserted element?
Because those can get invalidated if the map resizes I would wager...
Given the very limited interface of tokenmap, you can easily implement in on top of a std::list, whose iterators do not get invalidated. I think Andrey's question is a critical one and has not yet been addressed. Joaquín M López Muñoz Telefónica, Investigación y Desarrollo