Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re^7: RFC: Tutorial: use strict; now what!?

by chromatic (Archbishop)
on Feb 08, 2012 at 19:38 UTC ( [id://952564]=note: print w/replies, xml ) Need Help??


in reply to Re^6: RFC: Tutorial: use strict; now what!?
in thread RFC: Tutorial: use strict; now what!?

Which do you prefer?

The version which respects encapsulation boundaries, of course.

With "use warnings", you would see nothing; with "-w", you would get a message.

Nope; my logging module uses warnings and reports only what's relevant.

Replies are listed 'Best First'.
Re^8: RFC: Tutorial: use strict; now what!?
by educated_foo (Vicar) on Feb 08, 2012 at 19:44 UTC
    Okay, let's say you want to log undef as an empty string. Tragically, your "encapsulation boundaries" make this impossible. Oh, well.

      What in the world are you talking about?

      How do you know the logging module doesn't itself use warnings? How do you know the logging module does anything which would produce the "use of uninitialized value" warning? How do you know the logging module doesn't explicitly deal with the undef case? How do you know the logging module doesn't localize $^W? How do you know the logging module's API doesn't document exactly what it does and why?

      It's exceedingly silly to debate the nuances of imaginary code you haven't seen. (People who've studied logic tend to call that a strawman argument.)

      ... whereas anyone with a Perl 5 released in the past decade-plus can demonstrate the difference between -w and use warnings; as it relates to the use of and warnings reported from modules.

      A reply falls below the community's threshold of quality. You may see it by logging in.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others avoiding work at the Monastery: (7)
As of 2024-04-23 20:14 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found