[BUG:47:LOG] Dropped "and" in pod2man
[p5sagit/p5-mst-13.2.git] / pod / perlfunc.pod
index a99dffe..a28487a 100644 (file)
@@ -448,7 +448,7 @@ successfully changed.  See also L</oct>, if all you have is a string.
 
 =item chomp
 
-This is a slightly safer version of chop (see below).  It removes any
+This is a slightly safer version of L</chop>.  It removes any
 line ending that corresponds to the current value of C<$/> (also known as
 $INPUT_RECORD_SEPARATOR in the C<English> module).  It returns the total
 number of characters removed from all its arguments.  It's often used to
@@ -551,7 +551,11 @@ omitted, does chroot to $_.
 
 Closes the file or pipe associated with the file handle, returning TRUE
 only if stdio successfully flushes buffers and closes the system file
-descriptor.  You don't have to close FILEHANDLE if you are immediately
+descriptor.  If the file handle came from a piped open C<close> will
+additionally return FALSE if one of the other system calls involved
+fails or if the program exits with non-zero status.  (If the problem was
+that the program exited non-zero $! will be set to 0.)
+You don't have to close FILEHANDLE if you are immediately
 going to do another open() on it, because open() will close it for you.  (See
 open().)  However, an explicit close on an input file resets the line
 counter ($.), while the implicit close done by open() does not.  Also,
@@ -1727,7 +1731,7 @@ it succeeded, FALSE otherwise.  See example in L<perlipc/"Sockets: Client/Server
 A local modifies the listed variables to be local to the enclosing block,
 subroutine, C<eval{}>, or C<do>.  If more than one value is listed, the
 list must be placed in parentheses.  See L<perlsub/"Temporary Values via
-local()"> for details.
+local()"> for details, including issues with tied arrays and hashes.
 
 But you really probably want to be using my() instead, because local() isn't
 what most people think of as "local").  See L<perlsub/"Private Variables
@@ -2331,10 +2335,10 @@ If EXPR is omitted, uses $_.
 
 =item rand
 
-Returns a random fractional number between 0 and the value of EXPR.
-(EXPR should be positive.)  If EXPR is omitted, returns a value between
-0 and 1.  Automatically calls srand() unless srand() has already been
-called.  See also srand().
+Returns a random fractional number greater than or equal to 0 and less
+than the value of EXPR.  (EXPR should be positive.)  If EXPR is
+omitted, the value 1 is used.  Automatically calls srand() unless
+srand() has already been called.  See also srand().
 
 (Note: If your rand function consistently returns numbers that are too
 large or too small, then your version of Perl was probably compiled
@@ -3114,19 +3118,19 @@ Perl's sprintf() permits the following universally-known conversions:
    %f  a floating-point number, in fixed decimal notation
    %g  a floating-point number, in %e or %f notation
 
-In addition, Perl permits the following ANSI-invented conversions:
+In addition, Perl permits the following widely-supported conversions:
 
-   %i  a synonym for %d
    %X  like %x, but using upper-case letters
    %E  like %e, but using an upper-case "E"
    %G  like %g, but with an upper-case "E" (if applicable)
    %p  a pointer (outputs the Perl value's address in hexadecimal)
-   %n  special: B<stores> into the next variable in the parameter
-        list the number of characters printed so far
+   %n  special: *stores* the number of characters output so far
+        into the next variable in the parameter list 
 
-Finally, for backward (and we do mean "backward") compatibility,
-Perl permits these nonstandard but unaccountably popular conversions:
+Finally, for backward (and we do mean "backward") compatibility, Perl
+permits these unnecessary but widely-supported conversions:
 
+   %i  a synonym for %d
    %D  a synonym for %ld
    %U  a synonym for %lu
    %O  a synonym for %lo
@@ -3139,17 +3143,14 @@ and the conversion letter:
    +       prefix positive number with a plus sign
    -       left-justify within the field
    0       use zeros, not spaces, to right-justify
+   #       prefix octal with "0", hex with "0x"
    number  minimum field width
    .number "precision": digits after decimal point for floating-point,
            max length for string, minimum length for integer
    l       interpret integer as C type "long" or "unsigned long"
-
-In addition, Perl permits the following ANSI-invented flags:
-
-   #       prefix octal with "0", hex with "0x"
    h       interpret integer as C type "short" or "unsigned short"
 
-Finally, there is one Perl-specific flag:
+There is also one Perl-specific flag:
 
    V       interpret integer as Perl's standard integer type