Search results for "module:Perl::Critic::Policy::BuiltinFunctions::ProhibitVoidGrep"

Perl::Critic::Policy::BuiltinFunctions::ProhibitVoidGrep - Don't use grep in void contexts. River stage three • 131 direct dependents • 386 total dependents

"map" and "grep" are intended to be pure functions, not mutators. If you want to iterate with side-effects, then you should use a proper "for" or "foreach" loop. grep{ print frobulate($_) } @list; #not ok print map{ frobulate($_) } @list; #ok grep{ $...

PETDANCE/Perl-Critic-1.144 - 06 Dec 2022 04:59:59 UTC
1 result (0.078 seconds)