libperl-critic-policy-plicease-prohibitarrayassignaref-perl

Perl::Critic policy about not assigning an anonymous arrayref to an array

Description

The Perl::Critic::Policy::Plicease::ProhibitArrayAssignAref policy is a fork of Perl::Critic::Policy::ValuesAndExpressions::ProhibitArrayAssignAref. It differs from the original by not having a dependency on List::MoreUtils.

It asks you not to assign an anonymous arrayref to an array

 @array = [ 1, 2, 3 ]; # bad

The idea is that it's rather unclear whether an arrayref is intended, or might have meant to be a list like

 @array = ( 1, 2, 3 );

Upload more screenshots

Please help extend the collection of screenshots. Just make a screenshot and upload it here. You don't need to register or anything.

Upload a screenshot

Hint: upload an image here from your clipboard with Ctrl-V


Homepage

https://metacpan.org/release/Perl-Critic-Policy-Plicease-ProhibitArrayAssignAref


Install this software package

If the package is available for the distribution you are currently using on your computer then install the software by clicking on…

Install libperl-critic-policy-plicease-prohibitarrayassignaref-perl