in reply to Re: Catching error in DateTime::Format
in thread Catching error in DateTime::Format

OP here. Wow, yes, that was it! I put a "die" in there so I could study this one test while I was working on it. When I removed that, the tests worked as normal. And of course I didn't show the entire test suite in my example here, so I didn't include the "die" at the end of the relevant section.

Thank you so much! I never, ever would have figured that out. (In fact, it would have been even more confusing after I'd removed the "die" to run the complete test suite, and the test started working fine.)

  • Comment on Re^2: Catching error in DateTime::Format

Replies are listed 'Best First'.
Re^3: Catching error in DateTime::Format
by bliako (Abbot) on Oct 28, 2025 at 14:14 UTC

    hehe, die never moves on. Unless you reset $@ with reset('@'); prior to calling die, after your eval.

      Unless you reset...
      But don't do that.