> > > Was/is the 2 correct then? (if it was next(rbegin, 2) that'd be > equivalent > > to prev(end, 3), yes?) > > I think it is from looking at the test case, looping in martin to see > whether I'm right :)
At that point in the code, we have [..., PrePrev = '@', Prev = 'SomeToken'] and CurrentToken = 'Whatever', CurrentToken has not been appended to the list yet. So moving two from the end should be correct. I don't quite understand why rend() actually works in my code with the unit tests. Is that some unintentional side effect of its implementation leaking? I think I explicitly confirmed that my test does test what it's trying to test. Martin
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits