summaryrefslogtreecommitdiff
path: root/gnu/usr.bin/perl/t
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/usr.bin/perl/t')
-rw-r--r--gnu/usr.bin/perl/t/op/runlevel.t15
1 files changed, 15 insertions, 0 deletions
diff --git a/gnu/usr.bin/perl/t/op/runlevel.t b/gnu/usr.bin/perl/t/op/runlevel.t
index e988ad9362a..3865e52070d 100644
--- a/gnu/usr.bin/perl/t/op/runlevel.t
+++ b/gnu/usr.bin/perl/t/op/runlevel.t
@@ -349,3 +349,18 @@ A 1
bar
B 2
bar
+########
+sub n { 0 }
+sub f { my $x = shift; d(); }
+f(n());
+f();
+
+sub d {
+ my $i = 0; my @a;
+ while (do { { package DB; @a = caller($i++) } } ) {
+ @a = @DB::args;
+ for (@a) { print "$_\n"; $_ = '' }
+ }
+}
+EXPECT
+0