diff options
author | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2007-03-30 07:48:59 +0000 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2007-03-30 07:48:59 +0000 |
commit | abc718f2ca5cfe66c838e1324c1c153a085fea8b (patch) | |
tree | 23211c9fc93b1552429344d0efc4a0a611dd54ac /t/lib | |
parent | 37723ebb3f0f145b85438cb89891a2c80a5f149e (diff) | |
download | perl-abc718f2ca5cfe66c838e1324c1c153a085fea8b.tar.gz |
Add two deprecation warnings:
Opening dirhandle %s also as a file
Opening filehandle %s also as a directory
p4raw-id: //depot/perl@30780
Diffstat (limited to 't/lib')
-rw-r--r-- | t/lib/warnings/pp_sys | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/t/lib/warnings/pp_sys b/t/lib/warnings/pp_sys index 0dd3efea7a..2e9c613b02 100644 --- a/t/lib/warnings/pp_sys +++ b/t/lib/warnings/pp_sys @@ -494,3 +494,29 @@ chdir() on unopened filehandle FOO at - line 20. chdir() on closed filehandle BAR at - line 21. chdir() on unopened filehandle $dh at - line 22. chdir() on closed filehandle $fh at - line 23. +######## +# pp_sys.c [pp_open] +use warnings; +opendir FOO, "."; +opendir my $foo, "."; +open FOO, "TEST"; +open $foo, "TEST"; +no warnings qw(io deprecated); +open FOO, "TEST"; +open $foo, "TEST"; +EXPECT +Opening dirhandle FOO also as a file at - line 5. +Opening dirhandle $foo also as a file at - line 6. +######## +# pp_sys.c [pp_open_dir] +use warnings; +open FOO, "TEST"; +open my $foo, "TEST"; +opendir FOO, "."; +opendir $foo, "."; +no warnings qw(io deprecated); +opendir FOO, "."; +opendir $foo, "."; +EXPECT +Opening filehandle FOO also as a directory at - line 5. +Opening filehandle $foo also as a directory at - line 6. |