in reply to Re: How do I detect what modules are not being used?
in thread How do I detect what modules are not being used?
I assume you are thinking that if I do:
Then you will be able to tell if I have actually used that module? A huge portion of modules are not OO and export functions that do not need the module name to be invoked. Additionally, the module may be exporting constants.use CGI; my $q = CGI->new();
The best this method can do is attempt to confirm actual use. Even then it is subject to break since the module name may appear in comments or code as false positive. Even reducing the comments and POD with perl -MO=Deparse will not be fool proof. Your method will not be a good indicator of modules not actually being used and will be a poor indicator of modules that are being used.
Cheers - L~R
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: How do I detect what modules are not being used?
by adamk (Chaplain) on Apr 08, 2005 at 02:44 UTC |