in reply to Re: canonical doc explaing need for "eval { ... } or do {...}" construct
in thread canonical doc explaing need for "eval { ... } or do {...}" construct
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
(addicted to the Perl Programming Language :)
Wikisyntax for the Monastery
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: canonical doc explaing need for "eval { ... } or do {...}" construct
by hippo (Archbishop) on May 13, 2022 at 09:02 UTC | |
|
Re^3: canonical doc explaing need for "eval { ... } or do {...}" construct
by ikegami (Patriarch) on May 12, 2022 at 14:40 UTC | |
by LanX (Saint) on May 12, 2022 at 15:03 UTC | |
by ikegami (Patriarch) on May 13, 2022 at 05:19 UTC | |
by LanX (Saint) on May 13, 2022 at 06:20 UTC | |
by ikegami (Patriarch) on May 13, 2022 at 17:31 UTC | |
|