perl 2.0 (no announcement message available)
[p5sagit/p5-mst-13.2.git] / spat.h
1 /* $Header: spat.h,v 2.0 88/06/05 00:10:58 root Exp $
2  *
3  * $Log:        spat.h,v $
4  * Revision 2.0  88/06/05  00:10:58  root
5  * Baseline version 2.0.
6  * 
7  */
8
9 struct scanpat {
10     SPAT        *spat_next;             /* list of all scanpats */
11     REGEXP      *spat_regexp;           /* compiled expression */
12     ARG         *spat_repl;             /* replacement string for subst */
13     ARG         *spat_runtime;          /* compile pattern at runtime */
14     STR         *spat_short;            /* for a fast bypass of execute() */
15     bool        spat_flags;
16     char        spat_slen;
17 };
18
19 #define SPAT_USED 1                     /* spat has been used once already */
20 #define SPAT_ONCE 2                     /* use pattern only once per article */
21 #define SPAT_SCANFIRST 4                /* initial constant not anchored */
22 #define SPAT_ALL 8                      /* initial constant is whole pat */
23 #define SPAT_SKIPWHITE 16               /* skip leading whitespace for split */
24 #define SPAT_FOLD 32                    /* case insensitivity */
25
26 EXT SPAT *spat_root;            /* list of all spats */
27 EXT SPAT *curspat;              /* what to do \ interps from */
28 EXT SPAT *lastspat;             /* what to use in place of null pattern */
29
30 EXT char *hint INIT(Nullch);    /* hint from cmd_exec to do_match et al */
31
32 #define Nullspat Null(SPAT*)