[Top][All Lists]

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

Re: [PATCH] avoid new warning about undefined $ARGV[0]

From: Stefano Lattarini
Subject: Re: [PATCH] avoid new warning about undefined $ARGV[0]
Date: Sun, 15 Jan 2012 17:49:41 +0100

On 01/15/2012 05:33 PM, Jim Meyering wrote:
> Stefano Lattarini wrote:
>> Hi Jim.
>> On 01/15/2012 05:22 PM, Jim Meyering wrote:
>>> Without this change, numerous tests would fail.
>>> E.g., on a Fedora 16 system, running autoreconf would print this warning:
>>>     Use of uninitialized value $ARGV[0] in pattern match (m//) at \
>>>       /p/share/autoconf/Autom4te/ line 273.
>> Ouch, apparently you have missed my earlier patch that fixed this same bug:
>> <>
> Hi Stefano,
> I did indeed miss that.  Sorry.
> It didn't even occur to me that a known bug like that would
> be left (awaiting review?)
Yes, awaiting review.  For projects where I only contribute minimally, I want to
wait for an explicit ACK before *any* commit, whether bug-fix or not.  That's
why I'm also waiting for a review before pushing this patch:


which fix a bug more difficult to spot but which, when hit, can have much more
heinous consequences (details in the commit log).

> in master.
> I see you would have fixed it like this:
>   if (@ARGV > 0 && $ARGV[0] =~ /^-./)
> I prefer that to what I did (defined $ARGV[0]),
> but prefer this even more:
>   if (@ARGV && $ARGV[0] =~ /^-./)
> It's concise (less syntax), and no use of ">".
I like this more as well.  I assume you'll go ahead and make the change 


reply via email to

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