Function Vector.ptr

Return pointer to the first element.

inout inout(Vector.ElementType)* ptr() pure nothrow @nogc @property @system;

The pointer returned may be invalidated by further calls to other member functions that modify the object.

Examples

Vector!(int, 6) vec = Vector!(int, 6).build(1, 2, 3);

assert(vec.ptr[0 .. 3] == [1, 2, 3]);