Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re^3: How should I manage CPAN when using two versions of Perl in my computer?

by atcroft (Abbot)
on Jun 25, 2018 at 20:05 UTC ( [id://1217389]=note: print w/replies, xml ) Need Help??


in reply to Re^2: How should I manage CPAN when using two versions of Perl in my computer?
in thread How should I manage CPAN when using two versions of Perl in my computer?

Regarding the "shebang anomaly", perlrun indicates that:

  • -w
    prints warnings about dubious constructs, such as variable names mentioned only once and scalar variables used before being set; redefined subroutines; references to undefined filehandles; filehandles opened read-only that you are attempting to write on; values used as a number that don't look like numbers; using an array as though it were a scalar; if your subroutines recurse more than 100 deep; and innumerable other things.
    This switch really just enables the global $^W variable; normally, the lexically scoped use warnings pragma is preferred. You can disable or promote into fatal errors specific warnings using __WARN__ hooks, as described in perlvar and warn. See also perldiag and perltrap. A fine-grained warning facility is also available if you want to manipulate entire classes of warnings; see warnings.

I would think if you update the script to use warnings you should be okay in removing the '-w' from the shebang line (although if I am wrong, please respond, so I can learn from the mistake!).

Hope that helps.

  • Comment on Re^3: How should I manage CPAN when using two versions of Perl in my computer?
  • Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1217389]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others contemplating the Monastery: (3)
As of 2024-04-23 22:51 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found