summaryrefslogtreecommitdiff
path: root/src/regenc.h
diff options
context:
space:
mode:
authorJörg Frings-Fürst <debian@jff.email>2021-04-26 22:25:42 +0200
committerJörg Frings-Fürst <debian@jff.email>2021-04-26 22:25:42 +0200
commit5d5f76cad47d13dc0dd4328c2172ddc1d4b19d7b (patch)
treecd59a8ea003d6768af284fc913353983e2794a58 /src/regenc.h
parenteac65ba44805c402f894b700b602c2e891f92a84 (diff)
parent96b0c9871630512ec2c2e84072da0085d68d740f (diff)
Merge branch 'release/debian/6.9.7.1-1'debian/6.9.7.1-1
Diffstat (limited to 'src/regenc.h')
-rw-r--r--src/regenc.h16
1 files changed, 10 insertions, 6 deletions
diff --git a/src/regenc.h b/src/regenc.h
index d183b97..d0b447d 100644
--- a/src/regenc.h
+++ b/src/regenc.h
@@ -142,6 +142,10 @@ struct PropertyNameCtype {
#define ENC_GET_SKIP_OFFSET(enc) \
(((enc)->flag & ENC_FLAG_SKIP_OFFSET_MASK)>>2)
+#define CASE_FOLD_IS_ASCII_ONLY(flag) \
+ (((flag) & ONIGENC_CASE_FOLD_ASCII_ONLY) != 0)
+#define CASE_FOLD_IS_NOT_ASCII_ONLY(flag) \
+ (((flag) & ONIGENC_CASE_FOLD_ASCII_ONLY) == 0)
/* for encoding system implementation (internal) */
extern int onigenc_end(void);
@@ -202,12 +206,12 @@ extern int onigenc_wb_is_break_position P_((OnigEncoding enc, UChar* p, UChar* p
#define FOLDS1_UNFOLDS_NUM(i) (OnigUnicodeFolds1[(i)+1])
#define FOLDS2_UNFOLDS_NUM(i) (OnigUnicodeFolds2[(i)+2])
#define FOLDS3_UNFOLDS_NUM(i) (OnigUnicodeFolds3[(i)+3])
-#define FOLDS1_UNFOLDS(i) (OnigUnicodeFolds1 + (i) + 2)
-#define FOLDS2_UNFOLDS(i) (OnigUnicodeFolds2 + (i) + 3)
-#define FOLDS3_UNFOLDS(i) (OnigUnicodeFolds3 + (i) + 4)
-#define FOLDS1_NEXT_INDEX(i) ((i) + 2 + OnigUnicodeFolds1[(i)+1])
-#define FOLDS2_NEXT_INDEX(i) ((i) + 3 + OnigUnicodeFolds2[(i)+2])
-#define FOLDS3_NEXT_INDEX(i) ((i) + 4 + OnigUnicodeFolds3[(i)+3])
+#define FOLDS1_UNFOLDS(i) (FOLDS1_FOLD(i) + 2)
+#define FOLDS2_UNFOLDS(i) (FOLDS2_FOLD(i) + 3)
+#define FOLDS3_UNFOLDS(i) (FOLDS3_FOLD(i) + 4)
+#define FOLDS1_NEXT_INDEX(i) ((i) + 2 + FOLDS1_UNFOLDS_NUM(i))
+#define FOLDS2_NEXT_INDEX(i) ((i) + 3 + FOLDS2_UNFOLDS_NUM(i))
+#define FOLDS3_NEXT_INDEX(i) ((i) + 4 + FOLDS3_UNFOLDS_NUM(i))
#define FOLDS_FOLD_ADDR_BUK(buk, addr) do {\
if ((buk)->fold_len == 1)\