diff options
author | Jarkko Hietaniemi <jhi@iki.fi> | 2001-12-30 20:04:32 +0000 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2001-12-30 20:04:32 +0000 |
commit | 254ba52af7d39101b8ee76681bf95a1a95ebd042 (patch) | |
tree | 151569cef510eeaa419754ff11c6e8297f3b1aaa /regcomp.c | |
parent | d2ee51b61413d0946f6558ae280350393bbe9b35 (diff) | |
download | perl-254ba52af7d39101b8ee76681bf95a1a95ebd042.tar.gz |
Fix all the C(ommon) case foldings as per CaseFold.txt.
p4raw-id: //depot/perl@13963
Diffstat (limited to 'regcomp.c')
-rw-r--r-- | regcomp.c | 11 |
1 files changed, 11 insertions, 0 deletions
@@ -3985,6 +3985,17 @@ S_regclass(pTHX_ RExC_state_t *pRExC_state) Perl_sv_catpvf(aTHX_ listsv, "%04"UVxf"\n", (UV)value); if (FOLD) { + U8 tmpbuf [UTF8_MAXLEN+1]; + U8 foldbuf[UTF8_MAXLEN_FOLD+1]; + STRLEN foldlen; + UV f; + + uvchr_to_utf8(tmpbuf, value); + f = to_utf8_fold(tmpbuf, foldbuf, &foldlen); + + if (f != value) + Perl_sv_catpvf(aTHX_ listsv, "%04"UVxf"\n", f); + if (value == UNICODE_GREEK_SMALL_LETTER_FINAL_SIGMA) { Perl_sv_catpvf(aTHX_ listsv, "%04"UVxf"\n", (UV)UNICODE_GREEK_CAPITAL_LETTER_SIGMA); |