|
Boost : |
From: Hartmut Kaiser (hartmutkaiser_at_[hidden])
Date: 2004-01-09 13:34:48
David Abrahams wrote:
> > Completely relying on MOJO or similar techniques would
> require, that
> > I'm able/allowed to _modify_ the base iterator code, which isn't
> > always true.
>
> I'm not talking about relying on MOJO, I'm talking about
> andrei's finding that on compilers that elide copies, passing
> objects by reference if they're just going to be copied
> anyway is almost always a mistake.
Sorry, I've misunderstood.
It seems to me, that Andrei wrote his 'Lying const' statements under the
strong impression, that ZUTO would work as expected. But AFAIR ZUTO never
worked as envisioned and therefor MOJO was developed. But I'm not pushing
you to use a const reference, it was merely a question to understand the
rationale behind this design decision.
Regards Hartmut
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk