diff options
author | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2007-03-24 21:14:22 +0000 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2007-03-24 21:14:22 +0000 |
commit | e4b7ebf3387ae98739a0f53e0f27fa7a6228338f (patch) | |
tree | 45a7b8a5f380fa06c8b5c0d8852f562fa78ef38a /t | |
parent | 01f5bc1b1054964df4fcf07067d574b936dee120 (diff) | |
download | perl-e4b7ebf3387ae98739a0f53e0f27fa7a6228338f.tar.gz |
Make readline() default to *ARGV.
Plus MAD fixes.
p4raw-id: //depot/perl@30750
Diffstat (limited to 't')
-rw-r--r-- | t/op/readline.t | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/t/op/readline.t b/t/op/readline.t index 394acdb7a6..0d6598f711 100644 --- a/t/op/readline.t +++ b/t/op/readline.t @@ -6,7 +6,7 @@ BEGIN { require './test.pl'; } -plan tests => 17; +plan tests => 18; eval { for (\2) { $_ = <FH> } }; like($@, 'Modification of a read-only value attempted', '[perl #19566]'); @@ -83,6 +83,10 @@ fresh_perl_is('BEGIN{<>}', '', { switches => ['-w'], stdin => '', stderr => 1 }, 'No ARGVOUT used only once warning'); +fresh_perl_is('print readline', 'foo', + { switches => ['-w'], stdin => 'foo', stderr => 1 }, + 'readline() defaults to *ARGV'); + my $obj = bless []; $obj .= <DATA>; like($obj, qr/main=ARRAY.*world/, 'rcatline and refs'); |