summaryrefslogtreecommitdiff
path: root/utf8.h
diff options
context:
space:
mode:
authorJarkko Hietaniemi <jhi@iki.fi>2002-01-12 20:05:29 +0000
committerJarkko Hietaniemi <jhi@iki.fi>2002-01-12 20:05:29 +0000
commite0f9d4a8607e11c8ec6d3c60018f5ccbfea703e6 (patch)
treefc5b70022b30a53e73a84e5eedceb80c6d5f784a /utf8.h
parent3eaf8b6c1d0c4afb63259fb51f4f3670a1f5ed2c (diff)
downloadperl-e0f9d4a8607e11c8ec6d3c60018f5ccbfea703e6.tar.gz
Sharp S as a special treat for our German UTF-8 testers :-)
p4raw-id: //depot/perl@14222
Diffstat (limited to 'utf8.h')
-rw-r--r--utf8.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/utf8.h b/utf8.h
index 8c27afab50..2ac5f91c2c 100644
--- a/utf8.h
+++ b/utf8.h
@@ -189,6 +189,7 @@ END_EXTERN_C
#define UTF8_IS_ASCII(c) UTF8_IS_INVARIANT(c)
+#define UNICODE_LATIN_SMALL_LETTER_SHARP_S 0x00DF
#define UNICODE_GREEK_CAPITAL_LETTER_SIGMA 0x03A3
#define UNICODE_GREEK_SMALL_LETTER_FINAL_SIGMA 0x03C2
#define UNICODE_GREEK_SMALL_LETTER_SIGMA 0x03C3
@@ -198,3 +199,10 @@ END_EXTERN_C
#define UNI_DISPLAY_QQ (UNI_DISPLAY_ISPRINT|UNI_DISPLAY_BACKSLASH)
#define UNI_DISPLAY_REGEX (UNI_DISPLAY_ISPRINT|UNI_DISPLAY_BACKSLASH)
+#define ANYOF_UNICODE_FOLD_SHARP_S(n, s, e) \
+ (ANYOF_BITMAP_TEST(n, UNICODE_LATIN_SMALL_LETTER_SHARP_S) && \
+ ANYOF_FLAGS(n) & ANYOF_UNICODE && \
+ ANYOF_FLAGS(n) & ANYOF_FOLD && \
+ ((e) > (s) + 1) && \
+ toLOWER((s)[0]) == 's' && \
+ toLOWER((s)[1]) == 's')