On Monday, 6 October 2014 at 20:06:41 UTC, Nordlöw wrote:
I've almost satisfied with my new range slidingSplitter at

https://github.com/nordlow/justd/blob/master/range_ex.d#L19

All unittest work as expected except my radial test

https://github.com/nordlow/justd/blob/master/range_ex.d#L243

which, I believe, incorrectly prints

Tuple!(int[], int[])([1, 2], [3])
Tuple!(int[], int[])([1, 2], [3])
Tuple!(int[], int[])([1], [2, 3])
Tuple!(int[], int[])([1, 2, 3], [])
Tuple!(int[], int[])([], [1, 2, 3])

I cannot understand why the line

Tuple!(int[], int[])([1, 2], [3])

is printed twice at the beginning.

Have I done something wrong in my implementation of opIndex or opSlice?

I don't have time to investigate tonight, and it's probably not it, but your "save" isn't saving "_upper".

I don't know how your "radial" works. Does the first "back" print "([1, 2, 3], [])" as it should?

Reply via email to