eval { potentially_fatal_function_call(); } if ($@) { print "Fatal Error: $@"; # ... whatever other appropriate error recovery }