in reply to 'use' inside or outside of package declaration?
I treat the use strict; and use warnings; declarations as a way to document the beginning of the actual code. I therefore put them immediately after all my other use statements and obviously after the package statement as well.
use MyTest qw(mysub); use strict; use warnings; my $foo = 'bar'; mysub($foo);
This serves no purpose. The code would work the same if the strictures requirement was placed sooner.
I believe sometimes people put them later because they are lazy about their @EXPORT declarations, and don't always use our.
|
|---|