home *** CD-ROM | disk | FTP | other *** search
/ The C Users' Group Library 1994 August / wc-cdrom-cusersgrouplibrary-1994-08.iso / vol_300 / 329_01 / regexp.h < prev    next >
C/C++ Source or Header  |  1988-12-09  |  1KB  |  47 lines

  1. /*
  2. **    name:        regexp.h
  3. **    purpose:    Define stuff to compile under OS/2
  4. */
  5. #define    OS2    1
  6. #include    <string.h>
  7. #include    <stdlib.h>
  8. void    file();
  9. void    cant();
  10. void    help();
  11. void    usage();
  12. void    grep();
  13. int    match();
  14. void    error();
  15.  
  16.  
  17.  
  18. /*
  19.  * Definitions etc. for regexp(3) routines.
  20.  *
  21.  * Caveat:  this is V8 regexp(3) [actually, a reimplementation thereof],
  22.  * not the System V one.
  23.  */
  24. #define NSUBEXP  10
  25. typedef struct regexp {
  26.     char *startp[NSUBEXP];
  27.     char *endp[NSUBEXP];
  28.     char regstart;        /* Internal use only. */
  29.     char reganch;        /* Internal use only. */
  30.     char *regmust;        /* Internal use only. */
  31.     int regmlen;        /* Internal use only. */
  32.     char program[1];    /* Unwarranted chumminess with compiler. */
  33. } regexp;
  34.  
  35. #ifndef LINT_ARGS
  36. extern regexp *regcomp();
  37. extern int regexec();
  38. extern void regsub();
  39. extern void regerror();
  40. #else
  41. extern regexp *regcomp(char *);
  42. extern int regexec(regexp *,char *);
  43. extern void regsub(regexp *,char *,char *);
  44. extern void regerror(char *);
  45. #endif
  46.  
  47.