In praise of Try::Tiny
Try::Tiny is one of those tools that feels like it should always be in your toolbox. Handling exceptions in Perl is awkward; Java, JavaScript, Python, and Objective-C all provide native try syntax. Perl does, mostly, via eval {} blocks, but it's hinky. Errors coming out of the block aren't local by default, and it's almost a dozen lines of boilerplate to add it properly.
Enter Try::Tiny:
use Try::Tiny;
my $foo;
my $output;
try {
$output = $foo->plover() || DEFAULT_PLOVER…