Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical

RE: RE: RE: CGI::Carp

by SuperCruncher (Pilgrim)
on Jul 09, 2000 at 01:31 UTC ( #21673=note: print w/ replies, xml ) Need Help??

in reply to RE: RE: CGI::Carp
in thread Reviews Quest

As far as I know, the use warnings pragma was introduced as:

- it is easier for people who are on non 'shebang supporting' systems to use.
- it can be disabled for certain blocks etc. Here's an introduction to the new pragma from the What's new in Perl 5.6 page:

Lexical Warnings

'Death is not good. I reject death. I will stay away from trucks today.' - lwall

The way Perl generates warnings has also been completely revised: as a replacement for the -w flag and the $^W special variable, the warnings pragma gives you more flexibility about what warnings you receive and when. In terms of what, you can now specify warnings by category: there are a bunch of standard categories, such as 'syntax', 'io', 'void', and modules will be able to define their own categories. You can also choose to escalate any categories of warning into a fatal error. As for when, the pragma is lexically scoped, so you can switch it on and off as you wish:

use warnings; $a = @a[1]; # This generates a warning. { no warnings; $a = @a[1]; # This does not. }
See perllexwarn for how to use this from programs and modules.

Comment on RE: RE: RE: CGI::Carp
Download Code

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (10)
As of 2015-11-30 06:10 GMT
Find Nodes?
    Voting Booth?

    What would be the most significant thing to happen if a rope (or wire) tied the Earth and the Moon together?

    Results (758 votes), past polls