Tim Schumacher
6d4d6c3e2a
LibC: Implement wcswidth
2022-06-30 11:57:49 +02:00
Tim Schumacher
ffb95bace4
LibC: Implement wcsftime
using a makeshift solution
2022-06-23 15:45:04 +01:00
Ali Mohammad Pur
0d7d2b825e
LibC: Add POSIX spec links to all applicable wide character functions
2021-12-21 21:24:36 +03:30
Ali Mohammad Pur
687a3351c2
LibC: Stub out wcsftime()
2021-12-21 21:24:36 +03:30
Ali Mohammad Pur
f0709c7a24
LibC+AK: Implement all sorts of wprintf variants
2021-12-21 21:24:36 +03:30
Ali Mohammad Pur
3b281baf75
LibC: Implement wcs{,c}spn()
2021-12-21 21:24:36 +03:30
Ali Mohammad Pur
cacc3ee857
LibC: Switch to using east const in wchar.cpp
2021-12-21 21:24:36 +03:30
Tim Schumacher
8eca395e4c
LibC: Implement wcsdup
2021-12-19 18:22:41 -08:00
Tim Schumacher
89afd4d063
LibC: Implement mbsnrtowcs
2021-10-21 23:57:32 -07:00
Tim Schumacher
552ae77f0d
LibC: Implement wcsnrtombs
2021-10-21 23:57:32 -07:00
Tim Schumacher
e618602433
LibC: Implement mbrlen
2021-10-21 23:47:20 -07:00
Daniel Bertalan
95c32fdf19
LibC: Primitively implement wcsxfrm
...
The `wcsxfrm` function copies a wide character string into a buffer,
such that comparing the new string against any similarly pre-processed
string with `wcscmp` produces the same result as if the original strings
were compared with `wcscoll`.
Our current `wcscoll` implementation is simply an alias for `wcscmp`, so
`wcsxfrm` needs to perform no actions other than copying the string.
2021-10-17 17:09:58 +01:00
Daniel Bertalan
13e6d9d71a
LibC: Implement wcslcpy
2021-10-17 17:09:58 +01:00
Daniel Bertalan
e6164d35fa
LibC: Fix wcsrchr declaration to return a non-const wchar*
...
This is how the standard specifies it; similarly to the already
correctly declared wcschr function.
2021-10-17 17:09:58 +01:00
Daniel Bertalan
763a69d46d
LibC: Stub out mbsnrtowcs
2021-10-17 17:09:58 +01:00
Daniel Bertalan
54eee525e6
LibC: Stub out wcsnrtombs
2021-10-17 17:09:58 +01:00
Daniel Bertalan
57f0c12b9a
LibC: Implement wmemcmp
2021-10-17 17:09:58 +01:00
Tim Schumacher
3336c382fb
LibC: Implement wctob
2021-10-17 12:40:48 +01:00
Tim Schumacher
420bdccf0b
LibC: Implement mbsrtowcs
2021-10-15 21:50:19 -07:00
Tim Schumacher
b0babd062e
LibC: Implement wcsrtombs
2021-10-15 21:50:19 -07:00
Daniel Bertalan
c8367df746
LibC: Implement wcrtomb
...
This function converts a single wide character into its multibyte
representation (UTF-8 in our case). It is called from libc++'s
`std::basic_ostream<wchar_t>::flush`, which gets called at program exit
from a global destructor in order to flush `std::wcout`.
2021-10-15 21:50:19 -07:00
Tim Schumacher
9c29e6cde7
LibC: Partially implement wcwidth
2021-10-15 21:50:19 -07:00
Tim Schumacher
4ef3ed4ba3
LibC: Implement mbrtowc closer to POSIX
2021-10-03 11:13:50 +00:00
Tim Schumacher
212f9308d4
LibC: Specifically clear only stored bytes after successful mbrtowc
2021-10-03 11:13:50 +00:00
Tim Schumacher
06f30943ef
LibC: Manually count stored bytes in mbstate_t
...
This is probably a bit faster than constantly having to look through all
stored bytes. It also helps when we are trying to store actual null
bytes.
2021-10-03 11:13:50 +00:00
Tim Schumacher
3c807402b3
LibC: Remove the mbstate_reset helper
...
A zero-initialized mbstate_t struct has to be a valid initial state, so
we can just zero-initialize it whenever we need to reset.
Having a helper function for resetting the struct might imply that you
can add additional setup operations afterwards, which is not the case.
2021-10-03 11:13:50 +00:00
Tim Schumacher
c3b14588ec
LibC: Stub out swprintf
2021-10-03 05:28:51 +00:00
Tim Schumacher
e82dc7c77a
LibC: Stub out wcstold
2021-10-03 05:28:51 +00:00
Tim Schumacher
893d9e8741
LibC: Stub out wcstod
2021-10-03 05:28:51 +00:00
Tim Schumacher
e0548692ac
LibC: Stub out wcstof
2021-10-03 05:28:51 +00:00
Tim Schumacher
783ddd261d
LibC: Stub out wcstoull
2021-10-03 05:28:51 +00:00
Tim Schumacher
a65f52d8de
LibC: Stub out wcstoul
2021-10-03 05:28:51 +00:00
Tim Schumacher
05b283f552
LibC: Implement wmemmove
2021-10-03 05:28:51 +00:00
Tim Schumacher
fa1208edfd
LibC: Implement wmemset
2021-10-03 05:28:51 +00:00
Tim Schumacher
485c0ef691
LibC: Implement wmemcpy
2021-10-03 05:28:51 +00:00
Tim Schumacher
0ca1df4dc6
LibC: Implement wmemchr
2021-10-03 05:28:51 +00:00
Tim Schumacher
5ac2e84264
LibC: Implement wcsstr
2021-10-03 05:28:51 +00:00
Tim Schumacher
1b078f87b7
LibC: Implement wcspbrk
2021-10-03 05:28:51 +00:00
Tim Schumacher
b8c756a53a
LibC: Primitively implement wcscoll
...
At the moment, sorting like LC_COLLATE=C would do is better than
nothing.
2021-09-18 02:57:56 +00:00
Tim Schumacher
a1617faf44
LibC: Implement mbsinit and mbrtowc
2021-09-16 16:42:40 +02:00
Tim Schumacher
405f3d0aa3
LibC: Implement btowc()
2021-09-16 16:42:40 +02:00
Tim Schumacher
e4fa9c917e
LibC: Stub out a bunch of wchar functions
2021-09-16 16:42:40 +02:00
Tim Schumacher
d364abe4d5
LibC: Stub out btowc
...
wint_t is also not supposed to be defined by sys/types.h, but should
be defined in wchar.h instead. Since we require it for our definition of
btowc, let's move it to the correct place.
2021-05-30 14:56:50 +01:00
Andreas Kling
357a455b5c
iLibC: Fix some missed camelCase => snake_case
2021-04-29 10:34:02 +02:00
Brian Gianforcaro
1682f0b760
Everything: Move to SPDX license identifiers in all files.
...
SPDX License Identifiers are a more compact / standardized
way of representing file license information.
See: https://spdx.dev/resources/use/#identifiers
This was done with the `ambr` search and replace tool.
ambr --no-parent-ignore --key-from-file --rep-from-file key.txt rep.txt *
2021-04-22 11:22:27 +02:00
Linus Groh
3c68f557a9
LibC: Add wcstol() and wcstoll() stubs
2021-01-18 22:28:56 +01:00
Linus Groh
ec42f864d4
LibC: Add wcsncmp()
...
Taken from strncmp(), like wcscmp() in ef40ebb
. :^)
2021-01-18 22:28:56 +01:00
Andreas Kling
13d7c09125
Libraries: Move to Userland/Libraries/
2021-01-12 12:17:46 +01:00