summaryrefslogtreecommitdiff
path: root/t/re/subst.t
diff options
context:
space:
mode:
Diffstat (limited to 't/re/subst.t')
-rw-r--r--t/re/subst.t13
1 files changed, 11 insertions, 2 deletions
diff --git a/t/re/subst.t b/t/re/subst.t
index 8fa649dee2..16590b7ee3 100644
--- a/t/re/subst.t
+++ b/t/re/subst.t
@@ -7,7 +7,7 @@ BEGIN {
}
require './test.pl';
-plan( tests => 189 );
+plan( tests => 190 );
$_ = 'david';
$a = s/david/rules/r;
@@ -798,4 +798,13 @@ is(*bam =~ s/\*//rg, 'main::bam', 'Can s///rg a tyepglob');
tie my $kror, cowBug =>;
$kror =~ s/(?:)/""/e;
}
-pass("s/// on tied var returning a cow")
+pass("s/// on tied var returning a cow");
+
+# a test for 6502e08109cd003b2cdf39bc94ef35e52203240b
+# previously this would segfault
+
+{
+ my $s = "abc";
+ eval { $s =~ s/(.)/die/e; };
+ like($@, qr/Died at/, "s//die/e");
+}