in reply to Re: Entering and exiting subs in style
in thread Entering and exiting subs in style

Thanks, monks, for the thorough replies--very helpful. One thing I heard was "die" vs "exit." I have always associated "die" with errors related to internal operations, such as file handling, etc. So, I checked with perldocs on the issue of exit and found this concurring advice:
Don't use exit to abort a subroutine if there's any chance that someone might want to trap whatever error happened. Use die instead, which can be trapped by an eval.
So, better to "die" than just "exit." Sounds a bit too final ;^) but I'll defer to this advice.

—Brad
"A little yeast leavens the whole dough."
  • Comment on Re: Re: Entering and exiting subs in style