chiark
/
gitweb
/
~mdw
/
disorder
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
don't be fooled by First/Last entries in UnicodeData.txt
[disorder]
/
lib
/
unicode.c
diff --git
a/lib/unicode.c
b/lib/unicode.c
index 48b7b2cc16792930950ee3f0a3355f63da54ac91..618ff06b64ec5a15c908c53015503c0cb721a915 100644
(file)
--- a/
lib/unicode.c
+++ b/
lib/unicode.c
@@
-577,12
+577,12
@@
int utf32_cmp(const uint32_t *a, const uint32_t *b) {
* @param Code point
* @return General_Category property value
*/
* @param Code point
* @return General_Category property value
*/
-static inline enum unicode_
gc_cat
utf32__general_category(uint32_t c) {
+static inline enum unicode_
General_Category
utf32__general_category(uint32_t c) {
if(c < UNICODE_NCHARS) {
const struct unidata *const ud = &unidata[c / UNICODE_MODULUS][c % UNICODE_MODULUS];
if(c < UNICODE_NCHARS) {
const struct unidata *const ud = &unidata[c / UNICODE_MODULUS][c % UNICODE_MODULUS];
- return ud->g
c
;
+ return ud->g
eneral_category
;
} else
} else
- return unicode_
gc
_Cn;
+ return unicode_
General_Category
_Cn;
}
/** @brief Check Grapheme_Cluster_Break property
}
/** @brief Check Grapheme_Cluster_Break property
@@
-593,11
+593,11
@@
static int utf32__is_control_or_cr_or_lf(uint32_t c) {
switch(utf32__general_category(c)) {
default:
return 0;
switch(utf32__general_category(c)) {
default:
return 0;
- case unicode_
gc
_Zl:
- case unicode_
gc
_Zp:
- case unicode_
gc
_Cc:
+ case unicode_
General_Category
_Zl:
+ case unicode_
General_Category
_Zp:
+ case unicode_
General_Category
_Cc:
return 1;
return 1;
- case unicode_
gc
_Cf:
+ case unicode_
General_Category
_Cf:
if(c == 0x200C || c == 0x200D)
return 0;
return 1;
if(c == 0x200C || c == 0x200D)
return 0;
return 1;
@@
-842,7
+842,7
@@
int utf32_is_word_boundary(const uint32_t *s, size_t ns, size_t n) {
}
/*@}*/
}
/*@}*/
-/** @defgroup Functions that operate on UTF-8 strings */
+/** @defgroup
utf8
Functions that operate on UTF-8 strings */
/*@{*/
/** @brief Wrapper to transform a UTF-8 string using the UTF-32 function */
/*@{*/
/** @brief Wrapper to transform a UTF-8 string using the UTF-32 function */