{ my ($exception,$msg); sub throw { ($exception,$msg) = @_; eval { goto "$exception" }; if ($@) { warn "Couldn't find target $exception"; } } sub get_exception { return ($exception,$msg); } } sub test { throw "DONT_CATCH", "...because... Your Mother ..."; throw "ERROR", "...because"; } { test(); last; ERROR: warn "Caught Error..." , get_exception; } #### Couldn't find target DONT_CATCH at d:/Users/lanx/pm/catch_goto.pl line 12. Caught Error...ERROR...because at d:/Users/lanx/pm/catch_goto.pl line 39.