develooper Front page | perl.perl6.language | Postings from May 2001

Re: Apoc2 - <STDIN> concerns

From:
Simon Cozens
Date:
May 4, 2001 18:10
Subject:
Re: Apoc2 - <STDIN> concerns
Message ID:
20010505021045.B10450@netthink.co.uk
On Fri, May 04, 2001 at 04:42:07PM -0700, Nathan Wiger wrote:
> :      while ($STDIN) { ... }
> I'm wondering what this will do?
>    $thingy = $STDIN;
> This seems to have two possibilities:
>    1. Make a copy of $STDIN

This one. I see a filehandle in *boolean* context meaning "read to $_",
just like the current "while (<FOO>)" magic we all know and occasionally
love. I'd expect $FOO.readln (or something less Pascalish) to do an
explicit readline to a variable other than $_

-- 
You want to read that stuff, fine. You want to create a network for such 
things, fine. You want to explore the theoretical boundaries of free speech, 
fine. But when it starts impacting *people* trying to *communicate*, then 
that is where I draw the line. - Russ Allbery, http://www.slacker.com/rant.html



nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About