perl-modperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erik Aronesty <>
Subject Re: lexical scoping under mod perl solution
Date Thu, 12 Feb 2009 19:30:21 GMT
>> (A solution would be to force all "my" varialbes at the file scope to
>> be "our" and then put the cgi in an anonymous package:)
> A file/package-scoped "my" var is not the same thing as an "our" var. One
> example is that a "my" var can't be seen outside of the package/scope it's
> in. A package level "our" var can be seen.

Yes, I know.  Hence the anonymous, unnamed package idea.

But it's really silly.  Better warnings or more clear docs would be sufficient.

Just the concept that a top-level $my isn't good enough to localize a
variable seems to boggle until you realize what ::Registry is doing.

View raw message