P is for Practical | |
PerlMonks |
Re: Template to create modulesby choroba (Cardinal) |
on Jun 14, 2016 at 15:45 UTC ( [id://1165606]=note: print w/replies, xml ) | Need Help?? |
It depends on what you want to do with the module. diagnostics is for newbies only, it probably shouldn't stay in the module once published. Carp is nice, but not always desirable, so add it only if needed. The second template misses strict and warnings, and its way of using Exporter is clunky. I'd use something like the following instead:
Also note that the module doesn't need Exporter if it's object oriented.
In Section
Seekers of Perl Wisdom
|
|