Re: [PATCH] builtin-grep: workaround for non GNU grep.
- From
Junio C Hamano <junkio@cox.net>
- Date
- May 17, 2006, 17:42 UTC
- Message-ID
- <7vhd3ofsyv.fsf@assigned-by-dhcp.cox.net>
- In-Reply-To
- <4fb292fa0605170839r259732dcw1c1bae3f1808db32@mail.gmail.com>
"Bertrand Jacquin" <beber.mailing@gmail.com> writes:
Show 12 quoted lines
> Sorry, maybe a C code beginner question but while you define
> NO_H_OPTION_IN_GREP in Makefile, why don't use a build time ``if''
> instead of a runtime one ?
>
> Like :
>
> #if NO_H_OPTION_IN_GREP
> push_arg("/dev/null");
> #else
> push_arg("-H");
> push_arg("--");
> #fiExactly because I wanted to avoid conditional compilation using C preprocessor directive (#if).