Commit | Line | Data |
---|---|---|
b0b46c19 KB |
1 | /* |
2 | * Copyright (c) 1986 by University of Toronto. | |
3 | * Copyright (c) 1989 The Regents of the University of California. | |
4 | * All rights reserved. | |
5 | * | |
6 | * This code is derived from software contributed to Berkeley | |
7 | * by Henry Spencer. | |
8 | * | |
9 | * Redistribution and use in source and binary forms are permitted | |
10 | * provided that the above copyright notice and this paragraph are | |
11 | * duplicated in all such forms and that any documentation, | |
12 | * advertising materials, and other materials related to such | |
13 | * distribution and use acknowledge that the software was developed | |
14 | * by the University of California, Berkeley. The name of the | |
15 | * University may not be used to endorse or promote products derived | |
16 | * from this software without specific prior written permission. | |
17 | * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR | |
18 | * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED | |
19 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. | |
20 | * | |
21 | * @(#)regexp.h 1.2 (Berkeley) %G% | |
22 | */ | |
23 | ||
b403a696 KB |
24 | /* |
25 | * Definitions etc. for regexp(3) routines. | |
26 | * | |
27 | * Caveat: this is V8 regexp(3) [actually, a reimplementation thereof], | |
28 | * not the System V one. | |
b403a696 KB |
29 | */ |
30 | #define NSUBEXP 10 | |
31 | typedef struct regexp { | |
32 | char *startp[NSUBEXP]; | |
33 | char *endp[NSUBEXP]; | |
34 | char regstart; /* Internal use only. */ | |
35 | char reganch; /* Internal use only. */ | |
36 | char *regmust; /* Internal use only. */ | |
37 | int regmlen; /* Internal use only. */ | |
38 | char program[1]; /* Unwarranted chumminess with compiler. */ | |
39 | } regexp; | |
40 | ||
41 | extern regexp *regcomp(); | |
42 | extern int regexec(); | |
43 | extern void regsub(); | |
44 | extern void regerror(); |