summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorGerard Goossen <gerard@ggoossen.net>2011-08-09 20:35:06 +0200
committerFather Chrysostomos <sprout@cpan.org>2011-08-11 09:07:14 -0700
commiteb796c7f1a47acbd996034731639c1bb76e31a19 (patch)
treece561de43080ad2dc8c9a59d417dbd873faf1b80 /t
parent86a64801a038eae8c8c1c6f0ba6a8b40aeb8fa8d (diff)
downloadperl-eb796c7f1a47acbd996034731639c1bb76e31a19.tar.gz
Move bareword checking from the peephole optimizer to finalize_optree. Fixes [perl #95998]
The bareword checking is moved from the peephole optimizer to finalize_optree. newRANGE needs additional bareword checking because the constants may be optimized away by 'gen_constant_list'. The OPpCONST_STRICT flag is removed after giving an error about a bareword to prevent giving multiple errors about the same bareword.
Diffstat (limited to 't')
-rw-r--r--t/lib/strict/subs2
-rw-r--r--t/op/sigdispatch.t6
2 files changed, 4 insertions, 4 deletions
diff --git a/t/lib/strict/subs b/t/lib/strict/subs
index 394c8d1390..84bf874b25 100644
--- a/t/lib/strict/subs
+++ b/t/lib/strict/subs
@@ -433,7 +433,7 @@ foo:
ret
bar
########
-# TODO infinite loop breaks some strict checking
+# infinite loop breaks some strict checking
use strict 'subs';
sub foo {
1 while 1;
diff --git a/t/op/sigdispatch.t b/t/op/sigdispatch.t
index d36c357fd2..e08e35f3af 100644
--- a/t/op/sigdispatch.t
+++ b/t/op/sigdispatch.t
@@ -50,7 +50,7 @@ SKIP: {
my $gotit = 0;
$SIG{USR1} = sub { $gotit++ };
- kill SIGUSR1, $$;
+ kill 'SIGUSR1', $$;
is $gotit, 0, 'Haven\'t received third signal yet';
my $old = POSIX::SigSet->new();
@@ -58,7 +58,7 @@ SKIP: {
is $gotit, 1, 'Received third signal';
{
- kill SIGUSR1, $$;
+ kill 'SIGUSR1', $$;
local $SIG{USR1} = sub { die "FAIL\n" };
POSIX::sigprocmask(&POSIX::SIG_BLOCK, undef, $old);
ok $old->ismember(&POSIX::SIGUSR1), 'SIGUSR1 is blocked';
@@ -73,7 +73,7 @@ TODO:
}
POSIX::sigprocmask(&POSIX::SIG_BLOCK, $new);
- kill SIGUSR1, $$;
+ kill 'SIGUSR1', $$;
is $gotit, 1, 'Haven\'t received fifth signal yet';
POSIX::sigprocmask(&POSIX::SIG_UNBLOCK, $new, $old);
ok $old->ismember(&POSIX::SIGUSR1), 'SIGUSR1 was still blocked';