Skip Menu |

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

Report information
The Basics
Id: 102408
Status: resolved
Priority: 0/
Queue: Perl-Critic-Pulp

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

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



Subject: Uninitialized Warning
This is originally from: https://github.com/Perl-Critic/Perl-Critic/issues/620 --- I get a warning Use of uninitialized value in string eq at /usr/share/perl5/Perl/Critic/Policy/ValuesAndExpressions/ConstantBeforeLt.pm line 114. I have found a minimal test case for this. The minimal input file is not valid Perl code; however, I did see the warning also on input files which were valid Perl. I suggest that perlcritic should not produce the warning even on syntactically badly-formed input. Here's the minimal test case: sub y { Running this through perlcritic --brutal gives the above warning, among other messages.
CC: "Jeffrey Ryan Thalhammer via RT" <bug-Perl-Critic-Pulp [...] rt.cpan.org>
Subject: Re: [rt.cpan.org #102408] Uninitialized Warning
Date: Sat, 28 Feb 2015 17:07:40 +1100
To: Ed Avis <eda [...] waniasset.com>
From: Kevin Ryde <user42_kevin [...] yahoo.com.au>
"Jeffrey Ryan Thalhammer via RT" <bug-Perl-Critic-Pulp@rt.cpan.org> writes: Show quoted text
> > from: https://github.com/Perl-Critic/Perl-Critic/issues/620 > > Use of uninitialized value in string eq at /usr/share/perl5/Perl/Critic/Policy/ValuesAndExpressions/ConstantBeforeLt.pm line 114.
I suspect recent incompatible change to PPI ->prototype(). What version Perl-Critic-Pulp and PPI do you have? If the offending line 114 of ConstantBeforeLt.pm is if ($elem->prototype eq '()') { then it'll be due to PPI 1.220. I wrestled with some forward and backward compatibility, but the break in PPI is too bad. My latest Perl-Critic-Pulp is amended and demands PPI 1.220. -- When Mrs Jones found herself on a boat approaching a beacon set on a craggy windswept island she began to wonder whether she misunderstood the job advertisement for "A little light house keeping".
Yes, this was Perl::Critic::Pulp 83 and PPI 1.220.
Sorry, because I misfiled this bug against Perl::Critic I didn't think to test with a newer Pulp. I guess you can close it as fixed in a newer version.