Re: [PATCH] environment.c: introduce SETUP_GIT_ENV helper macro
Hello Junio,
On Sun, Feb 28, 2016 at 12:50 AM, Junio C Hamano <gitster@pobox.com> wrote:
Show 5 quoted lines
> Junio C Hamano <gitster@pobox.com> writes:
>
>
>> Please don't. A macro that hides "return" makes things harder to
>> follow, not easier.
I will consider it next time.
Show 5 quoted lines
> Having said that, I do think a higher-level macro that encapulates
> the whole thing may not be such a bad idea, i.e. making the above
> into
>
> DECLARE_GIT_GETTER(const char *, get_git_dir, git_dir)
Yes, it is better. Will resend the patch.
Thank you.