From 4c9f88ef2a730d9022ab53d3aac89c6913b79ac2 Mon Sep 17 00:00:00 2001 From: "James E. Keenan" Date: Sat, 3 Apr 2010 17:05:07 -0400 Subject: No evident need for 'for' loop in assignment from $args{filename}. --- dist/ExtUtils-ParseXS/lib/ExtUtils/ParseXS.pm | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/dist/ExtUtils-ParseXS/lib/ExtUtils/ParseXS.pm b/dist/ExtUtils-ParseXS/lib/ExtUtils/ParseXS.pm index 3d07eb57b9..6fc728637f 100644 --- a/dist/ExtUtils-ParseXS/lib/ExtUtils/ParseXS.pm +++ b/dist/ExtUtils-ParseXS/lib/ExtUtils/ParseXS.pm @@ -89,13 +89,20 @@ sub process_file { $self->{WantLineNumbers} = $args{linenumbers}; $self->{IncludedFiles} = {}; - for my $f ($args{filename}) { - die "Missing required parameter 'filename'" unless $f; - $self->{filepathname} = $f; - ($self->{dir}, $self->{filename}) = (dirname($f), basename($f)); - $self->{filepathname} =~ s/\\/\\\\/g; - $self->{IncludedFiles}->{$f}++; - } +# for my $f ($args{filename}) { +# die "Missing required parameter 'filename'" unless $f; +# $self->{filepathname} = $f; +# ($self->{dir}, $self->{filename}) = (dirname($f), basename($f)); +# $self->{filepathname} =~ s/\\/\\\\/g; +# $self->{IncludedFiles}->{$f}++; +# } + + die "Missing required parameter 'filename'" unless $args{filename}; + $self->{filepathname} = $args{filename}; + ($self->{dir}, $self->{filename}) = + (dirname($args{filename}), basename($args{filename})); + $self->{filepathname} =~ s/\\/\\\\/g; + $self->{IncludedFiles}->{$args{filename}}++; # Open the output file if given as a string. If they provide some # other kind of reference, trust them that we can print to it. -- cgit v1.2.1