Compiling the following code with DMD 2.052 on Mac OS X:

import std.array;

void main ()
{
    char[] a;
    char[] b;
    a.replace(1, 3, b);
}

Results in the following error:

test.d(7): Error: template std.array.replace(T,Range) if (isDynamicArray!(Range) && is(ElementType!(Range) : T)) does not match any function template declaration test.d(7): Error: template std.array.replace(T,Range) if (isDynamicArray!(Range) && is(ElementType!(Range) : T)) cannot deduce template function from argument types !()(char[],int,int,char[])

What am I doing wrong or isn't std.array.replace supposed to work with char[]?

--
/Jacob Carlborg

Reply via email to