4 ms·
> If you only need the byte count then even you can use strlen no matter what the encoding is. No, strlen won't give you the byte count on UTF16 encodings. >
by lelanthran 10mo ago
> If you only need the byte count then even you can use strlen no matter what the encoding is.
No, strlen won't give you the byte count on UTF16 encodings.
> If you need character count then you don't use strlen no matter what the encoding is (except in ASCII only environment).
What use-case requires the character count without also requiring a unicode glyph library?
- raincole 10mo ago> strlen won't give you the byte count on UTF16 encodings. You're right. I stand corrected.