-
-
Notifications
You must be signed in to change notification settings - Fork 131
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
strn*/utf8n* functions #105
Comments
I think I'd rather add |
Ahh, good point, what I suggested would break existing code that uses the header. Yes, I think your utf8ccmp is good solution. I think many of the utf8n* functions could use a utf8c* version, though it may not make sense in all cases. Thanks for the speedy reply. |
Do I see it correctly that even
FWIW, I'd vote for a breaking change, perhaps accompanied by a filename change (like |
For me too.
This is something I agree with as well. RETURN VALUE
The strlen() function returns the number of bytes in the string pointed to by s. whereas Since the |
I think your arguments are probably right the more I've considered this. My hesitation has been that the I can't commit to a timescale for this, but I'll try and work out a plan to do it. |
The utf8len function returns codepoints instead of bytes, as expected, but it seems things like utf8ncmp continue to use bytes, which wasn't what I expected. Perhaps utf8ncmp could use n in codepoints too, and another utf8bcmp could use b bytes?
Not at all critical, since a work-around is easy, and I have no idea if others would want codepoint counting instead of bytes for the n functions. I needed an n codepoint compare, so I noticed this.
The text was updated successfully, but these errors were encountered: