Paolo Bonzini wrote: > * Makefile.am (grep_SOURCES): Add gsearch.c. > (EXTRA_DIST): Add search.c. > * esearch.c (matchers): New. > * fsearch.c (matchers): New. > * gsearch.c: New. > * search.c (matchers): Remove. > * grep.c: Always compile most !GREP_PROGRAM sections. > (main): Use first matcher if none is explicitly provided. Remove > "default" matcher. > * grep.h (struct matcher): Adjust comments. ... ACK with one nit:
> diff --git a/src/grep.h b/src/grep.h > index 8a0ca3b..1277b61 100644 > --- a/src/grep.h > +++ b/src/grep.h > @@ -38,32 +38,21 @@ > (char const *buf, size_t size, size_t *match_size, char const *start_ptr) > /* start_ptr == NULL means the caller is not looking for an exact match. > */ > > -#ifdef GREP_PROGRAM > -/* Function definitions. */ > # define COMPILE_FCT(f) static COMPILE_RET f COMPILE_ARGS > # define EXECUTE_FCT(f) static EXECUTE_RET f EXECUTE_ARGS > + > /* Function pointer types. */ > typedef COMPILE_RET (*compile_fp_t) COMPILE_ARGS; > typedef EXECUTE_RET (*execute_fp_t) EXECUTE_ARGS; > > -/* grep.c expects the matchers vector to be terminated > - by an entry with a NULL name, and to contain at least > - an entry named "default". */ > +/* grep.c expects the matchers vector to be terminated by an entry > + * with a NULL name, and to contain at least an entry. */ s/an/one/ Also, s/^ \*/ /, to be consistent with commenting style.