summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--t/re/regexp_unicode_prop.t10
1 files changed, 6 insertions, 4 deletions
diff --git a/t/re/regexp_unicode_prop.t b/t/re/regexp_unicode_prop.t
index 54a2e7e94a..a36afdfc50 100644
--- a/t/re/regexp_unicode_prop.t
+++ b/t/re/regexp_unicode_prop.t
@@ -202,13 +202,15 @@ sub match {
}
undef $@;
- my $match_pat = eval "qr/$match/$caseless";
- is($@, '', "$name compiled correctly to a regexp");
+ my $pat = "qr/$match/$caseless";
+ my $match_pat = eval $pat;
+ is($@, '', "$pat compiled correctly to a regexp: $@");
like($str, $match_pat, "$name correctly matched");
undef $@;
- my $nomatch_pat = eval "qr/$nomatch/$caseless";
- is($@, '', "$name compiled correctly to a regexp");
+ $pat = "qr/$nomatch/$caseless";
+ my $nomatch_pat = eval $pat;
+ is($@, '', "$pat compiled correctly to a regexp: $@");
unlike($str, $nomatch_pat, "$name correctly did not match");
}