diff options
author | Nicholas Clark <nick@ccl4.org> | 2007-12-28 21:25:50 +0000 |
---|---|---|
committer | Nicholas Clark <nick@ccl4.org> | 2007-12-28 21:25:50 +0000 |
commit | 220fc49f9cd19ab777a22ef733671f0fbb81e6bd (patch) | |
tree | a91eae57fc34523216a9770d4b54a1f88987826b /pp_ctl.c | |
parent | f19b4ba939a9fcdd83b091f4baa1c12b87ff9886 (diff) | |
download | perl-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 'pp_ctl.c')
-rw-r--r-- | pp_ctl.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -130,8 +130,8 @@ PP(pp_regcomp) re = PM_GETRE(pm); /* Check against the last compiled regexp. */ - if (!re || !re->precomp || re->prelen != (I32)len || - memNE(re->precomp, t, len)) + if (!re || !RX_PRECOMP(re) || RX_PRELEN(re) != (I32)len || + memNE(RX_PRECOMP(re), t, len)) { const regexp_engine *eng = re ? re->engine : NULL; U32 pm_flags = pm->op_pmflags & PMf_COMPILETIME; @@ -172,7 +172,7 @@ PP(pp_regcomp) } #endif - if (!PM_GETRE(pm)->prelen && PL_curpm) + if (!RX_PRELEN(PM_GETRE(pm)) && PL_curpm) pm = PL_curpm; |