Subject: Re: git grep '(' = segfault

From: Junio C Hamano <[email-masked]>
Date: Mon, 27 Apr 2009 16:18:12 -0700

Erik Faye-Lund <[email-masked]> writes:

> Yeah, thanks for explaining. But isn't this functionality kind of
> redundant since we have the -E switch?
> As far as I can see, "git grep -E "(bar|boz)" should do the same thing
> as "git grep -e foo --and '(' -e bar --or -e boz ')'"...

With -E, --or is not strictly necessary.

With only -E, however, it is cumbersome to express what --and can.  Once
you learn the handiness of --and, naturally you would start wanting to
be able to say --or (especially if you do not even know about -E).