Nick Tonkin wrote:
On Thu, 20 Feb 2003, Stas Bekman wrote:


Nick Tonkin wrote:

Is it possible to combine the recommended syntax:

use warnings FATAL => 'all', NONFATAL => 'redefine';

with the ability to turn warnings on in httpd.conf with PerlSwitches -w?
-w is the same as:

  use warnings 'all';

then you can override things in your code using the warnings pragma.

Though I should add a note that NONFATAL was introduced only in 5.8, so you
probably don't want to use it.

I think that is already clear in the docs at
http://perl.apache.org/docs/2.0/user/coding/coding.html#Auto_Reloading_Modified_Modules_with_Apache__Reload
I've added a warning, just in case. and removed the use of NONFATAL in examples, so people won't copy-n-paste it.

I just wanted to know if it was possible to get the same effect somehow
using PerlSwitches in httpd.conf -- I guess not.

If I put the 'use warnings;' pragma in startup.pl it will be server-wide,
though, won't it?
no. all pragmas have work without a scope they are defined in.

That's why you should use '-w' in httpd.conf



__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

Reply via email to