ndslice: convert a sliced object to T[]

Ilya Yaroshenko via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Wed Jun 15 11:36:20 PDT 2016


On Wednesday, 15 June 2016 at 14:14:23 UTC, Seb wrote:
> ```
> T[] a = slice.ptr[0.. slice.elementsCount];
> ```

This would work only for slices with continuous memory 
representation and positive strides. -- Ilya


More information about the Digitalmars-d-learn mailing list