9 |
|
|
10 |
Written by: Philip Hazel <ph10@cam.ac.uk> |
Written by: Philip Hazel <ph10@cam.ac.uk> |
11 |
|
|
12 |
Copyright (c) 1998 University of Cambridge |
Copyright (c) 1997-1999 University of Cambridge |
13 |
|
|
14 |
----------------------------------------------------------------------------- |
----------------------------------------------------------------------------- |
15 |
Permission is granted to anyone to use this software for any purpose on any |
Permission is granted to anyone to use this software for any purpose on any |
4033 |
resetcount = 2 + re->top_bracket * 2; |
resetcount = 2 + re->top_bracket * 2; |
4034 |
if (resetcount > offsetcount) resetcount = ocount; |
if (resetcount > offsetcount) resetcount = ocount; |
4035 |
|
|
4036 |
|
/* Reset the working variable associated with each extraction. These should |
4037 |
|
never be used unless previously set, but they get saved and restored, and so we |
4038 |
|
initialize them to avoid reading uninitialized locations. */ |
4039 |
|
|
4040 |
|
if (match_block.offset_vector != NULL) |
4041 |
|
{ |
4042 |
|
register int *iptr = match_block.offset_vector + ocount; |
4043 |
|
register int *iend = iptr - resetcount/2 + 1; |
4044 |
|
while (--iptr >= iend) *iptr = -1; |
4045 |
|
} |
4046 |
|
|
4047 |
/* Set up the first character to match, if available. The first_char value is |
/* Set up the first character to match, if available. The first_char value is |
4048 |
never set for an anchored regular expression, but the anchoring may be forced |
never set for an anchored regular expression, but the anchoring may be forced |
4049 |
at run time, so we have to test for anchoring. The first char may be unset for |
at run time, so we have to test for anchoring. The first char may be unset for |