lazy slice of the same kind and the same structure Note: Does not allocate neither new slice nor a closure.
import mir.ndslice.topology; auto payload = [1, 2, 3, 4]; auto s = iota([payload.length], payload.ptr); // slice of references; assert(s[1] == payload.ptr + 1); auto c = *s; // the same as s.map!"*a" assert(c[1] == *s[1]); *s[1] = 3; assert(c[1] == *s[1]);
Element-wise binary operator overloading.