X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=regexp.h;h=81552baf6cec490c4a2730fc3cdabc483b2db232;hb=0ddaf51316ca1bab139289c51c648ec8213a8af3;hp=9e86a1efaa888f4397a4e88dc8af1990e5124c2a;hpb=bc9a0d2c623dd8bb74497904d844e3b82bd1c1a3;p=p5sagit%2Fp5-mst-13.2.git diff --git a/regexp.h b/regexp.h index 9e86a1e..81552ba 100644 --- a/regexp.h +++ b/regexp.h @@ -1,4 +1,10 @@ /* regexp.h + * + * Copyright (c) 1997-2002, Larry Wall + * + * You may distribute under the terms of either the GNU General Public + * License or the Artistic License, as specified in the README file. + * */ /* @@ -19,6 +25,8 @@ typedef struct regnode regnode; struct reg_substr_data; +struct reg_data; + typedef struct regexp { I32 *startp; I32 *endp; @@ -28,12 +36,14 @@ typedef struct regexp { struct reg_data *data; /* Additional data. */ char *subbeg; /* saved or original string so \digit works forever. */ + U32 *offsets; /* offset annotations 20001228 MJD */ I32 sublen; /* Length of string pointed by subbeg */ I32 refcnt; I32 minlen; /* mininum possible length of $& */ I32 prelen; /* length of precomp */ U32 nparens; /* number of parentheses */ U32 lastparen; /* last paren matched */ + U32 lastcloseparen; /* last paren matched */ U32 reganch; /* Internal use only + Tainted information used by regexec? */ regnode program[1]; /* Unwarranted chumminess with compiler. */ @@ -52,6 +62,8 @@ typedef struct regexp { #define ROPT_CHECK_ALL 0x00100 #define ROPT_LOOKBEHIND_SEEN 0x00200 #define ROPT_EVAL_SEEN 0x00400 +#define ROPT_CANY_SEEN 0x00800 +#define ROPT_SANY_SEEN ROPT_CANY_SEEN /* src bckwrd cmpt */ /* 0xf800 of reganch is used by PMf_COMPILETIME */ @@ -94,7 +106,7 @@ typedef struct regexp { #define REXEC_NOT_FIRST 0x10 /* This is another iteration of //g. */ #define REXEC_ML 0x20 /* $* was set. */ -#define ReREFCNT_inc(re) ((re && re->refcnt++), re) +#define ReREFCNT_inc(re) ((void)(re && re->refcnt++), re) #define ReREFCNT_dec(re) CALLREGFREE(aTHX_ re) #define FBMcf_TAIL_DOLLAR 1