summaryrefslogtreecommitdiff
path: root/lib/CGI/Carp.pm
diff options
context:
space:
mode:
authorJarkko Hietaniemi <jhi@iki.fi>2002-01-11 14:51:11 +0000
committerJarkko Hietaniemi <jhi@iki.fi>2002-01-11 14:51:11 +0000
commit3acbd4f53b544ab36759ef8cf0a6fcc4f696a8d0 (patch)
treee424814abda372636cc7c52882d37af15a8a1a89 /lib/CGI/Carp.pm
parentadd55984a417ef0bc7fcde2e3ae7dd9e93bbf85b (diff)
downloadperl-3acbd4f53b544ab36759ef8cf0a6fcc4f696a8d0.tar.gz
Upgrade to CGI.pm 2.79. Manual tweaks were
necessary in form.t and html.t @INC setups. p4raw-id: //depot/perl@14189
Diffstat (limited to 'lib/CGI/Carp.pm')
-rw-r--r--lib/CGI/Carp.pm13
1 files changed, 3 insertions, 10 deletions
diff --git a/lib/CGI/Carp.pm b/lib/CGI/Carp.pm
index 317fdf8553..a3b8b40678 100644
--- a/lib/CGI/Carp.pm
+++ b/lib/CGI/Carp.pm
@@ -217,7 +217,8 @@ CGI::Response
require 5.000;
use Exporter;
-use Carp;
+#use Carp;
+BEGIN { require Carp; }
use File::Spec;
@ISA = qw(Exporter);
@@ -226,7 +227,7 @@ use File::Spec;
$main::SIG{__WARN__}=\&CGI::Carp::warn;
$main::SIG{__DIE__}=\&CGI::Carp::die;
-$CGI::Carp::VERSION = '1.21';
+$CGI::Carp::VERSION = '1.22';
$CGI::Carp::CUSTOM_MSG = undef;
# fancy import routine detects and handles 'errorWrap' specially.
@@ -317,18 +318,10 @@ sub set_message {
return $CGI::Carp::CUSTOM_MSG;
}
-# Avoid generating "subroutine redefined" warnings with the following
-# hack:
-{
- local $^W=0;
- eval <<EOF;
sub confess { CGI::Carp::die Carp::longmess \@_; }
sub croak { CGI::Carp::die Carp::shortmess \@_; }
sub carp { CGI::Carp::warn Carp::shortmess \@_; }
sub cluck { CGI::Carp::warn Carp::longmess \@_; }
-EOF
- ;
-}
# We have to be ready to accept a filehandle as a reference
# or a string.