pike.git / src / modules / Regexp / pike_regexp.c

version» Context lines:

pike.git/src/modules/Regexp/pike_regexp.c:209:   static char regdummy;   static char *regcode; /* Code-emit pointer; &regdummy = don't. */   static long regsize; /* Code size. */      /*    * Forward declarations for regcomp()'s friends.    */   #ifndef STATIC   #define STATIC static   #endif - STATIC char *reg(); - STATIC char *regbranch(); - STATIC char *regpiece(); - STATIC char *regatom(); - STATIC char *regnode(); - STATIC char *regnext(); - STATIC void regc(); - STATIC void reginsert(); - STATIC void regtail(); - STATIC void regoptail(); + STATIC char *reg(int, int *); + STATIC char *regbranch(int *); + STATIC char *regpiece(int *); + STATIC char *regatom(int *); + STATIC char *regnode(char); + STATIC char *regnext(register char *); + STATIC void regc(char b); + STATIC void reginsert(char, char *); + STATIC void regtail(char *, char *); + STATIC void regoptail(char *, char *);      /*    - regcomp - compile a regular expression into internal code    *    * We can't allocate space until we know how big the compiled form will be,    * but we can't compile it (and thus know how big it is) until we've got a    * place to put the code. So we cheat: we compile it twice, once with code    * generation turned off and size counting turned on, and once "for real".    * This also means that we don't allocate space until we are sure that the    * thing really will compile successfully, and we never have to move the
pike.git/src/modules/Regexp/pike_regexp.c:762:    * Global work variables for regexec().    */   static char *reginput; /* String-input pointer. */   static char *regbol; /* Beginning of input, for ^ check. */   static char **regstartp; /* Pointer to startp array. */   static char **regendp; /* Ditto for endp. */      /*    * Forwards.    */ - STATIC int regtry(); - STATIC int regmatch(); - STATIC int regrepeat(); + STATIC int regtry(regexp *, char *); + STATIC int regmatch(char *); + STATIC int regrepeat(char *);      #ifdef DEBUG   int regnarrate = 0; - void regdump(); - STATIC char *regprop(); + void regdump(regexp *); + STATIC char *regprop(char *op);   #endif      /*    - regexec - match a regexp against a string    */   int pike_regexec(regexp *prog, char *string)   {    register char *s;       /* Be paranoid... */
pike.git/src/modules/Regexp/pike_regexp.c:1163:    return ((char *)NULL);       if (OP(p) == BACK)    return (p - offset);    else    return (p + offset);   }      #ifdef DEBUG    - STATIC char *regprop(); + STATIC char *regprop(char *);      /*    - regdump - dump a regexp onto stdout in vaguely comprehensible form    */   #ifdef __STDC__      void regdump(regexp *r)      #else