[ic] [interchange] * Back out previous change, exists for array is deprecated in

Mike Heins mike at perusion.com
Mon Jun 17 20:39:52 UTC 2013


Quoting Peter (peter at pajamian.dhs.org):
> On 06/18/2013 08:18 AM, Mike Heins wrote:
> >Quoting Peter (peter at pajamian.dhs.org):
> >>On 06/18/2013 07:16 AM, Mike Heins wrote:
> >>>commit 2b063379db2a7c0e876c62143933ea3d7f221354
> >>>Author: Mike Heins <mike at perusion.com>
> >>>Date:   Mon Jun 17 15:16:05 2013 -0400
> >>>
> >>>     * Back out previous change, exists for array is deprecated in
> >>>       Perl and we should not add new change based on that.
> >>
> >>This should work:
> >>
> >>next if $i > $#fields;
> >
> >Yes, actually could be
> >
> >   last if $i > $#fields;
> 
> Only if $i is actually incrementing.  From the looks of the code it is 
> not and could jump all around since the order of keys in perl is not 
> guaranteed and is in fact guaranteed to change for each running of the 
> program:
>  		for (keys %{$cfg->{PREFER_NULL}}) {
>  			my $i = $cfg->{COLUMN_INDEX}{$_};
> 

Aha, yes, of course you are right. In any case, while I am not sure
what autovivification hurts, it is probably not the best thing to do.
I will make the appropriate fix.

-- 
Mike Heins
Perusion -- Expert Interchange Consulting    http://www.perusion.com/
phone +1.765.253.4194  <mike at perusion.com>

Fast, reliable, cheap.  Pick two and we'll talk.
-- unknown



More information about the interchange-users mailing list