On Fri, Sep 23, 2005 at 04:03:32PM -0700, Jan Dubois wrote:
> > Ok, thanks. I'll let you know if I get any tuits to work on it
> > before then.
> 
> Maybe I'm missing something, but wouldn't it make sense to use
> Module::ScanDeps for this and put any additional heuristics in
> there?

Module::ScanDeps isn't pluggable, either.  In fact, none of the dep scanners
I've come across are. 

Some of the heuristics I need are general purpose, some are specific to my
company's code.  But they fall into two categories:

*  A module which loads another named module.  base.pm and aliased.pm are 
   examples.  For these your dep scanner needs to know the syntax of the
   loading module.  Sometime of these are on CPAN and thus of general use,
   some are not.

        use base 'Foo::Bar';

        use aliased 'Foo::Bar';

        use aliased;
        my $Customer = alias 'My::Company::Customer';


*  Loading of modules on demand, such as Class::Autouse's superloader.
   In this case your dep scanner has to find class method calls and infer
   module use from that.

        use Class::Autouse qw(:superloader);

        print CGI->b("Wow!");


-- 
Michael G Schwern     [EMAIL PROTECTED]     http://www.pobox.com/~schwern
Life is like a sewer - what you get out of it depends on what you put into it.
    - Tom Lehrer

Reply via email to