From: Gurusamy Sarathy Date: Wed, 17 Feb 1999 23:30:47 +0000 (+0000) Subject: correct slurp mode doc X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=449bc448608ab0510bce029f04816fc3b63d7d6a;p=p5sagit%2Fp5-mst-13.2.git correct slurp mode doc p4raw-id: //depot/perl@2969 --- diff --git a/pod/perlfunc.pod b/pod/perlfunc.pod index 1297e71..c4e9482 100644 --- a/pod/perlfunc.pod +++ b/pod/perlfunc.pod @@ -2911,9 +2911,9 @@ reads until end-of-file is reached and returns a list of lines. Note that the notion of "line" used here is however you may have defined it with C<$/> or C<$INPUT_RECORD_SEPARATOR>). See L. -When C<$/> is set to C and when readline() is in a scalar -context (i.e. file slurp mode), it returns C<''> the first time, -followed by C subsequently. +When C<$/> is set to C, when readline() is in a scalar +context (i.e. file slurp mode), and when an empty file is read, it +returns C<''> the first time, followed by C subsequently. This is the internal function implementing the CEXPRE> operator, but you can use it directly. The CEXPRE> diff --git a/pod/perlop.pod b/pod/perlop.pod index dfb893d..313ed58 100644 --- a/pod/perlop.pod +++ b/pod/perlop.pod @@ -1521,7 +1521,8 @@ security concerns.) In a scalar context, evaluating a filehandle in angle brackets yields the next line from that file (newline, if any, included), or C at end-of-file. When C<$/> is set to C (i.e. file slurp mode), -it returns C<''> the first time, followed by C subsequently. +and the file is empty, it returns C<''> the first time, followed by +C subsequently. Ordinarily you must assign the returned value to a variable, but there is one situation where an automatic assignment happens. I the