Boost logo

Boost :

From: Daniel Frey (daniel.frey_at_[hidden])
Date: 2004-02-23 11:39:14


Gabriel Dos Reis wrote:
> David Abrahams <dave_at_[hidden]> writes:
>
> | Hey! These implementations using "advance" don't work for
> | non-iterators (e.g. int) the way regular next() and prior() do. I
> | consider this a bug!
>
> You're right.

I don't see any need to extend the legal use of next/prior to anything
else than iterators. I considered the fact that it works/worked for
non-iterators an accident as the documentation only speaks about
iterators and never bothers to mention non-iterators. Thus, the bug is
IMHO that it's not explicitly documented that next/prior's first
argument must meet the interator requirements.

Regards, Daniel

(Gaby: Yes, it's bending the rules. So, agreed, I won't file a DR :)

-- 
Daniel Frey
aixigo AG - financial solutions & technology
Schloß-Rahe-Straße 15, 52072 Aachen, Germany
fon: +49 (0)241 936737-42, fax: +49 (0)241 936737-99
eMail: daniel.frey_at_[hidden], web: http://www.aixigo.de

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