Question about opSlice

Ali Çehreli via Digitalmars-d digitalmars-d at
Tue Mar 17 10:36:20 PDT 2015

On 03/17/2015 09:29 AM, John Colvin wrote:
> On Tuesday, 17 March 2015 at 13:57:18 UTC, Ilya Ivanov wrote:
> [snip]
> I recently did a full Array2D with slicing and non-contiguous views etc
> and found that it was quite a nightmare getting all this stuff correct.
> I think your mistake is that opSlice needs to be a template to trigger
> the new-style slicing/indexing.
> E.g.
> opSlice(size_t dim)(size_t i, size_t j)

I have simple but working code for both methods at the following links:


More information about the Digitalmars-d mailing list