diff options
author | David Mitchell <davem@iabyn.com> | 2013-05-21 14:49:30 +0100 |
---|---|---|
committer | David Mitchell <davem@iabyn.com> | 2013-06-02 22:28:53 +0100 |
commit | 1cb48e53e0cc9d610c1829b47f3ef0babdb62477 (patch) | |
tree | 5ac6e15925f57dd36a025d0e648bc54233c12077 /regexp.h | |
parent | 0254aed965cd47adab9025a192546e4a5e63873a (diff) | |
download | perl-1cb48e53e0cc9d610c1829b47f3ef0babdb62477.tar.gz |
eliminate PL_reg_maxiter, PL_reg_leftiter
Move these two fields of PL_reg_state into the regmatch_info struct, so
they are local to each match.
Diffstat (limited to 'regexp.h')
-rw-r--r-- | regexp.h | 6 |
1 files changed, 2 insertions, 4 deletions
@@ -611,6 +611,8 @@ typedef struct { char *ganch; char *cutpoint; regmatch_eval_state *eval_state; /* extra saved state for (?{}) */ + I32 poscache_maxiter; /* how many whilems todo before S-L cache kicks in */ + I32 poscache_iter; /* current countdown from _maxiter to zero */ bool intuit; /* re_intuit_start() is the top-level caller */ bool is_utf8_pat; /* regex is utf8 */ bool is_utf8_target; /* string being matched is utf8 */ @@ -787,15 +789,11 @@ typedef struct regmatch_slab { } regmatch_slab; #define PL_reg_curpm PL_reg_state.re_state_reg_curpm -#define PL_reg_maxiter PL_reg_state.re_state_reg_maxiter -#define PL_reg_leftiter PL_reg_state.re_state_reg_leftiter #define PL_reg_poscache PL_reg_state.re_state_reg_poscache #define PL_reg_poscache_size PL_reg_state.re_state_reg_poscache_size #define PL_reg_starttry PL_reg_state.re_state_reg_starttry struct re_save_state { - I32 re_state_reg_maxiter; /* max wait until caching pos */ - I32 re_state_reg_leftiter; /* wait until caching pos */ PMOP *re_state_reg_curpm; /* from regexec.c */ STRLEN re_state_reg_poscache_size; /* size of pos cache of WHILEM */ char *re_state_reg_poscache; /* cache of pos of WHILEM */ |