safec 3.8.0
Safe C Library - ISO TR24731 Bounds Checking Interface
|
#include "safe_str_lib.h"
Functions | |
int | iswfc (const uint32_t wc) |
int | _towfc_single (wchar_t *restrict dest, const uint32_t src) |
int | towfc_s (wchar_t *restrict dest, rsize_t dmax, const uint32_t src) |
Variables | ||
struct { | ||
unsigned short upper | ||
unsigned short lower1 | ||
unsigned short lower2 | ||
} | tbl2 [] | |
iswfc() checks the uppercase character for a mapping to foldcase, returning the number of new wide character codepoints needed. | ||
struct { | ||
unsigned short upper | ||
unsigned short lower1 | ||
unsigned short lower2 | ||
unsigned short lower3 | ||
} | tbl3 [] | |
int iswfc | ( | const uint32_t | wc | ) |
int _towfc_single | ( | wchar_t *restrict | dest, |
const uint32_t | src | ||
) |
int towfc_s | ( | wchar_t *restrict | dest, |
rsize_t | dmax, | ||
const uint32_t | src | ||
) |
unsigned short upper |
unsigned short lower1 |
unsigned short lower2 |
const struct { ... } tbl2[] |
iswfc() checks the uppercase character for a mapping to foldcase, returning the number of new wide character codepoints needed.
The usual iswupper(wc)
case returns 1, and the special 104 full folding cases as specified in Unicode 10.0 CaseFolding.txt
return either 2 or 3. This implements Unicode 14.0
[in] | wc | unicode character codepoint |
0 | when there is no corresponding lowercase mapping. |
1 | when there is a corresponding common or simple foldcase mapping. |
2 | a full case-folding expands to 2 characters |
3 | a full case-folding expands to 3 characters |
unsigned short lower3 |
const struct { ... } tbl3[] |