develooper Front page | perl.perl5.porters | Postings from February 2011

Re: [ #65284] Module broken with 5.13.x development perl versions

Thread Previous | Thread Next
David Golden
February 1, 2011 15:26
Re: [ #65284] Module broken with 5.13.x development perl versions
Message ID:
On Tue, Feb 1, 2011 at 5:39 PM, Eric Brine <> wrote:
> Of course, it could stop being invasive completely and track which modules
> it attempted to load in a hash instead of setting $VERSION or *VERSION. If
> memory usage is a concern, it could use the hash only when *Module::VERSION
> and $INC{''} don't exist.

I finally did the close read of the source that I should have
done originally and my reaction is "OMFG!".  Fiddling with $VERSION is
an absurd way to flag that a module has been loaded.  Even for inline
packages, it would seem much better to put an artificial entry into
%INC, as that would actually shortcut any subsequent calls to
require() also.

I take back my prior suggestion that a future version of set
$VERSION to 0.  It should not set $VERSION at all and should use an
alternative method to flag what it has loaded (or pretended to load).

I would like to see the existing behavior deprecated for 5.14 and this
fixed in 5.15.

-- David

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