Change 27692 by davem@davem-splatty on 2006/04/02 23:50:25
whoops, change 27691 blew away the regexec.c changes from 27688
Affected files
//depot/perl/regexec.c#390 edit
Differences
//depot/perl/regexec.c#390 (text)
Index: perl/regexec.c
perl/regexec.c#389~27691~2006-04-02 15:37:57.000000000 -0700
perl/regexec.c2006-04-02 16:50:25.000000000 -0700
@@ -1017,7 +1017,7 @@
U8 *sm = (U8 *) m;
U8 tmpbuf1[UTF8_MAXBYTES_CASE+1];
U8 tmpbuf2[UTF8_MAXBYTES_CASE+1];
-const U32 uniflags = ckWARN(WARN_UTF8) ? 0 : UTF8_ALLW_ANY;
+const U32 uniflags = UTF8_ALLW_DEFAULT;
to_utf8_lower((U8*)m, tmpbuf1, &ulen1);
to_utf8_upper((U8*)m, tmpbuf2, &ulen2);
@@ -1064,7 +1064,7 @@
UV c, f;
U8 tmpbuf [UTF8_MAXBYTES+1];
STRLEN len, foldlen;
-const U32 uniflags = ckWARN(WARN_UTF8) ? 0 : UTF8_ALLW_ANY;
+const U32 uniflags = UTF8_ALLW_DEFAULT;
if (c1 == c2) {
/* Upper and lower of 1st char are equal -
* probably not a "letter". */
@@ -1166,7 +1166,7 @@
tmp = '\n';
else {
U8 * const r = reghop3((U8*)s, -1, (U8*)PL_bostr);
- tmp = utf8n_to_uvchr(r, UTF8SKIP(r), 0, 0);
+ tmp = utf8n_to_uvchr(r, UTF8SKIP(r), 0, UTF8_ALLW_DEFAULT);
}
tmp = ((P(c) == BUND ?
isALNUM_uni(tmp) : isALNUM_LC_uvchr(UNI_TNATIVE(tmp))) != 0);
@@ -1208,7 +1208,7 @@
tmp = '\n';
else {
U8 * const r = reghop3((U8*)s, -1, (U8*)PL_bostr);
- tmp = utf8n_to_uvchr(r, UTF8SKIP(r), 0, 0);
+ tmp = utf8n_to_uvchr(r, UTF8SKIP(r), 0, UTF8_ALLW_DEFAULT);
}
tmp = ((P(c) == NBUND ?
isALNUM_uni(tmp) : isALNUM_LC_uvchr(UNI_TNATIVE(tmp))) != 0);
@@ -2430,7 +2430,7 @@
{
dVAR;
register const bool do_utf8 = PL_reg_match_utf8;
- const U32 uniflags = ckWARN(WARN_UTF8) ? 0 : UTF8_ALLW_ANY;
+ const U32 uniflags = UTF8_ALLW_DEFAULT;
regmatch_slab *orig_slab;
regmatch_state *orig_state;
@@ -3046,7 +3046,7 @@
else {
const U8 * const r = reghop3((U8*)locinput, -1, (U8*)PL_bostr);
- st->ln = utf8n_to_uvchr(r, UTF8SKIP(r), 0, 0);
+ st->ln = utf8n_to_uvchr(r, UTF8SKIP(r), 0, uniflags);
}
if (P(scan) == BUND || P(scan) == NBUND) {
st->ln = isALNUM_uni(st->ln);
@@ -4886,8 +4886,8 @@
if (do_utf8 && !UTF8_IS_INVARIANT(c)) {
c = utf8n_to_uvchr(p, UTF8_MAXBYTES, &len,
- ckWARN(WARN_UTF8) ? UTF8_CHECKNLY :
-UTF8_ALLW_ANYUV|UTF8_CHECKNLY);
+(UTF8_ALLW_DEFAULT & UTF8_ALLW_ANYUV) | UTF8_CHECKNLY);
+/* see [perl #37836] for UTF8_ALLW_ANYUV */
if (len == (STRLEN)-1)
Perl_croak(aTHX_ "Malformed UTF-8 character (fatal)");
}
End of Patch.