|
|
Choosing A Webhost: |
Re: [Fwd: Apache::Reload Module]: msg#00140apache.mod-perl.devel
Hi Stas, Stas Bekman wrote: Steve Hay wrote: It actually overkills it with "no warnings FATAL => 'all';", but this is irrelevant anyway -- "use warnings" / "no warnings" are lexically scoped. The line "require $file" doesn't generate any warnings within that lexical scope, so turning warnings off there doesn't achieve anything. The "redefine" warnings come from the lexical scope of the file that it being reloaded.
This is what all of my modules do, at least while under development -- which is also the scenario in which I want to make use of Apache::Reload! I don't see this as a "problem" of my module -- it's what I always do, and is recommended by various venerable sources. Simple replace it with: Yes, of course, this works for me, but I don't want to turn any warnings off. Supposing my module accidentally does redefine a subroutine? Maybe I'm mucking about with two different versions of a subroutine, and have accidentally left them both active. I'd like to know about that! It also wouldn't work for anyone running under "perl -W", which overrides all other means of disabling warnings. I would therefore prefer to have an explicit symbols undef done. I don't necessarily want an *option* for it, though -- I'd be happy if it *always* did that. Would you ever want to see those redefine warnings? If so, then maybe have an "UndefOnReload" option that defaults to "On", and users can turn it "Off" if they wish -- like your "ReloadConstantRedefineWarnings" option. (Presumably you would consolidate both of these things into one single option.) Steve
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Re: [Fwd: Apache::Reload Module], Steve Hay |
|---|---|
| Next by Date: | Re: [Fwd: Apache::Reload Module], Steve Hay |
| Previous by Thread: | Re: [Fwd: Apache::Reload Module], Stas Bekman |
| Next by Thread: | Re: [Fwd: Apache::Reload Module], Stas Bekman |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
Free MagazinesCisco NewsReceive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business. subscribe Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field. subscribe The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business. subscribe Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company. subscribe Total Telecom Total Telecom is "The Economist of the communications industry". subscribe |