Skip to content

Commit

Permalink
Maintainers.pl: use strict/warnings with "our"
Browse files Browse the repository at this point in the history
Add 2 pragmas, and scope globals with "our".

Scoped %Maintainers and %DistName (autovivified hashes) with our.

Fixes #21410

---

Archive: #21412
  • Loading branch information
rwp0 authored and tonycoz committed Sep 6, 2023
1 parent c542745 commit 008ae6a
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions Porting/Maintainers.pl
Expand Up @@ -8,14 +8,16 @@

package Maintainers;

use strict;
use warnings;
use utf8;
use File::Glob qw(:case);

# IGNORABLE: files which, if they appear in the root of a CPAN
# distribution, need not appear in core (i.e. core-cpan-diff won't
# complain if it can't find them)

@IGNORABLE = qw(
our @IGNORABLE = qw(
.cvsignore .dualLivedDiffConfig .gitignore .github .perlcriticrc .perltidyrc
.travis.yml ANNOUNCE Announce Artistic AUTHORS BENCHMARK BUGS Build.PL
CHANGELOG ChangeLog Changelog CHANGES Changes CONTRIBUTING CONTRIBUTING.md
Expand Down Expand Up @@ -124,7 +126,7 @@ package Maintainers;
# '' => 'lib/Foo/Bar/',
# }

%Modules = (
our %Modules = (

'Archive::Tar' => {
'DISTRIBUTION' => 'BINGOS/Archive-Tar-2.40.tar.gz',
Expand Down Expand Up @@ -1487,7 +1489,7 @@ package Maintainers;
},
);


our %DistName;
# legacy CPAN flag
for my $mod_name ( keys %Modules ) {
my $data = $Modules{$mod_name};
Expand Down Expand Up @@ -1515,6 +1517,7 @@ package Maintainers;
}
}

our %Maintainers;
# legacy MAINTAINER field
for ( keys %Modules ) {
# Keep any existing MAINTAINER flag so that "overrides" can be applied
Expand Down

0 comments on commit 008ae6a

Please sign in to comment.