summaryrefslogtreecommitdiff
path: root/pod/buildtoc
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2011-11-07 21:23:39 +0100
committerNicholas Clark <nick@ccl4.org>2011-11-18 11:08:56 +0100
commit85fa87dbdbe1a457bef61868d355ea1f4870d6f8 (patch)
tree585bfa6f4f8028927e3cd7c84a3e24cf38448ac0 /pod/buildtoc
parentf37610d895e1d30b2be6a7872374e35af560c75c (diff)
downloadperl-85fa87dbdbe1a457bef61868d355ea1f4870d6f8.tar.gz
In buildtoc, make %Readmepods lexical, and $delta_target global.
%Readmepods is only used within the code to read pod.lst, pod/perlpod.pod and MANIFEST, not by the generation code. $delta_target is set by the reading code, but used in the generation code. This makes the use of global and lexical variables more consistent.
Diffstat (limited to 'pod/buildtoc')
-rw-r--r--pod/buildtoc8
1 files changed, 4 insertions, 4 deletions
diff --git a/pod/buildtoc b/pod/buildtoc
index 57d0ff87ef..19bb81432d 100644
--- a/pod/buildtoc
+++ b/pod/buildtoc
@@ -2,7 +2,7 @@
use strict;
use vars qw($masterpodfile %Build %Targets $Verbose $Quiet %Ignore
- @Master %Readmes %Pods %Aux %Readmepods %Pragmata %Modules
+ @Master %Readmes %Pods %Aux %Pragmata %Modules $delta_target
%Copies %Generated $Test);
use File::Spec;
use File::Find;
@@ -110,8 +110,6 @@ if ($Verbose) {
print "I will be building $_\n" foreach keys %Build;
}
-my $delta_target;
-
{
my $source = 'perldelta.pod';
my $filename = "pod/$source";
@@ -130,6 +128,8 @@ my $delta_target;
}
# process pod.lst
+{
+ my %Readmepods;
open my $master, '<', $masterpodfile or my_die "Can't open $masterpodfile: $!";
@@ -184,7 +184,7 @@ foreach (<$master>) {
close $master;
# Sanity cross check
-{
+
my (%disk_pods, @disk_pods);
my (@manipods, %manipods);
my (@manireadmes, %manireadmes);