package Carp;
+our $VERSION = '1.00';
+
=head1 NAME
carp - warn of errors (from perspective of caller)
$MaxArgNums = 8; # How many arguments to print. 0 = all.
$Verbose = 0; # If true then make shortmess call longmess instead
+$CarpInternal{Carp}++;
+
require Exporter;
@ISA = ('Exporter');
@EXPORT = qw(confess croak carp);
# each function call on the stack.
sub longmess {
- require Carp::Heavy;
+ { local $@; require Carp::Heavy; } # XXX fix require to not clear $@?
goto &longmess_heavy;
}
# you always get a stack trace
sub shortmess { # Short-circuit &longmess if called via multiple packages
- require Carp::Heavy;
+ { local $@; require Carp::Heavy; } # XXX fix require to not clear $@?
goto &shortmess_heavy;
}