castaway has asked for the wisdom of the Perl Monks concerning the following question:
After some playing around I came up with the following:
Load module using:
Reload module using:$modname = "Blah::Module"; eval "require $modname";
(To ignore the 'Subrouting redefined' warnings)delete $INC{'Blah/Module.pm'}; eval "no warnings; require $modname";
Anyone have any comments or better ideas?
Casty
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Reloading changed modules
by larsen (Parson) on Dec 21, 2002 at 17:19 UTC | |
by castaway (Parson) on Dec 21, 2002 at 17:41 UTC | |
by grantm (Parson) on Dec 21, 2002 at 18:48 UTC | |
by castaway (Parson) on Dec 21, 2002 at 19:40 UTC | |
by castaway (Parson) on Dec 21, 2002 at 19:58 UTC | |
by castaway (Parson) on Dec 21, 2002 at 18:55 UTC | |
by demerphq (Chancellor) on Dec 21, 2002 at 20:42 UTC | |
|
Re: Reloading changed modules
by gjb (Vicar) on Dec 21, 2002 at 23:29 UTC |