Hi Monks,
I've sought high and low for an answer to my predicament. I am running several scripts on a mod_perl server. Both Carp and CGI::Carp are being loaded. In one of my modules (Petal), code is evaluated inside of a Safe compartment. When calling confess inside of this compartment, I get the following fatal error from CGI::Carp:
Can't locate object method "splitpath" via package "File::Spec" (perhaps you forgot to load "File::Spec"?) at /usr/share/perl/5.6.1/CGI/Carp.pm line 317.I wrote a test that proves this is only an issue with Safe and CGI::Carp (which is the topic for another discussion). For a quick workaround, I was hoping to find a way to tell my code being evaluated to use Carp::confess instead of using CGI::Carp. I can't convince it to do that. Is there a way to tell Perl which module to use for a method that is defined in more than one module?
Thanks!
William
In reply to Mixing Carp and CGI::Carp by knowmad
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |