]> git.vpit.fr Git - perl/modules/indirect.git/commitdiff
Cover ck_scope actually handling an OP_SCOPE
authorVincent Pit <vince@profvince.com>
Tue, 14 Jul 2009 16:44:15 +0000 (18:44 +0200)
committerVincent Pit <vince@profvince.com>
Tue, 14 Jul 2009 16:44:15 +0000 (18:44 +0200)
This never happens unless taint mode is off.

MANIFEST
t/23-bad-notaint.t [new file with mode: 0644]

index 4088973161c7eb51847f7d971491815ac544ee04..cab1db467fe424c41ffbe7680c3d80d00b8c2bb5 100644 (file)
--- a/MANIFEST
+++ b/MANIFEST
@@ -13,6 +13,7 @@ t/11-line.t
 t/20-good.t
 t/21-bad.t
 t/22-bad-mixed.t
+t/23-bad-notaint.t
 t/30-scope.t
 t/40-threads.t
 t/41-memory.t
diff --git a/t/23-bad-notaint.t b/t/23-bad-notaint.t
new file mode 100644 (file)
index 0000000..cb7580b
--- /dev/null
@@ -0,0 +1,15 @@
+#!perl
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+{
+ my @warns;
+ {
+  no indirect hook => sub { push @warns, \@_ };
+  eval { meh { } };
+ }
+ is_deeply \@warns, [ [ '{', 'meh', $0, __LINE__-2 ] ], 'covering OP_CONST';
+}