Subject: | Try::Tiny has an unfavorable interaction with given-when |
I don't know what the fix is, but this program does not work as I expect. I would expect the
output to be "bad stuff at try.pl line 12" but...
#!/usr/bin/perl
use 5.10.1;
use strict;
use warnings;
use Try::Tiny;
my $x = "neither here nor there";
given ($x) {
when ("neither here nor there") {
try {
die "bad stuff";
say "good stuff";
}
catch {
say $_;
};
}
}
# This program outputs:
#
# neither here nor there