in reply to How Do I Get the Line Number In My Error Message?
#!/perl -w use Carp; a_test_sub(); sub a_test_sub { confess("uh oh"); } __OUTPUT__ uh oh at test.pl line 7 main::a_test_sub() called at test.pl line 4 [download]