CC: | perl5-porters [...] perl.org, bug-AutoLoader [...] rt.cpan.org |
Subject: | Re: AutoLoader slowness in "can" |
Date: | Thu, 29 Nov 2007 09:50:38 -0600 |
To: | Steffen Mueller <l2ot9pa02 [...] sneakemail.com> |
From: | Graham Barr <gbarr [...] pobox.com> |
On Nov 29, 2007, at 7:05 AM, Steffen Mueller wrote:
Show quoted text
AutoLoader was originally written to load sub from files created by
AutoSplit. The intention was the AutoSplit was used to create the
file. The path name created and search for in AutoLoader is the same
as that created by AutoSplit. When the AutoLoader module is "use"d it
looks for a file autosplit.ix, which has stubs created by AutoSplit.
So I do not see why AutoLoader is trying to support a case where
stubs do not exist when its design was always that AutoSplit would
place those stubs in the index file that AutoLoader loads
Show quoted text
>> IMO, AutoLoader::can should just be removed all together.
>
> Along with all tests that assume AutoLoader::can works without a
> sub stub?
>
> Just to make sure: Do I understand you correctly in that you are
> saying
> AutoLoader should not try to work if there are no sub stubs in the
> user
> code (generated by AutoSplit or by hand)?
> I would assume that this breaks quite some code, no?
If AutoLoader/AutoSplit has been used as intended then no it should not.
Also, as I wrote in a separate message to you. As AutoLoader and
AutoSplit are designed to work together. I belive that AutoSplit
should be dual-lifed along with AutoLoader in the same distribution
on CPAN.
Graham.