Skip Menu |

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: 67159
Status: resolved
Priority: 0/
Queue: Perl-Critic

People
Owner: Nobody in particular
Requestors: aaron [...] priven.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: perl 5.12 package NAME VERSION not understood
Date: Fri, 1 Apr 2011 14:17:23 -0700
To: bug-Perl-Critic [...] rt.cpan.org
From: Aaron Priven <aaron [...] priven.com>
The following: -- #!perl # $Id$ use 5.012; use warnings; package MyPackage 0.001; -- yields this: % perlcritic --verbose 8 packagetest [Modules::RequireVersionVar] No package-scoped "$VERSION" variable found at line 1, column 1. (Severity: 2) [ValuesAndExpressions::ProhibitMagicNumbers] 0.001 is not one of the allowed literal values (-1, 0, 1, 2). Use the Readonly or Const::Fast module or the "constant" pragma instead at line 8, column 19. (Severity: 1) I think these should not show up. Thanks, -- Aaron Priven, aaron@priven.com
On Fri Apr 01 17:17:51 2011, apriven wrote: Show quoted text
> The following: > > -- > #!perl > > # $Id$ > > use 5.012; > use warnings; > > package MyPackage 0.001; > > -- > > yields this: > > % perlcritic --verbose 8 packagetest > [Modules::RequireVersionVar] No package-scoped "$VERSION" variable
found at Show quoted text
> line 1, column 1. (Severity: 2) > [ValuesAndExpressions::ProhibitMagicNumbers] 0.001 is not one of the
allowed Show quoted text
> literal values (-1, 0, 1, 2). Use the Readonly or Const::Fast module
or the Show quoted text
> "constant" pragma instead at line 8, column 19. (Severity: 1) > > I think these should not show up. > > Thanks, >
Thank you for catching this. Changes to both Modules::RequireVersionVar and ValuesAndExpressions::ProhibitMagicNumbers have been committed as SVN revision 4062.