summaryrefslogtreecommitdiff
path: root/op.c
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2007-12-28 21:25:50 +0000
committerNicholas Clark <nick@ccl4.org>2007-12-28 21:25:50 +0000
commit220fc49f9cd19ab777a22ef733671f0fbb81e6bd (patch)
treea91eae57fc34523216a9770d4b54a1f88987826b /op.c
parentf19b4ba939a9fcdd83b091f4baa1c12b87ff9886 (diff)
downloadperl-220fc49f9cd19ab777a22ef733671f0fbb81e6bd.tar.gz
Wrap all accesses to the members precomp and prelen of struct regexp in
the macros RX_PRECOMP() and RX_PRELEN(). This will allow us to reduce the regexp storage overhead by computing them at retrieve time. p4raw-id: //depot/perl@32753
Diffstat (limited to 'op.c')
-rw-r--r--op.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/op.c b/op.c
index bb6ac6286c..2185c25938 100644
--- a/op.c
+++ b/op.c
@@ -7558,8 +7558,8 @@ Perl_ck_join(pTHX_ OP *o)
if (kid && kid->op_type == OP_MATCH) {
if (ckWARN(WARN_SYNTAX)) {
const REGEXP *re = PM_GETRE(kPMOP);
- const char *pmstr = re ? re->precomp : "STRING";
- const STRLEN len = re ? re->prelen : 6;
+ const char *pmstr = re ? RX_PRECOMP(re) : "STRING";
+ const STRLEN len = re ? RX_PRELEN(re) : 6;
Perl_warner(aTHX_ packWARN(WARN_SYNTAX),
"/%.*s/ should probably be written as \"%.*s\"",
(int)len, pmstr, (int)len, pmstr);