shifting array slices

Ellery Newcomer ellery-newcomer at utulsa.edu
Sat Feb 11 10:09:32 PST 2012


I'm pretty sure this used to work:

import std.algorithm;

int[] ra;
copy(ra[5 .. 10], ra[4 .. 9]);

and would correctly shift the range [5 .. 10] down one
(unlike ra[4 .. 9] = ra[5 .. 10], which is prohibited by spec)

In dmd 2.057 of course it doesn't work; is this a bug or should I be 
looking elsewhere for this functionality?


More information about the Digitalmars-d-learn mailing list