Skip to content

Commit 599db2b

Browse files
ntynikhwilliamson
authored andcommitted
Don't call each on an anonymous hash
From perldiag: each on anonymous %s will always start from the beginning (W syntax) You called each on an anonymous hash or array. Since a new hash or array is created each time, each() will restart iterating over your hash or array every time. Bug: #190 Bug-Debian: https://bugs.debian.org/1114492
1 parent 0019223 commit 599db2b

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

lib/Pod/Simple/HTMLBatch.pm

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -717,12 +717,13 @@ sub _gen_css_wad {
717717
}
718718

719719
# Now a few indexless variations:
720-
for (my ($outfile, $variation) = each %{{
720+
my %variations = (
721721
blkbluw => 'black_with_blue_on_white',
722722
whtpurk => 'white_with_purple_on_black',
723723
whtgrng => 'white_with_green_on_grey',
724724
grygrnw => 'grey_with_green_on_white',
725-
}}) {
725+
);
726+
for (my ($outfile, $variation) = each %variations) {
726727
my $this_css = join "\n",
727728
"/* This file is autogenerated. Do not edit. $outfile */\n",
728729
"\@import url(\"./_$variation.css\");",

0 commit comments

Comments
 (0)