summaryrefslogtreecommitdiff
path: root/pp_ctl.c
diff options
context:
space:
mode:
authorDavid Mitchell <davem@iabyn.com>2011-12-07 11:29:27 +0000
committerDavid Mitchell <davem@iabyn.com>2012-06-13 13:32:46 +0100
commit2a92a97368adae0667f9a98890bb48727ed74e54 (patch)
tree7574572be9929ef6633dad50b46aa91c89d7d1ea /pp_ctl.c
parent6f635923850b5cd9fcb7399e6455299f0371c5ff (diff)
downloadperl-2a92a97368adae0667f9a98890bb48727ed74e54.tar.gz
add PMf_IS_QR flag
This indicates that a particular PMOP is in fact OP_QR. We should of course be able to tell this from op_type, but the regex-compiling API only gets passed op_flags. This then allows us to fix a bug where we were deciding during compilation whether to hang on to the code_blocks based on whether the PMOP was PMf_HAS_CV rather than PMf_IS_QR; the latter implies the former, but not the other way round.
Diffstat (limited to 'pp_ctl.c')
-rw-r--r--pp_ctl.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/pp_ctl.c b/pp_ctl.c
index 24a0d3e5d0..1b0422a10f 100644
--- a/pp_ctl.c
+++ b/pp_ctl.c
@@ -115,7 +115,7 @@ PP(pp_regcomp)
new_re = re_op_compile(args, nargs, pm->op_code_list, eng, re,
&is_bare_re,
- (pm->op_pmflags & (RXf_PMf_COMPILETIME|PMf_HAS_CV)));
+ (pm->op_pmflags & (RXf_PMf_COMPILETIME|PMf_HAS_CV|PMf_IS_QR)));
if (pm->op_pmflags & PMf_HAS_CV)
((struct regexp *)SvANY(new_re))->qr_anoncv
= (CV*) SvREFCNT_inc(PAD_SV(PL_op->op_targ));