AMp |UV |_to_uni_fold_flags|UV c|NN U8 *p|NN STRLEN *lenp|const U8 flags
ApPR |bool |is_uni_alnum_lc|UV c
ApPR |bool |is_uni_idfirst_lc|UV c
+AMpR |bool |_is_uni_perl_idstart|UV c
ApPR |bool |is_uni_alpha_lc|UV c
ApPR |bool |is_uni_ascii_lc|UV c
ApPR |bool |is_uni_space_lc|UV c
/* Hide global symbols */
#define Gv_AMupdate(a,b) Perl_Gv_AMupdate(aTHX_ a,b)
+#define _is_uni_perl_idstart(a) Perl__is_uni_perl_idstart(aTHX_ a)
#define _is_utf8_perl_idstart(a) Perl__is_utf8_perl_idstart(aTHX_ a)
#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)
last if $above_latins > 5;
}
+ # This makes sure we are using the Perl definition of idfirst, and not the
+ # Unicode. There are a few differences.
+ push @code_points, ord "\N{ESTIMATED SYMBOL}" if $name eq 'idfirst';
+
# And finally one non-Unicode code point.
push @code_points, 0x110000; # Above Unicode, no prop should match
no warnings 'non_unicode';
#define isWORDCHAR_uni(c) _generic_uni(_CC_WORDCHAR, is_uni_alnum, c)
#define isALNUM_uni(c) isWORDCHAR_uni(c)
#define isBLANK_uni(c) _generic_uni(_CC_BLANK, is_HORIZWS_cp_high, c)
-#define isIDFIRST_uni(c) _generic_uni(_CC_IDFIRST, is_uni_idfirst, c)
+#define isIDFIRST_uni(c) _generic_uni(_CC_IDFIRST, _is_uni_perl_idstart, c)
#define isALPHA_uni(c) _generic_uni(_CC_ALPHA, is_uni_alpha, c)
#define isSPACE_uni(c) _generic_uni(_CC_SPACE, is_XPERLSPACE_cp_high, c)
#define isVERTWS_uni(c) _generic_uni(_CC_VERTSPACE, is_VERTWS_cp_high, c)
/* To prevent S_scan_word in toke.c from hanging, we have to make sure that
* IDFIRST is an alnum. See
* http://rt.perl.org/rt3/Ticket/Display.html?id=74022 for more detail than you
- * ever wanted to know about. XXX It is unclear if this should extend to
- * isIDFIRST_uni() which it hasn't so far. (In the ASCII range, there isn't a
- * difference.) This used to be not the XID version, but we decided to go with
- * the more modern Unicode definition */
+ * ever wanted to know about. (In the ASCII range, there isn't a difference.)
+ * This used to be not the XID version, but we decided to go with the more
+ * modern Unicode definition */
#define isIDFIRST_utf8(p) _generic_utf8(_CC_IDFIRST, \
_is_utf8_perl_idstart, p)
#define PERL_ARGS_ASSERT_SLAB_FREE \
assert(op)
+PERL_CALLCONV bool Perl__is_uni_perl_idstart(pTHX_ UV c)
+ __attribute__warn_unused_result__;
+
PERL_CALLCONV bool Perl__is_utf8_perl_idstart(pTHX_ const U8 *p)
__attribute__warn_unused_result__
__attribute__nonnull__(pTHX_1);
}
bool
+Perl__is_uni_perl_idstart(pTHX_ UV c)
+{
+ U8 tmpbuf[UTF8_MAXBYTES+1];
+ uvchr_to_utf8(tmpbuf, c);
+ return _is_utf8_perl_idstart(tmpbuf);
+}
+
+bool
Perl_is_uni_alpha(pTHX_ UV c)
{
U8 tmpbuf[UTF8_MAXBYTES+1];