develooper Front page | perl.perl5.porters | Postings from March 2000

Re: [PATCH 5.6.0-RC1] more warnings tidy ups

Thread Previous | Thread Next
March 15, 2000 08:48
Re: [PATCH 5.6.0-RC1] more warnings tidy ups
Message ID:
In <>, writes:
:> Isn't this somewhat equivalent to the '-w on by default' scenario?
:I don't know how much you know about the warnings pragma, so forgive me if
:I'm telling you something you already know.
:The BIG difference between having a "use warnings" and "-w" is that the
:former will be limited to the scope of the new module only, while "-w"
:switches warnings on everywhere. That means that anyone developing a new
:module (in this case, using the skeleton that h2xs creates) can safely
:enable warnings in their module without having to worry about the warnings
:setting of modules that they make use of or code that will call their

This much I understand. However, if we were to have 'use warnings' by
default everywhere it would be essentially the same as having -w on by
default. Let me ask a different way: why are the .pm files generated by
h2xs special enough to have 'use warnings' by default, when nothing
else has that?

To repeat, I'm not suggesting this is necessarily a bad idea; I just
don't understand the rationale.


Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About