Silence perl critic
authorAndrew Dunstan <andrew@dunslane.net>
Sat, 15 Mar 2025 21:41:54 +0000 (17:41 -0400)
committerAndrew Dunstan <andrew@dunslane.net>
Sat, 15 Mar 2025 21:41:54 +0000 (17:41 -0400)
Commit 27bdec06841 uses a loop variable that is not strictly local to
the loop. Perlcritic disapproves, and there's really no reason as the
variable is not used outside the loop.

Per buildfarm animals koel and crake.

src/common/unicode/generate-unicode_case_table.pl

index 3c2edc7ca4de04429945c753c7f96a95eae2b027..ddd0980719b7c79690cb21d6ddfc2a934341b1e5 100644 (file)
@@ -619,7 +619,7 @@ sub branch
 sub make_ranges
 {
    my ($nums, $limit) = @_;
-   my ($prev, $start, $curr, $total, @sorted, @range);
+   my ($prev, $start, $total, @sorted, @range);
 
    @sorted = sort { $a <=> $b } @$nums;
 
@@ -635,7 +635,7 @@ sub make_ranges
    # append final 'undef' to signal final iteration
    push @sorted, undef;
 
-   foreach $curr (@sorted)
+   foreach my $curr (@sorted)
    {
        # if last iteration always append the range
        if (!defined($curr) || ($curr - $prev > $limit))