From: Yitzchak Scott-Thoennes Date: Thu, 2 Jun 2005 11:49:11 +0000 (-0700) Subject: Re: Should while ( <$fh> ) and while (< $fh >) do the same thing? X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=ef191992665fc6763066d411ee6596d9638d260f;p=p5sagit%2Fp5-mst-13.2.git Re: Should while ( <$fh> ) and while (< $fh >) do the same thing? Message-ID: <20050602184911.GA3292@efn.org> p4raw-id: //depot/perl@24690 --- diff --git a/pod/perlop.pod b/pod/perlop.pod index b86dda4..04e1b48 100644 --- a/pod/perlop.pod +++ b/pod/perlop.pod @@ -1987,7 +1987,8 @@ depending on context. This distinction is determined on syntactic grounds alone. That means C<< <$x> >> is always a readline() from an indirect handle, but C<< <$hash{key}> >> is always a glob(). That's because $x is a simple scalar variable, but C<$hash{key}> is -not--it's a hash element. +not--it's a hash element. Even C<< <$x > >> (note the extra space) +is treated as C, not C. One level of double-quote interpretation is done first, but you can't say C<< <$foo> >> because that's an indirect filehandle as explained