summaryrefslogtreecommitdiff
path: root/pod
diff options
context:
space:
mode:
authorGurusamy Sarathy <gsar@cpan.org>1998-08-08 22:18:54 +0000
committerGurusamy Sarathy <gsar@cpan.org>1998-08-08 22:18:54 +0000
commit84df6dbaac5dcce30923bafc61c52f3ffa1b669b (patch)
treecf12e2c57eeb3ade406af6984e8a91a4ea05a830 /pod
parent527cc686938e627799b4befb57128e2e7c3272c2 (diff)
parent1eccc87f4ae921520ce1893dd988f4a8a1fa061d (diff)
downloadperl-84df6dbaac5dcce30923bafc61c52f3ffa1b669b.tar.gz
integrate maint-5.005 changes into mainline
p4raw-id: //depot/perl@1760
Diffstat (limited to 'pod')
-rw-r--r--pod/perlcall.pod4
-rw-r--r--pod/perldelta.pod17
-rw-r--r--pod/perldiag.pod10
-rw-r--r--pod/perlembed.pod2
-rw-r--r--pod/perlfaq.pod4
-rw-r--r--pod/perlfaq1.pod22
-rw-r--r--pod/perlfaq2.pod96
-rw-r--r--pod/perlfaq3.pod17
-rw-r--r--pod/perlfaq4.pod15
-rw-r--r--pod/perlfaq8.pod4
-rw-r--r--pod/perlfunc.pod15
-rw-r--r--pod/perlhist.pod183
-rw-r--r--pod/perllocale.pod59
-rw-r--r--pod/perlport.pod673
-rw-r--r--pod/perlre.pod87
-rw-r--r--pod/perlrun.pod1
-rw-r--r--pod/roffitall156
17 files changed, 939 insertions, 426 deletions
diff --git a/pod/perlcall.pod b/pod/perlcall.pod
index 7c94d377c7..c239cfe324 100644
--- a/pod/perlcall.pod
+++ b/pod/perlcall.pod
@@ -279,8 +279,8 @@ belongs to C<joe>.
It is possible for the Perl subroutine you are calling to terminate
abnormally, e.g., by calling I<die> explicitly or by not actually
-existing. By default, when either of these of events occurs, the
-process will terminate immediately. If though, you want to trap this
+existing. By default, when either of these events occurs, the
+process will terminate immediately. If you want to trap this
type of event, specify the G_EVAL flag. It will put an I<eval { }>
around the subroutine call.
diff --git a/pod/perldelta.pod b/pod/perldelta.pod
index d43f657b14..a3c6b6cc05 100644
--- a/pod/perldelta.pod
+++ b/pod/perldelta.pod
@@ -165,7 +165,7 @@ perl program. The C backend generates C code that captures perl's state
just before execution begins. It eliminates the compile-time overheads
of the regular perl interpreter, but the run-time performance remains
comparatively the same. The CC backend generates optimized C code
-equivivalent to the code path at run-time. The CC backend has greater
+equivalent to the code path at run-time. The CC backend has greater
potential for big optimizations, but only a few optimizations are
implemented currently. The Bytecode backend generates a platform
independent bytecode representation of the interpreter's state
@@ -208,12 +208,12 @@ Changes in the RE engine:
New types of nodes to process (SUBEXPR)* and similar expressions
quickly, used if the SUBEXPR has no side effects and matches
strings of the same length;
- better optimizations by lookup for constant substrings;
+ Better optimizations by lookup for constant substrings;
Better search for constants substrings anchored by $ ;
Changes in Perl code using RE engine:
- more optimizations to s/longer/short/;
+ More optimizations to s/longer/short/;
study() was not working;
/blah/ may be optimized to an analogue of index() if $& $` $' not seen;
Unneeded copying of matched-against string removed;
@@ -230,7 +230,7 @@ Note that only the major bug fixes are listed here. See F<Changes> for others.
possibility of a segfault;
(ZERO-LENGTH)* could segfault;
(ZERO-LENGTH)* was prohibited;
- Long RE were not allowed;
+ Long REs were not allowed;
/RE/g could skip matches at the same position after a
zero-length match;
@@ -253,9 +253,10 @@ See L<New C<qr//> operator>.
=item Other improvements
- better debugging output (possibly with colors), even from non-debugging Perl;
+ Better debugging output (possibly with colors),
+ even from non-debugging Perl;
RE engine code now looks like C, not like assembler;
- behaviour of RE modifiable by `use re' directive;
+ Behaviour of RE modifiable by `use re' directive;
Improved documentation;
Test suite significantly extended;
Syntax [:^upper:] etc., reserved inside character classes;
@@ -455,7 +456,7 @@ substr() can now both return and replace in one operation. The optional
=head2 Negative LENGTH argument to splice
-Splice() with a negative LENGTH argument now work similar to what the
+splice() with a negative LENGTH argument now work similar to what the
LENGTH did for substr(). Previously a negative LENGTH was treated as
0. See L<perlfunc/splice>.
@@ -501,6 +502,8 @@ DOS is now supported under the DJGPP tools. See L<README.dos>.
MPE/iX is now supported. See L<README.mpeix>.
+MVS (OS390) is now supported. See L<README.os390>.
+
=head2 Changes in existing support
Win32 support has been vastly enhanced. Support for Perl Object, a C++
diff --git a/pod/perldiag.pod b/pod/perldiag.pod
index 5fdeb70ab8..8d213235a8 100644
--- a/pod/perldiag.pod
+++ b/pod/perldiag.pod
@@ -1538,7 +1538,7 @@ backwards.
=item Modification of non-creatable hash value attempted, subscript "%s"
-(F) You tried to make a hash value spring into existence, and it couldn't
+(P) You tried to make a hash value spring into existence, and it couldn't
be created for some peculiar reason.
=item Module name must be constant
@@ -2479,10 +2479,12 @@ if the error went away. Sort of the cybernetic version of S<20 questions>.
instead of Perl. Check the #! line, or manually feed your script
into Perl yourself.
-=item System V IPC is not implemented on this machine
+=item System V %s is not implemented on this machine
-(F) You tried to do something with a function beginning with "sem", "shm",
-or "msg". See L<perlfunc/semctl>, for example.
+(F) You tried to do something with a function beginning with "sem",
+"shm", or "msg" but that System V IPC is not implemented in your
+machine. In some machines the functionality can exist but be
+unconfigured. Consult your system support.
=item Syswrite on closed filehandle
diff --git a/pod/perlembed.pod b/pod/perlembed.pod
index 0323fd1110..c09d6e33cb 100644
--- a/pod/perlembed.pod
+++ b/pod/perlembed.pod
@@ -35,6 +35,8 @@ Read on...
=head2 ROADMAP
+=over 5
+
L<Compiling your C program>
L<Adding a Perl interpreter to your C program>
diff --git a/pod/perlfaq.pod b/pod/perlfaq.pod
index 1d81077760..e6be112008 100644
--- a/pod/perlfaq.pod
+++ b/pod/perlfaq.pod
@@ -1,6 +1,6 @@
=head1 NAME
-perlfaq - frequently asked questions about Perl ($Date: 1998/07/20 23:12:17 $)
+perlfaq - frequently asked questions about Perl ($Date: 1998/08/05 12:09:32 $)
=head1 DESCRIPTION
@@ -117,7 +117,7 @@ in respect of this information or its use.
=over 4
-=head 22/June/98
+=item 22/June/98
Significant changes throughout in preparation for the 5.005
release.
diff --git a/pod/perlfaq1.pod b/pod/perlfaq1.pod
index ee071e4216..5a95f19c79 100644
--- a/pod/perlfaq1.pod
+++ b/pod/perlfaq1.pod
@@ -1,6 +1,6 @@
=head1 NAME
-perlfaq1 - General Questions About Perl ($Revision: 1.14 $, $Date: 1998/06/14 22:15:25 $)
+perlfaq1 - General Questions About Perl ($Revision: 1.15 $, $Date: 1998/08/05 11:52:24 $)
=head1 DESCRIPTION
@@ -29,7 +29,8 @@ distribution policy of perl. Perl is supported by its users. The
core, the standard Perl library, the optional modules, and the
documentation you're reading now were all written by volunteers. See
the personal note at the end of the README file in the perl source
-distribution for more details.
+distribution for more details. See L<perlhist> (new as of 5.005)
+for Perl's milestone releases.
In particular, the core development team (known as the Perl
Porters) are a rag-tag band of highly altruistic individuals
@@ -51,10 +52,10 @@ users the informal support will more than suffice. See the answer to
You should definitely use version 5. Version 4 is old, limited, and
no longer maintained; its last patch (4.036) was in 1992. The most
-recent production release is 5.004_01. Further references to the Perl
+recent production release is 5.005_01. Further references to the Perl
language in this document refer to this production release unless
otherwise specified. There may be one or more official bug fixes for
-5.004_01 by the time you read this, and also perhaps some experimental
+5.005_01 by the time you read this, and also perhaps some experimental
versions on the way to the next release.
=head2 What are perl4 and perl5?
@@ -210,7 +211,7 @@ available from http://www.perl.com/CPAN/misc/japh .
Over a hundred quips by Larry, from postings of his or source code,
can be found at http://www.perl.com/CPAN/misc/lwall-quotes .
-=head2 How can I convince my sysadmin/supervisor/employees to use version (5/5.004/Perl instead of some other language)?
+=head2 How can I convince my sysadmin/supervisor/employees to use version (5/5.005/Perl instead of some other language)?
If your manager or employees are wary of unsupported software, or
software which doesn't officially ship with your Operating System, you
@@ -240,10 +241,15 @@ for any given task. Also mention that the difference between version
(Well, ok, maybe not quite that distinct, but you get the idea.) If
you want support and a reasonable guarantee that what you're
developing will continue to work in the future, then you have to run
-the supported version. That probably means running the 5.004 release,
-although 5.003 isn't that bad (it's just one year and one release
+the supported version. That probably means running the 5.005 release,
+although 5.004 isn't that bad (it's just one year and one release
behind). Several important bugs were fixed from the 5.000 through
-5.002 versions, though, so try upgrading past them if possible.
+5.003 versions, though, so try upgrading past them if possible.
+
+Of particular note is the massive bughunt for buffer overflow
+problems that went into the 5.004 release. All releases prior to
+that, including perl4, are considered insecure and should be upgraded
+as soon as possible.
=head1 AUTHOR AND COPYRIGHT
diff --git a/pod/perlfaq2.pod b/pod/perlfaq2.pod
index c743a0efc8..918e9369ae 100644
--- a/pod/perlfaq2.pod
+++ b/pod/perlfaq2.pod
@@ -1,6 +1,6 @@
=head1 NAME
-perlfaq2 - Obtaining and Learning about Perl ($Revision: 1.24 $, $Date: 1998/07/20 23:40:28 $)
+perlfaq2 - Obtaining and Learning about Perl ($Revision: 1.25 $, $Date: 1998/08/05 11:47:25 $)
=head1 DESCRIPTION
@@ -11,22 +11,25 @@ related matters.
=head2 What machines support Perl? Where do I get it?
The standard release of Perl (the one maintained by the perl
-development team) is distributed only in source code form. You can
-find this at http://www.perl.com/CPAN/src/latest.tar.gz, which is a
-gzipped archive in POSIX tar format. This source builds with no
-porting whatsoever on most Unix systems (Perl's native environment),
-as well as Plan 9, VMS, QNX, OS/2, and the Amiga.
-
-Although it's rumored that the (imminent) 5.004 release may build
-on Windows NT, this is yet to be proven. Binary distributions
-for 32-bit Microsoft systems and for Apple systems can be found
-http://www.perl.com/CPAN/ports/ directory. Because these are not part of
-the standard distribution, they may and in fact do differ from the base
-Perl port in a variety of ways. You'll have to check their respective
-release notes to see just what the differences are. These differences
-can be either positive (e.g. extensions for the features of the particular
-platform that are not supported in the source release of perl) or negative
-(e.g. might be based upon a less current source release of perl).
+development team) is distributed only in source code form. You
+can find this at http://www.perl.com/CPAN/src/latest.tar.gz, which
+in standard Internet format (a gzipped archive in POSIX tar format).
+
+Perl builds and runs on a bewildering number of platforms. Virtually
+all known and current Unix derivatives are supported (Perl's native
+platform), as are proprietary systems like VMS, DOS, OS/2, Windows,
+QNX, BeOS, and the Amiga. There are also the beginnings of support
+for MPE/iX.
+
+Binary distributions for some proprietary platforms, including
+Apple systems can be found http://www.perl.com/CPAN/ports/ directory.
+Because these are not part of the standard distribution, they may
+and in fact do differ from the base Perl port in a variety of ways.
+You'll have to check their respective release notes to see just
+what the differences are. These differences can be either positive
+(e.g. extensions for the features of the particular platform that
+are not supported in the source release of perl) or negative (e.g.
+might be based upon a less current source release of perl).
A useful FAQ for Win32 Perl users is
http://www.endcontsw.com/people/evangelo/Perl_for_Win32_FAQ.html
@@ -177,25 +180,41 @@ these are good, some are ok, but many aren't worth your money. Tom
Christiansen maintains a list of these books, some with extensive
reviews, at http://www.perl.com/perl/critiques/index.html.
-The incontestably definitive reference book on Perl, written by the
-creator of Perl and his apostles, is now in its second edition and
-fourth printing.
+The incontestably definitive reference book on Perl, written by
+the creator of Perl, is now in its second edition:
Programming Perl (the "Camel Book"):
Authors: Larry Wall, Tom Christiansen, and Randal Schwartz
ISBN 1-56592-149-6 (English)
ISBN 4-89052-384-7 (Japanese)
- (French, German, and Italian translations also available)
+ URL: http://www.oreilly.com/catalog/pperl2/
+ (French, German, Italian, and Hungarian translations also
+ available)
-Note that O'Reilly books are color-coded: turquoise (some would call
-it teal) covers indicate perl5 coverage, while magenta (some would
-call it pink) covers indicate perl4 only. Check the cover color
-before you buy!
+The companion volume to the Camel containing thousands
+of real-world examples, mini-tutorials, and complete programs
+(first premiering at the 1998 Perl Conference), is:
+
+ The Perl Cookbook (the "Ram Book"):
+ Authors: Tom Christiansen and Nathan Torkington,
+ with Foreword by Larry Wall
+ ISBN: 1-56592-243-3
+ URL: http://perl.oreilly.com/cookbook/
If you're already a hard-core systems programmer, then the Camel Book
might suffice for you to learn Perl from. But if you're not, check
-out I<Learning Perl> by Randal and Tom. The second edition of "Llama
-Book" has a blue cover, and is updated for the 5.004 release of Perl.
+out:
+
+ Learning Perl (the "Llama Book"):
+ Authors: Randal Schwartz and Tom Christiansen
+ with Foreword by Larry Wall
+ ISBN: 1-56592-284-0
+ URL: http://www.oreilly.com/catalog/lperl2/
+
+Despite the picture at the URL above, the second edition of "Llama
+Book" really has a blue cover, and is updated for the 5.004 release
+of Perl. Various foreign language editions are available, including
+I<Learning Perl on Win32 Systems> (the Gecko Book).
If you're not an accidental programmer, but a more serious and possibly
even degreed computer scientist who doesn't need as much hand-holding as
@@ -211,8 +230,8 @@ See http://www.ora.com/ on the Web.
What follows is a list of the books that the FAQ authors found personally
useful. Your mileage may (but, we hope, probably won't) vary.
-Recommended books on (or muchly on) Perl are the following.
-Those marked with a star may be ordered from O'Reilly.
+Recommended books on (or muchly on) Perl follow; those marked with
+a star may be ordered from O'Reilly.
=over
@@ -228,6 +247,7 @@ Those marked with a star may be ordered from O'Reilly.
*Learning Perl [2nd edition]
by Randal L. Schwartz and Tom Christiansen
+ with foreword by Larry Wall
*Learning Perl on Win32 Systems
by Randal L. Schwartz, Erik Olson, and Tom Christiansen,
@@ -273,9 +293,10 @@ The first and only periodical devoted to All Things Perl, I<The
Perl Journal> contains tutorials, demonstrations, case studies,
announcements, contests, and much more. TPJ has columns on web
development, databases, Win32 Perl, graphical programming, regular
-expressions, and networking, and sponsors the Obfuscated Perl Contest.
-It is published quarterly by Jon Orwant. See http://www.tpj.com/ or
-send mail to subscriptions@tpj.com.
+expressions, and networking, and sponsors the Obfuscated Perl
+Contest. It is published quarterly under the gentle hand of its
+editor, Jon Orwant. See http://www.tpj.com/ or send mail to
+subscriptions@tpj.com.
Beyond this, magazines that frequently carry high-quality articles
on Perl are I<Web Techniques> (see http://www.webtechniques.com/),
@@ -297,9 +318,6 @@ following list is I<not> the complete list of CPAN mirrors.
http://www.cs.ruu.nl/pub/PERL/CPAN/
ftp://ftp.cs.colorado.edu/pub/perl/CPAN/
-http:/www.oasis.leo.org/perl/ has, amongst other things, source to
-versions 1 through 5 of Perl.
-
=head2 What mailing lists are there for perl?
Most of the major modules (tk, CGI, libwww-perl) have their own
@@ -427,6 +445,8 @@ For more information, contact the The Perl Clinic:
Web: http://www.perl.co.uk/
Email: perl-support-info@perl.co.uk or Tim.Bunce@ig.co.uk
+See also www.perl.com for updates on training and support.
+
=head2 Where do I send bug reports?
If you are reporting a bug in the perl interpreter or the modules
@@ -443,7 +463,7 @@ Read the perlbug(1) man page (perl5.004 or later) for more information.
=head2 What is perl.com? perl.org? The Perl Institute?
-The perl.com domain is Tom Christiansen's domain. He created it as a
+The perl.com domain is managed by Tom Christiansen, who created it as a
public service long before perl.org came about. Despite the name, it's a
pretty non-commercial site meant to be a clearinghouse for information
about all things Perlian, accepting no paid advertisements, bouncy
@@ -454,9 +474,7 @@ Systems, a software-oriented subsidiary of O'Reilly and Associates.
perl.org is the official vehicle for The Perl Institute. The motto of
TPI is "helping people help Perl help people" (or something like
that). It's a non-profit organization supporting development,
-documentation, and dissemination of perl. Current directors of TPI
-include Larry Wall, Tom Christiansen, and Randal Schwartz, whom you
-may have heard of somewhere else around here.
+documentation, and dissemination of perl.
=head2 How do I learn about object-oriented Perl programming?
diff --git a/pod/perlfaq3.pod b/pod/perlfaq3.pod
index 11f105c48c..d06f2bef7a 100644
--- a/pod/perlfaq3.pod
+++ b/pod/perlfaq3.pod
@@ -1,6 +1,6 @@
=head1 NAME
-perlfaq3 - Programming Tools ($Revision: 1.28 $, $Date: 1998/07/16 22:08:49 $)
+perlfaq3 - Programming Tools ($Revision: 1.29 $, $Date: 1998/08/05 11:57:04 $)
=head1 DESCRIPTION
@@ -372,10 +372,10 @@ you want to be sure your licence's wording will stand up in court.
=head2 How can I compile my Perl program into byte code or C?
Malcolm Beattie has written a multifunction backend compiler,
-available from CPAN, that can do both these things. It is as of
-Jul-1998 in late alpha release, which means it's fun to play with if
-you're a programmer but not really for people looking for turn-key
-solutions.
+available from CPAN, that can do both these things. It is included
+in the perl5.005 release, but is still considered experimental.
+This means it's fun to play with if you're a programmer but not
+really for people looking for turn-key solutions.
Merely compiling into C does not in and of itself guarantee that your
code will run very much faster. That's because except for lucky cases
@@ -386,11 +386,6 @@ compilation time, leaving execution no more than 10-30% faster. A few
rare programs actually benefit significantly (like several times
faster), but this takes some tweaking of your code.
-The 5.005 release of Perl itself, whose main goal is merging the various
-non-Unix ports back into the one Perl source, will also have preliminary
-(strictly beta) support for Malcolm's compiler and his light-weight
-processes (sometimes called ``threads'').
-
You'll probably be astonished to learn that the current version of the
compiler generates a compiled form of your script whose executable is
just as big as the original perl executable, and then some. That's
@@ -410,7 +405,7 @@ and compilation never stopped software piracy in the form of crackers,
viruses, or bootleggers. The real advantage of the compiler is merely
packaging, and once you see the size of what it makes (well, unless
you use a shared I<libperl.so>), you'll probably want a complete
-Perl install anywayt.
+Perl install anyway.
=head2 How can I get C<#!perl> to work on [MS-DOS,NT,...]?
diff --git a/pod/perlfaq4.pod b/pod/perlfaq4.pod
index 0a47145a28..633f5f109b 100644
--- a/pod/perlfaq4.pod
+++ b/pod/perlfaq4.pod
@@ -1,6 +1,6 @@
=head1 NAME
-perlfaq4 - Data Manipulation ($Revision: 1.25 $, $Date: 1998/07/16 22:49:55 $)
+perlfaq4 - Data Manipulation ($Revision: 1.26 $, $Date: 1998/08/05 12:04:00 $)
=head1 DESCRIPTION
@@ -177,7 +177,11 @@ You can find the week of the year by dividing this by 7:
Of course, this believes that weeks start at zero. The Date::Calc
module from CPAN has a lot of date calculation functions, including
-day of the year, week of the year, and so on.
+day of the year, week of the year, and so on. Note that not
+all business consider ``week 1'' to be the same; for example,
+American business often consider the first week with a Monday
+in it to be Work Week #1, despite ISO 8601, which consider
+WW1 to be the frist week with a Thursday in it.
=head2 How can I compare two dates and find the difference?
@@ -202,8 +206,9 @@ http://www.perl.com/CPAN/authors/David_Muir_Sharnoff/modules/Time/JulianDay.pm.g
=head2 Does Perl have a year 2000 problem? Is Perl Y2K compliant?
-Short answer: No, Perl does not have a Year 2000 problem. Yes, Perl
-is Y2K compliant.
+Short answer: No, Perl does not have a Year 2000 problem. Yes,
+Perl is Y2K compliant. The programmers you're hired to use it,
+however, probably are not.
Long answer: Perl is just as Y2K compliant as your pencil--no more,
and no less. The date and time functions supplied with perl (gmtime
@@ -471,7 +476,7 @@ Or more nicely written as:
s/\s+$//;
}
-This idiom takes advantage of the C<for(each)> loop's aliasing
+This idiom takes advantage of the C<foreach> loop's aliasing
behavior to factor out common code. You can do this
on several strings at once, or arrays, or even the
values of a hash if you use a slide:
diff --git a/pod/perlfaq8.pod b/pod/perlfaq8.pod
index e99cf426ca..c4036ff35d 100644
--- a/pod/perlfaq8.pod
+++ b/pod/perlfaq8.pod
@@ -1,6 +1,6 @@
=head1 NAME
-perlfaq8 - System Interaction ($Revision: 1.25 $, $Date: 1998/07/05 15:07:20 $)
+perlfaq8 - System Interaction ($Revision: 1.26 $, $Date: 1998/08/05 12:20:28 $)
=head1 DESCRIPTION
@@ -1005,7 +1005,7 @@ Perl offers several different ways to include code from one file into
another. Here are the deltas between the various inclusion constructs:
1) do $file is like eval `cat $file`, except the former:
- 1.1: searches @INC.
+ 1.1: searches @INC and updates %INC.
1.2: bequeaths an *unrelated* lexical scope on the eval'ed code.
2) require $file is like do $file, except the former:
diff --git a/pod/perlfunc.pod b/pod/perlfunc.pod
index ec76881f63..e62532e0ce 100644
--- a/pod/perlfunc.pod
+++ b/pod/perlfunc.pod
@@ -225,6 +225,8 @@ the undefined value if the file doesn't exist. Despite the funny
names, precedence is the same as any other named unary operator, and
the argument may be parenthesized like any other unary operator. The
operator may be any of:
+X<-r>X<-w>X<-x>X<-o>X<-R>X<-W>X<-X>X<-O>X<-e>X<-z>X<-s>X<-f>X<-d>X<-l>X<-p>
+X<-S>X<-b>X<-c>X<-t>X<-u>X<-g>X<-k>X<-T>X<-B>X<-M>X<-A>X<-C>
-r File is readable by effective uid/gid.
-w File is writable by effective uid/gid.
@@ -917,6 +919,12 @@ scope like C<eval STRING> does. It's the same, however, in that it does
reparse the file every time you call it, so you probably don't want to
do this inside a loop.
+If C<do> cannot read the file, it returns undef and sets C<$!> to the
+error. If C<do> can read the file but cannot compile it, it
+returns undef and sets an error message in C<$@>. If the file is
+successfully compiled, C<do> returns the value of the last expression
+evaluated.
+
Note that inclusion of library modules is better done with the
C<use()> and C<require()> operators, which also do automatic error checking
and raise an exception if there's a problem.
@@ -3828,8 +3836,11 @@ FILENAME, MODE, PERMS.
The possible values and flag bits of the MODE parameter are
system-dependent; they are available via the standard module C<Fcntl>.
-However, for historical reasons, some values are universal: zero means
-read-only, one means write-only, and two means read/write.
+For historical reasons, some values work on almost every system
+supported by perl: zero means read-only, one means write-only, and two
+means read/write. We know that these values do I<not> work under
+OS/390 Unix and on the Macintosh; you probably don't want to use them
+in new code.
If the file named by FILENAME does not exist and the C<open()> call creates
it (typically because MODE includes the C<O_CREAT> flag), then the value of
diff --git a/pod/perlhist.pod b/pod/perlhist.pod
index 431f44e451..9ed8b6f52e 100644
--- a/pod/perlhist.pod
+++ b/pod/perlhist.pod
@@ -6,7 +6,7 @@ perlhist - the Perl history records
=for RCS
#
-# $Id: perlhist.pod,v 1.41 1998/06/09 15:20:18 jhi Exp $
+# $Id: perlhist.pod,v 1.48 1998/08/03 08:50:12 jhi Exp $
#
=end RCS
@@ -32,7 +32,7 @@ Perl history in brief, by Larry Wall:
Larry Wall, Andy Dougherty, Tom Christiansen, Charles Bailey, Nick
Ing-Simmons, Chip Salzenberg, Tim Bunce, Malcolm Beattie, Gurusamy
-Sarathy.
+Sarathy, Graham Barr.
=head2 PUMPKIN?
@@ -70,16 +70,16 @@ the strings?).
Larry 0 Classified. Don't ask.
Larry 1.000 1987-Dec-18
-
+
1.001..10 1988-Jan-30
1.011..14 1988-Feb-02
-
+
Larry 2.000 1988-Jun-05
-
+
2.001 1988-Jun-28
-
+
Larry 3.000 1989-Oct-18
-
+
3.001 1989-Oct-26
3.002..4 1989-Nov-11
3.005 1989-Nov-18
@@ -96,9 +96,9 @@ the strings?).
3.041 1990-Nov-13
3.042..43 1990-Jan-??
3.044 1991-Jan-12
-
+
Larry 4.000 1991-Mar-21
-
+
4.001..3 1991-Apr-12
4.004..9 1991-Jun-07
4.010 1991-Jun-10
@@ -108,7 +108,7 @@ the strings?).
4.034 1992-Jun-11
4.035 1992-Jun-23
Larry 4.036 1993-Feb-05 Very stable.
-
+
5.000alpha1 1993-Jul-31
5.000alpha2 1993-Aug-16
5.000alpha3 1993-Oct-10
@@ -148,9 +148,9 @@ the strings?).
5.000b3f 1994-Sep-30
5.000b3g 1994-Oct-04
Andy 5.000b3h 1994-Oct-07
-
+
Larry 5.000 1994-Oct-18
-
+
Andy 5.000a 1994-Dec-19
5.000b 1995-Jan-18
5.000c 1995-Jan-18
@@ -165,9 +165,9 @@ the strings?).
5.000l 1995-Feb-21
5.000m 1995-???-??
5.000n 1995-Mar-07
-
+
Larry 5.001 1995-Mar-13
-
+
Andy 5.001a 1995-Mar-15
5.001b 1995-Mar-31
5.001c 1995-Apr-07
@@ -195,13 +195,13 @@ the strings?).
Larry 5.002b3 1996-Feb-02
Andy 5.002gamma 1996-Feb-11
Larry 5.002delta 1996-Feb-27
-
- Larry 5.002 1996-Feb-29
-
+
+ Larry 5.002 1996-Feb-29 Prototypes.
+
Charles 5.002_01 1996-Mar-25
-
+
5.003 1996-Jun-25 Security release.
-
+
5.003_01 1996-Jul-31
Nick 5.003_02 1996-Aug-10
Andy 5.003_03 1996-Aug-28
@@ -252,10 +252,10 @@ the strings?).
5.003_99 1997-May-01
5.003_99a 1997-May-09
p54rc1 1997-May-12 Release Candidates.
- p54rc2 1997-May-14
-
+ p54rc2 1997-May-14
+
Chip 5.004 1997-May-15 A major maintenance release.
-
+
Tim 5.004_01 1997-Jun-13 The 5.004 maintenance track.
5.004_02 1997-Aug-07
5.004_03 1997-Sep-05
@@ -263,7 +263,9 @@ the strings?).
5.004m5t1 1998-Mar-04 Maintenance Trials (for 5.004_05).
5.004_04-m2 1997-May-01
5.004_04-m3 1998-May-15
-
+ 5.004_04-m4 1998-May-19
+ 5.004_04-MT5 1998-Jul-21
+
Malcolm 5.004_50 1997-Sep-09 The 5.005 development track.
5.004_51 1997-Oct-02
5.004_52 1997-Oct-15
@@ -288,10 +290,18 @@ the strings?).
5.004_71 1998-Jul-09
5.004_72 1998-Jul-12
5.004_73 1998-Jul-13
- 5.004_74 1998-Jul-14
- 5.004_75 1998-Jul-15
- 5.004_76 1998-Jul-21
- 5.005 1998-Jul-22
+ 5.004_74 1998-Jul-14 5.005 beta candidate.
+ 5.004_75 1998-Jul-15 5.005 beta1.
+ 5.004_76 1998-Jul-21 5.005 beta2.
+ 5.005 1998-Jul-22 Oneperl.
+
+ Sarathy 5.005_01 1998-Jul-27 The 5.005 maintenance track.
+ 5.005_02-T1 1998-Aug-02
+ 5.005_02-T2 1998-Aug-05
+ 5.005_02 1998-Aug-08
+ Graham 5.005_03 1998-
+
+ Sarathy 5.005_50 1998-Jul-26 The 5.006 development track.
=head2 SELECTED RELEASE SIZES
@@ -322,14 +332,19 @@ explained below.
5.003 1129 54 680 102 291 43 166 100 853 35
5.003_07 1231 60 748 106 396 53 213 137 976 39
5.004 1351 60 1230 136 408 51 355 161 1587 55
- 5.004_01 1356 60 1258 138 410 51 358 161 1587 55
+ 5.004_01 1356 60 1258 138 410 51 358 161 1587 55
5.004_04 1375 60 1294 139 413 51 394 162 1629 55
5.004_51 1401 61 1260 140 413 53 358 162 1594 56
5.004_53 1422 62 1295 141 438 70 394 162 1637 56
5.004_56 1501 66 1301 140 447 74 408 165 1648 57
- 5.004_59 1555 72 1317 142 448 74 424 171 1678 58
+ 5.004_59 1555 72 1317 142 448 74 424 171 1678 58
5.004_62 1602 77 1327 144 629 92 428 173 1674 58
5.004_65 1626 77 1358 146 615 92 446 179 1698 60
+ 5.004_68 1856 74 1382 152 619 92 463 187 1784 60
+ 5.004_70 1863 75 1456 154 675 92 494 194 1809 60
+ 5.004_73 1874 76 1467 152 762 102 506 196 1883 61
+ 5.004_75 1877 76 1467 152 770 103 508 196 1896 62
+ 5.005 1896 76 1469 152 795 103 509 197 1945 63
The "core"..."doc" mean the following files from the Perl source code
distribution. The glob notation ** means recursively, (.) means
@@ -347,62 +362,84 @@ the Perl source distribution for somewhat more selected releases.
======================================================================
Legend: kB #
- 1.014 2.001 3.044 4.000 4.019 4.036
-
- atarist - - - - - - - - - - 113 31
- Configure 31 1 37 1 62 1 73 1 83 1 86 1
- eg - - 34 28 47 39 47 39 47 39 47 39
- emacs - - - - - - 67 4 67 4 67 4
- h2pl - - - - 12 12 12 12 12 12 12 12
- hints - - - - - - - - 5 42 11 56
- msdos - - - - 41 13 57 15 58 15 60 15
- os2 - - - - 63 22 81 29 81 29 113 31
- usub - - - - 21 16 25 7 43 8 43 8
- x2p 103 17 104 17 137 17 147 18 152 19 154 19
+ 1.014 2.001 3.044 4.000 4.019 4.036
+
+ atarist - - - - - - - - - - 113 31
+ Configure 31 1 37 1 62 1 73 1 83 1 86 1
+ eg - - 34 28 47 39 47 39 47 39 47 39
+ emacs - - - - - - 67 4 67 4 67 4
+ h2pl - - - - 12 12 12 12 12 12 12 12
+ hints - - - - - - - - 5 42 11 56
+ msdos - - - - 41 13 57 15 58 15 60 15
+ os2 - - - - 63 22 81 29 81 29 113 31
+ usub - - - - 21 16 25 7 43 8 43 8
+ x2p 103 17 104 17 137 17 147 18 152 19 154 19
======================================================================
- 5.000a2 5.000a12h 5.000b3h 5.000 5.001m 5.002 5.003
-
+ 5.000a2 5.000a12h 5.000b3h 5.000 5.001m 5.002 5.003
+
atarist 113 31 113 31 - - - - - - - - - -
bench - - 0 1 - - - - - - - - - -
Bugs 2 5 26 1 - - - - - - - - - -
dlperl 40 5 - - - - - - - - - - - -
do 127 71 - - - - - - - - - - - -
- Configure - - 153 1 159 1 160 1 180 1 201 1 201 1
- Doc - - 26 1 75 7 11 1 11 1 - - - -
- eg 79 58 53 44 51 43 54 44 54 44 54 44 54 44
- emacs 67 4 104 6 104 6 104 1 104 6 108 1 108 1
- h2pl 12 12 12 12 12 12 12 12 12 12 12 12 12 12
- hints 11 56 12 46 18 48 18 48 44 56 73 59 77 60
- msdos 60 15 60 15 - - - - - - - - - -
- os2 113 31 113 31 - - - - - - 84 17 56 10
- U - - 62 8 112 42 - - - - - - - -
+ Configure - - 153 1 159 1 160 1 180 1 201 1 201 1
+ Doc - - 26 1 75 7 11 1 11 1 - - - -
+ eg 79 58 53 44 51 43 54 44 54 44 54 44 54 44
+ emacs 67 4 104 6 104 6 104 1 104 6 108 1 108 1
+ h2pl 12 12 12 12 12 12 12 12 12 12 12 12 12 12
+ hints 11 56 12 46 18 48 18 48 44 56 73 59 77 60
+ msdos 60 15 60 15 - - - - - - - - - -
+ os2 113 31 113 31 - - - - - - 84 17 56 10
+ U - - 62 8 112 42 - - - - - - - -
usub 43 8 - - - - - - - - - - - -
- utils - - - - - - - - - - 87 7 88 7
- vms - - 80 7 123 9 184 15 304 20 500 24 475 26
- x2p 171 22 171 21 162 20 162 20 279 20 280 20 280 20
+ utils - - - - - - - - - - 87 7 88 7
+ vms - - 80 7 123 9 184 15 304 20 500 24 475 26
+ x2p 171 22 171 21 162 20 162 20 279 20 280 20 280 20
+
+ ======================================================================
+
+ 5.003_07 5.004 5.004_04 5.004_62 5.004_65 5.004_68
+
+ beos - - - - - - - - 1 1 1 1
+ Configure 217 1 225 1 225 1 240 1 248 1 256 1
+ cygwin32 - - 23 5 23 5 23 5 24 5 24 5
+ djgpp - - - - - - 14 5 14 5 14 5
+ eg 54 44 81 62 81 62 81 62 81 62 81 62
+ emacs 143 1 194 1 204 1 212 2 212 2 212 2
+ h2pl 12 12 12 12 12 12 12 12 12 12 12 12
+ hints 90 62 129 69 132 71 144 72 151 74 155 74
+ os2 117 42 121 42 127 42 127 44 129 44 129 44
+ plan9 79 15 82 15 82 15 82 15 82 15 82 15
+ Porting 51 1 94 2 109 4 203 6 234 8 241 9
+ qnx - - 1 2 1 2 1 2 1 2 1 2
+ utils 97 7 112 8 118 8 124 8 156 9 159 9
+ vms 505 27 518 34 524 34 538 34 569 34 569 34
+ win32 - - 285 33 378 36 470 39 493 39 575 41
+ x2p 280 19 281 19 281 19 281 19 282 19 281 19
======================================================================
- 5.003_07 5.004 5.004_04 5.004_62 5.004_65
-
- beos - - - - - - - - 1 1
- Configure 217 1 225 1 225 1 240 1 248 1
- cygwin32 - - 23 5 23 5 23 5 24 5
- djgpp - - - - - - 14 5 14 5
- eg 54 44 81 62 81 62 81 62 81 62
- emacs 143 1 194 1 204 1 212 2 212 2
- h2pl 12 12 12 12 12 12 12 12 12 12
- hints 90 62 129 69 132 71 144 72 151 74
- os2 117 42 121 42 127 42 127 44 129 44
- plan9 79 15 82 15 82 15 82 15 82 15
- Porting 51 1 94 2 109 4 203 6 234 8
- qnx - - 1 2 1 2 1 2 1 2
- utils 97 7 112 8 118 8 124 8 156 9
- vms 505 27 518 34 524 34 538 34 569 34
- win32 - - 285 33 378 36 470 39 493 39
- x2p 280 19 281 19 281 19 281 19 282 19
+ 5.004_70 5.004_73 5.004_75 5.005
+
+ beos 1 1 1 1 1 1 1 1
+ Configure 256 1 256 1 264 1 264 1
+ cygwin32 24 5 24 5 24 5 24 5
+ djgpp 14 5 14 5 14 5 14 5
+ eg 86 65 86 65 86 65 86 65
+ emacs 262 2 262 2 262 2 262 2
+ h2pl 12 12 12 12 12 12 12 12
+ hints 157 74 157 74 159 74 160 74
+ mpeix - - - - 5 3 5 3
+ os2 129 44 139 44 142 44 143 44
+ plan9 82 15 82 15 82 15 82 15
+ Porting 241 9 253 9 259 10 264 12
+ qnx 1 2 1 2 1 2 1 2
+ utils 160 9 160 9 160 9 160 9
+ vms 570 34 572 34 573 34 575 34
+ win32 577 41 585 41 585 41 587 41
+ x2p 281 19 281 19 281 19 281 19
=head2 SELECTED PATCH SIZES
diff --git a/pod/perllocale.pod b/pod/perllocale.pod
index a3e3998883..4401be2053 100644
--- a/pod/perllocale.pod
+++ b/pod/perllocale.pod
@@ -169,15 +169,23 @@ combination of language, country or territory, and codeset. Read on for
hints on the naming of locales: not all systems name locales as in the
example.
-If no second argument is provided, the function returns a string naming
-the current locale for the category. You can use this value as the
-second argument in a subsequent call to setlocale(). If a second
-argument is given and it corresponds to a valid locale, the locale for
-the category is set to that value, and the function returns the
-now-current locale value. You can then use this in yet another call to
-setlocale(). (In some implementations, the return value may sometimes
-differ from the value you gave as the second argument--think of it as
-an alias for the value you gave.)
+If no second argument is provided and the category is something else
+than LC_ALL, the function returns a string naming the current locale
+for the category. You can use this value as the second argument in a
+subsequent call to setlocale().
+
+If no second argument is provided and the category is LC_ALL, the
+result is implementation-dependent. It may be a string of
+concatenated locales names (separator also implementation-dependent)
+or a single locale name. Please consult your L<setlocale(3)> for
+details.
+
+If a second argument is given and it corresponds to a valid locale,
+the locale for the category is set to that value, and the function
+returns the now-current locale value. You can then use this in yet
+another call to setlocale(). (In some implementations, the return
+value may sometimes differ from the value you gave as the second
+argument--think of it as an alias for the value you gave.)
As the example shows, if the second argument is an empty string, the
category's locale is returned to the default specified by the
@@ -210,10 +218,12 @@ I<SEE ALSO> section). If that fails, try the following command lines:
and see whether they list something resembling these
en_US.ISO8859-1 de_DE.ISO8859-1 ru_RU.ISO8859-5
+ en_US.iso88591 de_DE.iso88591 ru_RU.iso88595
en_US de_DE ru_RU
en de ru
english german russian
english.iso88591 german.iso88591 russian.iso88595
+ english.roman8 russian.koi8r
Sadly, even though the calling interface for setlocale() has
been standardized, names of locales and the directories where the
@@ -368,11 +378,12 @@ with a single parameter--see L<The setlocale function>.)
localeconv() takes no arguments, and returns B<a reference to> a hash.
The keys of this hash are variable names for formatting, such as
-C<decimal_point> and C<thousands_sep>. The values are the corresponding,
-er, values. See L<POSIX (3)/localeconv> for a longer example listing
-the categories an implementation might be expected to provide; some
-provide more and others fewer, however. You don't need an explicit C<use
-locale>, because localeconv() always observes the current locale.
+C<decimal_point> and C<thousands_sep>. The values are the
+corresponding, er, values. See L<POSIX (3)/localeconv> for a longer
+example listing the categories an implementation might be expected to
+provide; some provide more and others fewer. You don't need an
+explicit C<use locale>, because localeconv() always observes the
+current locale.
Here's a simple-minded example program that rewrites its command-line
parameters as integers correctly formatted in the current locale:
@@ -387,13 +398,29 @@ parameters as integers correctly formatted in the current locale:
# Apply defaults if values are missing
$thousands_sep = ',' unless $thousands_sep;
- $grouping = 3 unless $grouping;
+
+ # grouping and mon_grouping are packed lists
+ # of small integers (characters) telling the
+ # grouping (thousand_seps and mon_thousand_seps
+ # being the group dividers) of numbers and
+ # monetary quantities. The integers' meanings:
+ # 255 means no more grouping, 0 means repeat
+ # the previous grouping, 1-254 means use that
+ # as the current grouping. Grouping goes from
+ # right to left (low to high digits). In the
+ # below we cheat slightly by never using anything
+ # else than the first grouping (whatever that is).
+ if ($grouping) {
+ @grouping = unpack("C*", $grouping);
+ } else {
+ @grouping = (3);
+ }
# Format command line params for current locale
for (@ARGV) {
$_ = int; # Chop non-integer part
1 while
- s/(\d)(\d{$grouping}($|$thousands_sep))/$1$thousands_sep$2/;
+ s/(\d)(\d{$grouping[0]}($|$thousands_sep))/$1$thousands_sep$2/;
print "$_";
}
print "\n";
diff --git a/pod/perlport.pod b/pod/perlport.pod
index 83654689a6..79ca76769f 100644
--- a/pod/perlport.pod
+++ b/pod/perlport.pod
@@ -10,23 +10,25 @@ a lot in common, they also have their own very particular and unique
features.
This document is meant to help you to find out what constitutes portable
-perl code, so that once you have made your decision to write portably,
+Perl code, so that once you have made your decision to write portably,
you know where the lines are drawn, and you can stay within them.
There is a tradeoff between taking full advantage of B<a> particular type
-of computer, and taking advantage of a full B<range> of them. Naturally,
-as you make your range bigger (and thus more diverse), the common denominators
-drop, and you are left with fewer areas of common ground in which
-you can operate to accomplish a particular task. Thus, when you begin
-attacking a problem, it is important to consider which part of the tradeoff
-curve you want to operate under. Specifically, whether it is important to
-you that the task that you are coding needs the full generality of being
-portable, or if it is sufficient to just get the job done. This is the
-hardest choice to be made. The rest is easy, because Perl provides lots
-of choices, whichever way you want to approach your problem.
-
-Looking at it another way, writing portable code is usually about willfully
-limiting your available choices. Naturally, it takes discipline to do that.
+of computer, and taking advantage of a full B<range> of them. Naturally,
+as you make your range bigger (and thus more diverse), the common
+denominators drop, and you are left with fewer areas of common ground in
+which you can operate to accomplish a particular task. Thus, when you
+begin attacking a problem, it is important to consider which part of the
+tradeoff curve you want to operate under. Specifically, whether it is
+important to you that the task that you are coding needs the full
+generality of being portable, or if it is sufficient to just get the job
+done. This is the hardest choice to be made. The rest is easy, because
+Perl provides lots of choices, whichever way you want to approach your
+problem.
+
+Looking at it another way, writing portable code is usually about
+willfully limiting your available choices. Naturally, it takes discipline
+to do that.
Be aware of two important points:
@@ -59,18 +61,25 @@ take advantage of some unique feature of a particular platform, as is
often the case with systems programming (whether for Unix, Windows,
S<Mac OS>, VMS, etc.), consider writing platform-specific code.
-When the code will run on only two or three operating systems, then you may
-only need to consider the differences of those particular systems. The
-important thing is to decide where the code will run, and to be deliberate
-in your decision.
+When the code will run on only two or three operating systems, then you
+may only need to consider the differences of those particular systems.
+The important thing is to decide where the code will run, and to be
+deliberate in your decision.
+
+The material below is separated into three main sections: main issues of
+portability (L<"ISSUES">, platform-specific issues (L<"PLATFORMS">, and
+builtin perl functions that behave differently on various ports
+(L<"FUNCTION IMPLEMENTATIONS">.
This information should not be considered complete; it includes possibly
-transient information about idiosyncracies of some of the ports, almost
+transient information about idiosyncrasies of some of the ports, almost
all of which are in a state of constant evolution. Thus this material
should be considered a perpetual work in progress
(E<lt>IMG SRC="yellow_sign.gif" ALT="Under Construction"E<gt>).
+
+
=head1 ISSUES
=head2 Newlines
@@ -97,7 +106,7 @@ C<binmode> on a file, however, you can usually use C<seek> and C<tell>
with arbitrary values quite safely.
A common misconception in socket programming is that C<\n> eq C<\012>
-everywhere. When using protocols, such as common Internet protocols,
+everywhere. When using protocols such as common Internet protocols,
C<\012> and C<\015> are called for specifically, and the values of
the logical C<\n> and C<\r> (carriage return) are not reliable.
@@ -110,9 +119,9 @@ the most popular EBCDIC webserver, for instance, accepts C<\r\n>,
which translates those characters, along with all other
characters in text streams, from EBCDIC to ASCII.]
-However, C<\015\012> (or C<\cM\cJ>, or C<\x0D\x0A>) can be tedious and
-unsightly, as well as confusing to those maintaining the code. As such,
-the C<Socket> module supplies the Right Thing for those who want it.
+However, using C<\015\012> (or C<\cM\cJ>, or C<\x0D\x0A>) can be tedious
+and unsightly, as well as confusing to those maintaining the code. As
+such, the C<Socket> module supplies the Right Thing for those who want it.
use Socket qw(:DEFAULT :crlf);
print SOCKET "Hi there, client!$CRLF" # RIGHT
@@ -140,7 +149,33 @@ platforms, because now any C<\015>'s (C<\cM>'s) are stripped out
(and there was much rejoicing).
-=head2 File Paths
+=head2 Numbers endianness and Width
+
+Different CPUs store integers and floating point numbers in different
+orders (called I<endianness>) and widths (32-bit and 64-bit being the
+most common). This affects your programs if they attempt to transfer
+numbers in binary format from a CPU architecture to another over some
+channel: either 'live' via network connections or storing the numbers
+to secondary storage such as a disk file.
+
+Conflicting storage orders make utter mess out of the numbers: if a
+little-endian host (Intel, Alpha) stores 0x12345678 (305419896 in
+decimal), a big-endian host (Motorola, MIPS, Sparc, PA) reads it as
+0x78563412 (2018915346 in decimal). To avoid this problem in network
+(socket) connections use the C<pack()> and C<unpack()> formats C<"n">
+and C<"N">, the "network" orders, they are guaranteed to be portable.
+
+Different widths can cause truncation even between platforms of equal
+endianness: the platform of shorter width loses the upper parts of the
+number. There is no good solution for this problem except to avoid
+transferring or storing raw binary numbers.
+
+One can circumnavigate both these problems in two ways: either
+transfer and store numbers always in text format, instead of raw
+binary, or consider using modules like C<Data::Dumper> (included in
+the standard distribution as of Perl 5.005) and C<Storable>.
+
+=head2 Files
Most platforms these days structure files in a hierarchical fashion.
So, it is reasonably safe to assume that any platform supports the
@@ -148,11 +183,20 @@ notion of a "path" to uniquely identify a file on the system. Just
how that path is actually written, differs.
While they are similar, file path specifications differ between Unix,
-Windows, S<Mac OS>, OS/2, VMS and probably others. Unix, for example, is
-one of the few OSes that has the idea of a root directory. S<Mac OS>
-uses C<:> as a path separator instead of C</>. VMS, Windows, and OS/2
-can work similarly to Unix with C</> as path separator, or in their own
-idiosyncratic ways.
+Windows, S<Mac OS>, OS/2, VMS, S<RISC OS> and probably others. Unix,
+for example, is one of the few OSes that has the idea of a single root
+directory.
+
+VMS, Windows, and OS/2 can work similarly to Unix with C</> as path
+separator, or in their own idiosyncratic ways (such as having several
+root directories and various "unrooted" device files such NIL: and
+LPT:).
+
+S<Mac OS> uses C<:> as a path separator instead of C</>.
+
+C<RISC OS> perl can emulate Unix filenames with C</> as path
+separator, or go native and use C<.> for path separator and C<:> to
+signal filing systems and disc names.
As with the newline problem above, there are modules that can help. The
C<File::Spec> modules provide methods to do the Right Thing on whatever
@@ -180,10 +224,32 @@ Also of use is C<File::Basename>, from the standard distribution, which
splits a pathname into pieces (base filename, full path to directory,
and file suffix).
-Remember not to count on the existence of system-specific files, like
-F</etc/resolv.conf>. If code does need to rely on such a file, include a
-description of the file and its format in the code's documentation, and
-make it easy for the user to override the default location of the file.
+Even when on a single platform (if you can call UNIX a single
+platform), remember not to count on the existence or the contents of
+system-specific files, like F</etc/passwd>, F</etc/sendmail.conf>, or
+F</etc/resolv.conf>. For example the F</etc/passwd> may exist but it
+may not contain the encrypted passwords because the system is using
+some form of enhanced security-- or it may not contain all the
+accounts because the system is using NIS. If code does need to rely
+on such a file, include a description of the file and its format in
+the code's documentation, and make it easy for the user to override
+the default location of the file.
+
+Do not have two files of the same name with different case, like
+F<test.pl> and <Test.pl>, as many platforms have case-insensitive
+filenames. Also, try not to have non-word characters (except for C<.>)
+in the names, and keep them to the 8.3 convention, for maximum
+portability.
+
+Likewise, if using C<AutoSplit>, try to keep the split functions to
+8.3 naming and case-insensitive conventions; or, at the very least,
+make it so the resulting files have a unique (case-insensitively)
+first 8 characters.
+
+Don't assume C<E<lt>> won't be the first character of a filename. Always
+use C<E<gt>> explicitly to open a file for reading:
+
+ open(FILE, "<$existing_file") or die $!;
=head2 System Interaction
@@ -199,21 +265,27 @@ the system. Remember to C<close> files when you are done with them.
Don't C<unlink> or C<rename> an open file. Don't C<tie> to or C<open> a
file that is already tied to or opened; C<untie> or C<close> first.
+Don't open the same file more than once at a time for writing, as some
+operating systems put mandatory locks on such files.
+
Don't count on a specific environment variable existing in C<%ENV>.
-Don't even count on C<%ENV> entries being case-sensitive, or even
+Don't count on C<%ENV> entries being case-sensitive, or even
case-preserving.
-Don't count on signals in portable programs.
+Don't count on signals.
Don't count on filename globbing. Use C<opendir>, C<readdir>, and
C<closedir> instead.
+Don't count on per-program environment variables, or per-program current
+directories.
+
=head2 Interprocess Communication (IPC)
In general, don't directly access the system in code that is meant to be
-portable. That means, no: C<system>, C<exec>, C<fork>, C<pipe>, C<``>,
-C<qx//>, C<open> with a C<|>, or any of the other things that makes being
+portable. That means, no C<system>, C<exec>, C<fork>, C<pipe>, C<``>,
+C<qx//>, C<open> with a C<|>, nor any of the other things that makes being
a Unix perl hacker worth being.
Commands that launch external processes are generally supported on
@@ -238,10 +310,11 @@ mailing methods, including mail, sendmail, and direct SMTP
(via C<Net::SMTP>) if a mail transfer agent is not available.
The rule of thumb for portable code is: Do it all in portable Perl, or
-use a module that may internally implement it with platform-specific code,
-but expose a common interface. By portable Perl, we mean code that
-avoids the constructs described in this document as being non-portable.
+use a module (that may internally implement it with platform-specific
+code, but expose a common interface).
+The UNIX System V IPC (C<msg*(), sem*(), shm*()>) is not available
+even in all UNIX platforms.
=head2 External Subroutines (XS)
@@ -252,8 +325,8 @@ code might be. If the libraries and headers are portable, then it is
normally reasonable to make sure the XS code is portable, too.
There is a different kind of portability issue with writing XS
-code: availability of a C compiler on the end-user's system. C brings with
-it its own portability issues, and writing XS code will expose you to
+code: availability of a C compiler on the end-user's system. C brings
+with it its own portability issues, and writing XS code will expose you to
some of those. Writing purely in perl is a comparatively easier way to
achieve portability.
@@ -267,7 +340,8 @@ C<ExtUtils::MM_VMS>), and DBM modules.
There is no one DBM module that is available on all platforms.
C<SDBM_File> and the others are generally available on all Unix and DOSish
-ports, but not in MacPerl, where C<NBDM_File> and C<DB_File> are available.
+ports, but not in MacPerl, where only C<NBDM_File> and C<DB_File> are
+available.
The good news is that at least some DBM module should be available, and
C<AnyDBM_File> will use whichever module it can find. Of course, then
@@ -277,24 +351,49 @@ denominator (e.g., not exceeding 1K for each record).
=head2 Time and Date
-The system's notion of time of day and calendar date is controlled in widely
-different ways. Don't assume the timezone is stored in C<$ENV{TZ}>, and even
-if it is, don't assume that you can control the timezone through that
-variable.
+The system's notion of time of day and calendar date is controlled in
+widely different ways. Don't assume the timezone is stored in C<$ENV{TZ}>,
+and even if it is, don't assume that you can control the timezone through
+that variable.
+
+Don't assume that the epoch starts at 00:00:00, January 1, 1970,
+because that is OS-specific. Better to store a date in an unambiguous
+representation. The ISO 8601 standard defines YYYY-MM-DD as the date
+format. A text representation (like C<1 Jan 1970>) can be easily
+converted into an OS-specific value using a module like
+C<Date::Parse>. An array of values, such as those returned by
+C<localtime>, can be converted to an OS-specific representation using
+C<Time::Local>.
+
+
+=head2 Character sets and character encoding
+
+Assume very little about character sets. Do not assume anything about
+the numerical values (C<ord()>, C<chr()>) of characters. Do not
+assume that the alphabetic characters are encoded contiguously (in
+numerical sense). Do no assume anything about the ordering of the
+characters. The lowercase letters may come before or after the
+uppercase letters, the lowercase and uppercase may be interlaced so
+that both 'a' and 'A' come before the 'b', the accented and other
+international characters may be interlaced so that E<auml> comes
+before the 'b'.
+
-Don't assume that the epoch starts at January 1, 1970, because that is
-OS-specific. Better to store a date in an unambiguous representation.
-A text representation (like C<1 Jan 1970>) can be easily converted into an
-OS-specific value using a module like C<Date::Parse>. An array of values,
-such as those returned by C<localtime>, can be converted to an OS-specific
-representation using C<Time::Local>.
+=head2 Internationalisation
+
+If you may assume POSIX (a rather large assumption, that: in practise
+that means UNIX) you may read more about the POSIX locale system from
+L<perllocale>. The locale system at least attempts to make things a
+little bit more portable or at least more convenient and
+native-friendly for non-English users. The system affects character
+sets and encoding, and date and time formatting, among other things.
=head2 System Resources
-If your code is destined for systems with severely constrained (or missing!)
-virtual memory systems then you want to be especially mindful of avoiding
-wasteful constructs such as:
+If your code is destined for systems with severely constrained (or
+missing!) virtual memory systems then you want to be I<especially> mindful
+of avoiding wasteful constructs such as:
# NOTE: this is no longer "bad" in perl5.005
for (0..10000000) {} # bad
@@ -303,41 +402,45 @@ wasteful constructs such as:
@lines = <VERY_LARGE_FILE>; # bad
while (<FILE>) {$file .= $_} # sometimes bad
- $file = join '', <FILE>; # better
+ $file = join('', <FILE>); # better
The last two may appear unintuitive to most people. The first of those
two constructs repeatedly grows a string, while the second allocates a
large chunk of memory in one go. On some systems, the latter is more
efficient that the former.
+
=head2 Security
-Most Unix platforms provide basic levels of security that is usually felt
-at the file-system level. Other platforms usually don't (unfortunately).
-Thus the notion of User-ID, or "home" directory, or even the state of
-being logged-in may be unrecognizable on may platforms. If you write
-programs that are security conscious, it is usually best to know what
-type of system you will be operating under, and write code explicitly
+Most multi-user platforms provide basic levels of security that is usually
+felt at the file-system level. Other platforms usually don't
+(unfortunately). Thus the notion of user id, or "home" directory, or even
+the state of being logged-in, may be unrecognizable on many platforms. If
+you write programs that are security conscious, it is usually best to know
+what type of system you will be operating under, and write code explicitly
for that platform (or class of platforms).
+
=head2 Style
For those times when it is necessary to have platform-specific code,
consider keeping the platform-specific code in one place, making porting
to other platforms easier. Use the C<Config> module and the special
-variable C<$^O> to differentiate platforms, as described in L<"PLATFORMS">.
+variable C<$^O> to differentiate platforms, as described in
+L<"PLATFORMS">.
-=head1 CPAN TESTERS
+=head1 CPAN Testers
-Module uploaded to CPAN are tested by a variety of volunteers on
-different platforms. These CPAN testers are notified by e-mail of each
+Modules uploaded to CPAN are tested by a variety of volunteers on
+different platforms. These CPAN testers are notified by mail of each
new upload, and reply to the list with PASS, FAIL, NA (not applicable to
-this platform), or ???? (unknown), along with any relevant notations.
+this platform), or UNKNOWN (unknown), along with any relevant notations.
The purpose of the testing is twofold: one, to help developers fix any
-problems in their code; two, to provide users with information about
-whether or not a given module works on a given platform.
+problems in their code that crop up because of lack of testing on other
+platforms; two, to provide users with information about whether or not
+a given module works on a given platform.
=over 4
@@ -363,23 +466,24 @@ Perl works on a bewildering variety of Unix and Unix-like platforms (see
e.g. most of the files in the F<hints/> directory in the source code kit).
On most of these systems, the value of C<$^O> (hence C<$Config{'osname'}>,
too) is determined by lowercasing and stripping punctuation from the first
-field of the string returned by typing
-
- % uname -a
-
-(or a similar command) at the shell prompt. Here, for example, are a few
-of the more popular Unix flavors:
-
- uname $^O
- --------------------
- AIX aix
- FreeBSD freebsd
- Linux linux
- HP-UX hpux
- OSF1 dec_osf
- SunOS solaris
- SunOS4 sunos
-
+field of the string returned by typing C<uname -a> (or a similar command)
+at the shell prompt. Here, for example, are a few of the more popular
+Unix flavors:
+
+ uname $^O $Config{'archname'}
+ -------------------------------------------
+ AIX aix aix
+ FreeBSD freebsd freebsd-i386
+ Linux linux i386-linux
+ HP-UX hpux PA-RISC1.1
+ IRIX irix irix
+ OSF1 dec_osf alpha-dec_osf
+ SunOS solaris sun4-solaris
+ SunOS solaris i86pc-solaris
+ SunOS4 sunos sun4-sunos
+
+Note that because the C<$Config{'archname'}> may depend on the hardware
+architecture it may vary quite a lot, much more than the C<$^O>.
=head2 DOS and Derivatives
@@ -402,9 +506,9 @@ from calling any external programs, C</> will work just fine, and
probably better, as it is more consistent with popular usage, and avoids
the problem of remembering what to backwhack and what not to.
-The DOS FAT file system can only accomodate "8.3" style filenames. Under
+The DOS FAT filesystem can only accommodate "8.3" style filenames. Under
the "case insensitive, but case preserving" HPFS (OS/2) and NTFS (NT)
-file systems you may have to be careful about case returned with functions
+filesystems you may have to be careful about case returned with functions
like C<readdir> or used with functions like C<open> or C<opendir>.
DOS also treats several filenames as special, such as AUX, PRN, NUL, CON,
@@ -452,12 +556,13 @@ C<http://www.juge.com/bbs/Hobb.19.html>
=back
-=head2 MacPerl
+=head2 S<Mac OS>
Any module requiring XS compilation is right out for most people, because
MacPerl is built using non-free (and non-cheap!) compilers. Some XS
modules that can work with MacPerl are built and distributed in binary
-form on CPAN. See I<MacPerl: Power and Ease> for more details.
+form on CPAN. See I<MacPerl: Power and Ease> and L<"CPAN Testers">
+for more details.
Directories are specified as:
@@ -472,8 +577,8 @@ Files in a directory are stored in alphabetical order. Filenames are
limited to 31 characters, and may include any character except C<:>,
which is reserved as a path separator.
-Instead of C<flock>, see C<FSpSetFLock> and C<FSpRstFLock> in
-C<Mac::Files>.
+Instead of C<flock>, see C<FSpSetFLock> and C<FSpRstFLock> in the
+C<Mac::Files> module.
In the MacPerl application, you can't run a program from the command line;
programs that expect C<@ARGV> to be populated can be edited with something
@@ -495,7 +600,7 @@ shell:
perl myscript.plx some arguments
ToolServer is another app from Apple that provides access to MPW tools
-from MPW and the MacPerl app, which allows MacPerl program to use
+from MPW and the MacPerl app, which allows MacPerl programs to use
C<system>, backticks, and piped C<open>.
"S<Mac OS>" is the proper name for the operating system, but the value
@@ -508,6 +613,10 @@ the application or MPW tool version is running, check:
$is_ppc = $MacPerl::Architecture eq 'MacPPC';
$is_68k = $MacPerl::Architecture eq 'Mac68K';
+S<Mac OS X>, to be based on NeXT's OpenStep OS, will be able to run
+MacPerl natively (in the Blue Box, and even in the Yellow Box, once some
+changes to the toolbox calls are made), but Unix perl will also run
+natively.
Also see:
@@ -523,7 +632,7 @@ Also see:
=head2 VMS
Perl on VMS is discussed in F<vms/perlvms.pod> in the perl distribution.
-Note that perl on VMS can accept either VMS or Unix style file
+Note that perl on VMS can accept either VMS- or Unix-style file
specifications as in either of the following:
$ perl -ne "print if /perl_setup/i" SYS$LOGIN:LOGIN.COM
@@ -566,20 +675,22 @@ extensions is also 39 characters. Version is a number from 1 to
VMS' RMS filesystem is case insensitive and does not preserve case.
C<readdir> returns lowercased filenames, but specifying a file for
-opening remains case insensitive. Files without extensions have a
+opening remains case insensitive. Files without extensions have a
trailing period on them, so doing a C<readdir> with a file named F<A.;5>
-will return F<a.> (though that file could be opened with C<open(FH, 'A')>.
+will return F<a.> (though that file could be opened with
+C<open(FH, 'A')>).
-RMS has an eight level limit on directory depths from any rooted logical
-(allowing 16 levels overall). Hence C<PERL_ROOT:[LIB.2.3.4.5.6.7.8]>
-is a valid directory specification but C<PERL_ROOT:[LIB.2.3.4.5.6.7.8.9]>
-is not. F<Makefile.PL> authors might have to take this into account, but
-at least they can refer to the former as C</PERL_ROOT/lib/2/3/4/5/6/7/8/>.
+RMS had an eight level limit on directory depths from any rooted logical
+(allowing 16 levels overall) prior to VMS 7.2. Hence
+C<PERL_ROOT:[LIB.2.3.4.5.6.7.8]> is a valid directory specification but
+C<PERL_ROOT:[LIB.2.3.4.5.6.7.8.9]> is not. F<Makefile.PL> authors might
+have to take this into account, but at least they can refer to the former
+as C</PERL_ROOT/lib/2/3/4/5/6/7/8/>.
-The C<VMS::Filespec> module, which gets installed as part
-of the build process on VMS, is a pure Perl module that can easily be
-installed on non-VMS platforms and can be helpful for conversions to
-and from RMS native formats.
+The C<VMS::Filespec> module, which gets installed as part of the build
+process on VMS, is a pure Perl module that can easily be installed on
+non-VMS platforms and can be helpful for conversions to and from RMS
+native formats.
What C<\n> represents depends on the type of file that is open. It could
be C<\015>, C<\012>, C<\015\012>, or nothing. Reading from a file
@@ -637,15 +748,15 @@ can executed with a header similar to the following simple script:
print "Hello from perl!\n";
On these platforms, bear in mind that the EBCDIC character set may have
-an effect on what happens with perl functions such as C<chr>, C<pack>,
-C<print>, C<printf>, C<ord>, C<sort>, C<sprintf>, C<unpack>; as well as
-bit-fiddling with ASCII constants using operators like C<^>, C<&> and
-C<|>; not to mention dealing with socket interfaces to ASCII computers
+an effect on what happens with some perl functions (such as C<chr>,
+C<pack>, C<print>, C<printf>, C<ord>, C<sort>, C<sprintf>, C<unpack>), as
+well as bit-fiddling with ASCII constants using operators like C<^>, C<&>
+and C<|>, not to mention dealing with socket interfaces to ASCII computers
(see L<"NEWLINES">).
Fortunately, most web servers for the mainframe will correctly translate
the C<\n> in the following statement to its ASCII equivalent (note that
-C<\r> is the same under both ASCII and EBCDIC):
+C<\r> is the same under both Unix and OS/390):
print "Content-type: text/html\r\n\r\n";
@@ -661,9 +772,9 @@ platform could include any of the following (perhaps all):
if (chr(169) eq 'z') { print "EBCDIC may be spoken here!\n"; }
Note that one thing you may not want to rely on is the EBCDIC encoding
-of punctuation characters since these may differ from code page to code page
-(and once your module or script is rumoured to work with EBCDIC, folks will
-want it to work with all EBCDIC character sets).
+of punctuation characters since these may differ from code page to code
+page (and once your module or script is rumoured to work with EBCDIC,
+folks will want it to work with all EBCDIC character sets).
Also see:
@@ -675,19 +786,131 @@ The perl-mvs@perl.org list is for discussion of porting issues as well as
general usage issues for all EBCDIC Perls. Send a message body of
"subscribe perl-mvs" to majordomo@perl.org.
-=item AS/400 Perl information at C<http://as400.rochester.ibm.com>
+=item AS/400 Perl information at C<http://as400.rochester.ibm.com/>
=back
+
+=head2 Acorn RISC OS
+
+As Acorns use ASCII with newlines (C<\n>) in text files as C<\012> like
+Unix and Unix filename emulation is turned on by default, it is quite
+likely that most simple scripts will work "out of the box". The native
+filing system is modular, and individual filing systems are free to be
+case-sensitive or insensitive, and are usually case-preserving. Some
+native filing systems have name length limits which file and directory
+names are silently truncated to fit - scripts should be aware that the
+standard disc filing system currently has a name length limit of B<10>
+characters, with up to 77 items in a directory, but other filing systems
+may not impose such limitations.
+
+Native filenames are of the form
+
+ Filesystem#Special_Field::DiscName.$.Directory.Directory.File
+
+where
+
+ Special_Field is not usually present, but may contain . and $ .
+ Filesystem =~ m|[A-Za-z0-9_]|
+ DsicName =~ m|[A-Za-z0-9_/]|
+ $ represents the root directory
+ . is the path separator
+ @ is the current directory (per filesystem but machine global)
+ ^ is the parent directory
+ Directory and File =~ m|[^\0- "\.\$\%\&:\@\\^\|\177]+|
+
+The default filename translation is roughly C<tr|/.|./|;>
+
+Note that C<"ADFS::HardDisc.$.File" ne 'ADFS::HardDisc.$.File'> and that
+the second stage of C<$> interpolation in regular expressions will fall
+foul of the C<$.> if scripts are not careful.
+
+Logical paths specified by system variables containing comma-separated
+search lists are also allowed, hence C<System:Modules> is a valid
+filename, and the filesystem will prefix C<Modules> with each section of
+C<System$Path> until a name is made that points to an object on disc.
+Writing to a new file C<System:Modules> would only be allowed if
+C<System$Path> contains a single item list. The filesystem will also
+expand system variables in filenames if enclosed in angle brackets, so
+C<E<lt>System$DirE<gt>.Modules> would look for the file
+S<C<$ENV{'System$Dir'} . 'Modules'>>. The obvious implication of this is
+that B<fully qualified filenames can start with C<E<lt>E<gt>> and should
+be protected when C<open> is used for input.
+
+Because C<.> was in use as a directory separator and filenames could not
+be assumed to be unique after 10 characters, Acorn implemented the C
+compiler to strip the trailing C<.c> C<.h> C<.s> and C<.o> suffix from
+filenames specified in source code and store the respective files in
+subdirectories named after the suffix. Hence files are translated:
+
+ foo.h h.foo
+ C:foo.h C:h.foo (logical path variable)
+ sys/os.h sys.h.os (C compiler groks Unix-speak)
+ 10charname.c c.10charname
+ 10charname.o o.10charname
+ 11charname_.c c.11charname (assuming filesystem truncates at 10)
+
+The Unix emulation library's translation of filenames to native assumes
+that this sort of translation is required, and allows a user defined list
+of known suffixes which it will transpose in this fashion. This may
+appear transparent, but consider that with these rules C<foo/bar/baz.h>
+and C<foo/bar/h/baz> both map to C<foo.bar.h.baz>, and that C<readdir> and
+C<glob> cannot and do not attempt to emulate the reverse mapping. Other
+C<.>s in filenames are translated to C</>.
+
+As implied above the environment accessed through C<%ENV> is global, and
+the convention is that program specific environment variables are of the
+form C<Program$Name>. Each filing system maintains a current directory,
+and the current filing system's current directory is the B<global> current
+directory. Consequently, sociable scripts don't change the current
+directory but rely on full pathnames, and scripts (and Makefiles) cannot
+assume that they can spawn a child process which can change the current
+directory without affecting its parent (and everyone else for that
+matter).
+
+As native operating system filehandles are global and currently are
+allocated down from 255, with 0 being a reserved value the Unix emulation
+library emulates Unix filehandles. Consequently, you can't rely on
+passing C<STDIN>, C<STDOUT>, or C<STDERR> to your children.
+
+The desire of users to express filenames of the form
+C<E<lt>Foo$DirE<gt>.Bar> on the command line unquoted causes problems,
+too: C<``> command output capture has to perform a guessing game. It
+assumes that a string C<E<lt>[^E<lt>E<gt>]+\$[^E<lt>E<gt>]E<gt>> is a
+reference to an environment variable, whereas anything else involving
+C<E<lt>> or C<E<gt>> is redirection, and generally manages to be 99%
+right. Of course, the problem remains that scripts cannot rely on any
+Unix tools being available, or that any tools found have Unix-like command
+line arguments.
+
+Extensions and XS are, in theory, buildable by anyone using free tools.
+In practice, many don't, as users of the Acorn platform are used to binary
+distribution. MakeMaker does run, but no available make currently copes
+with MakeMaker's makefiles; even if/when this is fixed, the lack of a
+Unix-like shell can cause problems with makefile rules, especially lines
+of the form C<cd sdbm && make all>, and anything using quoting.
+
+"S<RISC OS>" is the proper name for the operating system, but the value
+in C<$^O> is "riscos" (because we don't like shouting).
+
+Also see:
+
+=over 4
+
+=item perl list
+
+=back
+
+
=head2 Other perls
Perl has been ported to a variety of platforms that do not fit into any of
the above categories. Some, such as AmigaOS, BeOS, QNX, and Plan 9, have
-been well integrated into the standard Perl source code kit. You may need
+been well-integrated into the standard Perl source code kit. You may need
to see the F<ports/> directory on CPAN for information, and possibly
-binaries, for the likes of: acorn, aos, atari, lynxos, HP-MPE/iX, riscos,
-Tandem Guardian, vos, I<etc.> (yes we know that some of these OSes may fall
-under the Unix category but we are not a standards body.)
+binaries, for the likes of: aos, atari, lynxos, riscos, Tandem Guardian,
+vos, I<etc.> (yes we know that some of these OSes may fall under the Unix
+category, but we are not a standards body.)
See also:
@@ -699,7 +922,7 @@ See also:
=item Novell Netware
-A free Perl 5 based PERL.NLM for Novell Netware is available from
+A free perl5-based PERL.NLM for Novell Netware is available from
C<http://www.novell.com/>
=back
@@ -715,14 +938,12 @@ The list may very well be incomplete, or wrong in some places. When in
doubt, consult the platform-specific README files in the Perl source
distribution, and other documentation resources for a given port.
-Be aware, moreover, that even among Unix-ish systems there are variations,
-and not all functions listed here are necessarily available, though
-most usually are.
+Be aware, moreover, that even among Unix-ish systems there are variations.
For many functions, you can also query C<%Config>, exported by default
from C<Config.pm>. For example, to check if the platform has the C<lstat>
-call, check C<$Config{'d_lstat'}>. See L<Config> for a full description
-of available variables.
+call, check C<$Config{'d_lstat'}>. See L<Config.pm> for a full
+description of available variables.
=head2 Alphabetical Listing of Perl Functions
@@ -742,28 +963,38 @@ considerations. C<-o> is not supported. (S<Mac OS>)
C<-r>, C<-w>, C<-x>, and C<-o> tell whether or not file is accessible,
which may not reflect UIC-based file protections. (VMS)
+C<-s> returns the size of the data fork, not the total size of data fork
+plus resource fork. (S<Mac OS>).
+
+C<-s> by name on an open file will return the space reserved on disk,
+rather than the current extent. C<-s> on an open filehandle returns the
+current size. (S<RISC OS>)
+
C<-R>, C<-W>, C<-X>, C<-O> are indistinguishable from C<-r>, C<-w>,
-C<-x>, C<-o>. (S<Mac OS>, Win32, VMS)
+C<-x>, C<-o>. (S<Mac OS>, Win32, VMS, S<RISC OS>)
C<-b>, C<-c>, C<-k>, C<-g>, C<-p>, C<-u>, C<-A> are not implemented.
(S<Mac OS>)
C<-g>, C<-k>, C<-l>, C<-p>, C<-u>, C<-A> are not particularly meaningful.
-(Win32, VMS)
+(Win32, VMS, S<RISC OS>)
C<-d> is true if passed a device spec without an explicit directory.
(VMS)
C<-T> and C<-B> are implemented, but might misclassify Mac text files
-with foreign characters; this is the case will all platforms, but
-affects S<Mac OS> a lot. (S<Mac OS>)
+with foreign characters; this is the case will all platforms, but may
+affect S<Mac OS> often. (S<Mac OS>)
C<-x> (or C<-X>) determine if a file ends in one of the executable
suffixes. C<-S> is meaningless. (Win32)
+C<-x> (or C<-X>) determine if a file has an executable file type.
+(S<RISC OS>)
+
=item binmode FILEHANDLE
-Meaningless. (S<Mac OS>)
+Meaningless. (S<Mac OS>, S<RISC OS>)
Reopens file and restores pointer; if function fails, underlying
filehandle may be closed, or pointer may be in a different position.
@@ -780,9 +1011,11 @@ locking/unlocking the file. (S<Mac OS>)
Only good for changing "owner" read-write access, "group", and "other"
bits are meaningless. (Win32)
+Only good for changing "owner" and "other" read-write access. (S<RISC OS>)
+
=item chown LIST
-Not implemented. (S<Mac OS>, Win32, Plan9)
+Not implemented. (S<Mac OS>, Win32, Plan9, S<RISC OS>)
Does nothing, but won't fail. (Win32)
@@ -790,12 +1023,12 @@ Does nothing, but won't fail. (Win32)
=item chroot
-Not implemented. (S<Mac OS>, Win32, VMS, Plan9)
+Not implemented. (S<Mac OS>, Win32, VMS, Plan9, S<RISC OS>)
=item crypt PLAINTEXT,SALT
May not be available if library or source was not provided when building
-perl. (Win32)
+perl. (Win32)
=item dbmclose HASH
@@ -807,11 +1040,11 @@ Not implemented. (VMS, Plan9)
=item dump LABEL
-Not useful. (S<Mac OS>)
+Not useful. (S<Mac OS>, S<RISC OS>)
Not implemented. (Win32)
-Invokes VMS debugger. (VMS)
+Invokes VMS debugger. (VMS)
=item exec LIST
@@ -823,37 +1056,39 @@ Not implemented. (Win32, VMS)
=item flock FILEHANDLE,OPERATION
-Not implemented (S<Mac OS>, VMS).
+Not implemented (S<Mac OS>, VMS, S<RISC OS>).
Available only on Windows NT (not on Windows 95). (Win32)
=item fork
-Not implemented. (S<Mac OS>, Win32, AmigaOS)
+Not implemented. (S<Mac OS>, Win32, AmigaOS, S<RISC OS>)
=item getlogin
-Not implemented. (S<Mac OS>)
+Not implemented. (S<Mac OS>, S<RISC OS>)
=item getpgrp PID
-Not implemented. (S<Mac OS>, Win32, VMS)
+Not implemented. (S<Mac OS>, Win32, VMS, S<RISC OS>)
=item getppid
-Not implemented. (S<Mac OS>, Win32, VMS)
+Not implemented. (S<Mac OS>, Win32, VMS, S<RISC OS>)
=item getpriority WHICH,WHO
-Not implemented. (S<Mac OS>, Win32, VMS)
+Not implemented. (S<Mac OS>, Win32, VMS, S<RISC OS>)
=item getpwnam NAME
Not implemented. (S<Mac OS>, Win32)
+Not useful. (S<RISC OS>)
+
=item getgrnam NAME
-Not implemented. (S<Mac OS>, Win32, VMS)
+Not implemented. (S<Mac OS>, Win32, VMS, S<RISC OS>)
=item getnetbyname NAME
@@ -863,9 +1098,11 @@ Not implemented. (S<Mac OS>, Win32, Plan9)
Not implemented. (S<Mac OS>, Win32)
+Not useful. (S<RISC OS>)
+
=item getgrgid GID
-Not implemented. (S<Mac OS>, Win32, VMS)
+Not implemented. (S<Mac OS>, Win32, VMS, S<RISC OS>)
=item getnetbyaddr ADDR,ADDRTYPE
@@ -905,27 +1142,27 @@ Not implemented. (Win32, Plan9)
=item setpwent
-Not implemented. (S<Mac OS>, Win32)
+Not implemented. (S<Mac OS>, Win32, S<RISC OS>)
=item setgrent
-Not implemented. (S<Mac OS>, Win32, VMS)
+Not implemented. (S<Mac OS>, Win32, VMS, S<RISC OS>)
=item sethostent STAYOPEN
-Not implemented. (S<Mac OS>, Win32, Plan9)
+Not implemented. (S<Mac OS>, Win32, Plan9, S<RISC OS>)
=item setnetent STAYOPEN
-Not implemented. (S<Mac OS>, Win32, Plan9)
+Not implemented. (S<Mac OS>, Win32, Plan9, S<RISC OS>)
=item setprotoent STAYOPEN
-Not implemented. (S<Mac OS>, Win32, Plan9)
+Not implemented. (S<Mac OS>, Win32, Plan9, S<RISC OS>)
=item setservent STAYOPEN
-Not implemented. (Plan9, Win32)
+Not implemented. (Plan9, Win32, S<RISC OS>)
=item endpwent
@@ -933,7 +1170,7 @@ Not implemented. (S<Mac OS>, Win32)
=item endgrent
-Not implemented. (S<Mac OS>, Win32, VMS)
+Not implemented. (S<Mac OS>, Win32, VMS, S<RISC OS>)
=item endhostent
@@ -962,8 +1199,14 @@ Not implemented. (S<Mac OS>, Plan9)
Globbing built-in, but only C<*> and C<?> metacharacters are supported.
(S<Mac OS>)
-Features depend on external perlglob.exe or perlglob.bat. May be overridden
-with something like File::DosGlob, which is recommended. (Win32)
+Features depend on external perlglob.exe or perlglob.bat. May be
+overridden with something like File::DosGlob, which is recommended.
+(Win32)
+
+Globbing built-in, but only C<*> and C<?> metacharacters are supported.
+Globbing relies on operating system calls, which may return filenames
+in any order. As most filesystems are case-insensitive, even "sorted"
+filenames will not be in case-sensitive order. (S<RISC OS>)
=item ioctl FILEHANDLE,FUNCTION,SCALAR
@@ -972,16 +1215,19 @@ Not implemented. (VMS)
Available only for socket handles, and it does what the ioctlsocket() call
in the Winsock API does. (Win32)
+Available only for socket handles. (S<RISC OS>)
+
=item kill LIST
-Not implemented. (S<Mac OS>)
+Not implemented, hence not useful for taint checking. (S<Mac OS>,
+S<RISC OS>)
-Available only for process handles returned by the C<system(1, ...)> method of
-spawning a process. (Win32)
+Available only for process handles returned by the C<system(1, ...)>
+method of spawning a process. (Win32)
=item link OLDFILE,NEWFILE
-Not implemented. (S<Mac OS>, Win32, VMS)
+Not implemented. (S<Mac OS>, Win32, VMS, S<RISC OS>)
=item lstat FILEHANDLE
@@ -989,9 +1235,9 @@ Not implemented. (S<Mac OS>, Win32, VMS)
=item lstat
-Not implemented. (VMS)
+Not implemented. (VMS, S<RISC OS>)
-Return values may be bogus. (Win32)
+Return values may be bogus. (Win32)
=item msgctl ID,CMD,ARG
@@ -1001,7 +1247,7 @@ Return values may be bogus. (Win32)
=item msgrcv ID,VAR,SIZE,TYPE,FLAGS
-Not implemented. (S<Mac OS>, Win32, VMS, Plan9)
+Not implemented. (S<Mac OS>, Win32, VMS, Plan9, S<RISC OS>)
=item open FILEHANDLE,EXPR
@@ -1010,7 +1256,7 @@ Not implemented. (S<Mac OS>, Win32, VMS, Plan9)
The C<|> variants are only supported if ToolServer is installed.
(S<Mac OS>)
-open to C<|-> and C<-|> are unsupported. (S<Mac OS>, Win32)
+open to C<|-> and C<-|> are unsupported. (S<Mac OS>, Win32, S<RISC OS>)
=item pipe READHANDLE,WRITEHANDLE
@@ -1020,27 +1266,29 @@ Not implemented. (S<Mac OS>)
=item readlink
-Not implemented. (Win32, VMS)
+Not implemented. (Win32, VMS, S<RISC OS>)
=item select RBITS,WBITS,EBITS,TIMEOUT
Only implemented on sockets. (Win32)
+Only reliable on sockets. (S<RISC OS>)
+
=item semctl ID,SEMNUM,CMD,ARG
=item semget KEY,NSEMS,FLAGS
=item semop KEY,OPSTRING
-Not implemented. (S<Mac OS>, Win32, VMS)
+Not implemented. (S<Mac OS>, Win32, VMS, S<RISC OS>)
=item setpgrp PID,PGRP
-Not implemented. (S<Mac OS>, Win32, VMS)
+Not implemented. (S<Mac OS>, Win32, VMS, S<RISC OS>)
=item setpriority WHICH,WHO,PRIORITY
-Not implemented. (S<Mac OS>, Win32, VMS)
+Not implemented. (S<Mac OS>, Win32, VMS, S<RISC OS>)
=item setsockopt SOCKET,LEVEL,OPTNAME,OPTVAL
@@ -1054,11 +1302,11 @@ Not implemented. (S<Mac OS>, Plan9)
=item shmwrite ID,STRING,POS,SIZE
-Not implemented. (S<Mac OS>, Win32, VMS)
+Not implemented. (S<Mac OS>, Win32, VMS, S<RISC OS>)
=item socketpair SOCKET1,SOCKET2,DOMAIN,TYPE,PROTOCOL
-Not implemented. (S<Mac OS>, Win32, VMS)
+Not implemented. (S<Mac OS>, Win32, VMS, S<RISC OS>)
=item stat FILEHANDLE
@@ -1073,13 +1321,23 @@ device and inode are not meaningful. (Win32)
device and inode are not necessarily reliable. (VMS)
+mtime, atime and ctime all return the last modification time. Device and
+inode are not necessarily reliable. (S<RISC OS>)
+
=item symlink OLDFILE,NEWFILE
-Not implemented. (Win32, VMS)
+Not implemented. (Win32, VMS, S<RISC OS>)
=item syscall LIST
-Not implemented. (S<Mac OS>, Win32, VMS)
+Not implemented. (S<Mac OS>, Win32, VMS, S<RISC OS>)
+
+=item sysopen FILEHANDLE,FILENAME,MODE,PERMS
+
+The traditional "0", "1", and "2" MODEs are implemented with different
+numeric values on some systems. The flags exported by C<Fcntl>
+(O_RDONLY, O_WRONLY, O_RDWR) should work everywhere though. (S<Mac
+OS>, OS/390)
=item system LIST
@@ -1091,6 +1349,16 @@ process and immediately returns its process designator, without
waiting for it to terminate. Return value may be used subsequently
in C<wait> or C<waitpid>. (Win32)
+There is no shell to process metacharacters, and the native standard is
+to pass a command line terminated by "\n" "\r" or "\0" to the spawned
+program. Redirection such as C<E<gt> foo> is performed (if at all) by
+the run time library of the spawned program. C<system> I<list> will call
+the Unix emulation library's C<exec> emulation, which attempts to provide
+emulation of the stdin, stdout, stderr in force in the parent, providing
+the child program uses a compatible version of the emulation library.
+I<scalar> will call the native command line direct and no such emulation
+of a child Unix program will exists. Mileage B<will> vary. (S<RISC OS>)
+
=item times
Only the first entry returned is nonzero. (S<Mac OS>)
@@ -1099,6 +1367,8 @@ Only the first entry returned is nonzero. (S<Mac OS>)
"system" time will be bogus, and "user" time is actually the time
returned by the clock() function in the C runtime library. (Win32)
+Not useful. (S<RISC OS>)
+
=item truncate FILEHANDLE,LENGTH
=item truncate EXPR,LENGTH
@@ -1113,9 +1383,13 @@ Returns undef where unavailable, as of version 5.005.
=item utime LIST
-Only the modification time is updated. (S<Mac OS>, VMS)
+Only the modification time is updated. (S<Mac OS>, VMS, S<RISC OS>)
-May not behave as expected. (Win32)
+May not behave as expected. Behavior depends on the C runtime
+library's implementation of utime(), and the filesystem being
+used. The FAT filesystem typically does not support an "access
+time" field, and it may limit timestamps to a granularity of
+two seconds. (Win32)
=item wait
@@ -1126,35 +1400,62 @@ Not implemented. (S<Mac OS>)
Can only be applied to process handles returned for processes spawned
using C<system(1, ...)>. (Win32)
+Not useful. (S<RISC OS>)
+
=back
+=head1 CHANGES
+
+=over 4
+
+=item 1.33, 06 August 1998
+
+Integrate more minor changes.
+
+=item 1.32, 05 August 1998
+
+Integrate more minor changes.
+
+=item 1.30, 03 August 1998
+
+Major update for RISC OS, other minor changes.
+
+=item 1.23, 10 July 1998
+
+First public release with perl5.005.
+
+=back
=head1 AUTHORS / CONTRIBUTORS
-Chris Nandor E<lt>pudge@pobox.comE<gt>,
-Gurusamy Sarathy E<lt>gsar@umich.eduE<gt>,
-Peter Prymmer E<lt>pvhp@forte.comE<gt>,
-Tom Christiansen E<lt>tchrist@perl.comE<gt>,
-Nathan Torkington E<lt>gnat@frii.comE<gt>,
-Paul Moore E<lt>Paul.Moore@uk.origin-it.comE<gt>,
-Matthias Neercher E<lt>neeri@iis.ee.ethz.chE<gt>,
+Abigail E<lt>abigail@fnx.comE<gt>,
Charles Bailey E<lt>bailey@genetics.upenn.eduE<gt>,
+Graham Barr E<lt>gbarr@pobox.comE<gt>,
+Tom Christiansen E<lt>tchrist@perl.comE<gt>,
+Nicholas Clark E<lt>Nicholas.Clark@liverpool.ac.ukE<gt>,
+Andy Dougherty E<lt>doughera@lafcol.lafayette.eduE<gt>,
+Dominic Dunlop E<lt>domo@vo.luE<gt>,
+M.J.T. Guy E<lt>mjtg@cus.cam.ac.ukE<gt>,
Luther Huffman E<lt>lutherh@stratcom.comE<gt>,
-Gary Ng E<lt>71564.1743@CompuServe.COME<gt>,
Nick Ing-Simmons E<lt>nick@ni-s.u-net.comE<gt>,
-Paul J. Schinder E<lt>schinder@pobox.comE<gt>,
+Andreas J. KE<ouml>nig E<lt>koenig@kulturbox.deE<gt>,
+Andrew M. Langmead E<lt>aml@world.std.comE<gt>,
+Paul Moore E<lt>Paul.Moore@uk.origin-it.comE<gt>,
+Chris Nandor E<lt>pudge@pobox.comE<gt>,
+Matthias Neeracher E<lt>neeri@iis.ee.ethz.chE<gt>,
+Gary Ng E<lt>71564.1743@CompuServe.COME<gt>,
Tom Phoenix E<lt>rootbeer@teleport.comE<gt>,
-Hugo van der Sanden E<lt>h.sanden@elsevier.nlE<gt>,
-Dominic Dunlop E<lt>domo@vo.luE<gt>,
+Peter Prymmer E<lt>pvhp@forte.comE<gt>,
+Hugo van der Sanden E<lt>hv@crypt0.demon.co.ukE<gt>,
+Gurusamy Sarathy E<lt>gsar@umich.eduE<gt>,
+Paul J. Schinder E<lt>schinder@pobox.comE<gt>,
Dan Sugalski E<lt>sugalskd@ous.eduE<gt>,
-Andreas J. Koenig E<lt>koenig@kulturbox.deE<gt>,
-Andrew M. Langmead E<lt>aml@world.std.comE<gt>,
-Andy Dougherty E<lt>doughera@lafcol.lafayette.eduE<gt>,
-Abigail E<lt>abigail@fnx.comE<gt>.
+Nathan Torkington E<lt>gnat@frii.comE<gt>.
This document is maintained by Chris Nandor.
=head1 VERSION
-Version 1.23, last modified 10 July 1998.
+Version 1.34, last modified 07 August 1998.
+
diff --git a/pod/perlre.pod b/pod/perlre.pod
index b7fda54061..1b49ba4e7b 100644
--- a/pod/perlre.pod
+++ b/pod/perlre.pod
@@ -7,12 +7,13 @@ perlre - Perl regular expressions
This page describes the syntax of regular expressions in Perl. For a
description of how to I<use> regular expressions in matching
operations, plus various examples of the same, see discussion
-of C<m//>, C<s///>, C<qr//> and C<??> in L<perlop/Regexp Quote-Like Operators>.
+of C<m//>, C<s///>, C<qr//> and C<??> in L<perlop/"Regexp Quote-Like Operators">.
The matching operations can have various modifiers. The modifiers
that relate to the interpretation of the regular expression inside
-are listed below. For the modifiers that alter the way regular expression
-is used by Perl, see L<perlop/Regexp Quote-Like Operators>.
+are listed below. For the modifiers that alter the way a regular expression
+is used by Perl, see L<perlop/"Regexp Quote-Like Operators"> and
+L<perlop/"Gory details of parsing quoted constructs">.
=over 4
@@ -346,10 +347,6 @@ Experimental "evaluate any Perl code" zero-width assertion. Always
succeeds. C<code> is not interpolated. Currently the rules to
determine where the C<code> ends are somewhat convoluted.
-Owing to the risks to security, this is only available when the
-C<use re 'eval'> pragma is used, and then only for patterns that don't
-have any variables that must be interpolated at run time.
-
The C<code> is properly scoped in the following sense: if the assertion
is backtracked (compare L<"Backtracking">), all the changes introduced after
C<local>isation are undone, so
@@ -380,6 +377,28 @@ other C<(?{ code })> assertions inside the same regular expression.
The above assignment to $^R is properly localized, thus the old value of $^R
is restored if the assertion is backtracked (compare L<"Backtracking">).
+Due to security concerns, this construction is not allowed if the regular
+expression involves run-time interpolation of variables, unless
+C<use re 'eval'> pragma is used (see L<re>), or the variables contain
+results of qr() operator (see L<perlop/"qr/STRING/imosx">).
+
+This restriction is due to the wide-spread (questionable) practice of
+using the construct
+
+ $re = <>;
+ chomp $re;
+ $string =~ /$re/;
+
+without tainting. While this code is frowned upon from security point
+of view, when C<(?{})> was introduced, it was considered bad to add
+I<new> security holes to existing scripts.
+
+B<NOTE:> Use of the above insecure snippet without also enabling taint mode
+is to be severely frowned upon. C<use re 'eval'> does not disable tainting
+checks, thus to allow $re in the above snippet to contain C<(?{})>
+I<with tainting enabled>, one needs both C<use re 'eval'> and untaint
+the $re.
+
=item C<(?E<gt>pattern)>
An "independent" subexpression. Matches the substring that a
@@ -392,7 +411,7 @@ C<a> at the beginning of string, leaving no C<a> for C<ab> to match.
In contrast, C<a*ab> will match the same as C<a+b>, since the match of
the subgroup C<a*> is influenced by the following group C<ab> (see
L<"Backtracking">). In particular, C<a*> inside C<a*ab> will match
-less characters that a standalone C<a*>, since this makes the tail match.
+fewer characters than a standalone C<a*>, since this makes the tail match.
An effect similar to C<(?E<gt>pattern)> may be achieved by
@@ -401,40 +420,42 @@ An effect similar to C<(?E<gt>pattern)> may be achieved by
since the lookahead is in I<"logical"> context, thus matches the same
substring as a standalone C<a+>. The following C<\1> eats the matched
string, thus making a zero-length assertion into an analogue of
-C<(?>...)>. (The difference between these two constructs is that the
+C<(?E<gt>...)>. (The difference between these two constructs is that the
second one uses a catching group, thus shifting ordinals of
backreferences in the rest of a regular expression.)
This construct is useful for optimizations of "eternal"
matches, because it will not backtrack (see L<"Backtracking">).
- m{ \( (
- [^()]+
- |
- \( [^()]* \)
- )+
- \)
- }x
+ m{ \(
+ (
+ [^()]+
+ |
+ \( [^()]* \)
+ )+
+ \)
+ }x
That will efficiently match a nonempty group with matching
two-or-less-level-deep parentheses. However, if there is no such group,
it will take virtually forever on a long string. That's because there are
so many different ways to split a long string into several substrings.
-This is essentially what C<(.+)+> is doing, and this is a subpattern
-of the above pattern. Consider that C<((()aaaaaaaaaaaaaaaaaa> on the
-pattern above detects no-match in several seconds, but that each extra
+This is what C<(.+)+> is doing, and C<(.+)+> is similar to a subpattern
+of the above pattern. Consider that the above pattern detects no-match
+on C<((()aaaaaaaaaaaaaaaaaa> in several seconds, but that each extra
letter doubles this time. This exponential performance will make it
appear that your program has hung.
However, a tiny modification of this pattern
- m{ \( (
- (?> [^()]+ )
- |
- \( [^()]* \)
- )+
- \)
- }x
+ m{ \(
+ (
+ (?> [^()]+ )
+ |
+ \( [^()]* \)
+ )+
+ \)
+ }x
which uses C<(?E<gt>...)> matches exactly when the one above does (verifying
this yourself would be a productive exercise), but finishes in a fourth
@@ -457,9 +478,9 @@ matched), or lookahead/lookbehind/evaluate zero-width assertion.
Say,
m{ ( \( )?
- [^()]+
+ [^()]+
(?(1) \) )
- }x
+ }x
matches a chunk of non-parentheses, possibly included in parentheses
themselves.
@@ -608,10 +629,10 @@ When using lookahead assertions and negations, this can all get even
tricker. Imagine you'd like to find a sequence of non-digits not
followed by "123". You might try to write that as
- $_ = "ABC123";
- if ( /^\D*(?!123)/ ) { # Wrong!
- print "Yup, no 123 in $_\n";
- }
+ $_ = "ABC123";
+ if ( /^\D*(?!123)/ ) { # Wrong!
+ print "Yup, no 123 in $_\n";
+ }
But that isn't going to match; at least, not the way you're hoping. It
claims that there is no 123 in the string. Here's a clearer picture of
@@ -904,6 +925,8 @@ part of this regular expression needs to be converted explicitly
L<perlop/"Regexp Quote-Like Operators">.
+L<perlop/"Gory details of parsing quoted constructs">.
+
L<perlfunc/pos>.
L<perllocale>.
diff --git a/pod/perlrun.pod b/pod/perlrun.pod
index da96acd9dc..a0c85b917b 100644
--- a/pod/perlrun.pod
+++ b/pod/perlrun.pod
@@ -272,6 +272,7 @@ equivalent to B<-Dtls>):
8192 H Hash dump -- usurps values()
16384 X Scratchpad allocation
32768 D Cleaning up
+ 65536 S Thread synchronization
All these flags require C<-DDEBUGGING> when you compile the Perl
executable. This flag is automatically set if you include C<-g>
diff --git a/pod/roffitall b/pod/roffitall
index 244048af2d..918fe0270a 100644
--- a/pod/roffitall
+++ b/pod/roffitall
@@ -14,8 +14,8 @@ fi
mandir=$installman1dir
libdir=$installman3dir
-test -d $mandir || mandir=/usr/local/man/man1
-test -d $libdir || libdir=/usr/local/man/man3
+test -d $mandir || mandir=/usr/new/man/man1
+test -d $libdir || libdir=/usr/new/man/man3
case "$1" in
-nroff) cmd="nroff -man"; ext='txt';;
@@ -30,40 +30,44 @@ esac
toroff=`
echo \
$mandir/perl.1 \
- $mandir/perldelta.1 \
$mandir/perldata.1 \
$mandir/perlsyn.1 \
$mandir/perlop.1 \
$mandir/perlre.1 \
$mandir/perlrun.1 \
- $mandir/perllocale.1 \
$mandir/perlfunc.1 \
$mandir/perlvar.1 \
$mandir/perlsub.1 \
$mandir/perlmod.1 \
$mandir/perlmodlib.1 \
+ $mandir/perlmodinstall.1 \
+ $mandir/perlform.1 \
+ $mandir/perllocale.1 \
$mandir/perlref.1 \
$mandir/perldsc.1 \
$mandir/perllol.1 \
+ $mandir/perltoot.1 \
$mandir/perlobj.1 \
$mandir/perltie.1 \
- $mandir/perltoot.1 \
$mandir/perlbot.1 \
+ $mandir/perlipc.1 \
$mandir/perldebug.1 \
$mandir/perldiag.1 \
- $mandir/perlform.1 \
- $mandir/perlipc.1 \
$mandir/perlsec.1 \
$mandir/perltrap.1 \
+ $mandir/perlport.1 \
$mandir/perlstyle.1 \
+ $mandir/perlpod.1 \
+ $mandir/perlbook.1 \
+ $mandir/perlembed.1 \
$mandir/perlapio.1 \
$mandir/perlxs.1 \
$mandir/perlxstut.1 \
$mandir/perlguts.1 \
$mandir/perlcall.1 \
- $mandir/perlembed.1 \
- $mandir/perlpod.1 \
- $mandir/perlbook.1 \
+ $mandir/perlhist.1 \
+ $mandir/perldelta.1 \
+ $mandir/perl5004delta.1 \
$mandir/perlfaq.1 \
$mandir/perlfaq1.1 \
$mandir/perlfaq2.1 \
@@ -75,13 +79,33 @@ toroff=`
$mandir/perlfaq8.1 \
$mandir/perlfaq9.1 \
\
+ $mandir/a2p.1 \
+ $mandir/c2ph.1 \
+ $mandir/h2ph.1 \
+ $mandir/h2xs.1 \
+ $mandir/perlbug.1 \
+ $mandir/perldoc.1 \
+ $mandir/pl2pm.1 \
+ $mandir/pod2html.1 \
+ $mandir/pod2man.1 \
+ $mandir/s2p.1 \
+ $mandir/splain.1 \
+ $mandir/xsubpp.1 \
+ \
+ $libdir/attrs.3 \
+ $libdir/autouse.3 \
+ $libdir/base.3 \
$libdir/blib.3 \
+ $libdir/constant.3 \
$libdir/diagnostics.3 \
+ $libdir/fields.3 \
$libdir/integer.3 \
$libdir/less.3 \
$libdir/lib.3 \
$libdir/locale.3 \
+ $libdir/ops.3 \
$libdir/overload.3 \
+ $libdir/re.3 \
$libdir/sigtrap.3 \
$libdir/strict.3 \
$libdir/subs.3 \
@@ -90,34 +114,81 @@ toroff=`
$libdir/AnyDBM_File.3 \
$libdir/AutoLoader.3 \
$libdir/AutoSplit.3 \
+ $libdir/B.3 \
+ $libdir/B::Asmdata.3 \
+ $libdir/B::Assembler.3 \
+ $libdir/B::Bblock.3 \
+ $libdir/B::Bytecode.3 \
+ $libdir/B::C.3 \
+ $libdir/B::CC.3 \
+ $libdir/B::Debug.3 \
+ $libdir/B::Deparse.3 \
+ $libdir/B::Disassembler.3 \
+ $libdir/B::Lint.3 \
+ $libdir/B::Showlex.3 \
+ $libdir/B::Stackobj.3 \
+ $libdir/B::Terse.3 \
+ $libdir/B::Xref.3 \
$libdir/Benchmark.3 \
$libdir/Carp.3 \
+ $libdir/CGI.3 \
+ $libdir/CGI::Apache.3 \
+ $libdir/CGI::Carp.3 \
+ $libdir/CGI::Cookie.3 \
+ $libdir/CGI::Fast.3 \
+ $libdir/CGI::Push.3 \
+ $libdir/CGI::Switch.3 \
+ $libdir/Class::Struct.3 \
$libdir/Config.3 \
+ $libdir/CPAN.3 \
+ $libdir/CPAN::FirstTime.3 \
+ $libdir/CPAN::Nox.3 \
$libdir/Cwd.3 \
+ $libdir/Data::Dumper.3 \
$libdir/DB_File.3 \
$libdir/Devel::SelfStubber.3 \
+ $libdir/DirHandle.3 \
$libdir/DynaLoader.3 \
$libdir/English.3 \
$libdir/Env.3 \
+ $libdir/Errno.3 \
$libdir/Exporter.3 \
+ $libdir/ExtUtils::Command.3 \
$libdir/ExtUtils::Embed.3 \
$libdir/ExtUtils::Install.3 \
+ $libdir/ExtUtils::Installed.3 \
$libdir/ExtUtils::Liblist.3 \
$libdir/ExtUtils::MakeMaker.3 \
$libdir/ExtUtils::Manifest.3 \
+ $libdir/ExtUtils::Miniperl.3 \
$libdir/ExtUtils::Mkbootstrap.3 \
$libdir/ExtUtils::Mksymlists.3 \
+ $libdir/ExtUtils::MM_OS2.3 \
+ $libdir/ExtUtils::MM_Unix.3 \
+ $libdir/ExtUtils::MM_VMS.3 \
+ $libdir/ExtUtils::MM_Win32.3 \
+ $libdir/ExtUtils::Packlist.3 \
+ $libdir/ExtUtils::testlib.3 \
+ $libdir/Fatal.3 \
$libdir/Fcntl.3 \
$libdir/File::Basename.3 \
$libdir/File::CheckTree.3 \
- $libdir/File::Copy.3 \
$libdir/File::Compare.3 \
+ $libdir/File::Copy.3 \
+ $libdir/File::DosGlob.3 \
$libdir/File::Find.3 \
$libdir/File::Path.3 \
+ $libdir/File::Spec.3 \
+ $libdir/File::Spec::Mac.3 \
+ $libdir/File::Spec::OS2.3 \
+ $libdir/File::Spec::Unix.3 \
+ $libdir/File::Spec::VMS.3 \
+ $libdir/File::Spec::Win32.3 \
$libdir/File::stat.3 \
$libdir/FileCache.3 \
$libdir/FileHandle.3 \
$libdir/FindBin.3 \
+ $libdir/GDBM_File.3 \
$libdir/Getopt::Long.3 \
$libdir/Getopt::Std.3 \
$libdir/I18N::Collate.3 \
@@ -128,21 +199,28 @@ toroff=`
$libdir/IO::Seekable.3 \
$libdir/IO::Select.3 \
$libdir/IO::Socket.3 \
+ $libdir/IPC::Msg.3 \
$libdir/IPC::Open2.3 \
$libdir/IPC::Open3.3 \
+ $libdir/IPC::Semaphore.3 \
+ $libdir/IPC::SysV.3 \
$libdir/Math::BigFloat.3 \
$libdir/Math::BigInt.3 \
$libdir/Math::Complex.3 \
$libdir/Math::Trig.3 \
- $libdir/Net::Ping.3 \
+ $libdir/NDBM_File.3 \
$libdir/Net::hostent.3 \
$libdir/Net::netent.3 \
+ $libdir/Net::Ping.3 \
$libdir/Net::protoent.3 \
$libdir/Net::servent.3 \
+ $libdir/O.3 \
$libdir/Opcode.3 \
- $libdir/POSIX.3 \
+ $libdir/Pod::Html.3 \
$libdir/Pod::Text.3 \
+ $libdir/POSIX.3 \
$libdir/Safe.3 \
+ $libdir/SDBM_File.3 \
$libdir/Search::Dict.3 \
$libdir/SelectSaver.3 \
$libdir/SelfLoader.3 \
@@ -153,50 +231,54 @@ toroff=`
$libdir/Sys::Syslog.3 \
$libdir/Term::Cap.3 \
$libdir/Term::Complete.3 \
+ $libdir/Term::ReadLine.3 \
+ $libdir/Test.3 \
$libdir/Test::Harness.3 \
$libdir/Text::Abbrev.3 \
$libdir/Text::ParseWords.3 \
$libdir/Text::Soundex.3 \
$libdir/Text::Tabs.3 \
+ $libdir/Text::Wrap.3 \
+ $libdir/Tie::Array.3 \
+ $libdir/Tie::Handle.3 \
$libdir/Tie::Hash.3 \
$libdir/Tie::RefHash.3 \
$libdir/Tie::Scalar.3 \
$libdir/Tie::SubstrHash.3 \
- $libdir/Time::Local.3 \
$libdir/Time::gmtime.3 \
+ $libdir/Time::Local.3 \
$libdir/Time::localtime.3 \
$libdir/Time::tm.3 \
$libdir/UNIVERSAL.3 \
$libdir/User::grent.3 \
$libdir/User::pwent.3 | \
-perl -ne 'map { -r && print "$_ " } split'`
+ perl -ne 'map { -r && print "$_ " } split'`
-# Bypass internal shell buffer limit -- can't use case
-if perl -e '$a = shift; exit($a =~ m|/|)' $toroff; then
+ # Bypass internal shell buffer limit -- can't use case
+ if perl -e '$a = shift; exit($a =~ m|/|)' $toroff; then
echo "$me: empty file list -- did you run install?" >&2
exit 1
-fi
-
-#psroff -t -man -rC1 -rD1 -rF1 > $tmp/PerlDoc.ps 2>$tmp/PerlTOC.raw
-#nroff -man -rC1 -rD1 -rF1 > $tmp/PerlDoc.txt 2>$tmp/PerlTOC.nr.raw
+ fi
-# First, create the raw data
-run="$cmd -rC1 -rD1 -rF1 >$tmp/PerlDoc.$ext 2>$tmp/PerlTOC.$ext.raw"
-echo "$me: running $run"
-eval $run $toroff
+ #psroff -t -man -rC1 -rD1 -rF1 > $tmp/PerlDoc.ps 2>$tmp/PerlTOC.raw
+ #nroff -man -rC1 -rD1 -rF1 > $tmp/PerlDoc.txt 2>$tmp/PerlTOC.nr.raw
-#Now create the TOC
-echo "$me: parsing TOC"
-./rofftoc $tmp/PerlTOC.$ext.raw > $tmp/PerlTOC.tmp.man
-run="$cmd $tmp/PerlTOC.tmp.man >$tmp/PerlTOC.$ext"
-echo "$me: running $run"
-eval $run
+ # First, create the raw data
+ run="$cmd -rC1 -rD1 -rF1 >$tmp/PerlDoc.$ext 2>$tmp/PerlTOC.$ext.raw"
+ echo "$me: running $run"
+ eval $run $toroff
-# Finally, recreate the Doc, without the blank page 0
-run="$cmd -rC1 -rD1 >$tmp/PerlDoc.$ext 2>$tmp/PerlTOC.$ext.raw"
-echo "$me: running $run"
-eval $run $toroff
-rm -f $tmp/PerlTOC.tmp.man $tmp/PerlTOC.$ext.raw
-echo "$me: leaving you with $tmp/PerlDoc.$ext and $tmp/PerlTOC.$ext"
+ #Now create the TOC
+ echo "$me: parsing TOC"
+ ./rofftoc $tmp/PerlTOC.$ext.raw > $tmp/PerlTOC.tmp.man
+ run="$cmd $tmp/PerlTOC.tmp.man >$tmp/PerlTOC.$ext"
+ echo "$me: running $run"
+ eval $run
+ # Finally, recreate the Doc, without the blank page 0
+ run="$cmd -rC1 -rD1 >$tmp/PerlDoc.$ext 2>$tmp/PerlTOC.$ext.raw"
+ echo "$me: running $run"
+ eval $run $toroff
+ rm -f $tmp/PerlTOC.tmp.man $tmp/PerlTOC.$ext.raw
+ echo "$me: leaving you with $tmp/PerlDoc.$ext and $tmp/PerlTOC.$ext"