summaryrefslogtreecommitdiff
path: root/t/pragma/warn/pp_hot
diff options
context:
space:
mode:
Diffstat (limited to 't/pragma/warn/pp_hot')
-rw-r--r--t/pragma/warn/pp_hot40
1 files changed, 20 insertions, 20 deletions
diff --git a/t/pragma/warn/pp_hot b/t/pragma/warn/pp_hot
index 208bf26b15..2a52dfb2df 100644
--- a/t/pragma/warn/pp_hot
+++ b/t/pragma/warn/pp_hot
@@ -35,16 +35,16 @@
__END__
# pp_hot.c
-use warning 'unopened' ;
+use warnings 'unopened' ;
$f = $a = "abc" ;
print $f $a;
-no warning 'unopened' ;
+no warnings 'unopened' ;
print $f $a;
EXPECT
Filehandle main::abc never opened at - line 4.
########
# pp_hot.c
-use warning 'io' ;
+use warnings 'io' ;
print STDIN "anc";
print <STDOUT>;
print <STDERR>;
@@ -52,7 +52,7 @@ open(FOO, ">&STDOUT") and print <FOO>;
print getc(STDERR);
print getc(FOO);
read(FOO,$_,1);
-no warning 'io' ;
+no warnings 'io' ;
print STDIN "anc";
####################################################################
# N O T E #
@@ -70,58 +70,58 @@ Filehandle main::FOO opened only for output at - line 8.
Filehandle main::FOO opened only for output at - line 9.
########
# pp_hot.c
-use warning 'closed' ;
+use warnings 'closed' ;
close STDIN ;
print STDIN "anc";
-no warning 'closed' ;
+no warnings 'closed' ;
print STDIN "anc";
EXPECT
print on closed filehandle main::STDIN at - line 4.
########
# pp_hot.c
-use warning 'uninitialized' ;
+use warnings 'uninitialized' ;
my $a = undef ;
my @b = @$a;
-no warning 'uninitialized' ;
+no warnings 'uninitialized' ;
my @c = @$a;
EXPECT
Use of uninitialized value at - line 4.
########
# pp_hot.c
-use warning 'uninitialized' ;
+use warnings 'uninitialized' ;
my $a = undef ;
my %b = %$a;
-no warning 'uninitialized' ;
+no warnings 'uninitialized' ;
my %c = %$a;
EXPECT
Use of uninitialized value at - line 4.
########
# pp_hot.c
-use warning 'unsafe' ;
+use warnings 'unsafe' ;
my %X ; %X = (1,2,3) ;
-no warning 'unsafe' ;
+no warnings 'unsafe' ;
my %Y ; %Y = (1,2,3) ;
EXPECT
Odd number of elements in hash assignment at - line 3.
########
# pp_hot.c
-use warning 'unsafe' ;
+use warnings 'unsafe' ;
my %X ; %X = [1 .. 3] ;
-no warning 'unsafe' ;
+no warnings 'unsafe' ;
my %Y ; %Y = [1 .. 3] ;
EXPECT
Reference found where even-sized list expected at - line 3.
########
# pp_hot.c
-use warning 'closed' ;
+use warnings 'closed' ;
close STDIN ; $a = <STDIN> ;
-no warning 'closed' ;
+no warnings 'closed' ;
$a = <STDIN> ;
EXPECT
Read on closed filehandle main::STDIN at - line 3.
########
# pp_hot.c
-use warning 'recursion' ;
+use warnings 'recursion' ;
sub fred
{
fred() if $a++ < 200
@@ -136,7 +136,7 @@ EXPECT
ok
########
# pp_hot.c
-no warning 'recursion' ;
+no warnings 'recursion' ;
sub fred
{
fred() if $a++ < 200
@@ -151,7 +151,7 @@ EXPECT
########
# pp_hot.c
-use warning 'recursion' ;
+use warnings 'recursion' ;
$b = sub
{
&$b if $a++ < 200
@@ -162,7 +162,7 @@ EXPECT
Deep recursion on anonymous subroutine at - line 5.
########
# pp_hot.c
-no warning 'recursion' ;
+no warnings 'recursion' ;
$b = sub
{
&$b if $a++ < 200