idup

Provide the .idup array property.

  1. immutable(T)[] idup [@property getter]
  2. immutable(T)[] idup [@property getter]
    @property
    immutable(T)[]
    idup
    (
    T : void
    )
    (
    const(T)[] a
    )

Examples

char[] arr = ['a', 'b', 'c'];
string s = arr.idup;
arr[0] = '.';
assert(s == "abc");

Meta