bug-grep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] grep: remove redundant syntax bit


From: Jim Meyering
Subject: Re: [PATCH] grep: remove redundant syntax bit
Date: Tue, 04 May 2010 17:44:29 +0200

Paolo Bonzini wrote:
> * grep.c (Gcompile): Remove RE_HAT_LISTS_NOT_NEWLINE.
> ---
>  src/grep.c |    5 +----
>  1 files changed, 1 insertions(+), 4 deletions(-)
>
> diff --git a/src/grep.c b/src/grep.c
> index 7b30f66..e12ae3d 100644
> --- a/src/grep.c
> +++ b/src/grep.c
> @@ -4,10 +4,7 @@
>  static void
>  Gcompile (char const *pattern, size_t size)
>  {
> -  GEAcompile (pattern, size,
> -              RE_SYNTAX_GREP
> -              | RE_HAT_LISTS_NOT_NEWLINE
> -              | RE_NO_EMPTY_RANGES);
> +  GEAcompile (pattern, size, RE_SYNTAX_GREP | RE_NO_EMPTY_RANGES);

Confirmed:

    $ grep -A3 AX_GRE /usr/include/regex.h
    #define RE_SYNTAX_GREP                                                  \
      (RE_BK_PLUS_QM              | RE_CHAR_CLASSES                         \
       | RE_HAT_LISTS_NOT_NEWLINE | RE_INTERVALS                            \
       | RE_NEWLINE_ALT)

ACK.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]