On Wed, Jun 29, 2005 at 08:37:29AM -0500, Steve Peters wrote: > Then, how does the following sound to everyone... > > --- ext/IO/lib/IO/Handle.pm.old Sun Apr 4 08:32:35 2004 > +++ ext/IO/lib/IO/Handle.pm Wed Jun 29 08:34:48 2005 > @@ -117,7 +117,10 @@ > > This works like <$io> described in L<perlop/"I/O Operators"> > except that it's more readable and can be safely called in a > -list context but still returns just one line. > +list context but still returns just one line. If used within a > +conditional statement, however, you will need to emulate the > +functionality of <$io> with C<defined($x = $io->getline)> where > +C<$x> is a scalar you have previously defined.
Why not just use $_ there? Not only does that emulate the actual behavior of <$io>, but then you don't need the confusing note about $x. Ronald