
3 Jun
2005
3 Jun
'05
7:39 p.m.
Christopher Diggins http://www.cdiggins.com ----- Original Message ----- From: "Peter Dimov" <pdimov@mmltd.net> To: <boost@lists.boost.org> Sent: Friday, June 03, 2005 3:07 PM Subject: Re: [boost] Re: Re: stride iterators and matricies
Neal Becker wrote:
Here's my version:
[...]
One interesting problem with strided iterators is coming up with end values. Suppose you have
int x[ 4 ];
and you want to iterate over x[1] and x[3] with stride 2. Your begin iterator will be x+1, and your end iterator will be x+5 - an invalid address.
I am very confused, isn't x+4 also an invalid address? What is the difference between x+4 and x+5 or any other address not within the range x to x+3 ? - Christopher