Boost logo

Boost :

Subject: Re: [boost] [utility] prior(it, n) for n being an unsigned type
From: Andrey Semashev (andrey.semashev_at_[hidden])
Date: 2014-06-30 11:05:51


On Monday 30 June 2014 15:12:37 Jürgen Hunold wrote:
> Hi Adam,
>
> Am Montag, 30. Juni 2014, 13:19:33 schrieb Adam Romanek:
> > > It broke some tests, see my recent post [1]. This change won't be merged
> > > to
> > > master until these problems are resolved.
> >
> > The problem with the tests suggests that this change may also cause some
> > regression in end-user code, but I guess there's nothing we can do about
> > it (except for putting a few words in the release notes).
>
> This definitely broke some code here. Some more words on how to adapt to the
> changes will be appreciated. Or even a non-breaking fix.

The functions now detect if the first operand supports arithmetic operators
(+=, + -=, -) and uses them if they are defined. The related pull request for
Boost.Iterator makes iterator_facade to not define these operators if the
iterator doesn't support them. If your case does not involve Boost.Iterator
iterators then you need to make a similar change to your iterators that you
use with next()/prior().


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