# warn user (from perspective of caller)
carp "string trimmed to 80 chars";
####
use strict;
use warnings;
TEST::first(1); # 4
package TEST;
use Carp qw/carp cluck longmess shortmess/;
sub first {
second(2); # 10
}
sub second {
# local $Carp::Verbose=1;
carp "Carp Second";
cluck "Cluck Second"; # 16
print shortmess("Shortmess Second");
print longmess("Longmess Second");
}
####
Carp Second at d:/Users/lanx/pm/carp.pl line 4.
Cluck Second at d:/Users/lanx/pm/carp.pl line 16.
TEST::second(2) called at d:/Users/lanx/pm/carp.pl line 10
TEST::first(1) called at d:/Users/lanx/pm/carp.pl line 4
Shortmess Second at d:/Users/lanx/pm/carp.pl line 4.
Longmess Second at d:/Users/lanx/pm/carp.pl line 10.
TEST::first(1) called at d:/Users/lanx/pm/carp.pl line 4
####
Shortmess Second at d:/Users/lanx/pm/carp.pl line 17.
TEST::second(2) called at d:/Users/lanx/pm/carp.pl line 10
TEST::first(1) called at d:/Users/lanx/pm/carp.pl line 4
Longmess Second at d:/Users/lanx/pm/carp.pl line 10.
TEST::first(1) called at d:/Users/lanx/pm/carp.pl line 4