This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
podcheck.t: Remove extra loop initialization
authorKarl Williamson <public@khwilliamson.com>
Sun, 25 Sep 2011 16:25:07 +0000 (10:25 -0600)
committerKarl Williamson <public@khwilliamson.com>
Sun, 25 Sep 2011 20:18:09 +0000 (14:18 -0600)
I think its clearer to put the subroutine call in each line of
initialization

t/porting/podcheck.t

index e273b57..47d4194 100644 (file)
@@ -334,20 +334,14 @@ my $dl_ext  = $Config{'dlext'};   $dl_ext  =~ tr/.//d;
 
 # Not really pods, but can look like them.
 my %excluded_files = (
-                        "lib/unicore/mktables" => 1,
-                        "Porting/perldelta_template.pod" => 1,
-                        "autodoc.pl" => 1,
-                        "configpm" => 1,
-                        "miniperl" => 1,
-                        "perl" => 1,
+                        canonicalize("lib/unicore/mktables") => 1,
+                        canonicalize("Porting/perldelta_template.pod") => 1,
+                        canonicalize("autodoc.pl") => 1,
+                        canonicalize("configpm") => 1,
+                        canonicalize("miniperl") => 1,
+                        canonicalize("perl") => 1,
                     );
 
-# Convert to more generic form.
-foreach my $file (keys %excluded_files) {
-    delete $excluded_files{$file};
-    $excluded_files{canonicalize($file)} = 1;
-}
-
 # This list should not include anything for which case sensitivity is
 # important, as it won't work on VMS, and won't show up until tested on VMS.
 # Instead is_pod_file() can be used to exclude these at a finer grained