#define PL_reg_ganch (vTHX->Treg_ganch)
#define PL_reg_leftiter (vTHX->Treg_leftiter)
#define PL_reg_magic (vTHX->Treg_magic)
+#define PL_reg_match_utf8 (vTHX->Treg_match_utf8)
#define PL_reg_maxiter (vTHX->Treg_maxiter)
#define PL_reg_oldcurpm (vTHX->Treg_oldcurpm)
#define PL_reg_oldpos (vTHX->Treg_oldpos)
#define PL_reg_start_tmpl (vTHX->Treg_start_tmpl)
#define PL_reg_starttry (vTHX->Treg_starttry)
#define PL_reg_sv (vTHX->Treg_sv)
-#define PL_reg_sv_utf8 (vTHX->Treg_sv_utf8)
#define PL_reg_whilem_seen (vTHX->Treg_whilem_seen)
#define PL_regbol (vTHX->Tregbol)
#define PL_regcc (vTHX->Tregcc)
#define PL_reg_ganch (aTHX->Treg_ganch)
#define PL_reg_leftiter (aTHX->Treg_leftiter)
#define PL_reg_magic (aTHX->Treg_magic)
+#define PL_reg_match_utf8 (aTHX->Treg_match_utf8)
#define PL_reg_maxiter (aTHX->Treg_maxiter)
#define PL_reg_oldcurpm (aTHX->Treg_oldcurpm)
#define PL_reg_oldpos (aTHX->Treg_oldpos)
#define PL_reg_start_tmpl (aTHX->Treg_start_tmpl)
#define PL_reg_starttry (aTHX->Treg_starttry)
#define PL_reg_sv (aTHX->Treg_sv)
-#define PL_reg_sv_utf8 (aTHX->Treg_sv_utf8)
#define PL_reg_whilem_seen (aTHX->Treg_whilem_seen)
#define PL_regbol (aTHX->Tregbol)
#define PL_regcc (aTHX->Tregcc)
#define PL_Treg_ganch PL_reg_ganch
#define PL_Treg_leftiter PL_reg_leftiter
#define PL_Treg_magic PL_reg_magic
+#define PL_Treg_match_utf8 PL_reg_match_utf8
#define PL_Treg_maxiter PL_reg_maxiter
#define PL_Treg_oldcurpm PL_reg_oldcurpm
#define PL_Treg_oldpos PL_reg_oldpos
#define PL_Treg_start_tmpl PL_reg_start_tmpl
#define PL_Treg_starttry PL_reg_starttry
#define PL_Treg_sv PL_reg_sv
-#define PL_Treg_sv_utf8 PL_reg_sv_utf8
#define PL_Treg_whilem_seen PL_reg_whilem_seen
#define PL_Tregbol PL_regbol
#define PL_Tregcc PL_regcc
else /* @- */
i = s;
- if (i > 0 && PL_reg_sv_utf8) {
+ if (i > 0 && PL_reg_match_utf8) {
char *b = rx->subbeg;
if (b)
i = Perl_utf8_length(aTHX_ (U8*)b, (U8*)(b+i));
{
i = t1 - s1;
getlen:
- if (i > 0 && PL_reg_sv_utf8) {
+ if (i > 0 && PL_reg_match_utf8) {
char *s = rx->subbeg + s1;
char *send = rx->subbeg + t1;
PL_tainted = FALSE;
}
sv_setpvn(sv, s, i);
- if (PL_reg_sv_utf8 && is_utf8_string((U8*)s, i))
+ if (PL_reg_match_utf8 && is_utf8_string((U8*)s, i))
SvUTF8_on(sv);
else
SvUTF8_off(sv);
#define PL_reg_leftiter (*Perl_Treg_leftiter_ptr(aTHX))
#undef PL_reg_magic
#define PL_reg_magic (*Perl_Treg_magic_ptr(aTHX))
+#undef PL_reg_match_utf8
+#define PL_reg_match_utf8 (*Perl_Treg_match_utf8_ptr(aTHX))
#undef PL_reg_maxiter
#define PL_reg_maxiter (*Perl_Treg_maxiter_ptr(aTHX))
#undef PL_reg_oldcurpm
#define PL_reg_starttry (*Perl_Treg_starttry_ptr(aTHX))
#undef PL_reg_sv
#define PL_reg_sv (*Perl_Treg_sv_ptr(aTHX))
-#undef PL_reg_sv_utf8
-#define PL_reg_sv_utf8 (*Perl_Treg_sv_utf8_ptr(aTHX))
#undef PL_reg_whilem_seen
#define PL_reg_whilem_seen (*Perl_Treg_whilem_seen_ptr(aTHX))
#undef PL_regbol
TAINT_IF((pm->op_pmflags & PMf_LOCALE) &&
(pm->op_pmflags & (PMf_WHITE | PMf_SKIPWHITE)));
- PL_reg_sv_utf8 = do_utf8;
+ PL_reg_match_utf8 = do_utf8;
if (pm->op_pmreplroot) {
#ifdef USE_ITHREADS
(PL_tainted && (pm->op_pmflags & PMf_RETAINT)));
TAINT_NOT;
- PL_reg_sv_utf8 = DO_UTF8(TARG);
+ PL_reg_match_utf8 = DO_UTF8(TARG);
if (pm->op_pmdynflags & PMdf_USED) {
failure:
if (global) {
rx->subbeg = truebase;
rx->startp[0] = s - truebase;
- if (PL_reg_sv_utf8) {
+ if (PL_reg_match_utf8) {
char *t = (char*)utf8_hop((U8*)s, rx->minlen);
rx->endp[0] = t - truebase;
}
rxtainted |= 2;
TAINT_NOT;
- PL_reg_sv_utf8 = DO_UTF8(TARG);
+ PL_reg_match_utf8 = DO_UTF8(TARG);
force_it:
if (!pm || !s)
DIE(aTHX_ "panic: pp_subst");
strend = s + len;
- slen = PL_reg_sv_utf8 ? utf8_length((U8*)s, (U8*)strend) : len;
+ slen = PL_reg_match_utf8 ? utf8_length((U8*)s, (U8*)strend) : len;
maxiters = 2 * slen + 10; /* We can match twice at each
position, once with zero-length,
second time with non-zero. */
SAVEVPTR(PL_reg_re); /* from regexec.c */
SAVEPPTR(PL_reg_ganch); /* from regexec.c */
SAVESPTR(PL_reg_sv); /* from regexec.c */
- SAVEI8(PL_reg_sv_utf8); /* from regexec.c */
+ SAVEI8(PL_reg_match_utf8); /* from regexec.c */
SAVEVPTR(PL_reg_magic); /* from regexec.c */
SAVEI32(PL_reg_oldpos); /* from regexec.c */
SAVEVPTR(PL_reg_oldcurpm); /* from regexec.c */
*/
#define CHR_SVLEN(sv) (UTF ? sv_len_utf8(sv) : SvCUR(sv))
-#define CHR_DIST(a,b) (PL_reg_sv_utf8 ? utf8_distance(a,b) : a - b)
+#define CHR_DIST(a,b) (PL_reg_match_utf8 ? utf8_distance(a,b) : a - b)
#define reghop_c(pos,off) ((char*)reghop((U8*)pos, off))
#define reghopmaybe_c(pos,off) ((char*)reghopmaybe((U8*)pos, off))
-#define HOP(pos,off) (PL_reg_sv_utf8 ? reghop((U8*)pos, off) : (U8*)(pos + off))
-#define HOPMAYBE(pos,off) (PL_reg_sv_utf8 ? reghopmaybe((U8*)pos, off) : (U8*)(pos + off))
+#define HOP(pos,off) (PL_reg_match_utf8 ? reghop((U8*)pos, off) : (U8*)(pos + off))
+#define HOPMAYBE(pos,off) (PL_reg_match_utf8 ? reghopmaybe((U8*)pos, off) : (U8*)(pos + off))
#define HOPc(pos,off) ((char*)HOP(pos,off))
#define HOPMAYBEc(pos,off) ((char*)HOPMAYBE(pos,off))
#define HOPBACK(pos, off) ( \
- (UTF && PL_reg_sv_utf8) \
+ (UTF && PL_reg_match_utf8) \
? reghopmaybe((U8*)pos, -off) \
: (pos - off >= PL_bostr) \
? (U8*)(pos - off) \
#define reghop3_c(pos,off,lim) ((char*)reghop3((U8*)pos, off, (U8*)lim))
#define reghopmaybe3_c(pos,off,lim) ((char*)reghopmaybe3((U8*)pos, off, (U8*)lim))
-#define HOP3(pos,off,lim) (PL_reg_sv_utf8 ? reghop3((U8*)pos, off, (U8*)lim) : (U8*)(pos + off))
-#define HOPMAYBE3(pos,off,lim) (PL_reg_sv_utf8 ? reghopmaybe3((U8*)pos, off, (U8*)lim) : (U8*)(pos + off))
+#define HOP3(pos,off,lim) (PL_reg_match_utf8 ? reghop3((U8*)pos, off, (U8*)lim) : (U8*)(pos + off))
+#define HOPMAYBE3(pos,off,lim) (PL_reg_match_utf8 ? reghopmaybe3((U8*)pos, off, (U8*)lim) : (U8*)(pos + off))
#define HOP3c(pos,off,lim) ((char*)HOP3(pos,off,lim))
#define HOPMAYBE3c(pos,off,lim) ((char*)HOPMAYBE3(pos,off,lim))
unsigned int c2;
char *e;
register I32 tmp = 1; /* Scratch variable? */
- register bool do_utf8 = PL_reg_sv_utf8;
+ register bool do_utf8 = PL_reg_match_utf8;
/* We know what class it must start with. */
switch (OP(c)) {
#if 0
I32 firstcp = PL_savestack_ix;
#endif
- register bool do_utf8 = PL_reg_sv_utf8;
+ register bool do_utf8 = PL_reg_match_utf8;
#ifdef DEBUGGING
PL_regindent++;
register I32 c;
register char *loceol = PL_regeol;
register I32 hardcount = 0;
- register bool do_utf8 = PL_reg_sv_utf8;
+ register bool do_utf8 = PL_reg_match_utf8;
scan = PL_reginput;
if (max != REG_INFTY && max < loceol - scan)
return 0;
start = PL_reginput;
- if (PL_reg_sv_utf8) {
+ if (PL_reg_match_utf8) {
while (PL_reginput < loceol && (scan = PL_reginput, res = regmatch(p))) {
if (!count++) {
l = 0;
PL_reg_re = (regexp*)NULL;
PL_reg_ganch = Nullch;
PL_reg_sv = Nullsv;
- PL_reg_sv_utf8 = FALSE;
+ PL_reg_match_utf8 = FALSE;
PL_reg_magic = (MAGIC*)NULL;
PL_reg_oldpos = 0;
PL_reg_oldcurpm = (PMOP*)NULL;
#endif /* USE_5005THREADS */
-PERLVAR(Treg_sv_utf8, bool) /* was what we matched against utf8 */
+PERLVAR(Treg_match_utf8, bool) /* was what we matched against utf8 */