laziness, impatience, and hubris | |
PerlMonks |
Re^2: use strict without typing use strict?by LanX (Saint) |
on May 26, 2021 at 09:15 UTC ( [id://11133045]=note: print w/replies, xml ) | Need Help?? |
Well in theory he could set the environment with PERL5OPT=-Mstrict or manipulate sitecustomize.pl (see perlrun for details) ...
... but I would hate the side effect of random errors, if the script was accidentally run in another environment and strict was missing. The safest would be to alias/link perl to a new name like superl - the "super language" ;) - which auto-defaults to strict. Like this superl script.pl would simply not run if the workaround was missing.
Cheers Rolf PS: On a side-note: The whole Perl7 mess could be solved like this too! (The language needs a rebranding anyway to overcome the mobbing. Don't shoot the messenger...:)
In Section
Seekers of Perl Wisdom
|
|