diff options
author | Thomas Voss <mail@thomasvoss.com> | 2024-05-04 04:01:45 +0200 |
---|---|---|
committer | Thomas Voss <mail@thomasvoss.com> | 2024-05-04 04:01:45 +0200 |
commit | ac1b4bcbaeaee7d2ef9132dcdc254f2d08691650 (patch) | |
tree | 90250966629653f0462cf17bc0b6f2476fb6d1fc /include/unicode | |
parent | 8b923ba5e5bb37ea26350b4c1c688b8697706609 (diff) |
Go all in on string views, and fix manuals
Diffstat (limited to 'include/unicode')
-rw-r--r-- | include/unicode/string.h | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/include/unicode/string.h b/include/unicode/string.h index 0ae49f0..bb8cafd 100644 --- a/include/unicode/string.h +++ b/include/unicode/string.h @@ -21,22 +21,22 @@ enum [[clang::flag_enum]] caseflags { /* clang-format on */ -[[nodiscard]] size_t u8gcnt(const char8_t *, size_t); -[[nodiscard]] size_t u8wcnt(const char8_t *, size_t); -[[nodiscard]] size_t u8wcnt_human(const char8_t *, size_t); - -size_t u8gnext(struct u8view *, const char8_t **, size_t *); -size_t u8wnext(struct u8view *, const char8_t **, size_t *); -size_t u8wnext_human(struct u8view *, const char8_t **, size_t *); - -[[mlib_warn_trunc]] size_t u8lower(char8_t *restrict, size_t, const char8_t *, - size_t, enum caseflags); -[[mlib_warn_trunc]] size_t u8title(char8_t *restrict, size_t, const char8_t *, - size_t, enum caseflags); -[[mlib_warn_trunc]] size_t u8upper(char8_t *restrict, size_t, const char8_t *, - size_t, enum caseflags); -[[mlib_warn_trunc]] size_t u8casefold(char8_t *restrict, size_t, - const char8_t *, size_t, enum caseflags); +[[nodiscard]] size_t u8gcnt(struct u8view); +[[nodiscard]] size_t u8wcnt(struct u8view); +[[nodiscard]] size_t u8wcnt_human(struct u8view); + +size_t u8gnext(struct u8view *, struct u8view *); +size_t u8wnext(struct u8view *, struct u8view *); +size_t u8wnext_human(struct u8view *, struct u8view *); + +[[mlib_warn_trunc]] size_t u8lower(char8_t *restrict, size_t, struct u8view, + enum caseflags); +[[mlib_warn_trunc]] size_t u8title(char8_t *restrict, size_t, struct u8view, + enum caseflags); +[[mlib_warn_trunc]] size_t u8upper(char8_t *restrict, size_t, struct u8view, + enum caseflags); +[[mlib_warn_trunc]] size_t u8casefold(char8_t *restrict, size_t, struct u8view, + enum caseflags); constexpr double U8LOWER_SCALE = 1.5; constexpr double U8LOWER_SCALE_LT = 3; |