Question about wchar[]
ollie
ollie at home.net
Mon Feb 4 10:13:22 PST 2013
I am using wchar[] and find the usage clunky. Am I doing something wrong?
Example:
// Compiler complains that wchar[] != immutable(char)[]
wchar[] wstr = "This is a wchar[]";
// Compiler accepts this
wchar[] wstr = "This is a wchar[]"w.dup;
// Compiler accepts this
wchar[] wstr;
wstr ~= "This is a wchar[]";
If the compiler knows the type in the last example with concatenation,
shouldn't it be able to figure that out in the first example.
I am using windows and DMD HEAD.
Thanks,
ollie
More information about the Digitalmars-d-learn
mailing list