String.get

Returns an array used internally by the string. The length of the returned array may be smaller than the size of the reserved memory for the string.

struct String
inout @nogc nothrow pure @trusted
inout(char)[]
get
()

Return Value

Type: inout(char)[]

The array representing the string.

Examples

auto s = String("Char array.");
assert(s.get().length == 11);

Meta