Skip Menu |

This queue is for tickets about the Module-AutoINC CPAN distribution.

Report information
The Basics
Id: 27760
Status: open
Priority: 0/
Queue: Module-AutoINC

People
Owner: mackenziespamcatcher [...] yahoo.com
Requestors: adrianissott [...] hotmail.com
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 0.02
Fixed in: (no value)



Subject: There's no way of turning the AutoINC off [+fix]
I have a script in which I'd like to run Module::AutoINC at the beginning when I import standard modules. However, I don't want to have it getting in the way during the main body of the script. Currently there doesn't seem a way to do that. How about using providing an unimport subrountine to do this? I.e. something like: sub unimport { my $package = shift; @INC = grep { $_ !~ m|$package| } @INC; }
From: adrianissott [...] hotmail.com
I forgot to mention why this is a good idea :} Basically despite the code needed to resolve the problem is quite easy for someone using the module they need to understand how the module works before they can do so. Basically the module would be better encapsulated if this simple subroutine was provided.
Sounds simple enough. I'll try to get that incorporated sometime soon. On Tue Jun 26 17:31:21 2007, adriani wrote: Show quoted text
> I have a script in which I'd like to run Module::AutoINC at the > beginning when I import standard modules. However, I don't want to have > it getting in the way during the main body of the script. Currently > there doesn't seem a way to do that. > > How about using providing an unimport subrountine to do this? I.e. > something like: > > sub unimport { > my $package = shift; > @INC = grep { $_ !~ m|$package| } @INC; > }