From 51ca120ff61004035433ccdce7c99f1c09d01bf9 Mon Sep 17 00:00:00 2001 From: Karl Williamson Date: Mon, 13 Jan 2014 12:13:18 -0700 Subject: [PATCH] Rename regex internal flag bit This is a clearer name; is used internally only in regcomp.c and regexec.c --- regcomp.c | 6 +++--- regcomp.h | 2 +- regexec.c | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/regcomp.c b/regcomp.c index 775d6ca..2e9183c 100644 --- a/regcomp.c +++ b/regcomp.c @@ -1050,7 +1050,7 @@ S_get_ANYOF_cp_list_for_ssc(pTHX_ const RExC_state_t *pRExC_state, /* If this can match all upper Latin1 code points, have to add them * as well */ - if (ANYOF_FLAGS(node) & ANYOF_NON_UTF8_LATIN1_ALL) { + if (ANYOF_FLAGS(node) & ANYOF_NON_UTF8_NON_ASCII_ALL) { _invlist_union(invlist, PL_UpperLatin1, &invlist); } @@ -14123,7 +14123,7 @@ parseit: if (DEPENDS_SEMANTICS) { /* Under /d, everything in the upper half of the Latin1 range * matches these complements */ - ANYOF_FLAGS(ret) |= ANYOF_NON_UTF8_LATIN1_ALL; + ANYOF_FLAGS(ret) |= ANYOF_NON_UTF8_NON_ASCII_ALL; } else if (AT_LEAST_ASCII_RESTRICTED) { /* Under /a and /aa, everything above ASCII matches these @@ -15284,7 +15284,7 @@ Perl_regprop(pTHX_ const regexp *prog, SV *sv, const regnode *o) sv_catpvs(sv, "^"); } - if (flags & ANYOF_NON_UTF8_LATIN1_ALL) { + if (flags & ANYOF_NON_UTF8_NON_ASCII_ALL) { sv_catpvs(sv, "{non-utf8-latin1-all}"); } diff --git a/regcomp.h b/regcomp.h index 8bca5d2..3a3add3 100644 --- a/regcomp.h +++ b/regcomp.h @@ -377,7 +377,7 @@ struct regnode_ssc { /* Match all Latin1 characters that aren't ASCII when the target string is not * in utf8. */ -#define ANYOF_NON_UTF8_LATIN1_ALL 0x80 +#define ANYOF_NON_UTF8_NON_ASCII_ALL 0x80 #define ANYOF_FLAGS_ALL (0xff) diff --git a/regexec.c b/regexec.c index b8b5b99..624ee4c 100644 --- a/regexec.c +++ b/regexec.c @@ -7454,7 +7454,7 @@ S_reginclass(pTHX_ regexp * const prog, const regnode * const n, const U8* const if (c < 256) { if (ANYOF_BITMAP_TEST(n, c)) match = TRUE; - else if (flags & ANYOF_NON_UTF8_LATIN1_ALL + else if (flags & ANYOF_NON_UTF8_NON_ASCII_ALL && ! utf8_target && ! isASCII(c)) { -- 2.7.4