Subject: Re: [boost] [Intrusive] [MultiIndex] Random Access mental model?
From: David Abrahams (dave_at_[hidden])
Date: 2008-11-02 08:54:36
on Sat Nov 01 2008, Joaquin M Lopez Munoz <joaquin-AT-tid.es> wrote:
> Not that this has to do with the multi-indexing capabilities
> of Boost.MultiIndex, but I think you can still take (a little)
> advantange of the lib by using a multi_index_container<hashed_unique>
> instead of a unordered_map, because the former has an iterator_to()
> member function that allows you to retrieve an iterator from
> a value_type*, so saving you the jump from Key* to an iterator
> via map.find() that your code has at pop().
Oh, that's awesome! Thanks!
-- Dave Abrahams BoostPro Computing http://www.boostpro.com
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk