On Sun, Jun 26, 2005 at 08:36:56PM -0700, chromatic wrote:
> Even easier (especially on the eyes):
> 
>       DynaLoader::bootstrap( 'Storable', $VERSION );

On Sun, Jun 26, 2005 at 08:36:39PM -0700, Yitzchak Scott-Thoennes wrote:
> AIUI the only time it needs to be ISA DynaLoader is during the
> bootstrap call.

Please observe the dire warning layed out in my sig below.

DynaLoader is documented as needing to be inherited from.  You screw with
that you flirt with breakage just to avoid writing one line of code.

There is the odd and largely unused bootstrap_inherit() function which
does the local @ISA thing.  Its undocumented and the only thing which uses
it is XSLoader [1] which does all sorts of incestuous things with DynaLoader 
so its techniques cannot be trusted.

List::Util does the local @ISA thing.  It, too, flirts with doom.

It would be great if DynaLoader did not need to be inherited from, this would
avoid all sorts of niggling little problems like accidental AutoLoader
inherited.  I can imagine that's the inspiration for local @ISA.  But that's 
a separate issue from patching up Storable to use XSLoader.  And anyway,
isn't that what XSLoader was made for in the first place?

Finally, the hacks in this patch are to avoid a dependency on XSLoader which
is currently not available from CPAN.  However, some time ago I released an
alpha of XSLoader to CPAN:

http://search.cpan.org/dist/XSLoader/
http://svn.schwern.org/svn/CPAN/XSLoader/

under the cavet that I cannot maintain it as I really don't understand it.
Its there for anyone who wants to pick up the baton and run.  The job is
really just integrating changes from bleadperl, releasing a CPAN version and
trying to keep it something like backwards compatible.  Take it over and 
release a stable version and all this messing with DynaLoader goes away.


[1]  wince/makedist.pl parrots the function but does not appear to use it


-- 
Michael G Schwern     [EMAIL PROTECTED]     http://www.pobox.com/~schwern
You are wicked and wrong to have broken inside and peeked at the
implementation and then relied upon it.
        -- tchrist in <[EMAIL PROTECTED]>

Reply via email to