Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: Who is turning $^W on?

by Aighearach (Initiate)
on Nov 08, 2004 at 16:02 UTC ( [id://406093]=note: print w/replies, xml ) Need Help??


in reply to Who is turning $^W on?

If you take a look at perldoc perllexwarn you'll find that the warnings pragma is not exactly the same as setting $^W. In particular, the pragma is scoped to the enclosing block. So if $^W is getting set, you can be pretty sure that you need to search for an actual $^W assignment, and not a use warnings pragma.

You could use the perl debugger to find the offender. Or just grep your files and modules you use for $^W.

Also note that, if you don't need pre-5.6.0 compatability, then look at perldoc warnings and in particular warnings::register() which provides a good way of turning on and off your own warnings, giving finer control to the user of your module.


--
Snazzy tagline here

Log In?
Username:
Password:

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

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

    No recent polls found