It is the year 2020: why should I use / learn D?
Steven Schveighoffer
schveiguy at gmail.com
Mon Nov 26 14:10:35 UTC 2018
On 11/24/18 11:23 PM, Walter Bright wrote:
> BTW, you can defeat autodecode for your own programs by using the
> .byChar filter:
>
> https://dlang.org/phobos/std_utf.html#byChar
No, use byCodeUnit instead. byChar will convert other characters to char
(in fact, byChar just returns r.byCodeUnit if it detects it's the same
width).
This is if you are expecting to ONLY get around auto-decoding. Of
course, if you need conversion to a specific width, byChar or byWchar or
byDchar will be useful.
-Steve
More information about the Digitalmars-d
mailing list