Grinnz / Perl-Critic-Community

Perl::Critic::Community - Community-inspired Perl::Critic policies
https://metacpan.org/pod/Perl::Critic::Community
Other
8 stars 10 forks source link

Constant interpolation triggers false DeprecatedFeatures positive #52

Open scop opened 3 months ago

scop commented 3 months ago
use constant CONSTANT => "foo";
my ($foo) = "foobar" =~ /(${\CONSTANT})/;

...yields

test.pl:2:25: /\C/ is deprecated. Use of the \C character class in regular expressions is deprecated in perl v5.20.0. To examine a string's UTF-8-encoded byte representation, encode it to UTF-8. [Community::DeprecatedFeatures]