summaryrefslogtreecommitdiff
path: root/t/op/gv.t
diff options
context:
space:
mode:
Diffstat (limited to 't/op/gv.t')
-rw-r--r--t/op/gv.t10
1 files changed, 10 insertions, 0 deletions
diff --git a/t/op/gv.t b/t/op/gv.t
index 0cb0d3985e..cbbb26b6ba 100644
--- a/t/op/gv.t
+++ b/t/op/gv.t
@@ -930,6 +930,16 @@ package lrcg {
'constants w/nulls in their names point 2 the right GVs when promoted';
}
+# Look away, please.
+# This violates perl's internal structures by fiddling with stashes in a
+# way that should never happen, but perl should not start trying to free
+# unallocated memory as a result. There is no ok() or is() because the
+# panic that used to occur only occurred during global destruction, and
+# only with PERL_DESTRUCT_LEVEL=2. (The panic itself was sufficient for
+# the harness to consider this test script to have failed.)
+$::{aoeuaoeuaoeaoeu} = __PACKAGE__; # cow
+() = *{"aoeuaoeuaoeaoeu"};
+
__END__
Perl
Rules