|
Boost Users : |
From: Frank Mori Hess (frank.hess_at_[hidden])
Date: 2007-02-16 16:55:32
On Friday 16 February 2007 16:09 pm, you wrote:
> > Such a combiner would violate the single pass traversal limitation
> > of the input iterator concept. The cache solution allows dereferencing
> > the same iterator multiple times to acquire the same value without
> > calling the slot again, which already is a stronger guarantee than
> > an input iterator usually provides. The combiner example in the
> > docs makes use of it.
>
> Timmo,
>
> Thanks for you reply. I don't think I'm violating anything spelled out
> in the single pass traversal requirements (maybe violating the spirit
> but not the letter).
Oh, nevermind. Now I see the line in the docs for the input iterator
concept that would be violated:
[3] After executing ++i, it is not required that copies of the old value of
i be dereferenceable or that they be in the domain of operator==.
-- Frank
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