Boost logo

Boost :

From: David Abrahams (dave_at_[hidden])
Date: 2004-09-16 09:47:30


"Peter Dimov" <pdimov_at_[hidden]> writes:

> David Abrahams wrote:
>>
>> Just because the original designers made the mistake of building in
>> rbegin() and rend() accessors, it doesn't mean we should perpetuate
>> the same mistake for consistency.
>
> I wouldn't call it a mistake. rbegin/rend isolate the user from the
> somewhat counter-intuitive notion that rbegin() is obtained from
> end().

Or they confuse the user who thinks "the iterator goes backwards,
therefore I should start from rend() and increment until rbegin()."

> I like the proposed cbegin/crbegin member functions. There is a vast
> audience of programmers that value ease of use and consistency above
> orthogonality.

Convenience functions are fine with me, actually. Still, I'd be
reluctant to do this without making the more general components
available.

-- 
Dave Abrahams
Boost Consulting
http://www.boost-consulting.com

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