mirror of
https://github.com/Perl/perl5.git
synced 2026-01-26 08:38:23 +00:00
Convert _to_uni_fold_flags to legal name
This commit is contained in:
parent
8e102f9ac3
commit
8bdb0ad55c
@ -3657,7 +3657,7 @@ Xiop |Stack_off_t|TOPMARK
|
||||
Cmp |UV |to_uni_fold |UV c \
|
||||
|NN U8 *p \
|
||||
|NN STRLEN *lenp
|
||||
Cp |UV |_to_uni_fold_flags \
|
||||
Cp |UV |to_uni_fold_flags_ \
|
||||
|UV c \
|
||||
|NN U8 *p \
|
||||
|NN STRLEN *lenp \
|
||||
|
||||
2
embed.h
2
embed.h
@ -122,7 +122,6 @@
|
||||
# define _is_utf8_FOO(a,b,c) Perl__is_utf8_FOO(aTHX_ a,b,c)
|
||||
# define _is_utf8_perl_idcont(a,b) Perl__is_utf8_perl_idcont(aTHX_ a,b)
|
||||
# define _is_utf8_perl_idstart(a,b) Perl__is_utf8_perl_idstart(aTHX_ a,b)
|
||||
# define _to_uni_fold_flags(a,b,c,d) Perl__to_uni_fold_flags(aTHX_ a,b,c,d)
|
||||
# define _to_utf8_fold_flags(a,b,c,d,e) Perl__to_utf8_fold_flags(aTHX_ a,b,c,d,e)
|
||||
# define _to_utf8_lower_flags(a,b,c,d,e) Perl__to_utf8_lower_flags(aTHX_ a,b,c,d,e)
|
||||
# define _to_utf8_title_flags(a,b,c,d,e) Perl__to_utf8_title_flags(aTHX_ a,b,c,d,e)
|
||||
@ -809,6 +808,7 @@
|
||||
# define sync_locale() Perl_sync_locale(aTHX)
|
||||
# define taint_env() Perl_taint_env(aTHX)
|
||||
# define taint_proper(a,b) Perl_taint_proper(aTHX_ a,b)
|
||||
# define to_uni_fold_flags_(a,b,c,d) Perl_to_uni_fold_flags_(aTHX_ a,b,c,d)
|
||||
# define to_uni_lower(a,b,c) Perl_to_uni_lower(aTHX_ a,b,c)
|
||||
# define to_uni_title(a,b,c) Perl_to_uni_title(aTHX_ a,b,c)
|
||||
# define to_uni_upper(a,b,c) Perl_to_uni_upper(aTHX_ a,b,c)
|
||||
|
||||
2
pp.c
2
pp.c
@ -5242,7 +5242,7 @@ PP_wrapped(pp_fc, 1, 0)
|
||||
|
||||
for (; s < send; s++) {
|
||||
STRLEN ulen;
|
||||
_to_uni_fold_flags(*s, d, &ulen, flags);
|
||||
to_uni_fold_flags_(*s, d, &ulen, flags);
|
||||
d += ulen;
|
||||
}
|
||||
break;
|
||||
|
||||
10
proto.h
generated
10
proto.h
generated
@ -124,11 +124,6 @@ Perl__is_utf8_perl_idstart(pTHX_ const U8 *p, const U8 * const e)
|
||||
#define PERL_ARGS_ASSERT__IS_UTF8_PERL_IDSTART \
|
||||
assert(p); assert(e)
|
||||
|
||||
PERL_CALLCONV UV
|
||||
Perl__to_uni_fold_flags(pTHX_ UV c, U8 *p, STRLEN *lenp, U8 flags);
|
||||
#define PERL_ARGS_ASSERT__TO_UNI_FOLD_FLAGS \
|
||||
assert(p); assert(lenp)
|
||||
|
||||
PERL_CALLCONV UV
|
||||
Perl__to_utf8_fold_flags(pTHX_ const U8 *p, const U8 *e, U8 *ustrp, STRLEN *lenp, U8 flags);
|
||||
#define PERL_ARGS_ASSERT__TO_UTF8_FOLD_FLAGS \
|
||||
@ -5282,6 +5277,11 @@ Perl_tmps_grow_p(pTHX_ SSize_t ix);
|
||||
/* PERL_CALLCONV UV
|
||||
Perl_to_uni_fold(pTHX_ UV c, U8 *p, STRLEN *lenp); */
|
||||
|
||||
PERL_CALLCONV UV
|
||||
Perl_to_uni_fold_flags_(pTHX_ UV c, U8 *p, STRLEN *lenp, U8 flags);
|
||||
#define PERL_ARGS_ASSERT_TO_UNI_FOLD_FLAGS_ \
|
||||
assert(p); assert(lenp)
|
||||
|
||||
PERL_CALLCONV UV
|
||||
Perl_to_uni_lower(pTHX_ UV c, U8 *p, STRLEN *lenp);
|
||||
#define PERL_ARGS_ASSERT_TO_UNI_LOWER \
|
||||
|
||||
12
regcomp.c
12
regcomp.c
@ -6848,7 +6848,7 @@ S_regatom(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth)
|
||||
UV folded;
|
||||
|
||||
fold_anyway:
|
||||
folded = _to_uni_fold_flags(
|
||||
folded = to_uni_fold_flags_(
|
||||
ender,
|
||||
(U8 *) s, /* We have allocated extra space
|
||||
in 's' so can't run off the
|
||||
@ -7262,7 +7262,7 @@ S_regatom(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth)
|
||||
Size_t added_len;
|
||||
|
||||
/* Append the fold of ender */
|
||||
(void) _to_uni_fold_flags(
|
||||
(void) to_uni_fold_flags_(
|
||||
ender,
|
||||
(U8 *) e,
|
||||
&added_len,
|
||||
@ -10508,7 +10508,7 @@ S_regclass(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth,
|
||||
U8 foldbuf[UTF8_MAXBYTES_CASE+1];
|
||||
STRLEN foldlen;
|
||||
|
||||
UV folded = _to_uni_fold_flags(
|
||||
UV folded = to_uni_fold_flags_(
|
||||
value,
|
||||
foldbuf,
|
||||
&foldlen,
|
||||
@ -10929,7 +10929,7 @@ S_regclass(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth,
|
||||
* rules hard-coded for it. First, get its fold. This is
|
||||
* the simple fold, as the multi-character folds have been
|
||||
* handled earlier and separated out */
|
||||
folded = _to_uni_fold_flags(j, foldbuf, &foldlen,
|
||||
folded = to_uni_fold_flags_(j, foldbuf, &foldlen,
|
||||
(ASCII_FOLD_RESTRICTED)
|
||||
? FOLD_FLAGS_NOMIX_ASCII
|
||||
: 0);
|
||||
@ -11687,7 +11687,7 @@ S_optimize_regclass(pTHX_
|
||||
|
||||
Size_t foldlen;
|
||||
U8 foldbuf[UTF8_MAXBYTES_CASE];
|
||||
UV folded = _to_uni_fold_flags(lowest_cp, foldbuf, &foldlen, 0);
|
||||
UV folded = to_uni_fold_flags_(lowest_cp, foldbuf, &foldlen, 0);
|
||||
U32 first_fold;
|
||||
const U32 * remaining_folds;
|
||||
Size_t folds_to_this_cp_count = _inverse_folds(
|
||||
@ -11811,7 +11811,7 @@ S_optimize_regclass(pTHX_
|
||||
|
||||
/* This is a kludge to the special casing issues with this
|
||||
* ligature under /aa. FB05 should fold to FB06, but the call
|
||||
* above to _to_uni_fold_flags() didn't find this, as it didn't
|
||||
* above to to_uni_fold_flags_() didn't find this, as it didn't
|
||||
* use the /aa restriction in order to not miss other folds
|
||||
* that would be affected. This is the only instance likely to
|
||||
* ever be a problem in all of Unicode. So special case it. */
|
||||
|
||||
@ -4782,7 +4782,7 @@ S_setup_EXACTISH_ST(pTHX_ const regnode * const text_node,
|
||||
* pattern to be folded, which the input isn't required to
|
||||
* be in this case. So, just fold the single character,
|
||||
* and the result will be in the expected form. */
|
||||
_to_uni_fold_flags(multi_fold_from, mod_pat, &pat_len,
|
||||
to_uni_fold_flags_(multi_fold_from, mod_pat, &pat_len,
|
||||
FOLD_FLAGS_FULL);
|
||||
pat = mod_pat;
|
||||
}
|
||||
@ -4841,7 +4841,7 @@ S_setup_EXACTISH_ST(pTHX_ const regnode * const text_node,
|
||||
{
|
||||
/* We may have to canonicalize a multi-char fold, as in the UTF-8
|
||||
* case */
|
||||
_to_uni_fold_flags(multi_fold_from, mod_pat, &pat_len,
|
||||
to_uni_fold_flags_(multi_fold_from, mod_pat, &pat_len,
|
||||
FOLD_FLAGS_FULL);
|
||||
pat = mod_pat;
|
||||
}
|
||||
|
||||
8
utf8.c
8
utf8.c
@ -3807,7 +3807,7 @@ Perl__to_fold_latin1(const U8 c, U8* p, STRLEN *lenp, const unsigned int flags)
|
||||
}
|
||||
|
||||
UV
|
||||
Perl__to_uni_fold_flags(pTHX_ UV c, U8* p, STRLEN *lenp, U8 flags)
|
||||
Perl_to_uni_fold_flags_(pTHX_ UV c, U8* p, STRLEN *lenp, U8 flags)
|
||||
{
|
||||
|
||||
/* Not currently externally documented, and subject to change
|
||||
@ -3818,7 +3818,7 @@ Perl__to_uni_fold_flags(pTHX_ UV c, U8* p, STRLEN *lenp, U8 flags)
|
||||
* FOLD_FLAGS_NOMIX_ASCII iff non-ASCII to ASCII folds are prohibited
|
||||
*/
|
||||
|
||||
PERL_ARGS_ASSERT__TO_UNI_FOLD_FLAGS;
|
||||
PERL_ARGS_ASSERT_TO_UNI_FOLD_FLAGS_;
|
||||
|
||||
if (flags & FOLD_FLAGS_LOCALE) {
|
||||
/* Treat a non-Turkic UTF-8 locale as not being in locale at all,
|
||||
@ -5069,7 +5069,7 @@ Perl_foldEQ_utf8_flags(pTHX_ const char *s1, char **pe1, UV l1, bool u1,
|
||||
_toFOLD_utf8_flags(p1, e1, foldbuf1, &n1, flags_for_folder);
|
||||
}
|
||||
else { /* Not UTF-8, get UTF-8 fold */
|
||||
_to_uni_fold_flags(*p1, foldbuf1, &n1, flags_for_folder);
|
||||
to_uni_fold_flags_(*p1, foldbuf1, &n1, flags_for_folder);
|
||||
}
|
||||
f1 = foldbuf1;
|
||||
}
|
||||
@ -5107,7 +5107,7 @@ Perl_foldEQ_utf8_flags(pTHX_ const char *s1, char **pe1, UV l1, bool u1,
|
||||
_toFOLD_utf8_flags(p2, e2, foldbuf2, &n2, flags_for_folder);
|
||||
}
|
||||
else {
|
||||
_to_uni_fold_flags(*p2, foldbuf2, &n2, flags_for_folder);
|
||||
to_uni_fold_flags_(*p2, foldbuf2, &n2, flags_for_folder);
|
||||
}
|
||||
f2 = foldbuf2;
|
||||
}
|
||||
|
||||
2
utf8.h
2
utf8.h
@ -202,7 +202,7 @@ For details, see the description for L<perlapi/uv_to_utf8_flags>.
|
||||
#define utf8_to_utf16_reversed(p, d, bytelen, newlen) \
|
||||
utf8_to_utf16_base(p, d, bytelen, newlen, 1, 0)
|
||||
|
||||
#define to_uni_fold(c, p, lenp) _to_uni_fold_flags(c, p, lenp, FOLD_FLAGS_FULL)
|
||||
#define to_uni_fold(c, p, lenp) to_uni_fold_flags_(c, p, lenp, FOLD_FLAGS_FULL)
|
||||
|
||||
#define foldEQ_utf8(s1, pe1, l1, u1, s2, pe2, l2, u2) \
|
||||
foldEQ_utf8_flags(s1, pe1, l1, u1, s2, pe2, l2, u2, 0)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user