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

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

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



Subject: String *may* require interpolation (false positive)
String *may* require interpolation at line 6, column 12. See page 51 of PBP. String *may* require interpolation at line 6, column 50. See page 51 of PBP. 1 #!/usr/bin/perl 2 use strict; 3 4 my $sign = "(C)"; 5 my $yyy = "2010"; 6 my $re = '(?:(?i)Copyright):?[ \t]+' . $sign . '[ \t]+' . $yyyy; Nothing to "may" here.
Subject: Re: [rt.cpan.org #56632] String *may* require interpolation (false positive)
Date: Thu, 15 Apr 2010 08:12:29 -0500
To: bug-Perl-Critic [...] rt.cpan.org
From: Elliot Shank <perl [...] galumph.com>
On 4/15/10 6:53 AM, Jari Aalto via RT wrote: Show quoted text
> String *may* require interpolation at line 6, column 12. See page 51 of > PBP. > String *may* require interpolation at line 6, column 50. See page 51 of > PBP. > 1 #!/usr/bin/perl > 2 use strict; > 3 > 4 my $sign = "(C)"; > 5 my $yyy = "2010"; > 6 my $re = '(?:(?i)Copyright):?[ \t]+' . $sign . '[ \t]+' . > $yyyy; > > Nothing to "may" here.
Yes, may: you've got \t inside single quotes.
On Thu Apr 15 09:12:44 2010, clonezone wrote: Show quoted text
> On 4/15/10 6:53 AM, Jari Aalto via RT wrote:
> > String *may* require interpolation at line 6, column 12. See page
51 of Show quoted text
> > PBP. > > String *may* require interpolation at line 6, column 50. See page
51 of Show quoted text
> > PBP. > > 1 #!/usr/bin/perl > > 2 use strict; > > 3 > > 4 my $sign = "(C)"; > > 5 my $yyy = "2010"; > > 6 my $re = '(?:(?i)Copyright):?[ \t]+' . $sign .
'[ \t]+' . Show quoted text
> > $yyyy; > > > > Nothing to "may" here.
> > Yes, may: you've got \t inside single quotes.
Naturally, because that is the ascii table's TAB character. Needed to express whitespace where regexp code \s isn't suitable. Perhaps the Perl::Critic could be more intelligent when checking standard the ASCII escape codes (the regexp codes are different thing).
Subject: Re: [rt.cpan.org #56632] String *may* require interpolation (false positive)
Date: Wed, 21 Apr 2010 20:12:43 -0500
To: bug-Perl-Critic [...] rt.cpan.org
From: Elliot Shank <perl [...] galumph.com>
On 4/15/10 10:59 AM, Jari Aalto via RT wrote: Show quoted text
> Perhaps the Perl::Critic could be more intelligent when checking > standard the ASCII escape codes (the regexp codes are different thing).
All Perl::Critic knows is that there's a non-interpolated string with something that looks like it might have been intended to be interpolated. What you're discussing involves flow analysis, which Perl::Critic is not capable of.