Pathologically Eclectic Rubbish Lister | |
PerlMonks |
Re^2: canonical doc explaing need for "eval { ... } or do {...}" constructby LanX (Saint) |
on May 12, 2022 at 13:29 UTC ( [id://11143833]=note: print w/replies, xml ) | Need Help?? |
Thank you all! :) I think the overall best solution is to mention Try::Tiny in the perldocs. eval { ...; 1 } or do {...} might be a good solution if you hate dependencies and want backwards compatibility. But it's just too much boilerplate to keep in mind. Me too, I forgot about the ;1 part when starting this thread. But I'm worried about compatibility issues with Try::Tiny and the new try feature in 5.36.
Cheers Rolf
In Section
Seekers of Perl Wisdom
|
|