autoconf-patches
[Top][All Lists]
Advanced

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

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


From: Jim Meyering
Subject: Re: [PATCH] avoid new warning about undefined $ARGV[0]
Date: Sun, 15 Jan 2012 17:33:51 +0100

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/General.pm line 273.
>>
> Ouch, apparently you have missed my earlier patch that fixed this same bug:
> <http://lists.gnu.org/archive/html/autoconf-patches/2012-01/msg00010.html>

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?) 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 ">".



reply via email to

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