summaryrefslogtreecommitdiff
path: root/regcomp.c
diff options
context:
space:
mode:
authorRafael Garcia-Suarez <rgarciasuarez@gmail.com>2005-03-22 09:21:09 +0000
committerRafael Garcia-Suarez <rgarciasuarez@gmail.com>2005-03-22 09:21:09 +0000
commit0111c4fd47c4cca05ba4f96d1ff28f7e9ff79155 (patch)
tree28a574650c97913efe008d8a4a4aa5dcc09c22b7 /regcomp.c
parenta399f54aa42608589fd1ea74b6eb5f6dc14c9622 (diff)
downloadperl-0111c4fd47c4cca05ba4f96d1ff28f7e9ff79155.tar.gz
Rename ${^RE_TRIE_MAXBUFF} to ${^RE_TRIE_MAXBUF},
and other neatification p4raw-id: //depot/perl@24065
Diffstat (limited to 'regcomp.c')
-rw-r--r--regcomp.c22
1 files changed, 10 insertions, 12 deletions
diff --git a/regcomp.c b/regcomp.c
index 5bfcd70f8a..1f7530f794 100644
--- a/regcomp.c
+++ b/regcomp.c
@@ -866,9 +866,9 @@ S_make_trie(pTHX_ RExC_state_t *pRExC_state, regnode *startbranch, regnode *firs
});
- re_trie_maxbuff=get_sv(RE_TRIE_MAXBUFF, 1);
+ re_trie_maxbuff = get_sv(RE_TRIE_MAXBUF_NAME, 1);
if (!SvIOK(re_trie_maxbuff)) {
- sv_setiv(re_trie_maxbuff, TRIE_SIMPLE_MAX_BUFF);
+ sv_setiv(re_trie_maxbuff, RE_TRIE_MAXBUF_INIT);
}
/* -- First loop and Setup --
@@ -941,8 +941,8 @@ S_make_trie(pTHX_ RExC_state_t *pRExC_state, regnode *startbranch, regnode *firs
/*
We now know what we are dealing with in terms of unique chars and
string sizes so we can calculate how much memory a naive
- representation using a flat table will take. If its over a reasonable
- limit (as specified by $^RE_TRIE_MAXBUFF) we use a more memory
+ representation using a flat table will take. If it's over a reasonable
+ limit (as specified by ${^RE_TRIE_MAXBUF}) we use a more memory
conservative but potentially much slower representation using an array
of lists.
@@ -1834,13 +1834,12 @@ S_study_chunk(pTHX_ RExC_state_t *pRExC_state, regnode **scanp, I32 *deltap, reg
it would just call its tail, no WHILEM/CURLY needed.
*/
- if (DO_TRIE) {
- if (!re_trie_maxbuff) {
- re_trie_maxbuff=get_sv(RE_TRIE_MAXBUFF, 1);
- if (!SvIOK(re_trie_maxbuff))
- sv_setiv(re_trie_maxbuff, TRIE_SIMPLE_MAX_BUFF);
-
- }
+ if (DO_TRIE) {
+ if (!re_trie_maxbuff) {
+ re_trie_maxbuff = get_sv(RE_TRIE_MAXBUF_NAME, 1);
+ if (!SvIOK(re_trie_maxbuff))
+ sv_setiv(re_trie_maxbuff, RE_TRIE_MAXBUF_INIT);
+ }
if ( SvIV(re_trie_maxbuff)>=0 && OP( startbranch )==BRANCH ) {
regnode *cur;
regnode *first = (regnode *)NULL;
@@ -1902,7 +1901,6 @@ S_study_chunk(pTHX_ RExC_state_t *pRExC_state, regnode **scanp, I32 *deltap, reg
regnode *noper = NEXTOPER( cur );
regnode *noper_next = regnext( noper );
-
DEBUG_OPTIMISE_r({
regprop( mysv, cur);
PerlIO_printf( Perl_debug_log, "%*s%s",