Remove the deprecated $# variable
[p5sagit/p5-mst-13.2.git] / t / lib / warnings / pp_sys
index 8dc0bf9..881e81e 100644 (file)
@@ -389,9 +389,18 @@ my $a = sysread(F, $a,10) ;
 no warnings 'io' ;
 my $a = sysread(F, $a,10) ;
 close F ;
+use warnings 'io' ;
+sysread(F, $a, 10);
+read(F, $a, 10);
+sysread(NONEXISTENT, $a, 10);
+read(NONEXISTENT, $a, 10);
 unlink $file ;
 EXPECT
 Filehandle F opened only for output at - line 12.
+sysread() on closed filehandle F at - line 17.
+read() on closed filehandle F at - line 18.
+sysread() on unopened filehandle NONEXISTENT at - line 19.
+read() on unopened filehandle NONEXISTENT at - line 20.
 ########
 # pp_sys.c [pp_binmode]
 use warnings 'unopened' ;
@@ -403,16 +412,18 @@ binmode() on unopened filehandle at - line 4.
 ########
 # pp_sys.c [pp_lstat]
 use warnings 'io';
-lstat STDIN;
+open FH, "harness" or die "# $!";
+lstat FH;
 open my $fh, $0 or die "# $!";
 lstat $fh;
 no warnings 'io';
-lstat STDIN;
+lstat FH;
 lstat $fh;
+close FH;
 close $fh;
 EXPECT
-lstat() on filehandle STDIN at - line 3.
-lstat() on filehandle $fh at - line 5.
+lstat() on filehandle FH at - line 4.
+lstat() on filehandle $fh at - line 6.
 ########
 # pp_sys.c [pp_getc]
 use warnings qw(unopened closed) ;