Basically, perl blows right past the "my $ans = <STDIN>;" line.Really? Not for me. I've added the following lines before your exit:
And this is what I get when running:chomp $ans; print "Got '$ans'\n"; print "stream = $stream";
$ ./stdin foo bar ^D Do you want to process the stream?yes Got 'yes' stream = foo bar $
Abigail
In reply to Re: Multiple STDIN sources
by Abigail-II
in thread Multiple STDIN sources
by perlfan
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |