They don’t get along.
As of the recent 1.07 release, Perl::Critic
, has started using Readonly
to be more more self-compliant with Perl Best Practices. We had been avoiding use of constant
for the reasons described in the book, but had not been willing to add the Readonly
dependency until now.
The Perl::Critic
coding standard has been to use sigils for subroutines in @EXPORT_OK
, etc. and import lists, but Exporter
treats them as optional. And, in fact, there’s code that strips them off (line 47 in v5.58). I haven’t figured out the commonality, but in a few environments, this fails spectacularly. Once we removed the subroutine sigils from everywhere, the problems have gone.
Explicitness: 0, Keyboard laziness: 1.
This post originally appeared at use.perl.org.