|
Boost Users : |
Subject: Re: [Boost-users] [multi_index] modify_key with an iterator to composite_key
From: Dominique Devienne (ddevienne_at_[hidden])
Date: 2010-01-27 11:01:02
On Wed, Jan 27, 2010 at 8:13 AM, <joaquin_at_[hidden]> wrote:
> On the bright side, index updating has been implemented so as to be as fast
> as possible: before relocating an element indices check internally whether
> the element remains in place after modification, which is usually a cheaper
> operation than brute relocation. In the particular case of a hashed index,
> if modify() hasn't touched its key then updating merely invokes a hash call
> and a couple of pointer comparisons (not even equality comparison is needed.)
Cool, that's a valuable tip about the implementation. Would make a
great note in the doc. Boost docs tend to be quite dry, and your very
insightful answer to Christian's question would be very appreciated in
the doc, perhaps linked from modify()/modify_key(). My $0.02, and once
again thanks for this fantastic library. --DD
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net