summaryrefslogtreecommitdiff
path: root/regcomp.c
diff options
context:
space:
mode:
authorJarkko Hietaniemi <jhi@iki.fi>2002-02-24 19:49:01 +0000
committerJarkko Hietaniemi <jhi@iki.fi>2002-02-24 19:49:01 +0000
commit2f3bf0116fb4a02e09f97f517a7e1ff497539a2d (patch)
tree13c3f5424a3a37a3875ec52d594f03bc583de9f7 /regcomp.c
parent4956848ff7879667129e0579e64c474ca6097eb0 (diff)
downloadperl-2f3bf0116fb4a02e09f97f517a7e1ff497539a2d.tar.gz
Use to_uni_fold().
p4raw-id: //depot/perl@14855
Diffstat (limited to 'regcomp.c')
-rw-r--r--regcomp.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/regcomp.c b/regcomp.c
index 2e8254e513..4bfef22563 100644
--- a/regcomp.c
+++ b/regcomp.c
@@ -4088,14 +4088,9 @@ S_regclass(pTHX_ RExC_state_t *pRExC_state)
else if (prevnatvalue == natvalue) {
Perl_sv_catpvf(aTHX_ listsv, "%04"UVxf"\n", natvalue);
if (FOLD) {
- U8 tmpbuf [UTF8_MAXLEN+1];
U8 foldbuf[UTF8_MAXLEN_FOLD+1];
STRLEN foldlen;
- UV f;
-
- uvchr_to_utf8(tmpbuf, natvalue);
- to_utf8_fold(tmpbuf, foldbuf, &foldlen);
- f = UNI_TO_NATIVE(utf8_to_uvchr(foldbuf, 0));
+ UV f = to_uni_fold(natvalue, foldbuf, &foldlen);
/* If folding and foldable and a single
* character, insert also the folded version