mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-07-03 17:58:30 +00:00
Do some string library work
This commit is contained in:
parent
83d41e4588
commit
35203c0551
42 changed files with 1381 additions and 136 deletions
|
@ -30,6 +30,6 @@ int wcsncasecmp(const wchar_t *a, const wchar_t *b, size_t n) {
|
|||
size_t i = 0;
|
||||
unsigned x, y;
|
||||
if (!n-- || a == b) return 0;
|
||||
while ((x = tolower(a[i])) == (y = tolower(b[i])) && b[i] && i < n) ++i;
|
||||
while ((x = towlower(a[i])) == (y = towlower(b[i])) && b[i] && i < n) ++i;
|
||||
return x - y;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue