Higher level built-in strings
Walter Bright
newshound2 at digitalmars.com
Tue Jul 20 12:21:34 PDT 2010
Steven Schveighoffer wrote:
> The omission of dchar is on purpose. Phobos has characterized string as
> a bidirectional range of dchars. For every range where I do:
>
> foreach(e; range)
>
> e is of the type of the range. Except for char and wchar. This
> schizophrenia of type induction is very bad for D, and it's a good
> argument of why strings should not simply be arrays.
For many algorithms on strings, iterating by char is preferred over dchar, even
for multibyte strings.
More information about the Digitalmars-d
mailing list