summaryrefslogtreecommitdiff
path: root/Porting/pod_lib.pl
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2011-12-19 20:01:29 +0100
committerNicholas Clark <nick@ccl4.org>2011-12-21 09:07:27 +0100
commitdc4373008ad8232b22c089a9e42f59b45e7c78a1 (patch)
tree8224b52b93044230d6a8be7355e1c4c073935fe8 /Porting/pod_lib.pl
parent4e604983952b1d2a9eb17c9c99e4d1d4947f3010 (diff)
downloadperl-dc4373008ad8232b22c089a9e42f59b45e7c78a1.tar.gz
Prune unused entries from the 'master' array returned by get_pod_metadata().
The description is only used to generate MANIFEST entries now from 'readmes' and 'pods'. now that perl.pod is the master and is no longer generated from pod.lst The leafname/podname distinction is only used by is_duplicate_pod(), so can be replaced by simple flag, 'dual'. Replace the now-unused entries with undef to preserve the indices.
Diffstat (limited to 'Porting/pod_lib.pl')
-rw-r--r--Porting/pod_lib.pl11
1 files changed, 5 insertions, 6 deletions
diff --git a/Porting/pod_lib.pl b/Porting/pod_lib.pl
index d6b43764a8..7e3cdab944 100644
--- a/Porting/pod_lib.pl
+++ b/Porting/pod_lib.pl
@@ -56,7 +56,7 @@ my %state = (
unless (%Lengths) {
__prime_state() unless $state{master};
foreach (@{$state{master}}) {
- next if $_->[1] eq $_->[4];
+ next unless $_->[0]{dual};
# This is a dual-life perl*.pod file, which will have be copied
# to lib/ by the build process, and hence also found there.
# These are the only pod files that might become duplicated.
@@ -152,6 +152,7 @@ sub __prime_state {
my %flags;
$flags{toc_omit} = 1 if $flags =~ tr/o//d;
+ $flags{dual} = $podname ne $leafname;
$state{generated}{"$podname.pod"}++ if $flags =~ tr/g//d;
@@ -166,15 +167,13 @@ sub __prime_state {
my_die "Unknown flag found in section line: $_" if length $flags;
push @{$state{master}},
- [\%flags, $podname, $filename, $desc, $leafname];
+ [\%flags, undef, $filename, undef, $leafname];
if ($podname eq 'perldelta') {
local $" = '.';
- my $delta_desc = "Perl changes in version @want";
push @{$state{master}},
- [{}, $state{delta_target}, "pod/$state{delta_target}",
- $delta_desc, $delta_leaf];
- $state{pods}{$delta_leaf} = $delta_desc;
+ [{}, undef, "pod/$state{delta_target}", undef, $delta_leaf];
+ $state{pods}{$delta_leaf} = "Perl changes in version @want";
}
} else {