Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Perl-Critic CPAN distribution.

Report information
The Basics
Id:
46727
Status:
new
Priority:
Low/Low
Queue:

People
Owner:
Nobody in particular
Requestors:
EDAVIS [...] cpan.org
Cc:
AdminCc:

BugTracker
Severity:
Unimportant
Broken in:
1.098
Fixed in:
(no value)



Subject: RequireLocalizedPunctuationVars should not want to localize in top-level scope
Variables::RequireLocalizedPunctuationVars embodies page 81 of PBP, which suggests using 'local' on a punctuation variable before changing it, so that the change has as small a scope as possible. This is normally sound advice, but it does not make sense to 'local' at the top-level scope of the program. In short scripts you often might set $ENV{PATH} or other environment variables at the top-level scope. Since the top-level scope is never exited, the previous value of the variable will never be restored, and so adding 'local' to the assignment statement has no effect. The rule should have an exception for the top-level scope.


This service runs on Request Tracker, is sponsored by The Perl Foundation, and maintained by Best Practical Solutions.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.