Boost logo

Boost :

From: David Abrahams (david.abrahams_at_[hidden])
Date: 2002-01-31 18:03:54


Oh, I see. It's just that way in the documentation. Thanks for pointing it
out.

APB: I'd appreciate it lots if someone would submit a documentation patch to
cover this and the issue of the accessibility of non-const versions base()
and policies() as discussed on the list a few days ago. I'm just too
overwhelmed to do it right now.

TIA,
Dave

----- Original Message -----
From: "David Abrahams" <david.abrahams_at_[hidden]>
To: <boost_at_[hidden]>
Sent: Thursday, January 31, 2002 6:00 PM
Subject: Re: [boost] iterator_adaptor policies

>
> ----- Original Message -----
> From: "witt_ive" <witt_at_[hidden]>
>
>
> >
> > The default_iterator_policies member often take the iterator_adaptor
> > argument by const reference. Doesn't this introduce uneccessary
> > tempories?
> >
> > As in:
> >
> > template <class IteratorAdaptor>
> > typename IteratorAdaptor::reference dereference(const
> > IteratorAdaptor& x) const
> > { return *x.base(); }
> >
> > Would mean get a copy of base (base() const is used) and dereference
> > that.
>
> ????
> The defintion of base()const is:
>
> base_type const& base() const { return m_iter_p.first(); }
>
> Where's the copy? Am I missing something here?
>
>
> Info: http://www.boost.org Send unsubscribe requests to:
<mailto:boost-unsubscribe_at_[hidden]>
>
> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk