in reply to carp up two levels

From the Carp.pm source

# The $CarpLevel variable can be set to "strip off" extra caller level +s for # those times when Carp calls are buried inside other functions.

E.g

sub subGit{ carp 'Outta here'; } sub Git{ subGit() } $Carp::CarpLevel = 0; print Git; Outta here main::subGit() called at (eval 5) line 1 main::Git() called at (eval 12) line 1 eval 'print Git ;' called at C:\test\p1.pl line 9 1 $Carp::CarpLevel = 1; print Git; Outta here main::Git() called at (eval 14) line 1 eval 'print Git ;' called at C:\test\p1.pl line 9 1 $Carp::CarpLevel = 2; print Git; Outta here eval 'print Git ;' called at C:\test\p1.pl line 9 1

Examine what is said, not who speaks.
"Efficiency is intelligent laziness." -David Dunham
"When I'm working on a problem, I never think about beauty. I think only how to solve the problem. But when I have finished, if the solution is not beautiful, I know it is wrong." -Richard Buckminster Fuller