diff options
author | Gurusamy Sarathy <gsar@cpan.org> | 1999-05-24 17:32:20 +0000 |
---|---|---|
committer | Gurusamy Sarathy <gsar@cpan.org> | 1999-05-24 17:32:20 +0000 |
commit | 14218588221b08417dacfb8f157681c6b381b73f (patch) | |
tree | 56817d24552ce5a29fc77965ab137d11b73fc29a | |
parent | 9263d47b7ba3c92b743ac884edfaa80847325f4d (diff) | |
download | perl-14218588221b08417dacfb8f157681c6b381b73f.tar.gz |
more pod updates from Tom Christiansen; regen perltoc
p4raw-id: //depot/perl@3462
-rw-r--r-- | pod/perl.pod | 34 | ||||
-rw-r--r-- | pod/perldelta.pod | 176 | ||||
-rw-r--r-- | pod/perlmod.pod | 12 | ||||
-rw-r--r-- | pod/perlobj.pod | 28 | ||||
-rw-r--r-- | pod/perlre.pod | 250 | ||||
-rw-r--r-- | pod/perltoc.pod | 2251 | ||||
-rw-r--r-- | pod/perlvar.pod | 73 |
7 files changed, 2167 insertions, 657 deletions
diff --git a/pod/perl.pod b/pod/perl.pod index 3b4d785960..87696fe55d 100644 --- a/pod/perl.pod +++ b/pod/perl.pod @@ -12,8 +12,8 @@ B<perl> S<[ B<-sTuU> ]> S<[ B<-hv> ] [ B<-V>[:I<configvar>] ]> S<[ B<-i>[I<extension>] ]> S<[ B<-e> I<'command'> ] [ B<--> ] [ I<programfile> ] [ I<argument> ]...> -For ease of access, the Perl manual has been split up into a number -of sections: +For ease of access, the Perl manual has been split up into several +sections: perl Perl overview (this section) perldelta Perl changes since previous version @@ -117,17 +117,17 @@ Perl combines (in the author's opinion, anyway) some of the best features of C, B<sed>, B<awk>, and B<sh>, so people familiar with those languages should have little difficulty with it. (Language historians will also note some vestiges of B<csh>, Pascal, and even -BASIC-PLUS.) Expression syntax corresponds quite closely to C +BASIC-PLUS.) Expression syntax corresponds closely to C expression syntax. Unlike most Unix utilities, Perl does not arbitrarily limit the size of your data--if you've got the memory, Perl can slurp in your whole file as a single string. Recursion is of unlimited depth. And the tables used by hashes (sometimes called "associative arrays") grow as necessary to prevent degraded performance. Perl can use sophisticated pattern matching techniques to -scan large amounts of data very quickly. Although optimized for +scan large amounts of data quickly. Although optimized for scanning text, Perl can also deal with binary data, and can make dbm files look like hashes. Setuid Perl scripts are safer than C programs -through a dataflow tracing mechanism which prevents many stupid +through a dataflow tracing mechanism that prevents many stupid security holes. If you have a problem that would ordinarily use B<sed> or B<awk> or @@ -188,7 +188,7 @@ Described in L<perlsub>. Described in L<perlre>, with additional examples in L<perlop>. -=item * enhanced debugger and interactive Perl environment, with intregrated editor support +=item * enhanced debugger and interactive Perl environment, with integrated editor support Described in L<perldebug>. @@ -202,12 +202,11 @@ Okay, that's I<definitely> enough hype. =head1 AVAILABILITY -Perl is available for the vast majority of operating system platforms, -including most Unix-like platforms. The following situation is as of -February 1999 and Perl 5.005_03. +Perl is available for most operating systems, including virtually +all Unix-like platforms. -The following platforms are able to build Perl from the standard -source code distribution available at +As of May 1999, the following platforms are able to build Perl +from the standard source code distribution available at http://www.perl.com/CPAN/src/index.html AIX Linux SCO ODT/OSR @@ -229,9 +228,9 @@ http://www.perl.com/CPAN/src/index.html 3) formerly known as Digital UNIX and before that DEC OSF/1 4) compilers: Borland, Cygwin32, Mingw32 EGCS/GCC, VC++ -The following platforms have been known to build Perl from the source -but for the Perl release 5.005_03 we haven't been able to verify them, -either because the hardware/software platforms are rather rare or +The following platforms have been known to build Perl from source, +but we haven't been able to verify their status for the current release, +either because the hardware/software platforms are rare or because we don't have an active champion on these platforms--or both. 3b1 FPS Plan 9 @@ -245,9 +244,8 @@ because we don't have an active champion on these platforms--or both. EP/IX Opus Unisys Dynix ESIX Unixware -The following platforms are planned to be supported in the standard -source code distribution of the Perl release 5.006 but are not -supported in the Perl release 5.005_03: +Support for the following platforms is planned for the next major +Perl release. BS2000 Netware @@ -308,7 +306,7 @@ and errors into these longer forms. Compilation errors will tell you the line number of the error, with an indication of the next token or token type that was to be examined. -(In the case of a script passed to Perl via B<-e> switches, each +(In a script passed to Perl via B<-e> switches, each B<-e> is counted as one line.) Setuid scripts have additional constraints that can produce error diff --git a/pod/perldelta.pod b/pod/perldelta.pod index 7ffaf7455d..5b4eb10553 100644 --- a/pod/perldelta.pod +++ b/pod/perldelta.pod @@ -21,29 +21,29 @@ None known at this time. Release 5.005 grandfathered old global symbol names by providing preprocessor macros for extension source compatibility. As of release 5.006, these preprocessor definitions are not available by default. You need to explicitly -compile perl with C<-DPERL_POLLUTE> in order to get these definitions. For -extensions that are still using the old symbols, this option can be +compile perl with C<-DPERL_POLLUTE> to get these definitions. For +extensions still using the old symbols, this option can be specified via MakeMaker: - perl Makefile.PL POLLUTE=1 + perl Makefile.PL POLLUTE=1 =item C<PERL_POLLUTE_MALLOC> -Enabling the use of Perl's malloc in release 5.005 and earlier caused +Enabling Perl's malloc in release 5.005 and earlier caused the namespace of system versions of the malloc family of functions to -be usurped by the Perl versions of these functions, since they used the -same names by default. +be usurped by the Perl versions, since by default they used the +same names. Besides causing problems on platforms that do not allow these functions to be cleanly replaced, this also meant that the system versions could not be called in programs that used Perl's malloc. Previous versions of Perl -have allowed this behavior to be suppressed with the HIDEMYMALLOC and +have allowed this behaviour to be suppressed with the HIDEMYMALLOC and EMBEDMYMALLOC preprocessor definitions. As of release 5.006, Perl's malloc family of functions have default names distinct from the system versions. You need to explicitly compile perl with -C<-DPERL_POLLUTE_MALLOC> in order to get the older behavior. HIDEMYMALLOC -and EMBEDMYMALLOC have no effect, since the behavior they enabled is now +C<-DPERL_POLLUTE_MALLOC> to get the older behaviour. HIDEMYMALLOC +and EMBEDMYMALLOC have no effect, since the behaviour they enabled is now the default. Note that these functions do B<not> constitute Perl's memory allocation API. @@ -52,7 +52,7 @@ See L<perlguts/"Memory Allocation"> for further information about that. =item C<PL_na> and C<dTHR> Issues The C<PL_na> global is now thread local, so a C<dTHR> declaration is needed -in the scope in which it appears. XSUBs should handle this automatically, +in the scope in which the global appears. XSUBs should handle this automatically, but if you have used C<PL_na> in support functions, you either need to change the C<PL_na> to a local variable (which is recommended), or put in a C<dTHR>. @@ -65,23 +65,23 @@ a C<dTHR>. =item C<PATCHLEVEL> is now C<PERL_VERSION> -The cpp macros C<PERL_REVISION>, C<PERL_VERSION> and C<PERL_SUBVERSION> +The cpp macros C<PERL_REVISION>, C<PERL_VERSION>, and C<PERL_SUBVERSION> are now available by default from perl.h, and reflect the base revision, -patchlevel and subversion respectively. C<PERL_REVISION> had no +patchlevel, and subversion respectively. C<PERL_REVISION> had no prior equivalent, while C<PERL_VERSION> and C<PERL_SUBVERSION> were previously available as C<PATCHLEVEL> and C<SUBVERSION>. -The new names cause less pollution of the cpp namespace, and reflect what +The new names cause less pollution of the B<cpp> namespace and reflect what the numbers have come to stand for in common practice. For compatibility, -the old names are still supported when patchlevel.h is explicitly +the old names are still supported when F<patchlevel.h> is explicitly included (as required before), so there is no source incompatibility -due to the change. +from the change. =back =head2 Binary Incompatibilities -This release is not binary compatible with the 5.005 release and its +This release is not binary compatible with the 5.005 release or its maintenance versions. =head1 Core Changes @@ -102,8 +102,8 @@ level using the C<use warning> pragma. See L<warning> for details. Binary numbers are now supported as literals, in s?printf formats, and C<oct()>: - $answer = 0b101010; - printf "The answer is: %b\n", oct("0b101010"); + $answer = 0b101010; + printf "The answer is: %b\n", oct("0b101010"); =head2 syswrite() ease-of-use @@ -123,22 +123,22 @@ Unix and UNICOS also have 64-bit support. Expressions such as: - print defined(&foo,&bar,&baz); - print uc("foo","bar","baz"); - undef($foo,&bar); + print defined(&foo,&bar,&baz); + print uc("foo","bar","baz"); + undef($foo,&bar); used to be accidentally allowed in earlier versions, and produced -unpredictable behavior. Some of them produced ancillary warnings -when used in this way, while others silently did the wrong thing. +unpredictable behaviour. Some produced ancillary warnings +when used in this way; others silently did the wrong thing. The parenthesized forms of most unary operators that expect a single -argument will now ensure that they are not called with more than one -argument, making the above cases syntax errors. Note that the usual -behavior of: +argument now ensure that they are not called with more than one +argument, making the cases shown above syntax errors. The usual +behaviour of: - print defined &foo, &bar, &baz; - print uc "foo", "bar", "baz"; - undef $foo, &bar; + print defined &foo, &bar, &baz; + print uc "foo", "bar", "baz"; + undef $foo, &bar; remains unchanged. See L<perlop>. @@ -146,8 +146,8 @@ remains unchanged. See L<perlop>. The C<qw//> operator is now evaluated at compile time into a true list instead of being replaced with a run time call to C<split()>. This -removes the confusing behavior of C<qw//> in scalar context stemming from -the older implementation, which inherited the behavior from split(). +removes the confusing misbehaviour of C<qw//> in scalar context, which +had inherited that behaviour from split(). Thus: @@ -162,7 +162,7 @@ strings. See L<perlfunc/"pack">. =head2 pack() format modifier '!' supported -The new format type modifer '!' is useful for packing and unpacking +The new format type modifier '!' is useful for packing and unpacking native shorts, ints, and longs. See L<perlfunc/"pack">. =head2 $^X variables may now have names longer than one character @@ -171,36 +171,36 @@ Formerly, $^X was synonymous with ${"\cX"}, but $^XY was a syntax error. Now variable names that begin with a control character may be arbitrarily long. However, for compatibility reasons, these variables I<must> be written with explicit braces, as C<${^XY}> for example. -C<${^XYZ}> is synonymous with ${"\cXYZ"}. Variable names with more +C<${^XYZ}> is synonymous with ${"\cXYZ"}. Variable names with more than one control character, such as C<${^XY^Z}>, are illegal. -The old syntax has not changed. As before, the `^X' may either be a -literal control-X character or the two character sequence `caret' plus -`X'. When the braces are omitted, the variable name stops after the +The old syntax has not changed. As before, `^X' may be either a +literal control-X character or the two-character sequence `caret' plus +`X'. When braces are omitted, the variable name stops after the control character. Thus C<"$^XYZ"> continues to be synonymous with C<$^X . "YZ"> as before. As before, lexical variables may not have names beginning with control characters. As before, variables whose names begin with a control -character are always forced to be in package `main'. These variables -are all reserved for future extensions, except the ones that begin -with C<^_>, which may be used by user programs and will not acquire a -special meaning in any future version of Perl. +character are always forced to be in package `main'. All such variables +are reserved for future extensions, except those that begin with +C<^_>, which may be used by user programs and is guaranteed not to +acquire special meaning in any future version of Perl. =head1 Significant bug fixes =head2 E<lt>HANDLEE<gt> on empty files With C<$/> set to C<undef>, slurping an empty file returns a string of -zero length (instead of C<undef>, as it used to) for the first time the -HANDLE is read. Subsequent reads yield C<undef>. +zero length (instead of C<undef>, as it used to) the first time the +HANDLE is read. Further reads yield C<undef>. This means that the following will append "foo" to an empty file (it used -to not do anything before): +to do nothing): perl -0777 -pi -e 's/^/foo/' empty_file -Note that the behavior of: +The behaviour of: perl -pi -e 's/^/foo/' empty_file @@ -214,8 +214,8 @@ This has been corrected. Lexical lookups for variables appearing in C<eval '...'> within functions that were themselves called within an C<eval '...'> were -searching the wrong place for lexicals. They now correctly terminate -the lexical search at the subroutine call boundary. +searching the wrong place for lexicals. The lexical search now +correctly ends at the subroutine's block boundary. Parsing of here documents used to be flawed when they appeared as the replacement expression in C<eval 's/.../.../e'>. This has @@ -223,11 +223,11 @@ been fixed. =head2 Automatic flushing of output buffers -fork(), exec(), system(), qx// and pipe open()s now flush the buffers -of all files that were opened for output at the time the operation -was attempted. This mostly eliminates the often confusing effects of +fork(), exec(), system(), qx//, and pipe open()s now flush buffers +of all files opened for output when the operation +was attempted. This mostly eliminates confusing buffering mishaps suffered by users unaware of how Perl internally -handled I/O. +handles I/O. =head1 Supported Platforms @@ -263,7 +263,7 @@ Rhapsody is now supported. =item op/io_const IO constants (SEEK_*, _IO*). - + =item op/io_dir Directory-related IO methods (new, read, close, rewind, tied delete). @@ -303,10 +303,10 @@ Added Dumpvalue module provides screen dumps of Perl data. =item Benchmark You can now run tests for I<n> seconds instead of guessing the right -number of tests to run: e.g. timethese(-5, ...) will run each of the -codes for at least 5 CPU seconds. Zero as the "number of repetitions" +number of tests to run: e.g. timethese(-5, ...) will run each +code for at least 5 CPU seconds. Zero as the "number of repetitions" means "for at least 3 CPU seconds". The output format has also -changed. For example: +changed. For example: use Benchmark;$x=3;timethese(-5,{a=>sub{$x*$x},b=>sub{$x**2}}) @@ -322,12 +322,12 @@ and the "@ operations/CPU second (n=operations)". =item Devel::Peek The Devel::Peek module provides access to the internal representation -of Perl variables. It is a data debugging tool for the XS programmer. +of Perl variables and data. It is a data debugging tool for the XS programmer. =item Fcntl More Fcntl constants added: F_SETLK64, F_SETLKW64, O_LARGEFILE for -large (more than 4G) file access (the 64-bit support is not yet +large (more than 4G) file access (64-bit support is not yet working, though, so no need to get overly excited), Free/Net/OpenBSD locking behaviour flags F_FLOCK, F_POSIX, Linux F_SHLCK, and O_ACCMODE: the mask of O_RDONLY, O_WRONLY, and O_RDWR. @@ -336,61 +336,61 @@ O_ACCMODE: the mask of O_RDONLY, O_WRONLY, and O_RDWR. New methods have been added to the File::Spec module: devnull() returns the name of the null device (/dev/null on Unix) and tmpdir() the name of -the temp directory (normally /tmp on Unix). There are now also methods +the temp directory (normally /tmp on Unix). There are now also methods to convert between absolute and relative filenames: abs2rel() and -rel2abs(). For compatibility with operating systems that specify volume -names in file paths, the splitpath(), splitdir() and catdir() methods +rel2abs(). For compatibility with operating systems that specify volume +names in file paths, the splitpath(), splitdir(), and catdir() methods have been added. =item File::Spec::Functions The new File::Spec::Functions modules provides a function interface -to the File::Spec module. Allows shorthand +to the File::Spec module. Allows shorthand - $fullname = catfile($dir1, $dir2, $file); + $fullname = catfile($dir1, $dir2, $file); instead of - $fullname = File::Spec->catfile($dir1, $dir2, $file); + $fullname = File::Spec->catfile($dir1, $dir2, $file); =item Math::BigInt -The logical operations C<E<lt>E<lt>>, C<E<gt>E<gt>>, C<&>, C<|> +The logical operations C<E<lt>E<lt>>, C<E<gt>E<gt>>, C<&>, C<|>, and C<~> are now supported on bigints. =item Math::Complex -The accessor methods Re, Im, arg, abs, rho, and theta, can now also +The accessor methods Re, Im, arg, abs, rho, and theta can now also act as mutators (accessor $z->Re(), mutator $z->Re(3)). =item Math::Trig -A little bit of radial trigonometry (cylindrical and spherical) added, -radial coordinate conversions and the great circle distance. +A little bit of radial trigonometry (cylindrical and spherical), +radial coordinate conversions, and the great circle distance were added. =item SDBM_File An EXISTS method has been added to this module (and sdbm_exists() has been added to the underlying sdbm library), so one can now call exists -on an SDBM_File tied hash and get the correct result rather than a +on an SDBM_File tied hash and get the correct result, rather than a runtime error. =item Time::Local The timelocal() and timegm() functions used to silently return bogus results when the date exceeded the machine's integer range. They -consistently croak() if the date falls in an unsupported range. +now consistently croak() if the date falls in an unsupported range. =item Win32 The error return value in list context has been changed for all functions -that return a list of values. Previously these functions returned a list -with a single element C<undef> in case an error occurred. Now these functions -return the empty list in these situations. This applies to the following +that return a list of values. Previously these functions returned a list +with a single element C<undef> if an error occurred. Now these functions +return the empty list in these situations. This applies to the following functions: - Win32::FsType - Win32::GetOSVersion + Win32::FsType + Win32::GetOSVersion The remaining functions are unchanged and continue to return C<undef> on error even in list context. @@ -399,22 +399,22 @@ The Win32::SetLastError(ERROR) function has been added as a complement to the Win32::GetLastError() function. The new Win32::GetFullPathName(FILENAME) returns the full absolute -pathname for FILENAME in scalar context. In list context it returns -a two element list containing the fully qualified directory name and +pathname for FILENAME in scalar context. In list context it returns +a two-element list containing the fully qualified directory name and the filename. =item DBM Filters A new feature called "DBM Filters" has been added to all the -DBM modules -- DB_File, GDBM_File, NDBM_File, ODBM_File and SDBM_File. -DBM Filters add four new methods to each of the DBM modules +DBM modules--DB_File, GDBM_File, NDBM_File, ODBM_File, and SDBM_File. +DBM Filters add four new methods to each DBM module: filter_store_key filter_store_value filter_fetch_key filter_fetch_value -These can be used to filter the contents of keys/values before they are +These can be used to filter key-value pairs before the pairs are written to the database or just after they are read from the database. See L<perldbmfilter> for further information. @@ -422,16 +422,16 @@ See L<perldbmfilter> for further information. =head2 Pragmata -C<use utf8;>, to enable UTF-8 and Unicode support. +C<use utf8> to enable UTF-8 and Unicode support. Lexical warnings pragma, C<use warning;>, to control optional warnings. -C<use filetest;>, to control the behaviour of filetests (C<-r> C<-w> ...). +C<use filetest> to control the behaviour of filetests (C<-r> C<-w> ...). Currently only one subpragma implemented, "use filetest 'access';", -that enables the use of access(2) or equivalent to check the +that enables the use of access(2) or equivalent to check permissions instead of using stat(2) as usual. This matters -in filesystems where there are ACLs (access control lists), the -stat(2) might lie, while access(2) knows better. +in filesystems where there are ACLs (access control lists): the +stat(2) might lie, but access(2) knows better. =head1 Utility Changes @@ -449,6 +449,10 @@ A tutorial on using open() effectively. A tutorial that introduces the essentials of references. +=item perltootc.pod + +A tutorial on managing class data for object modules. + =back =head1 New Diagnostics @@ -483,14 +487,14 @@ because many scripts assume to find Perl in /usr/bin/perl. =head1 BUGS If you find what you think is a bug, you might check the headers of -recently posted articles in the comp.lang.perl.misc newsgroup. +articles recently posted to the comp.lang.perl.misc newsgroup. There may also be information at http://www.perl.com/perl/, the Perl Home Page. If you believe you have an unreported bug, please run the B<perlbug> -program included with your release. Make sure you trim your bug down +program included with your release. Make sure to trim your bug down to a tiny but sufficient test case. Your bug report, along with the -output of C<perl -V>, will be sent off to <F<perlbug@perl.com>> to be +output of C<perl -V>, will be sent off to perlbug@perl.com to be analysed by the Perl porting team. =head1 SEE ALSO diff --git a/pod/perlmod.pod b/pod/perlmod.pod index 53426d3203..0031d6e0e6 100644 --- a/pod/perlmod.pod +++ b/pod/perlmod.pod @@ -212,7 +212,7 @@ This also has implications for the use of the SUPER:: qualifier =head2 Package Constructors and Destructors -There are two special subroutine definitions that function as package +Three special subroutines act as package constructors and destructors. These are the C<BEGIN>, C<INIT>, and C<END> routines. The C<sub> is optional for these routines. @@ -225,6 +225,11 @@ files in time to be visible to the rest of the file. Once a C<BEGIN> has run, it is immediately undefined and any code it used is returned to Perl's memory pool. This means you can't ever explicitly call a C<BEGIN>. +Similar to C<BEGIN> blocks, C<INIT> blocks are run just before the +Perl runtime begins execution. For example, the code generators +documented in L<perlcc> make use of C<INIT> blocks to initialize +and resolve pointers to XSUBs. + An C<END> subroutine is executed as late as possible, that is, when the interpreter is being exited, even if it is exiting as a result of a die() function. (But not if it's polymorphing into another program @@ -244,11 +249,6 @@ implemented (and subject to change, since its inconvenient at best), both C<BEGIN> and<END> blocks are run when you use the B<-c> switch for a compile-only syntax check, although your main code is not. -Similar to C<BEGIN> blocks, C<INIT> blocks are run just before the -Perl runtime begins execution. For example, the code generators -documented in L<perlcc> make use of C<INIT> blocks to initialize -and resolve pointers to XSUBs. - =head2 Perl Classes There is no special class syntax in Perl, but a package may act diff --git a/pod/perlobj.pod b/pod/perlobj.pod index 137896f1da..21073a795a 100644 --- a/pod/perlobj.pod +++ b/pod/perlobj.pod @@ -4,7 +4,7 @@ perlobj - Perl objects =head1 DESCRIPTION -First of all, you need to understand what references are in Perl. +First you need to understand what references are in Perl. See L<perlref> for that. Second, if you still find the following reference work too complicated, a tutorial on object-oriented programming in Perl can be found in L<perltoot> and L<perltootc>. @@ -50,7 +50,7 @@ a construct this way, too: package Critter; sub spawn { bless {} } -In fact, this might even be preferable, because the C++ programmers won't +This might even be preferable, because the C++ programmers won't be tricked into thinking that C<new> works in Perl as it does in C++. It doesn't. We recommend that you name your constructors whatever makes sense in the context of the problem you're solving. For example, @@ -73,7 +73,7 @@ have been returned directly, like this: return $self; } -In fact, you often see such a thing in more complicated constructors +You often see such a thing in more complicated constructors that wish to call methods in the class as part of the construction: sub new { @@ -115,7 +115,7 @@ reference as an ordinary reference. Outside the class package, the reference is generally treated as an opaque value that may be accessed only through the class's methods. -Although a a constructor can in theory re-bless a referenced object +Although a constructor can in theory re-bless a referenced object currently belonging to another class, this is almost certainly going to get you into trouble. The new class is responsible for all cleanup later. The previous blessing is forgotten, as an object @@ -155,7 +155,7 @@ last base class. Several commonly used methods are automatically supplied in the UNIVERSAL class; see L<"Default UNIVERSAL methods"> for more details. -If a missing method is found in one of the base classes, it is cached +If a missing method is found in a base class, it is cached in the current class for efficiency. Changing @ISA or defining new subroutines invalidates the cache and causes Perl to do the lookup again. @@ -285,13 +285,13 @@ For more reasons why the indirect object syntax is ambiguous, see L<"WARNING"> below. There are times when you wish to specify which class's method to use. -In this case, you can call your method as an ordinary subroutine +Here you can call your method as an ordinary subroutine call, being sure to pass the requisite first argument explicitly: $fred = MyCritter::find("Critter", "Fred"); MyCritter::display($fred, 'Height', 'Weight'); -Note however, that this does not do any inheritance. If you wish +Unlike method calls, function calls don't consider inheritance. If you wish merely to specify that Perl should I<START> looking for a method in a particular package, use an ordinary method call, but qualify the method name with the package like this: @@ -360,7 +360,7 @@ function in scope. You'd end up calling the current package's C<new> as a subroutine, rather than the desired class's method. The compiler tries to cheat by remembering bareword C<require>s, but the grief if it messes up just isn't worth the years of debugging it would likely take -you to to track such subtle bugs down. +you to track such subtle bugs down. The infix arrow notation using ``C<-E<gt>>'' doesn't suffer from either of these disturbing ambiguities, so we recommend you use it exclusively. @@ -411,7 +411,7 @@ C<isa> uses a very similar method and cache-ing strategy. This may cause strange effects if the Perl code dynamically changes @ISA in any package. You may add other methods to the UNIVERSAL class via Perl or XS code. -You do not need to C<use UNIVERSAL> in order to make these methods +You do not need to C<use UNIVERSAL> to make these methods available to your program. This is necessary only if you wish to have C<isa> available as a plain subroutine in the current package. @@ -436,7 +436,7 @@ object destruction, or for ensuring that destructors in the base classes of your choosing get called. Explicitly calling DESTROY is also possible, but is usually never needed. -Do not confuse the foregoing with how objects I<CONTAINED> in the current +Do not confuse the previous discussion with how objects I<CONTAINED> in the current one are destroyed. Such objects will be freed and destroyed automatically when the current object is freed, provided no other references to them exist elsewhere. @@ -449,8 +449,8 @@ with it for the next six months or so. =head2 Two-Phased Garbage Collection -For most purposes, Perl uses a fast and simple reference-based -garbage collection system. For this reason, there's an extra +For most purposes, Perl uses a fast and simple, reference-based +garbage collection system. That means there's an extra dereference going on at some level, so if you haven't built your Perl executable using your C compiler's C<-O> flag, performance will suffer. If you I<have> built Perl with C<cc -O>, then this @@ -535,8 +535,8 @@ When run as F</tmp/test>, the following output is produced: Notice that "global destruction" bit there? That's the thread garbage collector reaching the unreachable. -Objects are always destructed, even when regular refs aren't and in fact -are destructed in a separate pass before ordinary refs just to try to +Objects are always destructed, even when regular refs aren't. Objects +are destructed in a separate pass before ordinary refs just to prevent object destructors from using refs that have been themselves destructed. Plain refs are only garbage-collected if the destruct level is greater than 0. You can test the higher levels of global destruction diff --git a/pod/perlre.pod b/pod/perlre.pod index 98d7b35066..ca95638605 100644 --- a/pod/perlre.pod +++ b/pod/perlre.pod @@ -27,7 +27,7 @@ locale. See L<perllocale>. =item m Treat string as multiple lines. That is, change "^" and "$" from matching -at only the very start or end of the string to the start or end of any +the start or end of the string to matching the start or end of any line anywhere within the string. =item s @@ -50,9 +50,9 @@ Extend your pattern's legibility by permitting whitespace and comments. =back These are usually written as "the C</x> modifier", even though the delimiter -in question might not actually be a slash. In fact, any of these +in question might not really be a slash. Any of these modifiers may also be embedded within the regular expression itself using -the new C<(?...)> construct. See below. +the C<(?...)> construct. See below. The C</x> modifier itself needs a little more explanation. It tells the regular expression parser to ignore whitespace that is neither @@ -60,7 +60,7 @@ backslashed nor within a character class. You can use this to break up your regular expression into (slightly) more readable parts. The C<#> character is also treated as a metacharacter introducing a comment, just as in ordinary Perl code. This also means that if you want real -whitespace or C<#> characters in the pattern (outside of a character +whitespace or C<#> characters in the pattern (outside a character class, where they are unaffected by C</x>), that you'll either have to escape them or encode them using octal or hex escapes. Taken together, these features go a long way towards making Perl's regular expressions @@ -72,7 +72,7 @@ in L<perlop>. =head2 Regular Expressions The patterns used in Perl pattern matching derive from supplied in -the Version 8 regex routines. (In fact, the routines are derived +the Version 8 regex routines. (The routines are derived (distantly) from Henry Spencer's freely redistributable reimplementation of the V8 routines.) See L<Version 8 Regular Expressions> for details. @@ -88,9 +88,9 @@ meanings: () Grouping [] Character class -By default, the "^" character is guaranteed to match at only the -beginning of the string, the "$" character at only the end (or before the -newline at the end) and Perl does certain optimizations with the +By default, the "^" character is guaranteed to match only the +beginning of the string, the "$" character only the end (or before the +newline at the end), and Perl does certain optimizations with the assumption that the string contains only one line. Embedded newlines will not be matched by "^" or "$". You may, however, wish to treat a string as a multi-line buffer, such that the "^" will match after any @@ -99,7 +99,7 @@ cost of a little more overhead, you can do this by using the /m modifier on the pattern match operator. (Older programs did this by setting C<$*>, but this practice is now deprecated.) -To facilitate multi-line substitutions, the "." character never matches a +To simplify multi-line substitutions, the "." character never matches a newline unless you use the C</s> modifier, which in effect tells Perl to pretend the string is a single line--even if it isn't. The C</s> modifier also overrides the setting of C<$*>, in case you have some (badly behaved) older @@ -179,12 +179,12 @@ In addition, Perl defines the following: \C Match a single C char (octet) even under utf8. A C<\w> matches a single alphanumeric character, not a whole word. -To match a word you'd need to say C<\w+>. If C<use locale> is in -effect, the list of alphabetic characters generated by C<\w> is -taken from the current locale. See L<perllocale>. You may use -C<\w>, C<\W>, C<\s>, C<\S>, C<\d>, and C<\D> within character classes -(though not as either end of a range). See L<utf8> for details -about C<\pP>, C<\PP>, and C<\X>. +Use C<\w+> to match a string of Perl-identifier characters (which isn't +the same as matching an English word). If C<use locale> is in effect, the +list of alphabetic characters generated by C<\w> is taken from the +current locale. See L<perllocale>. You may use C<\w>, C<\W>, C<\s>, C<\S>, +C<\d>, and C<\D> within character classes (though not as either end of +a range). See L<utf8> for details about C<\pP>, C<\PP>, and C<\X>. Perl defines the following zero-width assertions: @@ -195,7 +195,7 @@ Perl defines the following zero-width assertions: \z Match only at end of string \G Match only where previous m//g left off (works only with /g) -A word boundary (C<\b>) is defined as a spot between two characters +A word boundary (C<\b>) is a spot between two characters that has a C<\w> on one side of it and a C<\W> on the other side of it (in either order), counting the imaginary characters off the beginning and end of the string as matching a C<\W>. (Within @@ -214,51 +214,63 @@ several patterns that you want to match against consequent substrings of your string, see the previous reference. The actual location where C<\G> will match can also be influenced by using C<pos()> as an lvalue. See L<perlfunc/pos>. - -When the bracketing construct C<( ... )> is used to create a capture -buffer, \E<lt>digitE<gt> matches the digit'th substring. Outside -of the pattern, always use "$" instead of "\" in front of the digit. -(While the \E<lt>digitE<gt> notation can on rare occasion work -outside the current pattern, this should not be relied upon. See -the WARNING below.) The scope of $E<lt>digitE<gt> (and C<$`>, -C<$&>, and C<$'>) extends to the end of the enclosing BLOCK or eval -string, or to the next successful pattern match, whichever comes -first. If you want to use parentheses to delimit a subpattern -(e.g., a set of alternatives) without saving it as a subpattern, -follow the ( with a ?:. - -You may have as many parentheses as you wish. If you have more -than 9 captured substrings, the variables $10, $11, ... refer to -the corresponding substring. Within the pattern, \10, \11, etc. -refer back to substrings if there have been at least that many left -parentheses before the backreference. Otherwise (for backward -compatibility) \10 is the same as \010, a backspace, and \11 the -same as \011, a tab. And so on. (\1 through \9 are always -backreferences.) - -C<$+> returns whatever the last bracket match matched. C<$&> returns the -entire matched string. (C<$0> used to return the same thing, but not any -more.) C<$`> returns everything before the matched string. C<$'> returns -everything after the matched string. Examples: + +The bracketing construct C<( ... )> creates capture buffers. To +refer to the digit'th buffer use \E<lt>digitE<gt> within the +match. Outside the match use "$" instead of "\". (The +\E<lt>digitE<gt> notation works in certain circumstances outside +the match. See the warning below about \1 vs $1 for details.) +Referring back to another part of the match is called a +I<backreference>. + +There is no limit to the number of captured substrings that you may +use. However Perl also uses \10, \11, etc. as aliases for \010, +\011, etc. (Recall that 0 means octal, so \011 is the 9'th ASCII +character, a tab.) Perl resolves this ambiguity by interpreting +\10 as a backreference only if at least 10 left parentheses have +opened before it. Likewise \11 is a backreference only if at least +11 left parentheses have opened before it. And so on. \1 through +\9 are always interpreted as backreferences." + +Examples: s/^([^ ]*) *([^ ]*)/$2 $1/; # swap first two words - if (/Time: (..):(..):(..)/) { + if (/(.)\1/) { # find first doubled char + print "'$1' is the first doubled character\n"; + } + + if (/Time: (..):(..):(..)/) { # parse out values $hours = $1; $minutes = $2; $seconds = $3; } - -Once Perl sees that you need one of C<$&>, C<$`> or C<$'> anywhere in -the program, it has to provide them on each and every pattern match. -This can slow your program down. The same mechanism that handles -these provides for the use of $1, $2, etc., so you pay the same price -for each pattern that contains capturing parentheses. But if you never -use $&, etc., in your script, then patterns I<without> capturing -parentheses won't be penalized. So avoid $&, $', and $` if you can, -but if you can't (and some algorithms really appreciate them), once -you've used them once, use them at will, because you've already paid -the price. As of 5.005, $& is not so costly as the other two. + +Several special variables also refer back to portions of the previous +match. C<$+> returns whatever the last bracket match matched. +C<$&> returns the entire matched string. (At one point C<$0> did +also, but now it returns the name of the program.) C<$`> returns +everything before the matched string. And C<$'> returns everything +after the matched string. + +The numbered variables ($1, $2, $3, etc.) and the related punctuation +set (C<<$+>, C<$&>, C<$`>, and C<$'>) are all dynamically scoped +until the end of the enclosing block or until the next successful +match, whichever comes first. (See L<perlsyn/"Compound Statements">.) + +B<WARNING>: Once Perl sees that you need one of C<$&>, C<$`>, or +C<$'> anywhere in the program, it has to provide them for every +pattern match. This may substantially slow your program. Perl +uses the same mechanism to produce $1, $2, etc, so you also pay a +price for each pattern that contains capturing parentheses. (To +avoid this cost while retaining the grouping behaviour, use the +extended regular expression C<(?: ... )> instead.) But if you never +use C<$&>, C<$`> or C<$'>, then patterns I<without> capturing +parentheses will not be penalized. So avoid C<$&>, C<$'>, and C<$`> +if you can, but if you can't (and some algorithms really appreciate +them), once you've used them once, use them at will, because you've +already paid the price. As of 5.005, C<$&> is not so costly as the +other two. Backslashed metacharacters in Perl are alphanumeric, such as C<\b>, C<\w>, C<\n>. Unlike some other regular expression languages, there @@ -271,36 +283,36 @@ use for a pattern. Simply quote all non-alphanumeric characters: $pattern =~ s/(\W)/\\$1/g; -In modern days, it is more common to see either the quotemeta() -function or the C<\Q> metaquoting escape sequence used to disable -all metacharacters' special meanings like this: +Today it is more common to use the quotemeta() function or the C<\Q> +metaquoting escape sequence to disable all metacharacters' special +meanings like this: /$unquoted\Q$quoted\E$unquoted/ =head2 Extended Patterns -For those situations where simple regular expression patterns are -not enough, Perl defines a consistent extension syntax for venturing -beyond simple patterns such as are found in standard tools like -B<awk> and B<lex>. That syntax is a pair of parentheses with a -question mark as the first thing within the parentheses (this was -a syntax error in older versions of Perl). The character after the -question mark gives the function of the extension. +Perl also defines a consistent extension syntax for features not +found in standard tools like B<awk> and B<lex>. The syntax is a +pair of parentheses with a question mark as the first thing within +the parentheses. The character after the question mark indicates +the extension. -Many extensions are already supported, some for almost five years -now. Other, more exotic forms are very new, and should be considered -highly experimental, and are so marked. +The stability of these extensions varies widely. Some have been +part of the core language for many years. Others are experimental +and may change without warning or be completely removed. Check +the documentation on an individual feature to verify its current +status. -A question mark was chosen for this and for the new minimal-matching -construct because 1) question mark is pretty rare in older regular -expressions, and 2) whenever you see one, you should stop and "question" -exactly what is going on. That's psychology... +A question mark was chosen for this and for the minimal-matching +construct because 1) question marks are rare in older regular +expressions, and 2) whenever you see one, you should stop and +"question" exactly what is going on. That's psychology... =over 10 =item C<(?#text)> -A comment. The text is ignored. If the C</x> modifier is used to enable +A comment. The text is ignored. If the C</x> modifier enables whitespace formatting, a simple C<#> will suffice. Note that Perl closes the comment as soon as it sees a C<)>, so there is no way to put a literal C<)> in the comment. @@ -328,7 +340,7 @@ localized inside an enclosing group (if any). For example, ( (?i) blah ) \s+ \1 will match a repeated (I<including the case>!) word C<blah> in any -case, assuming C<x> modifier, and no C<i> modifier outside of this +case, assuming C<x> modifier, and no C<i> modifier outside this group. =item C<(?:pattern)> @@ -352,7 +364,7 @@ C<(?imsx-imsx)>. For example, /(?s-i:more.*than).*million/i -is equivalent to more verbose +is equivalent to the more verbose /(?:(?s-i)more.*than).*million/i @@ -420,7 +432,7 @@ C<local>ization are undone, so that >x; will set C<$res = 4>. Note that after the match, $cnt returns to the globally -introduced value, since the scopes which restrict C<local> operators +introduced value, because the scopes that restrict C<local> operators are unwound. This assertion may be used as a C<(?(condition)yes-pattern|no-pattern)> @@ -439,20 +451,20 @@ perilous C<use re 'eval'> pragma has been used (see L<re>), or the variables contain results of C<qr//> operator (see L<perlop/"qr/STRING/imosx">). -This restriction is due to the wide-spread and remarkably convenient +This restriction is because of the wide-spread and remarkably convenient custom of using run-time determined strings as patterns. For example: $re = <>; chomp $re; $string =~ /$re/; -Prior to the execution of code in a pattern, this was completely -safe from a security point of view, although it could of course -raise an exception from an illegal pattern. If you turn on the -C<use re 'eval'>, though, it is no longer secure, so you should -only do so if you are also using taint checking. Better yet, use -the carefully constrained evaluation within a Safe module. See -L<perlsec> for details about both these mechanisms. +Before Perl knew how to execute interpolated code within a pattern, +this operation was completely safe from a security point of view, +although it could raise an exception from an illegal pattern. If +you turn on the C<use re 'eval'>, though, it is no longer secure, +so you should only do so if you are also using taint checking. +Better yet, use the carefully constrained evaluation within a Safe +module. See L<perlsec> for details about both these mechanisms. =item C<(?p{ code })> @@ -486,7 +498,7 @@ highly experimental, and may be changed or deleted without notice. An "independent" subexpression, one which matches the substring that a I<standalone> C<pattern> would match if anchored at the given -position -- but it matches no more than this substring. This +position--but it matches no more than this substring. This construct is useful for optimizations of what would otherwise be "eternal" matches, because it will not backtrack (see L<"Backtracking">). @@ -527,7 +539,7 @@ to a subpattern of the above pattern. Consider how the pattern above 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 +hung. However, a tiny change to this pattern m{ \( ( @@ -615,7 +627,7 @@ Which perhaps unexpectedly yields: got <d is under the bar in the > That's because C<.*> was greedy, so you get everything between the -I<first> "foo" and the I<last> "bar". In this case, it's more effective +I<first> "foo" and the I<last> "bar". Here it's more effective to use minimal matching to make sure you get the text between a "foo" and the first "bar" thereafter. @@ -714,8 +726,9 @@ that you've asked "Is it true that at the start of $x, following 0 or more non-digits, you have something that's not 123?" If the pattern matcher had let C<\D*> expand to "ABC", this would have caused the whole pattern to fail. + The search engine will initially match C<\D*> with "ABC". Then it will -try to match C<(?!123> with "123", which of course fails. But because +try to match C<(?!123> with "123", which fails. But because a quantifier (C<\D*>) has been used in the regular expression, the search engine can backtrack and retry the match differently in the hope of matching the complete regular expression. @@ -723,13 +736,13 @@ in the hope of matching the complete regular expression. The pattern really, I<really> wants to succeed, so it uses the standard pattern back-off-and-retry and lets C<\D*> expand to just "AB" this time. Now there's indeed something following "AB" that is not -"123". It's in fact "C123", which suffices. +"123". It's "C123", which suffices. -We can deal with this by using both an assertion and a negation. We'll -say that the first part in $1 must be followed by a digit, and in fact, it -must also be followed by something that's not "123". Remember that the -look-aheads are zero-width expressions--they only look, but don't consume -any of the string in their match. So rewriting this way produces what +We can deal with this by using both an assertion and a negation. +We'll say that the first part in $1 must be followed both by a digit +and by something that's not "123". Remember that the look-aheads +are zero-width expressions--they only look, but don't consume any +of the string in their match. So rewriting this way produces what you'd expect; that is, case 5 will fail, but case 6 succeeds: print "5: got $1\n" if $x =~ /^(\D*)(?=\d)(?!123)/ ; @@ -747,20 +760,20 @@ although the attempted matches are made at different positions because "a" is not a zero-width assertion, but a one-width assertion. B<WARNING>: particularly complicated regular expressions can take -exponential time to solve due to the immense number of possible +exponential time to solve because of the immense number of possible ways they can use backtracking to try match. For example, this will -take a very long time to run +take a painfully long time to run /((a{0,5}){0,5}){0,5}/ -And if you used C<*>'s instead of limiting it to 0 through 5 matches, then -it would take literally forever--or until you ran out of stack space. +And if you used C<*>'s instead of limiting it to 0 through 5 matches, +then it would take forever--or until you ran out of stack space. A powerful tool for optimizing such beasts is "independent" groups, which do not backtrace (see L<C<(?E<gt>pattern)>>). Note also that zero-length look-ahead/look-behind assertions will not backtrace to make -the tail match, since they are in "logical" context: only the fact -whether they match or not is considered relevant. For an example +the tail match, since they are in "logical" context: only +whether they match is considered relevant. For an example where side-effects of a look-ahead I<might> have influenced the following match, see L<C<(?E<gt>pattern)>>. @@ -780,7 +793,7 @@ would match "blurfl" in the target string. You can specify a character class, by enclosing a list of characters in C<[]>, which will match any one character from the list. If the first character after the "[" is "^", the class matches any character not -in the list. Within a list, the "-" character is used to specify a +in the list. Within a list, the "-" character specifies a range, so that C<a-z> represents all characters between "a" and "z", inclusive. If you want "-" itself to be a member of a class, put it at the start or end of the list, or escape it with a backslash. (The @@ -810,8 +823,8 @@ or "foe" in the target string (as would C<f(e|i|o)e>). The first alternative includes everything from the last pattern delimiter ("(", "[", or the beginning of the pattern) up to the first "|", and the last alternative contains everything from the last "|" to the next -pattern delimiter. For this reason, it's common practice to include -alternatives in parentheses, to minimize confusion about where they +pattern delimiter. That's why it's common practice to include +alternatives in parentheses: to minimize confusion about where they start and end. Alternatives are tried from left to right, so the first @@ -825,16 +838,16 @@ important when you are capturing matched text using parentheses.) Also remember that "|" is interpreted as a literal within square brackets, so if you write C<[fee|fie|foe]> you're really only matching C<[feio|]>. -Within a pattern, you may designate subpatterns for later reference by -enclosing them in parentheses, and you may refer back to the I<n>th -subpattern later in the pattern using the metacharacter \I<n>. -Subpatterns are numbered based on the left to right order of their -opening parenthesis. A backreference matches whatever -actually matched the subpattern in the string being examined, not the -rules for that subpattern. Therefore, C<(0|0x)\d*\s\1\d*> will -match "0x1234 0x4321", but not "0x1234 01234", because subpattern 1 -actually matched "0x", even though the rule C<0|0x> could -potentially match the leading 0 in the second number. +Within a pattern, you may designate subpatterns for later reference +by enclosing them in parentheses, and you may refer back to the +I<n>th subpattern later in the pattern using the metacharacter +\I<n>. Subpatterns are numbered based on the left to right order +of their opening parenthesis. A backreference matches whatever +actually matched the subpattern in the string being examined, not +the rules for that subpattern. Therefore, C<(0|0x)\d*\s\1\d*> will +match "0x1234 0x4321", but not "0x1234 01234", because subpattern +1 matched "0x", even though the rule C<0|0x> could potentially match +the leading 0 in the second number. =head2 Warning on \1 vs $1 @@ -857,7 +870,7 @@ Or if you try to do s/(\d+)/\1000/; You can't disambiguate that by saying C<\{1}000>, whereas you can fix it with -C<${1}000>. Basically, the operation of interpolation should not be confused +C<${1}000>. The operation of interpolation should not be confused with the operation of matching a backreference. Certainly they mean two different things on the I<left> side of the C<s///>. @@ -876,7 +889,7 @@ loops using regular expressions, with something as innocuous as: The C<o?> can match at the beginning of C<'foo'>, and since the position in the string is not moved by the match, C<o?> would match again and again -due to the C<*> modifier. Another common way to create a similar cycle +because of the C<*> modifier. Another common way to create a similar cycle is with the looping modifier C<//g>: @matches = ( 'foo' =~ m{ o? }xg ); @@ -888,8 +901,8 @@ or or the loop implied by split(). However, long experience has shown that many programming tasks may -be significantly simplified by using repeated subexpressions which -may match zero-length substrings, with a simple example being: +be significantly simplified by using repeated subexpressions that +may match zero-length substrings. Here's a simple example being: @chars = split //, $string; # // is not magic in split ($whitewashed = $string) =~ s/()/ /g; # parens avoid magic s// / @@ -993,8 +1006,11 @@ L<perlop/"Regexp Quote-Like Operators">. L<perlop/"Gory details of parsing quoted constructs">. +L<perlfaq6>. + L<perlfunc/pos>. L<perllocale>. -I<Mastering Regular Expressions> by Jeffrey Friedl. +I<Mastering Regular Expressions> by Jeffrey Friedl, published +by O'Reilly and Associates. diff --git a/pod/perltoc.pod b/pod/perltoc.pod index 9dc0b36d91..b17a889959 100644 --- a/pod/perltoc.pod +++ b/pod/perltoc.pod @@ -17,12 +17,17 @@ through to locate the proper section you're looking for. =item DESCRIPTION -Many usability enhancements, Simplified grammar, Lexical scoping, -Arbitrarily nested data structures, Modularity and reusability, -Object-oriented programming, Embeddable and Extensible, POSIX compliant, -Package constructors and destructors, Multiple simultaneous DBM -implementations, Subroutine definitions may now be autoloaded, Regular -expression enhancements, Innumerable Unbundled Modules, Compilability +modularity and reusability using innumerable modules, embeddable and +extensible, roll-your-own magic variables (including multiple simultaneous +DBM implementations), subroutines can now be overridden, autoloaded, and +prototyped, arbitrarily nested data structures and anonymous functions, +object-oriented programming, compilability into C code or Perl bytecode, +support for light-weight processes (threads), support for +internationalization, localization, and Unicode, lexical scoping, regular +expression enhancements, enhanced debugger and interactive Perl +environment, with integrated editor support, POSIX 1003.1 compliant library + +=item AVAILABILITY =item ENVIRONMENT @@ -38,16 +43,227 @@ expression enhancements, Innumerable Unbundled Modules, Compilability =item NOTES -=head2 perlfaq - frequently asked questions about Perl ($Date: 1998/07/20 -23:12:17 $) +=head2 perlfaq - frequently asked questions about Perl ($Date: 1999/05/23 +20:38:02 $) =item DESCRIPTION perlfaq: Structural overview of the FAQ, L<perlfaq1>: General Questions -About Perl, L<perlfaq2>: Obtaining and Learning about Perl, L<perlfaq3>: -Programming Tools, L<perlfaq4>: Data Manipulation, L<perlfaq5>: Files and -Formats, L<perlfaq6>: Regexps, L<perlfaq7>: General Perl Language Issues, -L<perlfaq8>: System Interaction, L<perlfaq9>: Networking +About Perl, What is Perl?, Who supports Perl? Who develops it? Why is it +free?, Which version of Perl should I use?, What are perl4 and perl5?, What +is perl6?, How stable is Perl?, Is Perl difficult to learn?, How does Perl +compare with other languages like Java, Python, REXX, Scheme, or Tcl?, Can +I do [task] in Perl?, When shouldn't I program in Perl?, What's the +difference between "perl" and "Perl"?, Is it a Perl program or a Perl +script?, What is a JAPH?, Where can I get a list of Larry Wall witticisms?, +How can I convince my sysadmin/supervisor/employees to use version +(5/5.005/Perl instead of some other language)?, L<perlfaq2>: Obtaining and +Learning about Perl, What machines support Perl? Where do I get it?, How +can I get a binary version of Perl?, I don't have a C compiler on my +system. How can I compile perl?, I copied the Perl binary from one machine +to another, but scripts don't work, I grabbed the sources and tried to +compile but gdbm/dynamic loading/malloc/linking/... failed. How do I make +it work?, What modules and extensions are available for Perl? What is +CPAN? What does CPAN/src/... mean?, Is there an ISO or ANSI certified +version of Perl?, Where can I get information on Perl?, What are the Perl +newsgroups on USENET? Where do I post questions?, Where should I post +source code?, Perl Books, Perl in Magazines, Perl on the Net: FTP and WWW +Access, What mailing lists are there for perl?, Archives of +comp.lang.perl.misc, Where can I buy a commercial version of Perl?, Where +do I send bug reports?, What is perl.com?, L<perlfaq3>: Programming Tools, +How do I do (anything)?, How can I use Perl interactively?, Is there a Perl +shell?, How do I debug my Perl programs?, How do I profile my Perl +programs?, How do I cross-reference my Perl programs?, Is there a +pretty-printer (formatter) for Perl?, Is there a ctags for Perl?, Is there +an IDE or Windows Perl Editor?, Where can I get Perl macros for vi?, Where +can I get perl-mode for emacs?, How can I use curses with Perl?, How can I +use X or Tk with Perl?, How can I generate simple menus without using CGI +or Tk?, What is undump?, How can I make my Perl program run faster?, How +can I make my Perl program take less memory?, Is it unsafe to return a +pointer to local data?, How can I free an array or hash so my program +shrinks?, How can I make my CGI script more efficient?, How can I hide the +source for my Perl program?, How can I compile my Perl program into byte +code or C?, How can I compile Perl into Java?, How can I get C<#!perl> to +work on [MS-DOS,NT,...]?, Can I write useful perl programs on the command +line?, Why don't perl one-liners work on my DOS/Mac/VMS system?, Where can +I learn about CGI or Web programming in Perl?, Where can I learn about +object-oriented Perl programming?, Where can I learn about linking C with +Perl? [h2xs, xsubpp], I've read perlembed, perlguts, etc., but I can't +embed perl inmy C program, what am I doing wrong?, When I tried to run my +script, I got this message. What does itmean?, What's MakeMaker?, +L<perlfaq4>: Data Manipulation, Why am I getting long decimals (eg, +19.9499999999999) instead of the numbers I should be getting (eg, 19.95)?, +Why isn't my octal data interpreted correctly?, Does Perl have a round() +function? What about ceil() and floor()? Trig functions?, How do I +convert bits into ints?, Why doesn't & work the way I want it to?, How do I +multiply matrices?, How do I perform an operation on a series of integers?, +How can I output Roman numerals?, Why aren't my random numbers random?, How +do I find the week-of-the-year/day-of-the-year?, How do I find the current +century or millennium?, How can I compare two dates and find the +difference?, How can I take a string and turn it into epoch seconds?, How +can I find the Julian Day?, How do I find yesterday's date?, Does Perl have +a year 2000 problem? Is Perl Y2K compliant?, How do I validate input?, How +do I unescape a string?, How do I remove consecutive pairs of characters?, +How do I expand function calls in a string?, How do I find matching/nesting +anything?, How do I reverse a string?, How do I expand tabs in a string?, +How do I reformat a paragraph?, How can I access/change the first N letters +of a string?, How do I change the Nth occurrence of something?, How can I +count the number of occurrences of a substring within a string?, How do I +capitalize all the words on one line?, How can I split a [character] +delimited string except when inside[character]? (Comma-separated files), +How do I strip blank space from the beginning/end of a string?, How do I +pad a string with blanks or pad a number with zeroes?, How do I extract +selected columns from a string?, How do I find the soundex value of a +string?, How can I expand variables in text strings?, What's wrong with +always quoting "$vars"?, Why don't my E<lt>E<lt>HERE documents work?, What +is the difference between a list and an array?, What is the difference +between $array[1] and @array[1]?, How can I remove duplicate elements from +a list or array?, How can I tell whether a list or array contains a certain +element?, How do I compute the difference of two arrays? How do I compute +the intersection of two arrays?, How do I test whether two arrays or hashes +are equal?, How do I find the first array element for which a condition is +true?, How do I handle linked lists?, How do I handle circular lists?, How +do I shuffle an array randomly?, How do I process/modify each element of an +array?, How do I select a random element from an array?, How do I permute N +elements of a list?, How do I sort an array by (anything)?, How do I +manipulate arrays of bits?, Why does defined() return true on empty arrays +and hashes?, How do I process an entire hash?, What happens if I add or +remove keys from a hash while iterating over it?, How do I look up a hash +element by value?, How can I know how many entries are in a hash?, How do I +sort a hash (optionally by value instead of key)?, How can I always keep my +hash sorted?, What's the difference between "delete" and "undef" with +hashes?, Why don't my tied hashes make the defined/exists distinction?, How +do I reset an each() operation part-way through?, How can I get the unique +keys from two hashes?, How can I store a multidimensional array in a DBM +file?, How can I make my hash remember the order I put elements into it?, +Why does passing a subroutine an undefined element in a hash create it?, +How can I make the Perl equivalent of a C structure/C++ class/hash or array +of hashes or arrays?, How can I use a reference as a hash key?, How do I +handle binary data correctly?, How do I determine whether a scalar is a +number/whole/integer/float?, How do I keep persistent data across program +calls?, How do I print out or copy a recursive data structure?, How do I +define methods for every class/object?, How do I verify a credit card +checksum?, How do I pack arrays of doubles or floats for XS code?, +L<perlfaq5>: Files and Formats, How do I flush/unbuffer an output +filehandle? Why must I do this?, How do I change one line in a file/delete +a line in a file/insert a line in the middle of a file/append to the +beginning of a file?, How do I count the number of lines in a file?, How do +I make a temporary file name?, How can I manipulate fixed-record-length +files?, How can I make a filehandle local to a subroutine? How do I pass +filehandles between subroutines? How do I make an array of filehandles?, +How can I use a filehandle indirectly?, How can I set up a footer format to +be used with write()?, How can I write() into a string?, How can I output +my numbers with commas added?, How can I translate tildes (~) in a +filename?, How come when I open a file read-write it wipes it out?, Why do +I sometimes get an "Argument list too long" when I use E<lt>*E<gt>?, Is +there a leak/bug in glob()?, How can I open a file with a leading "E<gt>" +or trailing blanks?, How can I reliably rename a file?, How can I lock a +file?, Why can't I just open(FH, ">file.lock")?, I still don't get locking. + I just want to increment the number in the file. How can I do this?, How +do I randomly update a binary file?, How do I get a file's timestamp in +perl?, How do I set a file's timestamp in perl?, How do I print to more +than one file at once?, How can I read in an entire file all at once?, How +can I read in a file by paragraphs?, How can I read a single character from +a file? From the keyboard?, How can I tell whether there's a character +waiting on a filehandle?, How do I do a C<tail -f> in perl?, How do I dup() +a filehandle in Perl?, How do I close a file descriptor by number?, Why +can't I use "C:\temp\foo" in DOS paths? What doesn't `C:\temp\foo.exe` +work?, Why doesn't glob("*.*") get all the files?, Why does Perl let me +delete read-only files? Why does C<-i> clobber protected files? Isn't +this a bug in Perl?, How do I select a random line from a file?, Why do I +get weird spaces when I print an array of lines?, L<perlfaq6>: Regexps, How +can I hope to use regular expressions without creating illegible and +unmaintainable code?, I'm having trouble matching over more than one line. +What's wrong?, How can I pull out lines between two patterns that are +themselves on different lines?, I put a regular expression into $/ but it +didn't work. What's wrong?, How do I substitute case insensitively on the +LHS, but preserving case on the RHS?, How can I make C<\w> match national +character sets?, How can I match a locale-smart version of C</[a-zA-Z]/>?, +How can I quote a variable to use in a regex?, What is C</o> really for?, +How do I use a regular expression to strip C style comments from a file?, +Can I use Perl regular expressions to match balanced text?, What does it +mean that regexes are greedy? How can I get around it?, How do I process +each word on each line?, How can I print out a word-frequency or +line-frequency summary?, How can I do approximate matching?, How do I +efficiently match many regular expressions at once?, Why don't +word-boundary searches with C<\b> work for me?, Why does using $&, $`, or +$' slow my program down?, What good is C<\G> in a regular expression?, Are +Perl regexes DFAs or NFAs? Are they POSIX compliant?, What's wrong with +using grep or map in a void context?, How can I match strings with +multibyte characters?, How do I match a pattern that is supplied by the +user?, L<perlfaq7>: General Perl Language Issues, Can I get a BNF/yacc/RE +for the Perl language?, What are all these $@%&* punctuation signs, and how +do I know when to use them?, Do I always/never have to quote my strings or +use semicolons and commas?, How do I skip some return values?, How do I +temporarily block warnings?, What's an extension?, Why do Perl operators +have different precedence than C operators?, How do I declare/create a +structure?, How do I create a module?, How do I create a class?, How can I +tell if a variable is tainted?, What's a closure?, What is variable suicide +and how can I prevent it?, How can I pass/return a {Function, FileHandle, +Array, Hash, Method, Regex}?, How do I create a static variable?, What's +the difference between dynamic and lexical (static) scoping? Between +local() and my()?, How can I access a dynamic variable while a similarly +named lexical is in scope?, What's the difference between deep and shallow +binding?, Why doesn't "my($foo) = E<lt>FILEE<gt>;" work right?, How do I +redefine a builtin function, operator, or method?, What's the difference +between calling a function as &foo and foo()?, How do I create a switch or +case statement?, How can I catch accesses to undefined +variables/functions/methods?, Why can't a method included in this same file +be found?, How can I find out my current package?, How can I comment out a +large block of perl code?, How do I clear a package?, How can I use a +variable as a variable name?, L<perlfaq8>: System Interaction, How do I +find out which operating system I'm running under?, How come exec() doesn't +return?, How do I do fancy stuff with the keyboard/screen/mouse?, How do I +print something out in color?, How do I read just one key without waiting +for a return key?, How do I check whether input is ready on the keyboard?, +How do I clear the screen?, How do I get the screen size?, How do I ask the +user for a password?, How do I read and write the serial port?, How do I +decode encrypted password files?, How do I start a process in the +background?, How do I trap control characters/signals?, How do I modify the +shadow password file on a Unix system?, How do I set the time and date?, +How can I sleep() or alarm() for under a second?, How can I measure time +under a second?, How can I do an atexit() or setjmp()/longjmp()? (Exception +handling), Why doesn't my sockets program work under System V (Solaris)? +What does the error message "Protocol not supported" mean?, How can I call +my system's unique C functions from Perl?, Where do I get the include files +to do ioctl() or syscall()?, Why do setuid perl scripts complain about +kernel problems?, How can I open a pipe both to and from a command?, Why +can't I get the output of a command with system()?, How can I capture +STDERR from an external command?, Why doesn't open() return an error when a +pipe open fails?, What's wrong with using backticks in a void context?, How +can I call backticks without shell processing?, Why can't my script read +from STDIN after I gave it EOF (^D on Unix, ^Z on MS-DOS)?, How can I +convert my shell script to perl?, Can I use perl to run a telnet or ftp +session?, How can I write expect in Perl?, Is there a way to hide perl's +command line from programs such as "ps"?, I {changed directory, modified my +environment} in a perl script. How come the change disappeared when I +exited the script? How do I get my changes to be visible?, How do I close +a process's filehandle without waiting for it to complete?, How do I fork a +daemon process?, How do I make my program run with sh and csh?, How do I +find out if I'm running interactively or not?, How do I timeout a slow +event?, How do I set CPU limits?, How do I avoid zombies on a Unix system?, +How do I use an SQL database?, How do I make a system() exit on control-C?, +How do I open a file without blocking?, How do I install a module from +CPAN?, What's the difference between require and use?, How do I keep my own +module/library directory?, How do I add the directory my program lives in +to the module/library search path?, How do I add a directory to my include +path at runtime?, What is socket.ph and where do I get it?, L<perlfaq9>: +Networking, My CGI script runs from the command line but not the browser. +(500 Server Error), How can I get better error messages from a CGI +program?, How do I remove HTML from a string?, How do I extract URLs?, How +do I download a file from the user's machine? How do I open a file on +another machine?, How do I make a pop-up menu in HTML?, How do I fetch an +HTML file?, How do I automate an HTML form submission?, How do I decode or +create those %-encodings on the web?, How do I redirect to another page?, +How do I put a password on my web pages?, How do I edit my .htpasswd and +.htgroup files with Perl?, How do I make sure users can't enter values into +a form that cause my CGI script to do bad things?, How do I parse a mail +header?, How do I decode a CGI form?, How do I check a valid mail address?, +How do I decode a MIME/BASE64 string?, How do I return the user's mail +address?, How do I send mail?, How do I read mail?, How do I find out my +hostname/domainname/IP address?, How do I fetch a news article or the +active newsgroups?, How do I fetch/put an FTP file?, How can I do RPC in +Perl? =over @@ -74,11 +290,11 @@ authors =item Changes -24/April/97, 23/April/97, 25/March/97, 18/March/97, 17/March/97 Version, -Initial Release: 11/March/97 +23/May/99, 13/April/99, 7/January/99, 22/June/98, 24/April/97, 23/April/97, +25/March/97, 18/March/97, 17/March/97 Version, Initial Release: 11/March/97 -=head2 perlfaq1 - General Questions About Perl ($Revision: 1.14 $, $Date: -1998/06/14 22:15:25 $) +=head2 perlfaq1 - General Questions About Perl ($Revision: 1.23 $, $Date: +1999/05/23 16:08:30 $) =item DESCRIPTION @@ -92,6 +308,8 @@ Initial Release: 11/March/97 =item What are perl4 and perl5? +=item What is perl6? + =item How stable is Perl? =item Is Perl difficult to learn? @@ -112,14 +330,14 @@ Scheme, or Tcl? =item Where can I get a list of Larry Wall witticisms? =item How can I convince my sysadmin/supervisor/employees to use version -(5/5.004/Perl instead of some other language)? +(5/5.005/Perl instead of some other language)? =back =item AUTHOR AND COPYRIGHT -=head2 perlfaq2 - Obtaining and Learning about Perl ($Revision: 1.24 $, -$Date: 1998/07/20 23:40:28 $) +=head2 perlfaq2 - Obtaining and Learning about Perl ($Revision: 1.31 $, +$Date: 1999/04/14 03:46:19 $) =item DESCRIPTION @@ -137,7 +355,7 @@ don't work. =item I grabbed the sources and tried to compile but gdbm/dynamic loading/malloc/linking/... failed. How do I make it work? -=item What modules and extensions are available for Perl? What is CPAN? +=item What modules and extensions are available for Perl? What is CPAN? What does CPAN/src/... mean? =item Is there an ISO or ANSI certified version of Perl? @@ -150,9 +368,10 @@ What does CPAN/src/... mean? =item Perl Books -References, Tutorials -*Learning Perl [2nd edition] -by Randal L. Schwartz and Tom Christiansen, Task-Oriented, Special Topics +References, Tutorials + *Learning Perl [2nd edition] + by Randal L. Schwartz and Tom Christiansen + with foreword by Larry Wall, Task-Oriented, Special Topics =item Perl in Magazines @@ -160,24 +379,20 @@ by Randal L. Schwartz and Tom Christiansen, Task-Oriented, Special Topics =item What mailing lists are there for perl? -MacPerl, Perl5-Porters, NTPerl, Perl-Packrats - =item Archives of comp.lang.perl.misc =item Where can I buy a commercial version of Perl? =item Where do I send bug reports? -=item What is perl.com? perl.org? The Perl Institute? - -=item How do I learn about object-oriented Perl programming? +=item What is perl.com? =back =item AUTHOR AND COPYRIGHT -=head2 perlfaq3 - Programming Tools ($Revision: 1.28 $, $Date: 1998/07/16 -22:08:49 $) +=head2 perlfaq3 - Programming Tools ($Revision: 1.38 $, $Date: 1999/05/23 +16:08:30 $) =item DESCRIPTION @@ -199,6 +414,8 @@ MacPerl, Perl5-Porters, NTPerl, Perl-Packrats =item Is there a ctags for Perl? +=item Is there an IDE or Windows Perl Editor? + =item Where can I get Perl macros for vi? =item Where can I get perl-mode for emacs? @@ -225,6 +442,8 @@ MacPerl, Perl5-Porters, NTPerl, Perl-Packrats =item How can I compile my Perl program into byte code or C? +=item How can I compile Perl into Java? + =item How can I get C<#!perl> to work on [MS-DOS,NT,...]? =item Can I write useful perl programs on the command line? @@ -249,8 +468,8 @@ mean? =item AUTHOR AND COPYRIGHT -=head2 perlfaq4 - Data Manipulation ($Revision: 1.25 $, $Date: 1998/07/16 -22:49:55 $) +=head2 perlfaq4 - Data Manipulation ($Revision: 1.49 $, $Date: 1999/05/23 +20:37:49 $) =item DESCRIPTION @@ -263,11 +482,13 @@ numbers I should be getting (eg, 19.95)? =item Why isn't my octal data interpreted correctly? -=item Does perl have a round function? What about ceil() and floor()? +=item Does Perl have a round() function? What about ceil() and floor()? Trig functions? =item How do I convert bits into ints? +=item Why doesn't & work the way I want it to? + =item How do I multiply matrices? =item How do I perform an operation on a series of integers? @@ -284,12 +505,16 @@ Trig functions? =item How do I find the week-of-the-year/day-of-the-year? +=item How do I find the current century or millennium? + =item How can I compare two dates and find the difference? =item How can I take a string and turn it into epoch seconds? =item How can I find the Julian Day? +=item How do I find yesterday's date? + =item Does Perl have a year 2000 problem? Is Perl Y2K compliant? =back @@ -328,6 +553,8 @@ string? =item How do I strip blank space from the beginning/end of a string? +=item How do I pad a string with blanks or pad a number with zeroes? + =item How do I extract selected columns from a string? =item How do I find the soundex value of a string? @@ -336,7 +563,7 @@ string? =item What's wrong with always quoting "$vars"? -=item Why don't my <<HERE documents work? +=item Why don't my E<lt>E<lt>HERE documents work? 1. There must be no space after the << part, 2. There (probably) should be a semicolon at the end, 3. You can't (easily) have any space in front of @@ -348,9 +575,11 @@ the tag =over +=item What is the difference between a list and an array? + =item What is the difference between $array[1] and @array[1]? -=item How can I extract just the unique elements of an array? +=item How can I remove duplicate elements from a list or array? a) If @in is sorted, and you want @out to be sorted:(this assumes all true values in the array), b) If you don't know whether @in is sorted:, c) Like @@ -363,6 +592,8 @@ integers: =item How do I compute the difference of two arrays? How do I compute the intersection of two arrays? +=item How do I test whether two arrays or hashes are equal? + =item How do I find the first array element for which a condition is true? =item How do I handle linked lists? @@ -440,12 +671,14 @@ array of hashes or arrays? =item How do I verify a credit card checksum? +=item How do I pack arrays of doubles or floats for XS code? + =back =item AUTHOR AND COPYRIGHT -=head2 perlfaq5 - Files and Formats ($Revision: 1.24 $, $Date: 1998/07/05 -15:07:20 $) +=head2 perlfaq5 - Files and Formats ($Revision: 1.38 $, $Date: 1999/05/23 +16:08:30 $) =item DESCRIPTION @@ -477,7 +710,8 @@ filehandles between subroutines? How do I make an array of filehandles? =item How come when I open a file read-write it wipes it out? -=item Why do I sometimes get an "Argument list too long" when I use <*>? +=item Why do I sometimes get an "Argument list too long" when I use +E<lt>*E<gt>? =item Is there a leak/bug in glob()? @@ -487,7 +721,7 @@ filehandles between subroutines? How do I make an array of filehandles? =item How can I lock a file? -=item What can't I just open(FH, ">file.lock")? +=item Why can't I just open(FH, ">file.lock")? =item I still don't get locking. I just want to increment the number in the file. How can I do this? @@ -500,11 +734,13 @@ the file. How can I do this? =item How do I print to more than one file at once? +=item How can I read in an entire file all at once? + =item How can I read in a file by paragraphs? =item How can I read a single character from a file? From the keyboard? -=item How can I tell if there's a character waiting on a filehandle? +=item How can I tell whether there's a character waiting on a filehandle? =item How do I do a C<tail -f> in perl? @@ -522,11 +758,13 @@ protected files? Isn't this a bug in Perl? =item How do I select a random line from a file? +=item Why do I get weird spaces when I print an array of lines? + =back =item AUTHOR AND COPYRIGHT -=head2 perlfaq6 - Regexps ($Revision: 1.22 $, $Date: 1998/07/16 14:01:07 $) +=head2 perlfaq6 - Regexes ($Revision: 1.27 $, $Date: 1999/05/23 16:08:30 $) =item DESCRIPTION @@ -535,8 +773,7 @@ protected files? Isn't this a bug in Perl? =item How can I hope to use regular expressions without creating illegible and unmaintainable code? -Comments Outside the Regexp, Comments Inside the Regexp, Different -Delimiters +Comments Outside the Regex, Comments Inside the Regex, Different Delimiters =item I'm having trouble matching over more than one line. What's wrong? @@ -552,7 +789,7 @@ case on the RHS? =item How can I match a locale-smart version of C</[a-zA-Z]/>? -=item How can I quote a variable to use in a regexp? +=item How can I quote a variable to use in a regex? =item What is C</o> really for? @@ -561,7 +798,7 @@ file? =item Can I use Perl regular expressions to match balanced text? -=item What does it mean that regexps are greedy? How can I get around it? +=item What does it mean that regexes are greedy? How can I get around it? =item How do I process each word on each line? @@ -577,18 +814,20 @@ file? =item What good is C<\G> in a regular expression? -=item Are Perl regexps DFAs or NFAs? Are they POSIX compliant? +=item Are Perl regexes DFAs or NFAs? Are they POSIX compliant? =item What's wrong with using grep or map in a void context? =item How can I match strings with multibyte characters? +=item How do I match a pattern that is supplied by the user? + =back =item AUTHOR AND COPYRIGHT -=head2 perlfaq7 - Perl Language Issues ($Revision: 1.21 $, $Date: -1998/06/22 15:20:07 $) +=head2 perlfaq7 - Perl Language Issues ($Revision: 1.28 $, $Date: +1999/05/23 20:36:18 $) =item DESCRIPTION @@ -596,7 +835,7 @@ file? =item Can I get a BNF/yacc/RE for the Perl language? -=item What are all these $@%* punctuation signs, and how do I know when to +=item What are all these $@%&* punctuation signs, and how do I know when to use them? =item Do I always/never have to quote my strings or use semicolons and @@ -623,14 +862,14 @@ commas? =item What is variable suicide and how can I prevent it? =item How can I pass/return a {Function, FileHandle, Array, Hash, Method, -Regexp}? +Regex}? -Passing Variables and Functions, Passing Filehandles, Passing Regexps, +Passing Variables and Functions, Passing Filehandles, Passing Regexes, Passing Methods =item How do I create a static variable? -=item What's the difference between dynamic and lexical (static) scoping? +=item What's the difference between dynamic and lexical (static) scoping? Between local() and my()? =item How can I access a dynamic variable while a similarly named lexical @@ -638,7 +877,7 @@ is in scope? =item What's the difference between deep and shallow binding? -=item Why doesn't "my($foo) = <FILE>;" work right? +=item Why doesn't "my($foo) = E<lt>FILEE<gt>;" work right? =item How do I redefine a builtin function, operator, or method? @@ -654,12 +893,16 @@ is in scope? =item How can I comment out a large block of perl code? +=item How do I clear a package? + +=item How can I use a variable as a variable name? + =back =item AUTHOR AND COPYRIGHT -=head2 perlfaq8 - System Interaction ($Revision: 1.25 $, $Date: 1998/07/05 -15:07:20 $) +=head2 perlfaq8 - System Interaction ($Revision: 1.39 $, $Date: 1999/05/23 +18:37:57 $) =item DESCRIPTION @@ -767,7 +1010,7 @@ complete? =item How do I open a file without blocking? -=item How do I install a CPAN module? +=item How do I install a module from CPAN? =item What's the difference between require and use? @@ -778,11 +1021,13 @@ search path? =item How do I add a directory to my include path at runtime? +=item What is socket.ph and where do I get it? + =back =item AUTHOR AND COPYRIGHT -=head2 perlfaq9 - Networking ($Revision: 1.20 $, $Date: 1998/06/22 18:31:09 +=head2 perlfaq9 - Networking ($Revision: 1.26 $, $Date: 1999/05/23 16:08:30 $) =item DESCRIPTION @@ -844,35 +1089,25 @@ CGI script to do bad things? =item AUTHOR AND COPYRIGHT -=head2 perldelta - what's new for perl5.005 +=head2 perldelta - what's new for perl5.006 (as of 5.005_56) =item DESCRIPTION -=item About the new versioning system - =item Incompatible Changes =over -=item WARNING: This version is not binary compatible with Perl 5.004. - -=item Default installation structure has changed +=item Perl Source Incompatibilities -=item Perl Source Compatibility +=item C Source Incompatibilities -=item C Source Compatibility +C<PERL_POLLUTE>, C<PERL_POLLUTE_MALLOC>, C<PL_na> and C<dTHR> Issues -Core sources now require ANSI C compiler, All Perl global variables must -now be referenced with an explicit prefix, Enabling threads has source -compatibility issues +=item Compatible C Source API Changes -=item Binary Compatibility +C<PATCHLEVEL> is now C<PERL_VERSION> -=item Security fixes may affect compatibility - -=item Relaxed new mandatory warnings introduced in 5.004 - -=item Licensing +=item Binary Incompatibilities =back @@ -880,105 +1115,55 @@ compatibility issues =over -=item Threads - -=item Compiler - -=item Regular Expressions - -Many new and improved optimizations, Many bug fixes, New regular expression -constructs, New operator for precompiled regular expressions, Other -improvements, Incompatible changes - -=item Improved malloc() +=item Unicode and UTF-8 support -=item Quicksort is internally implemented +=item Lexically scoped warning categories -=item Reliable signals +=item Binary numbers supported -=item Reliable stack pointers +=item syswrite() ease-of-use -=item More generous treatment of carriage returns +=item 64-bit support -=item Memory leaks +=item Better syntax checks on parenthesized unary operators -=item Better support for multiple interpreters +=item Improved C<qw//> operator -=item Behavior of local() on array and hash elements is now well-defined +=item pack() format 'Z' supported -=item C<%!> is transparently tied to the L<Errno> module +=item pack() format modifier '!' supported -=item Pseudo-hashes are supported +=item $^X variables may now have names longer than one character -=item C<EXPR foreach EXPR> is supported - -=item Keywords can be globally overridden - -=item C<$^E> is meaningful on Win32 - -=item C<foreach (1..1000000)> optimized - -=item C<Foo::> can be used as implicitly quoted package name - -=item C<exists $Foo::{Bar::}> tests existence of a package - -=item Better locale support - -=item Experimental support for 64-bit platforms - -=item prototype() returns useful results on builtins - -=item Extended support for exception handling - -=item Re-blessing in DESTROY() supported for chaining DESTROY() methods - -=item All C<printf> format conversions are handled internally - -=item New C<INIT> keyword - -=item New C<lock> keyword - -=item New C<qr//> operator - -=item C<our> is now a reserved word - -=item Tied arrays are now fully supported +=back -=item Tied handles support is better +=item Significant bug fixes -=item 4th argument to substr +=over -=item Negative LENGTH argument to splice +=item E<lt>HANDLEE<gt> on empty files -=item Magic lvalues are now more magical +=item C<eval '...'> improvements -=item E<lt>E<gt> now reads in records +=item Automatic flushing of output buffers =back =item Supported Platforms -=over - -=item New Platforms - -=item Changes in existing support - -=back +=item New tests =item Modules and Pragmata =over -=item New Modules - -B, Data::Dumper, Errno, File::Spec, ExtUtils::Installed, -ExtUtils::Packlist, Fatal, IPC::SysV, Test, Tie::Array, Tie::Handle, -Thread, attrs, fields, re +=item Modules -=item Changes in existing modules +Dumpvalue, Benchmark, Devel::Peek, Fcntl, File::Spec, +File::Spec::Functions, Math::BigInt, Math::Complex, Math::Trig, SDBM_File, +Time::Local, Win32, DBM Filters -CGI, POSIX, DB_File, MakeMaker, CPAN, Cwd, Benchmark +=item Pragmata =back @@ -986,30 +1171,16 @@ CGI, POSIX, DB_File, MakeMaker, CPAN, Cwd, Benchmark =item Documentation Changes +perlopentut.pod, perlreftut.pod, perltootc.pod + =item New Diagnostics -Ambiguous call resolved as CORE::%s(), qualify as such or use &, Bad index -while coercing array into hash, Bareword "%s" refers to nonexistent -package, Can't call method "%s" on an undefined value, Can't coerce array -into hash, Can't goto subroutine from an eval-string, Can't localize -pseudo-hash element, Can't use %%! because Errno.pm is not available, -Cannot find an opnumber for "%s", Character class syntax [. .] is reserved -for future extensions, Character class syntax [: :] is reserved for future -extensions, Character class syntax [= =] is reserved for future extensions, -%s: Eval-group in insecure regular expression, %s: Eval-group not allowed, -use re 'eval', %s: Eval-group not allowed at run time, Explicit blessing to -'' (assuming package main), Illegal hex digit ignored, No such array field, -No such field "%s" in variable %s of type %s, Out of memory during -ridiculously large request, Range iterator outside integer range, Recursive -inheritance detected while looking for method '%s' in package '%s', -Reference found where even-sized list expected, Undefined value assigned to -typeglob, Use of reserved word "%s" is deprecated, perl: warning: Setting -locale failed +/%s/: Unrecognized escape \\%c passed through, Unrecognized escape \\%c +passed through, Missing command in piped open =item Obsolete Diagnostics -Can't mktemp(), Can't write to temp file for B<-e>: %s, Cannot open -temporary file +=item Configuration Changes =item BUGS @@ -1033,10 +1204,14 @@ temporary file =item List value constructors +=item Slices + =item Typeglobs and Filehandles =back +=item SEE ALSO + =head2 perlsyn - Perl syntax =item DESCRIPTION @@ -1131,8 +1306,8 @@ unary &, unary *, (TYPE) ?PATTERN?, m/PATTERN/cgimosx, /PATTERN/cgimosx, q/STRING/, C<'STRING'>, qq/STRING/, "STRING", qr/STRING/imosx, qx/STRING/, `STRING`, qw/STRING/, -s/PATTERN/REPLACEMENT/egimosx, tr/SEARCHLIST/REPLACEMENTLIST/cds, -y/SEARCHLIST/REPLACEMENTLIST/cds +s/PATTERN/REPLACEMENT/egimosx, tr/SEARCHLIST/REPLACEMENTLIST/cdsUC, +y/SEARCHLIST/REPLACEMENTLIST/cdsUC =item Gory details of parsing quoted constructs @@ -1166,25 +1341,29 @@ i, m, s, x =item Regular Expressions -C<(?#text)>, C<(?:pattern)>, C<(?imsx-imsx:pattern)>, C<(?=pattern)>, -C<(?!pattern)>, C<(?E<lt>=pattern)>, C<(?<!pattern)>, C<(?{ code })>, -C<(?E<gt>pattern)>, C<(?(condition)yes-pattern|no-pattern)>, -C<(?(condition)yes-pattern)>, C<(?imsx-imsx)> +=item Extended Patterns + +C<(?#text)>, C<(?imsx-imsx)>, C<(?:pattern)>, C<(?imsx-imsx:pattern)>, +C<(?=pattern)>, C<(?!pattern)>, C<(?E<lt>=pattern)>, C<(?<!pattern)>, C<(?{ +code })>, C<(?p{ code })>, C<(?E<gt>pattern)>, +C<(?(condition)yes-pattern|no-pattern)>, C<(?(condition)yes-pattern)> =item Backtracking =item Version 8 Regular Expressions -=item WARNING on \1 vs $1 +=item Warning on \1 vs $1 =item Repeated patterns matching zero-length substring =item Creating custom RE engines -=item SEE ALSO - =back +=item BUGS + +=item SEE ALSO + =head2 perlrun - how to execute the Perl interpreter =item SYNOPSIS @@ -1195,11 +1374,11 @@ C<(?(condition)yes-pattern)>, C<(?imsx-imsx)> =item #! and quoting on non-Unix systems -OS/2, MS-DOS, Win95/NT, Macintosh +OS/2, MS-DOS, Win95/NT, Macintosh, VMS =item Location of Perl -=item Switches +=item Command Switches B<-0>[I<digits>], B<-a>, B<-c>, B<-d>, B<-d:>I<foo>, B<-D>I<letters>, B<-D>I<number>, B<-e> I<commandline>, B<-F>I<pattern>, B<-h>, @@ -1213,7 +1392,7 @@ B<-T>, B<-u>, B<-U>, B<-v>, B<-V>, B<-V:>I<name>, B<-w>, B<-x> I<directory> =item ENVIRONMENT HOME, LOGDIR, PATH, PERL5LIB, PERL5OPT, PERLLIB, PERL5DB, PERL5SHELL -(specific to WIN32 port), PERL_DEBUG_MSTATS, PERL_DESTRUCT_LEVEL +(specific to the Win32 port), PERL_DEBUG_MSTATS, PERL_DESTRUCT_LEVEL =head2 perlfunc - Perl builtin functions @@ -1235,6 +1414,8 @@ communication functions, Fetching user and group info, Fetching network info, Time-related functions, Functions new in perl5, Functions obsoleted in perl5 +=item Portability + =item Alphabetical Listing of Perl Functions I<-X> FILEHANDLE, I<-X> EXPR, I<-X>, abs VALUE, abs, accept @@ -1244,10 +1425,10 @@ chdir EXPR, chmod LIST, chomp VARIABLE, chomp LIST, chomp, chop VARIABLE, chop LIST, chop, chown LIST, chr NUMBER, chr, chroot FILENAME, chroot, close FILEHANDLE, close, closedir DIRHANDLE, connect SOCKET,NAME, continue BLOCK, cos EXPR, crypt PLAINTEXT,SALT, dbmclose HASH, dbmopen -HASH,DBNAME,MODE, defined EXPR, defined, delete EXPR, die LIST, do BLOCK, -do SUBROUTINE(LIST), do EXPR, dump LABEL, each HASH, eof FILEHANDLE, eof -(), eof, eval EXPR, eval BLOCK, exec LIST, exec PROGRAM LIST, exists EXPR, -exit EXPR, exp EXPR, exp, fcntl FILEHANDLE,FUNCTION,SCALAR, fileno +HASH,DBNAME,MASK, defined EXPR, defined, delete EXPR, die LIST, do BLOCK, +do SUBROUTINE(LIST), do EXPR, dump LABEL, dump, each HASH, eof FILEHANDLE, +eof (), eof, eval EXPR, eval BLOCK, exec LIST, exec PROGRAM LIST, exists +EXPR, exit EXPR, exp EXPR, exp, fcntl FILEHANDLE,FUNCTION,SCALAR, fileno FILEHANDLE, flock FILEHANDLE,OPERATION, fork, format, formline PICTURE,LIST, getc FILEHANDLE, getc, getlogin, getpeername SOCKET, getpgrp PID, getppid, getpriority WHICH,WHO, getpwnam NAME, getgrnam NAME, @@ -1263,19 +1444,19 @@ goto &NAME, grep BLOCK LIST, grep EXPR,LIST, hex EXPR, hex, import, index STR,SUBSTR,POSITION, index STR,SUBSTR, int EXPR, int, ioctl FILEHANDLE,FUNCTION,SCALAR, join EXPR,LIST, keys HASH, kill LIST, last LABEL, last, lc EXPR, lc, lcfirst EXPR, lcfirst, length EXPR, length, link -OLDFILE,NEWFILE, listen SOCKET,QUEUESIZE, local EXPR, localtime EXPR, log -EXPR, log, lstat FILEHANDLE, lstat EXPR, lstat, m//, map BLOCK LIST, map -EXPR,LIST, mkdir FILENAME,MODE, msgctl ID,CMD,ARG, msgget KEY,FLAGS, msgsnd -ID,MSG,FLAGS, msgrcv ID,VAR,SIZE,TYPE,FLAGS, my EXPR, next LABEL, next, no -Module LIST, oct EXPR, oct, open FILEHANDLE,EXPR, open FILEHANDLE, opendir -DIRHANDLE,EXPR, ord EXPR, ord, pack TEMPLATE,LIST, package, package +OLDFILE,NEWFILE, listen SOCKET,QUEUESIZE, local EXPR, localtime EXPR, lock, +log EXPR, log, lstat FILEHANDLE, lstat EXPR, lstat, m//, map BLOCK LIST, +map EXPR,LIST, mkdir FILENAME,MASK, msgctl ID,CMD,ARG, msgget KEY,FLAGS, +msgsnd ID,MSG,FLAGS, msgrcv ID,VAR,SIZE,TYPE,FLAGS, my EXPR, next LABEL, +next, no Module LIST, oct EXPR, oct, open FILEHANDLE,EXPR, open FILEHANDLE, +opendir DIRHANDLE,EXPR, ord EXPR, ord, pack TEMPLATE,LIST, package, package NAMESPACE, pipe READHANDLE,WRITEHANDLE, pop ARRAY, pop, pos SCALAR, pos, print FILEHANDLE LIST, print LIST, print, printf FILEHANDLE FORMAT, LIST, printf FORMAT, LIST, prototype FUNCTION, push ARRAY,LIST, q/STRING/, qq/STRING/, qr/STRING/, qx/STRING/, qw/STRING/, quotemeta EXPR, quotemeta, rand EXPR, rand, read FILEHANDLE,SCALAR,LENGTH,OFFSET, read FILEHANDLE,SCALAR,LENGTH, readdir DIRHANDLE, readline EXPR, readlink EXPR, -readlink, readpipe EXPR, recv SOCKET,SCALAR,LEN,FLAGS, redo LABEL, redo, +readlink, readpipe EXPR, recv SOCKET,SCALAR,LENGTH,FLAGS, redo LABEL, redo, ref EXPR, ref, rename OLDNAME,NEWNAME, require EXPR, require, reset EXPR, reset, return EXPR, return, reverse LIST, rewinddir DIRHANDLE, rindex STR,SUBSTR,POSITION, rindex STR,SUBSTR, rmdir FILENAME, rmdir, s///, scalar @@ -1298,14 +1479,14 @@ sysopen FILEHANDLE,FILENAME,MODE, sysopen FILEHANDLE,FILENAME,MODE,PERMS, sysread FILEHANDLE,SCALAR,LENGTH,OFFSET, sysread FILEHANDLE,SCALAR,LENGTH, sysseek FILEHANDLE,POSITION,WHENCE, system LIST, system PROGRAM LIST, syswrite FILEHANDLE,SCALAR,LENGTH,OFFSET, syswrite -FILEHANDLE,SCALAR,LENGTH, tell FILEHANDLE, tell, telldir DIRHANDLE, tie -VARIABLE,CLASSNAME,LIST, tied VARIABLE, time, times, tr///, truncate -FILEHANDLE,LENGTH, truncate EXPR,LENGTH, uc EXPR, uc, ucfirst EXPR, -ucfirst, umask EXPR, umask, undef EXPR, undef, unlink LIST, unlink, unpack -TEMPLATE,EXPR, untie VARIABLE, unshift ARRAY,LIST, use Module LIST, use -Module, use Module VERSION LIST, use VERSION, utime LIST, values HASH, vec -EXPR,OFFSET,BITS, wait, waitpid PID,FLAGS, wantarray, warn LIST, write -FILEHANDLE, write EXPR, write, y/// +FILEHANDLE,SCALAR,LENGTH, syswrite FILEHANDLE,SCALAR, tell FILEHANDLE, +tell, telldir DIRHANDLE, tie VARIABLE,CLASSNAME,LIST, tied VARIABLE, time, +times, tr///, truncate FILEHANDLE,LENGTH, truncate EXPR,LENGTH, uc EXPR, +uc, ucfirst EXPR, ucfirst, umask EXPR, umask, undef EXPR, undef, unlink +LIST, unlink, unpack TEMPLATE,EXPR, untie VARIABLE, unshift ARRAY,LIST, use +Module LIST, use Module, use Module VERSION LIST, use VERSION, utime LIST, +values HASH, vec EXPR,OFFSET,BITS, wait, waitpid PID,FLAGS, wantarray, warn +LIST, write FILEHANDLE, write EXPR, write, y/// =back @@ -1318,31 +1499,36 @@ FILEHANDLE, write EXPR, write, y/// =item Predefined Names $ARG, $_, $E<lt>I<digits>E<gt>, $MATCH, $&, $PREMATCH, $`, $POSTMATCH, $', -$LAST_PAREN_MATCH, $+, $MULTILINE_MATCHING, $*, input_line_number HANDLE -EXPR, $INPUT_LINE_NUMBER, $NR, $, input_record_separator HANDLE EXPR, -$INPUT_RECORD_SEPARATOR, $RS, $/, autoflush HANDLE EXPR, $OUTPUT_AUTOFLUSH, -$|, output_field_separator HANDLE EXPR, $OUTPUT_FIELD_SEPARATOR, $OFS, $,, -output_record_separator HANDLE EXPR, $OUTPUT_RECORD_SEPARATOR, $ORS, $\, -$LIST_SEPARATOR, $", $SUBSCRIPT_SEPARATOR, $SUBSEP, $;, $OFMT, $#, -format_page_number HANDLE EXPR, $FORMAT_PAGE_NUMBER, $%, -format_lines_per_page HANDLE EXPR, $FORMAT_LINES_PER_PAGE, $=, -format_lines_left HANDLE EXPR, $FORMAT_LINES_LEFT, $-, format_name HANDLE -EXPR, $FORMAT_NAME, $~, format_top_name HANDLE EXPR, $FORMAT_TOP_NAME, $^, +$LAST_PAREN_MATCH, $+, @+, $MULTILINE_MATCHING, $*, input_line_number +HANDLE EXPR, $INPUT_LINE_NUMBER, $NR, $, input_record_separator HANDLE +EXPR, $INPUT_RECORD_SEPARATOR, $RS, $/, autoflush HANDLE EXPR, +$OUTPUT_AUTOFLUSH, $|, output_field_separator HANDLE EXPR, +$OUTPUT_FIELD_SEPARATOR, $OFS, $,, output_record_separator HANDLE EXPR, +$OUTPUT_RECORD_SEPARATOR, $ORS, $\, $LIST_SEPARATOR, $", +$SUBSCRIPT_SEPARATOR, $SUBSEP, $;, $OFMT, $#, format_page_number HANDLE +EXPR, $FORMAT_PAGE_NUMBER, $%, format_lines_per_page HANDLE EXPR, +$FORMAT_LINES_PER_PAGE, $=, format_lines_left HANDLE EXPR, +$FORMAT_LINES_LEFT, $-, @-, format_name HANDLE EXPR, $FORMAT_NAME, $~, +format_top_name HANDLE EXPR, $FORMAT_TOP_NAME, $^, format_line_break_characters HANDLE EXPR, $FORMAT_LINE_BREAK_CHARACTERS, $:, format_formfeed HANDLE EXPR, $FORMAT_FORMFEED, $^L, $ACCUMULATOR, $^A, $CHILD_ERROR, $?, $OS_ERROR, $ERRNO, $!, $EXTENDED_OS_ERROR, $^E, $EVAL_ERROR, $@, $PROCESS_ID, $PID, $$, $REAL_USER_ID, $UID, $<, $EFFECTIVE_USER_ID, $EUID, $>, $REAL_GROUP_ID, $GID, $(, $EFFECTIVE_GROUP_ID, $EGID, $), $PROGRAM_NAME, $0, $[, $PERL_VERSION, $], -$DEBUGGING, $^D, $SYSTEM_FD_MAX, $^F, $^H, $INPLACE_EDIT, $^I, $^M, -$OSNAME, $^O, $PERLDB, $^P, 0x01, 0x02, 0x04, 0x08, 0x10, 0x20, $^R, $^S, -$BASETIME, $^T, $WARNING, $^W, $EXECUTABLE_NAME, $^X, $ARGV, @ARGV, @INC, -@_, %INC, %ENV $ENV{expr}, %SIG $SIG{expr} +$COMPILING, $^C, $DEBUGGING, $^D, $SYSTEM_FD_MAX, $^F, $^H, $INPLACE_EDIT, +$^I, $^M, $OSNAME, $^O, $PERLDB, $^P, 0x01, 0x02, 0x04, 0x08, 0x10, 0x20, +$^R, $^S, $BASETIME, $^T, $WARNING, $^W, $EXECUTABLE_NAME, $^X, $ARGV, +@ARGV, @INC, @_, %INC, %ENV, $ENV{expr}, %SIG, $SIG{expr} =item Error Indicators +=item Technical Note on the Syntax of Variable Names + =back +=item BUGS + =head2 perlsub - Perl subroutines =item SYNOPSIS @@ -1351,7 +1537,7 @@ $BASETIME, $^T, $WARNING, $^W, $EXECUTABLE_NAME, $^X, $ARGV, @ARGV, @INC, =over -=item Private Variables via C<my()> +=item Private Variables via my() =item Persistent Private Variables @@ -1361,9 +1547,9 @@ $BASETIME, $^T, $WARNING, $^W, $EXECUTABLE_NAME, $^X, $ARGV, @ARGV, @INC, =item When to Still Use local() -1. You need to give a global variable a temporary value, especially C<$_>, -2. You need to create a local file or directory handle or a local function, -3. You want to temporarily change just one element of an array or hash +1. You need to give a global variable a temporary value, especially $_, 2. +You need to create a local file or directory handle or a local function, 3. +You want to temporarily change just one element of an array or hash =item Pass by Reference @@ -1371,7 +1557,7 @@ $BASETIME, $^T, $WARNING, $^W, $EXECUTABLE_NAME, $^X, $ARGV, @ARGV, @INC, =item Constant Functions -=item Overriding Builtin Functions +=item Overriding Built-in Functions =item Autoloading @@ -1409,29 +1595,42 @@ $BASETIME, $^T, $WARNING, $^W, $EXECUTABLE_NAME, $^X, $ARGV, @ARGV, @INC, =item Pragmatic Modules -use autouse MODULE => qw(sub1 sub2 sub3), blib, diagnostics, integer, less, -lib, locale, ops, overload, re, sigtrap, strict, subs, vmsish, vars +attrs, autouse, base, blib, constant, diagnostics, fields, filetest, +integer, less, lib, locale, ops, overload, re, sigtrap, strict, subs, utf8, +vars, vmsish, warning =item Standard Modules -AnyDBM_File, AutoLoader, AutoSplit, Benchmark, CPAN, CPAN::FirstTime, -CPAN::Nox, Carp, Class::Struct, Config, Cwd, DB_File, Devel::SelfStubber, -DirHandle, DynaLoader, English, Env, Exporter, ExtUtils::Embed, -ExtUtils::Install, ExtUtils::Liblist, ExtUtils::MM_OS2, ExtUtils::MM_Unix, -ExtUtils::MM_VMS, ExtUtils::MakeMaker, ExtUtils::Manifest, -ExtUtils::Mkbootstrap, ExtUtils::Mksymlists, ExtUtils::testlib, Fatal, -Fcntl, File::Basename, File::CheckTree, File::Compare, File::Copy, -File::Find, File::Path, File::stat, FileCache, FileHandle, FindBin, -GDBM_File, Getopt::Long, Getopt::Std, I18N::Collate, IO, IO::File, -IO::Handle, IO::Pipe, IO::Seekable, IO::Select, IO::Socket, IPC::Open2, -IPC::Open3, Math::BigFloat, Math::BigInt, Math::Complex, Math::Trig, -NDBM_File, Net::Ping, Net::hostent, Net::netent, Net::protoent, -Net::servent, Opcode, Pod::Text, POSIX, SDBM_File, Safe, Search::Dict, -SelectSaver, SelfLoader, Shell, Socket, Symbol, Sys::Hostname, Sys::Syslog, -Term::Cap, Term::Complete, Term::ReadLine, Test::Harness, Text::Abbrev, -Text::ParseWords, Text::Soundex, Text::Tabs, Text::Wrap, Tie::Hash, -Tie::RefHash, Tie::Scalar, Tie::SubstrHash, Time::Local, Time::gmtime, -Time::localtime, Time::tm, UNIVERSAL, User::grent, User::pwent +AnyDBM_File, AutoLoader, AutoSplit, B, B::Asmdata, B::Assembler, B::Bblock, +B::Bytecode, B::C, B::CC, B::Debug, B::Deparse, B::Disassembler, B::Lint, +B::Showlex, B::Stackobj, B::Terse, B::Xref, Benchmark, CGI, CGI::Apache, +CGI::Carp, CGI::Cookie, CGI::Fast, CGI::Push, CGI::Switch, CPAN, +CPAN::FirstTime, CPAN::Nox, Carp, Class::Struct, Config, Cwd, DB, DB_File, +Data::Dumper, Devel::Peek, Devel::SelfStubber, DirHandle, Dumpvalue, +DynaLoader, English, Env, Errno, Exporter, ExtUtils::Command, +ExtUtils::Embed, ExtUtils::Install, ExtUtils::Installed, ExtUtils::Liblist, +ExtUtils::MM_OS2, ExtUtils::MM_Unix, ExtUtils::MM_VMS, ExtUtils::MM_Win32, +ExtUtils::MakeMaker, ExtUtils::Manifest, ExtUtils::Miniperl, +ExtUtils::Mkbootstrap, ExtUtils::Mksymlists, ExtUtils::Packlist, +ExtUtils::testlib, Fatal, Fcntl, File::Basename, File::Compare, File::Copy, +File::DosGlob, File::Find, File::Path, File::Spec, File::Spec::Functions, +File::Spec::Mac, File::Spec::OS2, File::Spec::Unix, File::Spec::VMS, +File::Spec::Win32, File::stat, FileCache, FileHandle, FindBin, GDBM_File, +Getopt::Long, Getopt::Std, I18N::Collate, IO, IO::Dir, IO::File, +IO::Handle, IO::Pipe, IO::Poll, IO::Seekable, IO::Select, IO::Socket, +IO::Socket::INET, IO::Socket::UNIX, IPC::Msg, IPC::Open2, IPC::Open3, +IPC::Semaphore, IPC::SysV, Math::BigFloat, Math::BigInt, Math::Complex, +Math::Trig, NDBM_File, Net::Ping, Net::hostent, Net::netent, Net::protoent, +Net::servent, O, Opcode, POSIX, Pod::Html, Pod::Text, SDBM_File, Safe, +Search::Dict, SelectSaver, SelfLoader, Shell, Socket, Symbol, +Sys::Hostname, Sys::Syslog, Term::Cap, Term::Complete, Term::ReadLine, +Test, Test::Harness, Text::Abbrev, Text::ParseWords, Text::Soundex, +Text::Tabs -- expand and unexpand tabs per the unix expand(1) and +unexpand(1), Text::Wrap, Thread, Thread::Queue, Thread::Semaphore, +Thread::Signal, Thread::Specific, Tie::Array, Tie::Handle, Tie::Hash, +Tie::StdHash, Tie::RefHash, Tie::Scalar, Tie::StdScalar, Tie::SubstrHash, +Time::Local, Time::gmtime, Time::localtime, Time::tm, UNIVERSAL, +User::grent, User::pwent =item Extension Modules @@ -1557,7 +1756,7 @@ localization) =item Permanently fixing your locale configuration -=item Permanently fixing system locale configuration +=item Fixing system locale configuration =item The localeconv function @@ -1596,8 +1795,8 @@ isxdigit()): =item ENVIRONMENT -PERL_BADLANG, LC_ALL, LC_CTYPE, LC_COLLATE, LC_MONETARY, LC_NUMERIC, -LC_TIME, LANG +PERL_BADLANG, LC_ALL, LANGUAGE, LC_CTYPE, LC_COLLATE, LC_MONETARY, +LC_NUMERIC, LC_TIME, LANG =item NOTES @@ -1633,6 +1832,8 @@ LC_TIME, LANG =head2 perlref - Perl references and nested data structures +=item NOTE + =item DESCRIPTION =over @@ -1655,6 +1856,42 @@ LC_TIME, LANG =item SEE ALSO +=head2 perlreftut - Mark's very short tutorial about references + +=item DESCRIPTION + +=item Who Needs Complicated Data Structures? + +=item The Solution + +=item Syntax + +=over + +=item Making References + +=item Using References + +=back + +=item An Example + +=item Arrow Rule + +=item Solution + +=item The Rest + +=item Summary + +=item Credits + +=over + +=item Distribution Conditions + +=back + =head2 perldsc - Perl Data Structures Cookbook =item DESCRIPTION @@ -1674,39 +1911,39 @@ more elaborate constructs =item CODE EXAMPLES -=item LISTS OF LISTS +=item ARRAYS OF ARRAYS =over -=item Declaration of a LIST OF LISTS +=item Declaration of a ARRAY OF ARRAYS -=item Generation of a LIST OF LISTS +=item Generation of a ARRAY OF ARRAYS -=item Access and Printing of a LIST OF LISTS +=item Access and Printing of a ARRAY OF ARRAYS =back -=item HASHES OF LISTS +=item HASHES OF ARRAYS =over -=item Declaration of a HASH OF LISTS +=item Declaration of a HASH OF ARRAYS -=item Generation of a HASH OF LISTS +=item Generation of a HASH OF ARRAYS -=item Access and Printing of a HASH OF LISTS +=item Access and Printing of a HASH OF ARRAYS =back -=item LISTS OF HASHES +=item ARRAYS OF HASHES =over -=item Declaration of a LIST OF HASHES +=item Declaration of a ARRAY OF HASHES -=item Generation of a LIST OF HASHES +=item Generation of a ARRAY OF HASHES -=item Access and Printing of a LIST OF HASHES +=item Access and Printing of a ARRAY OF HASHES =back @@ -1740,11 +1977,11 @@ more elaborate constructs =item AUTHOR -=head2 perllol, perlLoL - Manipulating Lists of Lists in Perl +=head2 perllol - Manipulating Arrays of Arrays in Perl =item DESCRIPTION -=item Declaration and Access of Lists of Lists +=item Declaration and Access of Arrays of Arrays =item Growing Your Own @@ -1852,6 +2089,54 @@ more elaborate constructs =back +=head2 perltootc - Tom's OO Tutorial for Class Data in Perl + +=item DESCRIPTION + +=item Class Data as Package Variables + +=over + +=item Putting All Your Eggs in One Basket + +=item Inheritance Concerns + +=item The Eponymous Meta-Object + +=item Indirect References to Class Data + +=item Monadic Classes + +=item Translucent Attributes + +=back + +=item Class Data as Lexical Variables + +=over + +=item Privacy and Responsibility + +=item File-Scoped Lexicals + +=item More Inheritance Concerns + +=item Locking the Door and Throwing Away the Key + +=item Translucency Revisited + +=back + +=item NOTES + +=item SEE ALSO + +=item AUTHOR AND COPYRIGHT + +=item ACKNOWLEDGEMENTS + +=item HISTORY + =head2 perlobj - Perl objects =item DESCRIPTION @@ -1866,14 +2151,14 @@ more elaborate constructs =item Method Invocation +=item WARNING + =item Default UNIVERSAL methods isa(CLASS), can(METHOD), VERSION( [NEED] ) =item Destructors -=item WARNING - =item Summary =item Two-Phased Garbage Collection @@ -2021,6 +2306,29 @@ Proto, LocalPort, Listen, Reuse =item SEE ALSO +=head2 perldbmfilter - Perl DBM Filters + +=item SYNOPSIS + +=item DESCRIPTION + +B<filter_store_key>, B<filter_store_value>, B<filter_fetch_key>, +B<filter_fetch_value> + +=over + +=item The Filter + +=item An Example -- the NULL termination problem. + +=item Another Example -- Key is a C int. + +=back + +=item SEE ALSO + +=item AUTHOR + =head2 perldebug - Perl debugging =item DESCRIPTION @@ -2219,7 +2527,7 @@ LIMIT specified =item DESCRIPTION -Not all Perl programs have to be portable, The vast majority of Perl B<is> +Not all Perl programs have to be portable, The vast majority of Perl I<is> portable =item ISSUES @@ -2228,7 +2536,9 @@ portable =item Newlines -=item File Paths +=item Numbers endianness and Width + +=item Files and Filesystems =item System Interaction @@ -2240,6 +2550,10 @@ portable =item Time and Date +=item Character sets and character encoding + +=item Internationalisation + =item System Resources =item Security @@ -2248,10 +2562,10 @@ portable =back -=item CPAN TESTERS +=item CPAN Testers Mailing list: cpan-testers@perl.org, Testing results: -C<http://www.connect.net/gbarr/cpan-test/> +C<http://www.perl.org/cpan-testers/> =item PLATFORMS @@ -2263,29 +2577,38 @@ C<http://www.connect.net/gbarr/cpan-test/> The djgpp environment for DOS, C<http://www.delorie.com/djgpp/>, The EMX environment for DOS, OS/2, etc. -C<emx@iaehv.nl>,C<http://www.leo.org/pub/comp/os/os2/leo/gnu/emx+gcc/index.html>, -C<ftp://hobbes.nmsu.edu/pub/os2/dev/emx>. Build instructions -for Win32, L<perlwin32>, The ActiveState Pages, -C<http://www.activestate.com/> +C<emx@iaehv.nl>,C<http://www.leo.org/pub/comp/os/os2/leo/gnu/emx+gcc/index. +html> or +C<ftp://hobbes.nmsu.edu/pub/os2/dev/emx>, Build instructions for Win32, +L<perlwin32>, The ActiveState Pages, C<http://www.activestate.com/> -=item MacPerl +=item S<Mac OS> -The MacPerl Pages, C<http://www.ptf.com/macperl/>, The MacPerl mailing -list, C<mac-perl-request@iis.ee.ethz.ch> +The MacPerl Pages, C<http://www.macperl.com/>, The MacPerl mailing lists, +C<http://www.macperl.org/>, MacPerl Module Porters, +C<http://pudge.net/mmp/> =item VMS -L<perlvms.pod>, vmsperl list, C<vmsperl-request@newman.upenn.edu>, vmsperl -on the web, C<http://www.sidhe.org/vmsperl/index.html> +L<perlvms.pod>, vmsperl list, C<majordomo@perl.org>, vmsperl on the web, +C<http://www.sidhe.org/vmsperl/index.html> + +=item VOS + +L<README.vos>, VOS mailing list, VOS Perl on the web at +C<http://ftp.stratus.com/pub/vos/vos.html> =item EBCDIC Platforms -perl-mvs list, AS/400 Perl information at C<http://as400.rochester.ibm.com> +perl-mvs list, AS/400 Perl information at +C<http://as400.rochester.ibm.com/> + +=item Acorn RISC OS =item Other perls Atari, Guido Flohr's page C<http://stud.uni-sb.de/~gufl0000/>, HP 300 -MPE/iX C<http://www.cccd.edu/~markb/perlix.html>, Novell Netware +MPE/iX C<http://www.cccd.edu/~markb/perlix.html>, Novell Netware =back @@ -2315,12 +2638,22 @@ KEY,NSEMS,FLAGS, semop KEY,OPSTRING, setpgrp PID,PGRP, setpriority WHICH,WHO,PRIORITY, setsockopt SOCKET,LEVEL,OPTNAME,OPTVAL, shmctl ID,CMD,ARG, shmget KEY,SIZE,FLAGS, shmread ID,VAR,POS,SIZE, shmwrite ID,STRING,POS,SIZE, socketpair SOCKET1,SOCKET2,DOMAIN,TYPE,PROTOCOL, stat -FILEHANDLE, stat EXPR, stat, symlink OLDFILE,NEWFILE, syscall LIST, system -LIST, times, truncate FILEHANDLE,LENGTH, truncate EXPR,LENGTH, umask EXPR, -umask, utime LIST, wait, waitpid PID,FLAGS +FILEHANDLE, stat EXPR, stat, symlink OLDFILE,NEWFILE, syscall LIST, sysopen +FILEHANDLE,FILENAME,MODE,PERMS, system LIST, times, truncate +FILEHANDLE,LENGTH, truncate EXPR,LENGTH, umask EXPR, umask, utime LIST, +wait, waitpid PID,FLAGS =back +=item CHANGES + +v1.42, 22 May 1999Added notes about tests, sprintf/printf, and epoch +offsets. +=item v1.41, 19 May 1999, v1.40, 11 April 1999, v1.39, 11 February 1999, +v1.38, 31 December 1998, v1.37, 19 December 1998, v1.36, 9 September 1998, +v1.35, 13 August 1998, v1.33, 06 August 1998, v1.32, 05 August 1998, v1.30, +03 August 1998, v1.23, 10 July 1998 + =item AUTHORS / CONTRIBUTORS =item VERSION @@ -2675,17 +3008,16 @@ dXSARGS, dXSI32, do_binmode, ENTER, EXTEND, fbm_compile, fbm_instr, FREETMPS, G_ARRAY, G_DISCARD, G_EVAL, GIMME, GIMME_V, G_NOARGS, G_SCALAR, gv_fetchmeth, gv_fetchmethod, gv_fetchmethod_autoload, G_VOID, gv_stashpv, gv_stashsv, GvSV, HEf_SVKEY, HeHASH, HeKEY, HeKLEN, HePV, HeSVKEY, -HeSVKEY_force, HeSVKEY_set, HeVAL, hv_clear, hv_delayfree_ent, hv_delete, -hv_delete_ent, hv_exists, hv_exists_ent, hv_fetch, hv_fetch_ent, -hv_free_ent, hv_iterinit, hv_iterkey, hv_iterkeysv, hv_iternext, -hv_iternextsv, hv_iterval, hv_magic, HvNAME, hv_store, hv_store_ent, -hv_undef, isALNUM, isALPHA, isDIGIT, isLOWER, isSPACE, isUPPER, items, ix, -LEAVE, looks_like_number, MARK, mg_clear, mg_copy, mg_find, mg_free, -mg_get, mg_len, mg_magical, mg_set, Move, PL_na, New, newAV, Newc, -newCONSTSUB, newHV, newRV_inc, newRV_noinc, NEWSV, newSViv, newSVnv, -newSVpv, newSVpvf, newSVpvn, newSVrv, newSVsv, newXS, newXSproto, Newz, -Nullav, Nullch, Nullcv, Nullhv, Nullsv, ORIGMARK, perl_alloc, -perl_call_argv, perl_call_method, perl_call_pv, perl_call_sv, +HeSVKEY_force, HeSVKEY_set, HeVAL, hv_clear, hv_delete, hv_delete_ent, +hv_exists, hv_exists_ent, hv_fetch, hv_fetch_ent, hv_iterinit, hv_iterkey, +hv_iterkeysv, hv_iternext, hv_iternextsv, hv_iterval, hv_magic, HvNAME, +hv_store, hv_store_ent, hv_undef, isALNUM, isALPHA, isDIGIT, isLOWER, +isSPACE, isUPPER, items, ix, LEAVE, looks_like_number, MARK, mg_clear, +mg_copy, mg_find, mg_free, mg_get, mg_len, mg_magical, mg_set, modglobal, +Move, PL_na, New, newAV, Newc, newCONSTSUB, newHV, newRV_inc, newRV_noinc, +NEWSV, newSViv, newSVnv, newSVpv, newSVpvf, newSVpvn, newSVrv, newSVsv, +newXS, newXSproto, Newz, Nullav, Nullch, Nullcv, Nullhv, Nullsv, ORIGMARK, +perl_alloc, perl_call_argv, perl_call_method, perl_call_pv, perl_call_sv, perl_construct, perl_destruct, perl_eval_sv, perl_eval_pv, perl_free, perl_get_av, perl_get_cv, perl_get_hv, perl_get_sv, perl_parse, perl_require_pv, perl_run, POPi, POPl, POPp, POPn, POPs, PUSHMARK, PUSHi, @@ -2694,15 +3026,15 @@ safemalloc, saferealloc, savepv, savepvn, SAVETMPS, SP, SPAGAIN, ST, strEQ, strGE, strGT, strLE, strLT, strNE, strnEQ, strnNE, sv_2mortal, sv_bless, sv_catpv, sv_catpv_mg, sv_catpvn, sv_catpvn_mg, sv_catpvf, sv_catpvf_mg, sv_catsv, sv_catsv_mg, sv_chop, sv_cmp, SvCUR, SvCUR_set, sv_dec, -sv_derived_from, sv_derived_from, SvEND, sv_eq, SvGETMAGIC, SvGROW, -sv_grow, sv_inc, sv_insert, SvIOK, SvIOK_off, SvIOK_on, SvIOK_only, SvIOKp, -sv_isa, sv_isobject, SvIV, SvIVX, SvLEN, sv_len, sv_magic, sv_mortalcopy, +sv_derived_from, SvEND, sv_eq, SvGETMAGIC, SvGROW, sv_grow, sv_inc, +sv_insert, SvIOK, SvIOK_off, SvIOK_on, SvIOK_only, SvIOKp, sv_isa, +sv_isobject, SvIV, SvIVX, SvLEN, sv_len, sv_magic, sv_mortalcopy, sv_newmortal, SvNIOK, SvNIOK_off, SvNIOKp, PL_sv_no, SvNOK, SvNOK_off, SvNOK_on, SvNOK_only, SvNOKp, SvNV, SvNVX, SvOK, SvOOK, SvPOK, SvPOK_off, -SvPOK_on, SvPOK_only, SvPOKp, SvPV, SvPV_force, SvPVX, SvREFCNT, -SvREFCNT_dec, SvREFCNT_inc, SvROK, SvROK_off, SvROK_on, SvRV, SvSETMAGIC, -sv_setiv, sv_setiv_mg, sv_setnv, sv_setnv_mg, sv_setpv, sv_setpv_mg, -sv_setpviv, sv_setpviv_mg, sv_setpvn, sv_setpvn_mg, sv_setpvf, +SvPOK_on, SvPOK_only, SvPOKp, SvPV, SvPV_force, SvPV_nolen, SvPVX, +SvREFCNT, SvREFCNT_dec, SvREFCNT_inc, SvROK, SvROK_off, SvROK_on, SvRV, +SvSETMAGIC, sv_setiv, sv_setiv_mg, sv_setnv, sv_setnv_mg, sv_setpv, +sv_setpv_mg, sv_setpviv, sv_setpviv_mg, sv_setpvn, sv_setpvn_mg, sv_setpvf, sv_setpvf_mg, sv_setref_iv, sv_setref_nv, sv_setref_pv, sv_setref_pvn, SvSetSV, SvSetSV_nosteal, sv_setsv, sv_setsv_mg, sv_setuv, sv_setuv_mg, SvSTASH, SvTAINT, SvTAINTED, SvTAINTED_off, SvTAINTED_on, SVt_IV, SVt_PV, @@ -2726,7 +3058,7 @@ An Error Handler, An Event Driven Program =item THE PERL_CALL FUNCTIONS -B<perl_call_sv>, B<perl_call_pv>, B<perl_call_method>, B<perl_call_argv> +perl_call_sv, perl_call_pv, perl_call_method, perl_call_argv =item FLAG VALUES @@ -2842,6 +3174,14 @@ method, locked =item DESCRIPTION +=head2 attrs - set/get attributes of a subroutine + +=item SYNOPSIS + +=item DESCRIPTION + +method, locked + =head2 autouse - postpone load of modules until a function is used =item SYNOPSIS @@ -2860,6 +3200,8 @@ method, locked =item DESCRIPTION +=item HISTORY + =item SEE ALSO =head2 blib - Use MakeMaker's uninstalled version of a package @@ -2919,6 +3261,25 @@ diagnostics =item SEE ALSO +=head2 filetest - Perl pragma to control the filetest permission operators + +=item SYNOPSIS + + $can_perhaps_read = -r "file"; # use the mode bits + { + use filetest 'access'; # intuit harder + $can_really_read = -r "file"; + } + $can_perhaps_read = -r "file"; # use the mode bits again + +=item DESCRIPTION + +=over + +=item subpragma access + +=back + =head2 integer - Perl pragma to compute arithmetic in integer instead of double @@ -2959,12 +3320,18 @@ operations =item DESCRIPTION +=head2 ops - Perl pragma to restrict unsafe operations when compiling + +=item SYNOPSIS + +=item DESCRIPTION + +=item SEE ALSO + =head2 overload - Package for overloading perl operations =item SYNOPSIS -=item CAVEAT SCRIPTOR - =item DESCRIPTION =over @@ -2977,11 +3344,15 @@ FALSE, TRUE, C<undef> =item Calling Conventions for Unary Operations +=item Calling Conventions for Mutators + +C<++> and C<-->, C<x=> and other assignment versions + =item Overloadable Operations I<Arithmetic operations>, I<Comparison operations>, I<Bit operations>, I<Increment and decrement>, I<Transcendental functions>, I<Boolean, string -and numeric conversion>, I<Special> +and numeric conversion>, I<Iteration>, I<Dereferencing>, I<Special> =item Inheritance and overloading @@ -3010,9 +3381,10 @@ B<Example> I<Assignment forms of arithmetic operations>, I<Conversion operations>, I<Increment and decrement>, C<abs($a)>, I<Unary minus>, I<Negation>, -I<Concatenation>, I<Comparison operations>, I<Copy operator> +I<Concatenation>, I<Comparison operations>, I<Iterator>, I<Dereferencing>, +I<Copy operator> -=item WARNING +=item Losing overloading =item Run-time Overloading @@ -3026,12 +3398,34 @@ integer, float, binary, q, qr =item IMPLEMENTATION +=item Metaphor clash + +=item Cookbook + +=over + +=item Two-face scalars + +=item Two-face references + +=item Symbolic calculator + +=item I<Really> symbolic calculator + +=back + =item AUTHOR =item DIAGNOSTICS =item BUGS +=head2 re - Perl pragma to alter regular expression behaviour + +=item SYNOPSIS + +=item DESCRIPTION + =head2 sigtrap - Perl pragma to enable simple signal handling =item SYNOPSIS @@ -3072,12 +3466,28 @@ C<strict refs>, C<strict vars>, C<strict subs> =item DESCRIPTION +=head2 utf8 - Perl pragma to turn on UTF-8 and Unicode support + +=item SYNOPSIS + +=item DESCRIPTION + +=item CAVEATS + =head2 vars - Perl pragma to predeclare global variable names =item SYNOPSIS =item DESCRIPTION +=head2 warning - Perl pragma to control optional warnings + +=item SYNOPSIS + +=item DESCRIPTION + +C<warning deprecated> + =head1 MODULE DOCUMENTATION =head2 AnyDBM_File - provide framework for multiple DBMs @@ -3200,7 +3610,8 @@ FILL, MAX, OFF, ARRAY, AvFLAGS =item B::CV METHODS -STASH, START, ROOT, GV, FILEGV, DEPTH, PADLIST, OUTSIDE, XSUB, XSUBANY +STASH, START, ROOT, GV, FILEGV, DEPTH, PADLIST, OUTSIDE, XSUB, XSUBANY, +CvFLAGS =item B::HV METHODS @@ -3260,10 +3671,11 @@ label, stash, filegv, cop_seq, arybase, line =item FUNCTIONS EXPORTED BY C<B> -main_cv, main_root, main_start, comppadlist, sv_undef, sv_yes, sv_no, -walkoptree(OP, METHOD), walkoptree_debug(DEBUG), walksymtable(SYMREF, -METHOD, RECURSE), svref_2object(SV), ppname(OPNUM), hash(STR), cast_I32(I), -minus_c, cstring(STR), class(OBJ), threadsv_names, byteload_fh(FILEHANDLE) +main_cv, init_av, main_root, main_start, comppadlist, sv_undef, sv_yes, +sv_no, amagic_generation, walkoptree(OP, METHOD), walkoptree_debug(DEBUG), +walksymtable(SYMREF, METHOD, RECURSE), svref_2object(SV), ppname(OPNUM), +hash(STR), cast_I32(I), minus_c, cstring(STR), class(OBJ), threadsv_names, +byteload_fh(FILEHANDLE) =item AUTHOR @@ -3304,6 +3716,8 @@ B<-ofilename>, B<-->, B<-f>, B<-fcompress-nullops>, B<-fomit-sequence-numbers>, B<-fbypass-nullops>, B<-fstrip-syntax-tree>, B<-On>, B<-D>, B<-Do>, B<-Db>, B<-Da>, B<-DC>, B<-S>, B<-m> +=item EXAMPLES + =item BUGS =item AUTHOR @@ -3373,7 +3787,7 @@ B<-ffreetmps-each-bblock>, B<-ffreetmps-each-loop>, B<-fomit-taint>, B<-On> =item OPTIONS -B<-p>, B<-u>I<PACKAGE>, B<-l>, B<-s>I<LETTERS>, B<C> +B<-l>, B<-p>, B<-q>, B<-u>I<PACKAGE>, B<-s>I<LETTERS>, B<C> =item BUGS @@ -3456,6 +3870,14 @@ C<-oFILENAME>, C<-r>, C<-D[tO]> =item AUTHOR +=head2 Bblock, B::Bblock - Walk basic blocks + +=item SYNOPSIS + +=item DESCRIPTION + +=item AUTHOR + =head2 Benchmark - benchmark running times of code =item SYNOPSIS @@ -3471,8 +3893,8 @@ new, debug =item Standard Exports timeit(COUNT, CODE), timethis ( COUNT, CODE, [ TITLE, [ STYLE ]] ), -timethese ( COUNT, CODEHASHREF, [ STYLE ] ), timediff ( T1, T2 ), timestr ( -TIMEDIFF, [ STYLE, [ FORMAT ] ] ) +timethese ( COUNT, CODEHASHREF, [ STYLE ] ), timediff ( T1, T2 ), timesum ( +T1, T2 ), timestr ( TIMEDIFF, [ STYLE, [ FORMAT ] ] ) =item Optional Exports @@ -3490,6 +3912,34 @@ clearcache ( COUNT ), clearallcache ( ), disablecache ( ), enablecache ( ) =item MODIFICATION HISTORY +=head2 ByteLoader - load byte compiled perl code + +=item SYNOPSIS + +=item DESCRIPTION + +=item AUTHOR + +=item SEE ALSO + +=head2 Bytecode, B::Bytecode - Perl compiler's bytecode backend + +=item SYNOPSIS + +=item DESCRIPTION + +=item OPTIONS + +B<-ofilename>, B<-->, B<-f>, B<-fcompress-nullops>, +B<-fomit-sequence-numbers>, B<-fbypass-nullops>, B<-fstrip-syntax-tree>, +B<-On>, B<-D>, B<-Do>, B<-Db>, B<-Da>, B<-DC>, B<-S>, B<-m> + +=item EXAMPLES + +=item BUGS + +=item AUTHOR + =head2 CGI - Simple Common Gateway Interface Class =item SYNOPSIS @@ -3539,7 +3989,14 @@ B<:standard>, B<:all> =item PRAGMAS --any, -compile, -nph, -autoload, -no_debug, -private_tempfiles +-any, -compile, -nph, -newstyle_urls, -autoload, -no_debug, +-private_tempfiles + +=item SPECIAL FORMS FOR IMPORTING HTML-TAG FUNCTIONS + +1. start_table() (generates a <TABLE> tag), 2. end_table() (generates a +</TABLE> tag), 3. start_ul() (generates a <UL> tag), 4. end_ul() (generates +a </UL> tag) =back @@ -3564,6 +4021,8 @@ B<Parameters:>, 4, 5, 6.. B<-absolute>, B<-relative>, B<-full>, B<-path> (B<-path_info>), B<-query> (B<-query_string>) +=item MIXING POST AND URL PARAMETERS + =back =item CREATING STANDARD HTML ELEMENTS: @@ -3578,6 +4037,8 @@ B<-absolute>, B<-relative>, B<-full>, B<-path> (B<-path_info>), B<-query> =item NON-STANDARD HTML SHORTCUTS +=item PRETTY-PRINTING HTML + =back =item CREATING FILL-OUT FORMS: @@ -3642,12 +4103,12 @@ TOP, BOTTOM or MIDDLE =back -=item NETSCAPE COOKIES +=item HTTP COOKIES 1. an expiration time, 2. a domain, 3. a path, 4. a "secure" flag, B<-name>, B<-value>, B<-path>, B<-domain>, B<-expires>, B<-secure> -=item WORKING WITH NETSCAPE FRAMES +=item WORKING WITH FRAMES 1. Create a <Frameset> document, 2. Specify the destination for the document in the HTTP header, 3. Specify the destination for the document in @@ -3665,7 +4126,7 @@ the <FORM> tag =item FETCHING ENVIRONMENT VARIABLES -B<accept()>, B<raw_cookie()>, B<user_agent()>, B<path_info()>, +B<Accept()>, B<raw_cookie()>, B<user_agent()>, B<path_info()>, B<path_translated()>, B<remote_host()>, B<script_name()>Return the script name as a partial URL, for self-refering scripts, B<referer()>, B<auth_type ()>, B<server_name ()>, B<virtual_host @@ -3680,7 +4141,7 @@ parameters in the B<header()> and B<redirect()> statements: =item Server Push multipart_init() -multipart_init(-boundary=>$boundary);, multipart_start(), multipart_end() + multipart_init(-boundary=>$boundary);, multipart_start(), multipart_end() =item Avoiding Denial of Service Attacks @@ -3696,15 +4157,15 @@ basis>, B<2. Globally for all scripts> Matt Heffron (heffron@falstaff.css.beckman.com), James Taylor (james.taylor@srs.gov), Scott Anguish <sanguish@digifix.com>, Mike Jewell (mlj3u@virginia.edu), Timothy Shimmin (tes@kbs.citri.edu.au), Joergen Haegg -(jh@axis.se), Laurent Delfosse (delfosse@csgrad1.cs.wvu.edu), Richard -Resnick (applepi1@aol.com), Craig Bishop (csb@barwonwater.vic.gov.au), Tony -Curtis (tc@vcpc.univie.ac.at), Tim Bunce (Tim.Bunce@ig.co.uk), Tom -Christiansen (tchrist@convex.com), Andreas Koenig -(k@franz.ww.TU-Berlin.DE), Tim MacKenzie (Tim.MacKenzie@fulcrum.com.au), -Kevin B. Hendricks (kbhend@dogwood.tyler.wm.edu), Stephen Dahmen -(joyfire@inxpress.net), Ed Jordan (ed@fidalgo.net), David Alan Pisoni -(david@cnation.com), Doug MacEachern (dougm@opengroup.org), Robin Houston -(robin@oneworld.org), ...and many many more.. +(jh@axis.se), Laurent Delfosse (delfosse@delfosse.com), Richard Resnick +(applepi1@aol.com), Craig Bishop (csb@barwonwater.vic.gov.au), Tony Curtis +(tc@vcpc.univie.ac.at), Tim Bunce (Tim.Bunce@ig.co.uk), Tom Christiansen +(tchrist@convex.com), Andreas Koenig (k@franz.ww.TU-Berlin.DE), Tim +MacKenzie (Tim.MacKenzie@fulcrum.com.au), Kevin B. Hendricks +(kbhend@dogwood.tyler.wm.edu), Stephen Dahmen (joyfire@inxpress.net), Ed +Jordan (ed@fidalgo.net), David Alan Pisoni (david@cnation.com), Doug +MacEachern (dougm@opengroup.org), Robin Houston (robin@oneworld.org), +...and many many more.. =item A COMPLETE EXAMPLE OF A SIMPLE FORM-BASED SCRIPT @@ -3821,8 +4282,6 @@ B<name()>, B<value()>, B<domain()>, B<path()>, B<expires()> =item INSTALLING CGI::Push SCRIPTS -=item CAVEATS - =item AUTHOR INFORMATION =item BUGS @@ -3866,7 +4325,7 @@ distribution, Signals expand($type,@things), Programming Examples -=item Methods in the four +=item Methods in the four Classes =item Cache Manager @@ -3878,7 +4337,7 @@ expand($type,@things), Programming Examples =item Debugging -=item Floppy, Zip, and all that Jazz +=item Floppy, Zip, Offline Mode =back @@ -3891,7 +4350,9 @@ E<lt>listE<gt> =over -=item CD-ROM support +=item Note on urllist parameter's format + +=item urllist parameter has CD-ROM support =back @@ -3899,6 +4360,12 @@ E<lt>listE<gt> =item EXPORT +=item POPULATE AN INSTALLATION WITH LOTS OF MODULES + +=item WORKING WITH CPAN.pm BEHIND FIREWALLS + +http firewall, ftp firewall, One way visibility, SOCKS, IP Masquerade + =item BUGS =item AUTHOR @@ -3932,6 +4399,8 @@ module =back +=item BUGS + =head2 Class::Struct - declare struct-like datatypes as Perl classes =item SYNOPSIS @@ -3955,12 +4424,273 @@ Example 1, Example 2 =item Author and Modification History +=head2 Config - access Perl configuration information + +=item SYNOPSIS + +=item DESCRIPTION + +myconfig(), config_sh(), config_vars(@names) + +=item EXAMPLE + +=item WARNING + +=item GLOSSARY + +=over + +=item _ + +C<_a>, C<_exe>, C<_o> + +=item a + +C<afs>, C<alignbytes>, C<ansi2knr>, C<aphostname>, C<apiversion>, C<ar>, +C<archlib>, C<archlibexp>, C<archname64>, C<archname>, C<archobjs>, C<awk> + +=item b + +C<baserev>, C<bash>, C<bin>, C<binexp>, C<bison>, C<byacc>, C<byteorder> + +=item c + +C<c>, C<castflags>, C<cat>, C<cc>, C<cccdlflags>, C<ccdlflags>, C<ccflags>, +C<ccsymbols>, C<cf_by>, C<cf_email>, C<cf_time>, C<chgrp>, C<chmod>, +C<chown>, C<clocktype>, C<comm>, C<compress>, C<contains>, C<cp>, C<cpio>, +C<cpp>, C<cpp_stuff>, C<cppccsymbols>, C<cppflags>, C<cpplast>, +C<cppminus>, C<cpprun>, C<cppstdin>, C<cppsymbols>, C<crosscompile>, +C<cryptlib>, C<csh> + +=item d + +C<d_access>, C<d_accessx>, C<d_alarm>, C<d_archlib>, C<d_attribut>, +C<d_bcmp>, C<d_bcopy>, C<d_bsd>, C<d_bsdgetpgrp>, C<d_bsdsetpgrp>, +C<d_bzero>, C<d_casti32>, C<d_castneg>, C<d_charvspr>, C<d_chown>, +C<d_chroot>, C<d_chsize>, C<d_closedir>, C<d_cmsghdr_s>, C<d_const>, +C<d_crypt>, C<d_csh>, C<d_cuserid>, C<d_dbl_dig>, C<d_dbmclose64>, +C<d_dbminit64>, C<d_delete64>, C<d_difftime>, C<d_dirent64_s>, +C<d_dirnamlen>, C<d_dlerror>, C<d_dlopen>, C<d_dlsymun>, C<d_dosuid>, +C<d_drand48proto>, C<d_dup2>, C<d_eaccess>, C<d_endgrent>, C<d_endhent>, +C<d_endnent>, C<d_endpent>, C<d_endpwent>, C<d_endsent>, C<d_eofnblk>, +C<d_eunice>, C<d_fchmod>, C<d_fchown>, C<d_fcntl>, C<d_fd_macros>, +C<d_fd_set>, C<d_fds_bits>, C<d_fetch64>, C<d_fgetpos64>, C<d_fgetpos>, +C<d_firstkey64>, C<d_flexfnam>, C<d_flock64_s>, C<d_flock>, C<d_fopen64>, +C<d_fork>, C<d_fpathconf>, C<d_freopen64>, C<d_fseek64>, C<d_fseeko64>, +C<d_fseeko>, C<d_fsetpos64>, C<d_fsetpos>, C<d_fstat64>, C<d_fstatfs>, +C<d_fstatvfs>, C<d_ftell64>, C<d_ftello64>, C<d_ftello>, C<d_ftime>, +C<d_ftruncate64>, C<d_Gconvert>, C<d_getgrent>, C<d_getgrps>, +C<d_gethbyaddr>, C<d_gethbyname>, C<d_gethent>, C<d_gethname>, +C<d_gethostprotos>, C<d_getlogin>, C<d_getmntent>, C<d_getnbyaddr>, +C<d_getnbyname>, C<d_getnent>, C<d_getnetprotos>, C<d_getpbyname>, +C<d_getpbynumber>, C<d_getpent>, C<d_getpgid>, C<d_getpgrp2>, C<d_getpgrp>, +C<d_getppid>, C<d_getprior>, C<d_getprotoprotos>, C<d_getpwent>, +C<d_getsbyname>, C<d_getsbyport>, C<d_getsent>, C<d_getservprotos>, +C<d_gettimeod>, C<d_gnulibc>, C<d_grpasswd>, C<d_hasmntopt>, C<d_htonl>, +C<d_index>, C<d_inetaton>, C<d_ino64_t>, C<d_int64t>, C<d_iovec_s>, +C<d_isascii>, C<d_killpg>, C<d_lchown>, C<d_link>, C<d_llseek>, +C<d_locconv>, C<d_lockf64>, C<d_lockf>, C<d_longdbl>, C<d_longlong>, +C<d_lseek64>, C<d_lstat64>, C<d_lstat>, C<d_madvise>, C<d_mblen>, +C<d_mbstowcs>, C<d_mbtowc>, C<d_memchr>, C<d_memcmp>, C<d_memcpy>, +C<d_memmove>, C<d_memset>, C<d_mkdir>, C<d_mkfifo>, C<d_mktime>, C<d_mmap>, +C<d_mprotect>, C<d_msg>, C<d_msg_ctrunc>, C<d_msg_dontroute>, C<d_msg_oob>, +C<d_msg_peek>, C<d_msg_proxy>, C<d_msgctl>, C<d_msgget>, C<d_msghdr_s>, +C<d_msgrcv>, C<d_msgsnd>, C<d_msync>, C<d_munmap>, C<d_mymalloc>, +C<d_nextkey64>, C<d_nice>, C<d_off64_t>, C<d_offset_t>, +C<d_old_pthread_create_joinable>, C<d_oldpthreads>, C<d_oldsock>, +C<d_open3>, C<d_open64>, C<d_opendir64>, C<d_pathconf>, C<d_pause>, +C<d_phostname>, C<d_pipe>, C<d_poll>, C<d_portable>, C<d_pthread_yield>, +C<d_pwage>, C<d_pwchange>, C<d_pwclass>, C<d_pwcomment>, C<d_pwexpire>, +C<d_pwgecos>, C<d_pwpasswd>, C<d_pwquota>, C<d_readdir64>, C<d_readdir>, +C<d_readlink>, C<d_readv>, C<d_recvmsg>, C<d_rename>, C<d_rewinddir>, +C<d_rmdir>, C<d_safebcpy>, C<d_safemcpy>, C<d_sanemcmp>, C<d_sched_yield>, +C<d_scm_rights>, C<d_seekdir64>, C<d_seekdir>, C<d_select>, C<d_sem>, +C<d_semctl>, C<d_semctl_semid_ds>, C<d_semctl_semun>, C<d_semget>, +C<d_semop>, C<d_sendmsg>, C<d_setegid>, C<d_seteuid>, C<d_setgrent>, +C<d_setgrps>, C<d_sethent>, C<d_setlinebuf>, C<d_setlocale>, C<d_setnent>, +C<d_setpent>, C<d_setpgid>, C<d_setpgrp2>, C<d_setpgrp>, C<d_setprior>, +C<d_setpwent>, C<d_setregid>, C<d_setresgid>, C<d_setresuid>, +C<d_setreuid>, C<d_setrgid>, C<d_setruid>, C<d_setsent>, C<d_setsid>, +C<d_setvbuf>, C<d_sfio>, C<d_shm>, C<d_shmat>, C<d_shmatprototype>, +C<d_shmctl>, C<d_shmdt>, C<d_shmget>, C<d_sigaction>, C<d_sigsetjmp>, +C<d_socket>, C<d_sockpair>, C<d_stat64>, C<d_statblks>, C<d_statfs>, +C<d_statfsflags>, C<d_statvfs>, C<d_stdio_cnt_lval>, C<d_stdio_ptr_lval>, +C<d_stdio_stream_array>, C<d_stdiobase>, C<d_stdstdio>, C<d_store64>, +C<d_strchr>, C<d_strcoll>, C<d_strctcpy>, C<d_strerrm>, C<d_strerror>, +C<d_strtod>, C<d_strtol>, C<d_strtoul>, C<d_strxfrm>, C<d_suidsafe>, +C<d_symlink>, C<d_syscall>, C<d_sysconf>, C<d_sysernlst>, C<d_syserrlst>, +C<d_system>, C<d_tcgetpgrp>, C<d_tcsetpgrp>, C<d_telldir64>, C<d_telldir>, +C<d_telldirproto>, C<d_time>, C<d_times>, C<d_tmpfile64>, C<d_truncate64>, +C<d_truncate>, C<d_tzname>, C<d_umask>, C<d_uname>, C<d_union_semun>, +C<d_vfork>, C<d_void_closedir>, C<d_voidsig>, C<d_voidtty>, C<d_volatile>, +C<d_vprintf>, C<d_wait4>, C<d_waitpid>, C<d_wcstombs>, C<d_wctomb>, +C<d_writev>, C<d_xenix>, C<date>, C<db_hashtype>, C<db_prefixtype>, +C<defvoidused>, C<direntrytype>, C<dlext>, C<dlsrc>, C<doublesize>, +C<drand01>, C<dynamic_ext> + +=item e + +C<eagain>, C<ebcdic>, C<echo>, C<egrep>, C<emacs>, C<eunicefix>, +C<exe_ext>, C<expr>, C<extensions> + +=item f + +C<fflushall>, C<fflushNULL>, C<find>, C<firstmakefile>, C<flex>, +C<fpostype>, C<freetype>, C<full_ar>, C<full_csh>, C<full_sed> + +=item g + +C<gccversion>, C<gidtype>, C<glibpth>, C<grep>, C<groupcat>, C<groupstype>, +C<gzip> + +=item h + +C<h_fcntl>, C<h_sysfile>, C<hint>, C<hostcat>, C<huge> + +=item i + +C<i_arpainet>, C<i_bsdioctl>, C<i_db>, C<i_dbm>, C<i_dirent>, C<i_dld>, +C<i_dlfcn>, C<i_fcntl>, C<i_float>, C<i_gdbm>, C<i_grp>, C<i_inttypes>, +C<i_limits>, C<i_locale>, C<i_machcthr>, C<i_malloc>, C<i_math>, +C<i_memory>, C<i_mntent>, C<i_ndbm>, C<i_netdb>, C<i_neterrno>, +C<i_netinettcp>, C<i_niin>, C<i_poll>, C<i_pthread>, C<i_pwd>, +C<i_rpcsvcdbm>, C<i_sfio>, C<i_sgtty>, C<i_stdarg>, C<i_stddef>, +C<i_stdlib>, C<i_string>, C<i_sysaccess>, C<i_sysdir>, C<i_sysfile>, +C<i_sysfilio>, C<i_sysin>, C<i_sysioctl>, C<i_sysmman>, C<i_sysmount>, +C<i_sysndir>, C<i_sysparam>, C<i_sysresrc>, C<i_syssecrt>, C<i_sysselct>, +C<i_syssockio>, C<i_sysstat>, C<i_sysstatvfs>, C<i_systime>, C<i_systimek>, +C<i_systimes>, C<i_systypes>, C<i_sysuio>, C<i_sysun>, C<i_syswait>, +C<i_termio>, C<i_termios>, C<i_time>, C<i_unistd>, C<i_utime>, C<i_values>, +C<i_varargs>, C<i_varhdr>, C<i_vfork>, C<ignore_versioned_solibs>, +C<incpath>, C<inews>, C<installarchlib>, C<installbin>, C<installman1dir>, +C<installman3dir>, C<installprivlib>, C<installscript>, C<installsitearch>, +C<installsitelib>, C<installusrbinperl>, C<intsize> + +=item k + +C<known_extensions>, C<ksh> + +=item l + +C<large>, C<ld>, C<lddlflags>, C<ldflags>, C<less>, C<lib_ext>, C<libc>, +C<libperl>, C<libpth>, C<libs>, C<libswanted>, C<line>, C<lint>, +C<lkflags>, C<ln>, C<lns>, C<locincpth>, C<loclibpth>, C<longdblsize>, +C<longlongsize>, C<longsize>, C<lp>, C<lpr>, C<ls>, C<lseeksize>, +C<lseektype> + +=item m + +C<mail>, C<mailx>, C<make>, C<make_set_make>, C<mallocobj>, C<mallocsrc>, +C<malloctype>, C<man1dir>, C<man1direxp>, C<man1ext>, C<man3dir>, +C<man3direxp>, C<man3ext> + +=item M + +C<Mcc>, C<medium>, C<mips_type>, C<mkdir>, C<mmaptype>, C<models>, +C<modetype>, C<more>, C<multiarch>, C<mv>, C<myarchname>, C<mydomain>, +C<myhostname>, C<myuname> + +=item n + +C<n>, C<netdb_hlen_type>, C<netdb_host_type>, C<netdb_name_type>, +C<netdb_net_type>, C<nm>, C<nm_opt>, C<nm_so_opt>, C<nonxs_ext>, C<nroff> + +=item o + +C<o_nonblock>, C<obj_ext>, C<old_pthread_create_joinable>, C<optimize>, +C<orderlib>, C<osname>, C<osvers> + +=item p + +C<package>, C<pager>, C<passcat>, C<patchlevel>, C<path_sep>, C<perl>, +C<perladmin>, C<perlpath>, C<pg>, C<phostname>, C<pidtype>, C<plibpth>, +C<pmake>, C<pr>, C<prefix>, C<prefixexp>, C<privlib>, C<privlibexp>, +C<prototype>, C<ptrsize> + +=item r + +C<randbits>, C<randfunc>, C<randseedtype>, C<ranlib>, C<rd_nodata>, C<rm>, +C<rmail>, C<runnm> + +=item s + +C<sched_yield>, C<scriptdir>, C<scriptdirexp>, C<sed>, C<seedfunc>, +C<selectminbits>, C<selecttype>, C<sendmail>, C<sh>, C<shar>, C<sharpbang>, +C<shmattype>, C<shortsize>, C<shrpenv>, C<shsharp>, C<sig_count>, +C<sig_name>, C<sig_name_init>, C<sig_num>, C<sig_num_init>, C<signal_t>, +C<sitearch>, C<sitearchexp>, C<sitelib>, C<sitelibexp>, C<sizetype>, +C<sleep>, C<smail>, C<small>, C<so>, C<sockethdr>, C<socketlib>, C<sort>, +C<spackage>, C<spitshell>, C<split>, C<src>, C<ssizetype>, C<startperl>, +C<startsh>, C<static_ext>, C<stdchar>, C<stdio_base>, C<stdio_bufsiz>, +C<stdio_cnt>, C<stdio_filbuf>, C<stdio_ptr>, C<stdio_stream_array>, +C<strings>, C<submit>, C<subversion>, C<sysman> + +=item t + +C<tail>, C<tar>, C<tbl>, C<tee>, C<test>, C<timeincl>, C<timetype>, +C<touch>, C<tr>, C<trnl>, C<troff> + +=item u + +C<uidtype>, C<uname>, C<uniq>, C<use64bits>, C<usedl>, C<usemultiplicity>, +C<usemymalloc>, C<usenm>, C<useopcode>, C<useperlio>, C<useposix>, +C<usesfio>, C<useshrplib>, C<usethreads>, C<usevfork>, C<usrinc>, C<uuname> + +=item v + +C<version>, C<vi>, C<voidflags> + +=item x + +C<xlibpth> + +=item z + +C<zcat>, C<zip> + +=back + +=item NOTE + =head2 Cwd, getcwd - get pathname of current working directory =item SYNOPSIS =item DESCRIPTION +=head2 DB - programmatic interface to the Perl debugging API (draft, +subject to +change) + +=item SYNOPSIS + +=item DESCRIPTION + +=over + +=item Global Variables + + $DB::sub, %DB::sub, $DB::single, $DB::signal, $DB::trace, @DB::args, +@DB::dbline, %DB::dbline, $DB::package, $DB::filename, $DB::subname, +$DB::lineno + +=item API Methods + +CLIENT->register(), CLIENT->evalcode(STRING), CLIENT->skippkg('D::hide'), +CLIENT->run(), CLIENT->step(), CLIENT->next(), CLIENT->done() + +=item Client Callback Methods + +CLIENT->init(), CLIENT->prestop([STRING]), CLIENT->stop(), CLIENT->idle(), +CLIENT->poststop([STRING]), CLIENT->evalcode(STRING), CLIENT->cleanup(), +CLIENT->output(LIST) + +=back + +=item BUGS + +=item AUTHOR + =head2 DB_File - Perl5 access to Berkeley DB version 1.x =item SYNOPSIS @@ -4001,6 +4731,10 @@ B<DB_HASH>, B<DB_BTREE>, B<DB_RECNO> =item The get_dup() Method +=item The find_dup() Method + +=item The del_dup() Method + =item Matching Partial Keys =back @@ -4013,7 +4747,7 @@ B<DB_HASH>, B<DB_BTREE>, B<DB_RECNO> =item A Simple Example -=item Extra Methods +=item Extra RECNO Methods B<$X-E<gt>push(list) ;>, B<$value = $X-E<gt>pop ;>, B<$X-E<gt>shift>, B<$X-E<gt>unshift(list) ;>, B<$X-E<gt>length> @@ -4078,8 +4812,8 @@ printing and C<eval> =item Methods -I<PACKAGE>->new(I<ARRAYREF [>, I<ARRAYREF]>), I<$OBJ>->Dump I<or> -I<PACKAGE>->Dump(I<ARRAYREF [>, I<ARRAYREF]>), I<$OBJ>->Dumpxs I<or> +I<PACKAGE>->new(I<ARRAYREF [>, I<ARRAYREF]>), I<$OBJ>->Dump I<or> +I<PACKAGE>->Dump(I<ARRAYREF [>, I<ARRAYREF]>), I<$OBJ>->Dumpxs I<or> I<PACKAGE>->Dumpxs(I<ARRAYREF [>, I<ARRAYREF]>), I<$OBJ>->Seen(I<[HASHREF]>), I<$OBJ>->Values(I<[ARRAYREF]>), I<$OBJ>->Names(I<[ARRAYREF]>), I<$OBJ>->Reset @@ -4118,6 +4852,44 @@ Dumper =item SEE ALSO +=head2 Devel::Peek - A data debugging tool for the XS programmer + +=item SYNOPSIS + +=item DESCRIPTION + +=item EXAMPLES + +=over + +=item A simple scalar string + +=item A simple scalar number + +=item A simple scalar with an extra reference + +=item A reference to a simple scalar + +=item A reference to an array + +=item A reference to a hash + +=item Dumping a large array or hash + +=item A reference to an SV which holds a C pointer + +=item A reference to a subroutine + +=back + +=item EXPORTS + +=item BUGS + +=item AUTHOR + +=item SEE ALSO + =head2 Devel::SelfStubber - generate stubs for a SelfLoading module =item SYNOPSIS @@ -4130,6 +4902,42 @@ Dumper =item DESCRIPTION +=head2 Dumpvalue - provides screen dump of Perl data. + +=item SYNOPSYS + +=item DESCRIPTION + +=over + +=item Creation + +C<arrayDepth>, C<hashDepth>, C<compactDump>, C<veryCompact>, C<globPrint>, +C<DumpDBFiles>, C<DumpPackages>, C<DumpReused>, C<tick>, C<HighBit>, +C<printUndef>, C<UsageOnly>, unctrl, subdump, bareStringify, quoteHighBit, +stopDbSignal + +=item Methods + +dumpValue, dumpValues, dumpvars, set_quote, set_unctrl, compactDump, +veryCompact, set, get + +=back + +=head2 DynaLoader - Dynamically load C libraries into Perl code + +=item SYNOPSIS + +=item DESCRIPTION + +@dl_library_path, @dl_resolve_using, @dl_require_symbols, @dl_librefs, +@dl_modules, dl_error(), $dl_debug, dl_findfile(), dl_expandspec(), +dl_load_file(), dl_loadflags(), dl_find_symbol(), +dl_find_symbol_anywhere(), dl_undef_symbols(), dl_install_xsub(), +bootstrap() + +=item AUTHOR + =head2 English - use nice English (or awk) names for ugly punctuation variables @@ -4145,6 +4953,16 @@ variables =item AUTHOR +=head2 Errno - System errno constants + +=item SYNOPSIS + +=item DESCRIPTION + +=item AUTHOR + +=item COPYRIGHT + =head2 Exporter - Implements default import method for modules =item SYNOPSIS @@ -4256,6 +5074,15 @@ For static extensions, For dynamic extensions, For dynamic extensions =item SEE ALSO +=head2 ExtUtils::MM_Cygwin - methods to override UN*X behaviour in +ExtUtils::MakeMaker + +=item SYNOPSIS + +=item DESCRIPTION + +canonpath, cflags, manifypods, perl_archive + =head2 ExtUtils::MM_OS2 - methods to override UN*X behaviour in ExtUtils::MakeMaker @@ -4297,7 +5124,7 @@ perm_rw (o), perm_rwx (o), pm_to_blib, post_constants (o), post_initialize replace_manpage_separator, static (o), static_lib (o), staticmake (o), subdir_x (o), subdirs (o), test (o), test_via_harness (o), test_via_script (o), tool_autosplit (o), tools_other (o), tool_xsubpp (o), top_targets (o), -writedoc, xs_c (o), xs_o (o), perl_archive, export_list +writedoc, xs_c (o), xs_cpp (o), xs_o (o), perl_archive, export_list =back @@ -4379,21 +5206,23 @@ dist_ci (o), dist_core (o), pasthru (o) =item Using Attributes and Parameters -C, CCFLAGS, CONFIG, CONFIGURE, DEFINE, DIR, DISTNAME, DL_FUNCS, DL_VARS, -EXCLUDE_EXT, EXE_FILES, NO_VC, FIRST_MAKEFILE, FULLPERL, H, IMPORTS, INC, +AUTHOR, ABSTRACT, ABSTRACT_FROM, BINARY_LOCATION, C, CAPI, CCFLAGS, CONFIG, +CONFIGURE, DEFINE, DIR, DISTNAME, DL_FUNCS, DL_VARS, EXCLUDE_EXT, +EXE_FILES, FIRST_MAKEFILE, FULLPERL, FUNCLIST, H, IMPORTS, INC, INCLUDE_EXT, INSTALLARCHLIB, INSTALLBIN, INSTALLDIRS, INSTALLMAN1DIR, -INSTALLMAN3DIR, INSTALLPRIVLIB, INSTALLSCRIPT, INSTALLSITELIB, -INSTALLSITEARCH, INST_ARCHLIB, INST_BIN, INST_EXE, INST_LIB, INST_MAN1DIR, -INST_MAN3DIR, INST_SCRIPT, LDFROM, LIBPERL_A, LIB, LIBS, LINKTYPE, +INSTALLMAN3DIR, INSTALLPRIVLIB, INSTALLSCRIPT, INSTALLSITEARCH, +INSTALLSITELIB, INST_ARCHLIB, INST_BIN, INST_EXE, INST_LIB, INST_MAN1DIR, +INST_MAN3DIR, INST_SCRIPT, LDFROM, LIB, LIBPERL_A, LIBS, LINKTYPE, MAKEAPERL, MAKEFILE, MAN1PODS, MAN3PODS, MAP_TARGET, MYEXTLIB, NAME, -NEEDS_LINKING, NOECHO, NORECURS, OBJECT, OPTIMIZE, PERL, PERLMAINCC, +NEEDS_LINKING, NOECHO, NORECURS, NO_VC, OBJECT, OPTIMIZE, PERL, PERLMAINCC, PERL_ARCHLIB, PERL_LIB, PERL_SRC, PERM_RW, PERM_RWX, PL_FILES, PM, -PMLIBDIRS, PREFIX, PREREQ_PM, SKIP, TYPEMAPS, VERSION, VERSION_FROM, XS, -XSOPT, XSPROTOARG, XS_VERSION +PMLIBDIRS, POLLUTE, PPM_INSTALL_EXEC, PPM_INSTALL_SCRIPT, PREFIX, +PREREQ_PM, SKIP, TYPEMAPS, VERSION, VERSION_FROM, XS, XSOPT, XSPROTOARG, +XS_VERSION =item Additional lowercase attributes -clean, depend, dist, dynamic_lib, installpm, linkext, macro, realclean, +clean, depend, dist, dynamic_lib, linkext, macro, realclean, test, tool_autosplit =item Overriding MakeMaker Methods @@ -4402,14 +5231,18 @@ tool_autosplit =item Distribution Support -make distcheck, make skipcheck, make distclean, make manifest, -make distdir, make tardist, make dist, make uutardist, make + make distcheck, make skipcheck, make distclean, make manifest, + make distdir, make tardist, make dist, make uutardist, make shdist, make zipdist, make ci =item Disabling an extension =back +=item ENVIRONMENT + +PERL_MM_OPT + =item SEE ALSO =item AUTHORS @@ -4435,6 +5268,14 @@ C<Added to MANIFEST:> I<file> =item AUTHOR +=head2 ExtUtils::Miniperl, writemain - write the C code for perlmain.c + +=item SYNOPSIS + +=item DESCRIPTION + +=item SEE ALSO + =head2 ExtUtils::Mkbootstrap - make a bootstrap file for use by DynaLoader =item SYNOPSIS @@ -4448,7 +5289,7 @@ extension =item DESCRIPTION -NAME, DL_FUNCS, DL_VARS, FILE, FUNCLIST, DLBASE +DLBASE, DL_FUNCS, DL_VARS, FILE, FUNCLIST, IMPORTS, NAME =item AUTHOR @@ -4530,7 +5371,7 @@ C<basename>, C<dirname> =over -=item Special behavior if C<syscopy> is defined (VMS and OS/2) +=item Special behaviour if C<syscopy> is defined (OS/2, VMS and Win32) rmscopy($from,$to[,$date_flag]) @@ -4572,8 +5413,6 @@ rmscopy($from,$to[,$date_flag]) =item AUTHORS -=item REVISION - =head2 File::Spec - portably perform operations on file names =item SYNOPSIS @@ -4584,6 +5423,20 @@ rmscopy($from,$to[,$date_flag]) =item AUTHORS +=head2 File::Spec::Functions - portably perform operations on file names + +=item SYNOPSIS + +=item DESCRIPTION + +=over + +=item Exports + +=back + +=item SEE ALSO + =head2 File::Spec::Mac - File::Spec for MacOS =item SYNOPSIS @@ -4592,8 +5445,8 @@ rmscopy($from,$to[,$date_flag]) =item METHODS -canonpath, catdir, catfile, curdir, rootdir, updir, file_name_is_absolute, -path +canonpath, catdir, catfile, curdir, devnull, rootdir, tmpdir, updir, +file_name_is_absolute, path =item SEE ALSO @@ -4611,8 +5464,9 @@ path =item METHODS -canonpath, catdir, catfile, curdir, rootdir, updir, no_upwards, -file_name_is_absolute, path, join, nativename +canonpath, catdir, catfile, curdir, devnull, rootdir, tmpdir, updir, +no_upwards, file_name_is_absolute, path, join, splitpath, splitdir, +catpath, abs2rel, rel2abs =item SEE ALSO @@ -4626,18 +5480,24 @@ file_name_is_absolute, path, join, nativename =item Methods always loaded -catdir, catfile, curdir (override), rootdir (override), updir (override), -path (override), file_name_is_absolute (override) +catdir, catfile, curdir (override), devnull (override), rootdir (override), +tmpdir (override), updir (override), path (override), file_name_is_absolute +(override) =back +=item SEE ALSO + =head2 File::Spec::Win32 - methods for Win32 file specs =item SYNOPSIS =item DESCRIPTION -catfile, canonpath +devnull, tmpdir, catfile, canonpath, splitpath, splitdir, catpath, abs2rel, +rel2abs + +=item SEE ALSO =head2 File::stat - by-name interface to Perl's built-in stat() functions @@ -4681,8 +5541,6 @@ $fh->print, $fh->printf, $fh->getline, $fh->getlines =item COPYRIGHT -=item REVISION - =head2 GDBM_File - Perl5 access to the gdbm library. =item SYNOPSIS @@ -4725,7 +5583,7 @@ options =item CONFIGURATION OPTIONS default, auto_abbrev, getopt_compat, require_order, permute, bundling -(default: reset), bundling_override (default: reset), ignore_case +(default: reset), bundling_override (default: reset), ignore_case (default: set), ignore_case_always (default: reset), pass_through (default: reset), prefix, prefix_pattern, debug (default: reset) @@ -4757,6 +5615,215 @@ locale =item DESCRIPTION +=head2 IO::Dir - supply object methods for directory handles + +=item SYNOPSIS + +=item DESCRIPTION + +new ( [ DIRNAME ] ), open ( DIRNAME ), read (), seek ( POS ), tell (), +rewind (), close (), tie %hash, IO::Dir, DIRNAME [, OPTIONS ] + +=item SEE ALSO + +=item AUTHOR + +=item COPYRIGHT + +=head2 IO::File - supply object methods for filehandles + +=item SYNOPSIS + +=item DESCRIPTION + +=item CONSTRUCTOR + +new ( FILENAME [,MODE [,PERMS]] ), new_tmpfile + +=item METHODS + +open( FILENAME [,MODE [,PERMS]] ) + +=item SEE ALSO + +=item HISTORY + +=head2 IO::Handle - supply object methods for I/O handles + +=item SYNOPSIS + +=item DESCRIPTION + +=item CONSTRUCTOR + +new (), new_from_fd ( FD, MODE ) + +=item METHODS + +$io->fdopen ( FD, MODE ), $io->opened, $io->getline, $io->getlines, +$io->ungetc ( ORD ), $io->write ( BUF, LEN [, OFFSET ] ), $io->error, +$io->clearerr, $io->sync, $io->flush, $io->printflush ( ARGS ), +$io->blocking ( [ BOOL ] ), $io->untaint + +=item NOTE + +=item SEE ALSO + +=item BUGS + +=item HISTORY + +=head2 IO::Pipe - supply object methods for pipes + +=item SYNOPSIS + +=item DESCRIPTION + +=item CONSTRUCTOR + +new ( [READER, WRITER] ) + +=item METHODS + +reader ([ARGS]), writer ([ARGS]), handles () + +=item SEE ALSO + +=item AUTHOR + +=item COPYRIGHT + +=head2 IO::Poll - Object interface to system poll call + +=item SYNOPSIS + +=item DESCRIPTION + +=item METHODS + +mask ( IO [, EVENT_MASK ] ), poll ( [ TIMEOUT ] ), events ( IO ), remove ( +IO ), handles( [ EVENT_MASK ] ) + +=item SEE ALSO + +=item AUTHOR + +=item COPYRIGHT + +=head2 IO::Seekable - supply seek based methods for I/O objects + +=item SYNOPSIS + +=item DESCRIPTION + +=item SEE ALSO + +=item HISTORY + +=head2 IO::Select - OO interface to the select system call + +=item SYNOPSIS + +=item DESCRIPTION + +=item CONSTRUCTOR + +new ( [ HANDLES ] ) + +=item METHODS + +add ( HANDLES ), remove ( HANDLES ), exists ( HANDLE ), handles, can_read ( +[ TIMEOUT ] ), can_write ( [ TIMEOUT ] ), has_exception ( [ TIMEOUT ] ), +count (), bits(), select ( READ, WRITE, ERROR [, TIMEOUT ] ) + +=item EXAMPLE + +=item AUTHOR + +=item COPYRIGHT + +=head2 IO::Socket - Object interface to socket communications + +=item SYNOPSIS + +=item DESCRIPTION + +=item CONSTRUCTOR + +new ( [ARGS] ) + +=item METHODS + +accept([PKG]), timeout([VAL]), sockopt(OPT [, VAL]), sockdomain, socktype, +protocol, connected + +=item SEE ALSO + +=item AUTHOR + +=item COPYRIGHT + +=head2 IO::Socket::INET - Object interface for AF_INET domain sockets + +=item SYNOPSIS + +=item DESCRIPTION + +=item CONSTRUCTOR + +new ( [ARGS] ) + +=over + +=item METHODS + +sockaddr (), sockport (), sockhost (), peeraddr (), peerport (), peerhost +() + +=back + +=item SEE ALSO + +=item AUTHOR + +=item COPYRIGHT + +=head2 IO::Socket::UNIX - Object interface for AF_UNIX domain sockets + +=item SYNOPSIS + +=item DESCRIPTION + +=item CONSTRUCTOR + +new ( [ARGS] ) + +=item METHODS + +hostpath(), peerpath() + +=item SEE ALSO + +=item AUTHOR + +=item COPYRIGHT + +=head2 IO::lib::IO::Dir, IO::Dir - supply object methods for directory +handles + +=item SYNOPSIS + +=item DESCRIPTION + +new ( [ DIRNAME ] ), open ( DIRNAME ), read (), seek ( POS ), tell (), +rewind (), close (), tie %hash, IO::Dir, DIRNAME [, OPTIONS ] + +=item SEE ALSO + +=item AUTHOR + +=item COPYRIGHT + =head2 IO::lib::IO::File, IO::File - supply object methods for filehandles =item SYNOPSIS @@ -4765,7 +5832,7 @@ locale =item CONSTRUCTOR -new ([ ARGS ] ), new_tmpfile +new ( FILENAME [,MODE [,PERMS]] ), new_tmpfile =item METHODS @@ -4788,9 +5855,10 @@ new (), new_from_fd ( FD, MODE ) =item METHODS -$fh->fdopen ( FD, MODE ), $fh->opened, $fh->getline, $fh->getlines, -$fh->ungetc ( ORD ), $fh->write ( BUF, LEN [, OFFSET }\] ), $fh->flush, -$fh->error, $fh->clearerr, $fh->untaint +$io->fdopen ( FD, MODE ), $io->opened, $io->getline, $io->getlines, +$io->ungetc ( ORD ), $io->write ( BUF, LEN [, OFFSET ] ), $io->error, +$io->clearerr, $io->sync, $io->flush, $io->printflush ( ARGS ), +$io->blocking ( [ BOOL ] ), $io->untaint =item NOTE @@ -4800,13 +5868,13 @@ $fh->error, $fh->clearerr, $fh->untaint =item HISTORY -=head2 IO::lib::IO::Pipe, IO::pipe - supply object methods for pipes +=head2 IO::lib::IO::Pipe, IO::Pipe - supply object methods for pipes =item SYNOPSIS =item DESCRIPTION -=item CONSTRCUTOR +=item CONSTRUCTOR new ( [READER, WRITER] ) @@ -4820,6 +5888,23 @@ reader ([ARGS]), writer ([ARGS]), handles () =item COPYRIGHT +=head2 IO::lib::IO::Poll, IO::Poll - Object interface to system poll call + +=item SYNOPSIS + +=item DESCRIPTION + +=item METHODS + +mask ( IO [, EVENT_MASK ] ), poll ( [ TIMEOUT ] ), events ( IO ), remove ( +IO ), handles( [ EVENT_MASK ] ) + +=item SEE ALSO + +=item AUTHOR + +=item COPYRIGHT + =head2 IO::lib::IO::Seekable, IO::Seekable - supply seek based methods for I/O objects @@ -4845,8 +5930,8 @@ new ( [ HANDLES ] ) =item METHODS add ( HANDLES ), remove ( HANDLES ), exists ( HANDLE ), handles, can_read ( -[ TIMEOUT ] ), can_write ( [ TIMEOUT ] ), has_error ( [ TIMEOUT ] ), count -(), bits(), bits(), select ( READ, WRITE, ERROR [, TIMEOUT ] ) +[ TIMEOUT ] ), can_write ( [ TIMEOUT ] ), has_exception ( [ TIMEOUT ] ), +count (), bits(), select ( READ, WRITE, ERROR [, TIMEOUT ] ) =item EXAMPLE @@ -4868,26 +5953,72 @@ new ( [ARGS] ) =item METHODS accept([PKG]), timeout([VAL]), sockopt(OPT [, VAL]), sockdomain, socktype, -protocol +protocol, connected -=item SUB-CLASSES +=item SEE ALSO -=over +=item AUTHOR + +=item COPYRIGHT + +=head2 IO::lib::IO::Socket::INET, IO::Socket::INET - Object interface for +AF_INET domain sockets -=item IO::Socket::INET +=item SYNOPSIS + +=item DESCRIPTION + +=item CONSTRUCTOR + +new ( [ARGS] ) + +=over =item METHODS sockaddr (), sockport (), sockhost (), peeraddr (), peerport (), peerhost () -=item IO::Socket::UNIX +=back + +=item SEE ALSO + +=item AUTHOR + +=item COPYRIGHT + +=head2 IO::lib::IO::Socket::UNIX, IO::Socket::UNIX - Object interface for +AF_UNIX domain sockets + +=item SYNOPSIS + +=item DESCRIPTION + +=item CONSTRUCTOR + +new ( [ARGS] ) =item METHODS hostpath(), peerpath() -=back +=item SEE ALSO + +=item AUTHOR + +=item COPYRIGHT + +=head2 IPC::Msg - SysV Msg IPC object class + +=item SYNOPSIS + +=item DESCRIPTION + +=item METHODS + +new ( KEY , FLAGS ), id, rcv ( BUF, LEN [, TYPE [, FLAGS ]] ), remove, set +( STAT ), set ( NAME => VALUE [, NAME => VALUE ...] ), snd ( TYPE, MSG [, +FLAGS ] ), stat =item SEE ALSO @@ -4914,6 +6045,25 @@ handling =item WARNING +=head2 IPC::Semaphore - SysV Semaphore IPC object class + +=item SYNOPSIS + +=item DESCRIPTION + +=item METHODS + +new ( KEY , NSEMS , FLAGS ), getall, getncnt ( SEM ), getpid ( SEM ), +getval ( SEM ), getzcnt ( SEM ), id, op ( OPLIST ), remove, set ( STAT ), +set ( NAME => VALUE [, NAME => VALUE ...] ), setall ( VALUES ), setval ( N +, VALUE ), stat + +=item SEE ALSO + +=item AUTHOR + +=item COPYRIGHT + =head2 IPC::SysV - SysV IPC constants =item SYNOPSIS @@ -4972,7 +6122,8 @@ set ( NAME => VALUE [, NAME => VALUE ...] ), setall ( VALUES ), setval ( N =item DESCRIPTION -number format, Error returns 'NaN', Division is computed to +number format, Error returns 'NaN', Division is computed to, Rounding is +performed =item BUGS @@ -5133,6 +6284,18 @@ functions =item AUTHOR +=head2 O - Generic interface to Perl Compiler backends + +=item SYNOPSIS + +=item DESCRIPTION + +=item CONVENTIONS + +=item IMPLEMENTATION + +=item AUTHOR + =head2 ODBM_File - Tied access to odbm files =item SYNOPSIS @@ -5209,7 +6372,7 @@ Memory, CPU, Snooping, Signals, State Changes =head2 Opcode::ops, ops - Perl pragma to restrict unsafe operations when compiling -=item SYNOPSIS +=item SYNOPSIS =item DESCRIPTION @@ -5342,6 +6505,18 @@ Constants, Macros =item CREATION +=head2 Pod::Checker, podchecker() - check pod documents for syntax errors + +=item SYNOPSIS + +=item OPTIONS/ARGUMENTS + +=item DESCRIPTION + +=item EXAMPLES + +=item AUTHOR + =head2 Pod::Html - module to convert pod files to HTML =item SYNOPSIS @@ -5350,8 +6525,8 @@ Constants, Macros =item ARGUMENTS -help, htmlroot, infile, outfile, podroot, podpath, libpods, netscape, -nonetscape, index, noindex, recurse, norecurse, title, verbose +help, htmldir, htmlroot, infile, outfile, podroot, podpath, libpods, +netscape, nonetscape, index, noindex, recurse, norecurse, title, verbose =item EXAMPLE @@ -5363,6 +6538,261 @@ nonetscape, index, noindex, recurse, norecurse, title, verbose =item COPYRIGHT +=head2 Pod::InputObjects - objects representing POD input paragraphs, +commands, etc. + +=item SYNOPSIS + +=item REQUIRES + +=item EXPORTS + +=item DESCRIPTION + +B<Pod::InputSource>, B<Pod::Paragraph>, B<Pod::InteriorSequence>, +B<Pod::ParseTree> + +=item B<Pod::InputSource> + +=over + +=item B<new()> + +=item B<name()> + +=item B<handle()> + +=item B<was_cutting()> + +=back + +=item B<Pod::Paragraph> + +=over + +=item B<new()> + +=item B<cmd_name()> + +=item B<text()> + +=item B<raw_text()> + +=item B<cmd_prefix()> + +=item B<cmd_separator()> + +=item B<parse_tree()> + +=item B<file_line()> + +=back + +=item B<Pod::InteriorSequence> + +=over + +=item B<new()> + +=item B<cmd_name()> + +=item B<prepend()> + +=item B<append()> + +=item B<nested()> + +=item B<raw_text()> + +=item B<left_delimiter()> + +=item B<right_delimiter()> + +=item B<parse_tree()> + +=item B<file_line()> + +=item B<DESTROY()> + +=back + +=item B<Pod::ParseTree> + +=over + +=item B<new()> + +=item B<top()> + +=item B<children()> + +=item B<prepend()> + +=item B<append()> + +=item B<raw_text()> + +=item B<DESTROY()> + +=back + +=item SEE ALSO + +=item AUTHOR + +=head2 Pod::Parser - base class for creating POD filters and translators + +=item SYNOPSIS + +=item REQUIRES + +=item EXPORTS + +=item DESCRIPTION + +=item QUICK OVERVIEW + +=item RECOMMENDED SUBROUTINE/METHOD OVERRIDES + +=item B<command()> + +C<$cmd>, C<$text>, C<$line_num>, C<$pod_para> + +=item B<verbatim()> + +C<$text>, C<$line_num>, C<$pod_para> + +=item B<textblock()> + +C<$text>, C<$line_num>, C<$pod_para> + +=item B<interior_sequence()> + +=item OPTIONAL SUBROUTINE/METHOD OVERRIDES + +=item B<new()> + +=item B<initialize()> + +=item B<begin_pod()> + +=item B<begin_input()> + +=item B<end_input()> + +=item B<end_pod()> + +=item B<preprocess_line()> + +=item B<preprocess_paragraph()> + +=item METHODS FOR PARSING AND PROCESSING + +=item B<parse_text()> + +B<-expand_seq> =E<gt> I<code-ref>|I<method-name>, B<-expand_ptree> =E<gt> +I<code-ref>|I<method-name> + +=item B<interpolate()> + +=item B<parse_paragraph()> + +=item B<parse_from_filehandle()> + +=item B<parse_from_file()> + +=item ACCESSOR METHODS + +=item B<cutting()> + +=item B<output_file()> + +=item B<output_handle()> + +=item B<input_file()> + +=item B<input_handle()> + +=item B<input_streams()> + +=item B<top_stream()> + +=item PRIVATE METHODS AND DATA + +=item B<_push_input_stream()> + +=item B<_pop_input_stream()> + +=item SEE ALSO + +=item AUTHOR + +=head2 Pod::PlainText, pod2plaintext - function to convert POD data to +formatted ASCII text + +=item SYNOPSIS + +=item REQUIRES + +=item EXPORTS + +=item DESCRIPTION + +=item SEE ALSO + +=item AUTHOR + +=head2 Pod::Select, podselect() - extract selected sections of POD from +input + +=item SYNOPSIS + +=item REQUIRES + +=item EXPORTS + +=item DESCRIPTION + +=item SECTION SPECIFICATIONS + +=item RANGE SPECIFICATIONS + +=item OBJECT METHODS + +=item B<curr_headings()> + +=item B<select()> + +=item B<add_selection()> + +=item B<clear_selections()> + +=item B<match_section()> + +=item B<is_selected()> + +=item EXPORTED FUNCTIONS + +=item B<podselect()> + +B<-output>, B<-sections>, B<-ranges> + +=item PRIVATE METHODS AND DATA + +=item B<_compile_section_spec()> + +=over + +=item $self->{_SECTION_HEADINGS} + +=item $self->{_SELECTED_SECTIONS} + +=back + +=item SEE ALSO + +=item AUTHOR + =head2 Pod::Text - convert POD data to formatted ASCII text =item SYNOPSIS @@ -5373,12 +6803,67 @@ nonetscape, index, noindex, recurse, norecurse, title, verbose =item TODO +=head2 Pod::Usage, pod2usage() - print a usage message from embedded pod +documentation + +=item SYNOPSIS + +=item ARGUMENTS + +C<-message>, C<-msg>, C<-exitval>, C<-verbose>, C<-output>, C<-input>, +C<-pathlist> + +=item DESCRIPTION + +=item EXAMPLES + +=over + +=item Recommended Use + +=back + +=item CAVEATS + +=item AUTHOR + +=item ACKNOWLEDGEMENTS + =head2 SDBM_File - Tied access to sdbm files =item SYNOPSIS =item DESCRIPTION +=head2 Safe - Compile and execute code in restricted compartments + +=item SYNOPSIS + +=item DESCRIPTION + +a new namespace, an operator mask + +=item WARNING + +=over + +=item RECENT CHANGES + +=item Methods in class Safe + +permit (OP, ...), permit_only (OP, ...), deny (OP, ...), deny_only (OP, +...), trap (OP, ...), untrap (OP, ...), share (NAME, ...), share_from +(PACKAGE, ARRAYREF), varglob (VARNAME), reval (STRING), rdo (FILENAME), +root (NAMESPACE), mask (MASK) + +=item Some Safety Issues + +Memory, CPU, Snooping, Signals, State Changes + +=item AUTHOR + +=back + =head2 Search::Dict, look - search for key in dictionary file =item SYNOPSIS @@ -5511,7 +6996,7 @@ C<tkRunning>, C<ornaments>, C<newTTY> =item ENVIRONMENT -=head2 Test - provides a simple framework for writing test scripts +=head2 Test - provides a simple framework for writing test scripts =item SYNOPSIS @@ -5521,6 +7006,8 @@ C<tkRunning>, C<ornaments>, C<newTTY> NORMAL TESTS, SKIPPED TESTS, TODO TESTS +=item RETURN VALUE + =item ONFAIL =item SEE ALSO @@ -5613,8 +7100,6 @@ unexpand(1) =item EXAMPLE -=item BUGS - =item AUTHOR =head2 Thread - multithreading @@ -5627,11 +7112,11 @@ unexpand(1) new \&start_sub, new \&start_sub, LIST, lock VARIABLE, async BLOCK;, Thread->self, Thread->list, cond_wait VARIABLE, cond_signal VARIABLE, -cond_broadcast VARIABLE +cond_broadcast VARIABLE, yield =item METHODS -join, eval, tid +join, eval, detach, equal, tid =item LIMITATIONS @@ -5671,11 +7156,13 @@ new, new NUMBER, down, down NUMBER, up, up NUMBER =item SYNOPSIS +=item DESCRIPTION + =head2 Tie::Array - base class for tied arrays -=item SYNOPSIS +=item SYNOPSIS -=item DESCRIPTION +=item DESCRIPTION TIEARRAY classname, LIST, STORE this, index, value, FETCH this, index, FETCHSIZE this, STORESIZE this, count, EXTEND this, count, CLEAR this, @@ -5686,7 +7173,8 @@ SPLICE this, offset, length, LIST =item AUTHOR -=head2 Tie::Handle - base class definitions for tied handles +=head2 Tie::Handle, Tie::StdHandle - base class definitions for tied +handles =item SYNOPSIS @@ -5694,7 +7182,8 @@ SPLICE this, offset, length, LIST TIEHANDLE classname, LIST, WRITE this, scalar, length, offset, PRINT this, LIST, PRINTF this, format, LIST, READ this, scalar, length, offset, -READLINE this, GETC this, DESTROY this +READLINE this, GETC this, CLOSE this, OPEN this, filename, BINMODE this, +EOF this, TELL this, SEEK this, offset, whence, DESTROY this =item MORE INFORMATION @@ -5750,6 +7239,10 @@ TIESCALAR classname, LIST, FETCH this, STORE this, value, DESTROY this =item DESCRIPTION +=item IMPLEMENTATION + +=item BUGS + =head2 Time::gmtime - by-name interface to Perl's built-in gmtime() function diff --git a/pod/perlvar.pod b/pod/perlvar.pod index b9c8195d08..cb41c96aa0 100644 --- a/pod/perlvar.pod +++ b/pod/perlvar.pod @@ -7,9 +7,9 @@ perlvar - Perl predefined variables =head2 Predefined Names The following names have special meaning to Perl. Most -punctuation names have reasonable mnemonics, or analogues in one of -the shells. Nevertheless, if you wish to use long variable names, -you just need to say +punctuation names have reasonable mnemonics, or analogs in the +shells. Nevertheless, if you wish to use long variable names, +you need only say use English; @@ -32,12 +32,12 @@ or more safely, HANDLE->method(EXPR) -Each of the methods returns the old value of the IO::Handle attribute. +Each method returns the old value of the IO::Handle attribute. The methods each take an optional EXPR, which if supplied specifies the new value for the IO::Handle attribute in question. If not supplied, -most of the methods do nothing to the current value, except for +most methods do nothing to the current value--except for autoflush(), which will assume a 1 for you, just to be different. -It costs quite a bit to load in the IO::Handle class, so you should +Because loading in the IO::Handle class is an expensive operation, you should learn how to use the regular built-in variables. A few of these variables are considered "read-only". This means that if @@ -46,7 +46,7 @@ a reference, you'll raise a run-time exception. The following list is ordered by scalar variables first, then the arrays, then the hashes (except $^M was added in the wrong place). -This is somewhat obscured by the fact that %ENV and %SIG are listed as +This is somewhat obscured because %ENV and %SIG are listed as $ENV{expr} and $SIG{expr}. =over 8 @@ -103,7 +103,7 @@ The implicit iterator variable in the grep() and map() functions. The default place to put an input record when a C<E<lt>FHE<gt>> operation's result is tested by itself as the sole criterion of a C<while> -test. Outside of a C<while> test, this will not happen. +test. Outside a C<while> test, this will not happen. =back @@ -186,8 +186,8 @@ Thus after a match against $_, $& coincides with C<substr $_, $-[0], $+[0] - $-[0]>. Similarly, C<$>I<n> coincides with C<substr $_, $-[>I<n>C<], $+[>I<n>C<] - $-[>I<n>C<]> if C<$-[>I<n>C<]> is defined, and $+ coincides with C<substr $_, $-[$#-], $+[$#-]>. One can use C<$#+> to find the number -of subgroups in the last successful match. Note the difference with -C<$#->, which is the last I<matched> subgroup. Compare with C<@->. +of subgroups in the last successful match. Contrast with +C<$#->, the last I<matched> subgroup. Compare with C<@->. =item $MULTILINE_MATCHING @@ -213,7 +213,7 @@ the C</s> and C</m> modifiers on pattern matching. =item $. The current input record number for the last file handle from which -you just read() (or performed a C<seek> or C<tell> on). The value +you just read() (or called a C<seek> or C<tell> on). The value may be different from the actual physical line number in the file, depending on what notion of "line" is in effect--see C<$/> on how to change that. An explicit close on a filehandle resets the line @@ -221,7 +221,7 @@ number. Because C<E<lt>E<gt>> never does an explicit close, line numbers increase across ARGV files (but see examples in L<perlfunc/eof>). Consider this variable read-only: setting it does not reposition the seek pointer; you'll have to do that on your own. (Mnemonic: -many programs use "." to mean the current line number.) +many programs use "." to mean the current line number.) =item input_record_separator HANDLE EXPR @@ -231,18 +231,18 @@ many programs use "." to mean the current line number.) =item $/ -The input record separator, newline by default. This is used to -influence Perl's idea of what a "line" is. Works like B<awk>'s RS +The input record separator, newline by default. This +influences Perl's idea of what a "line" is. Works like B<awk>'s RS variable, including treating empty lines as a terminator if set to -the null string. (Note: An empty line cannot contain any spaces -or tabs.) You may set it to a multi-character string to match a +the null string. (An empty line cannot contain any spaces +or tabs.) You may set it to a multi-character string to match a multi-character terminator, or to C<undef> to read through the end of file. Setting it to C<"\n\n"> means something slightly different than setting to C<"">, if the file contains consecutive empty lines. Setting to C<""> will treat two or more consecutive empty lines as a single empty line. Setting to C<"\n\n"> will blindly assume that the next input character belongs to the next -paragraph, even if it's a newline. (Mnemonic: / is used to delimit +paragraph, even if it's a newline. (Mnemonic: / delimits line boundaries when quoting poetry.) undef $/; # enable "slurp" mode @@ -271,10 +271,10 @@ On VMS, record reads are done with the equivalent of C<sysread>, so it's best not to mix record and non-record reads on the same file. (This is unlikely to be a problem, because any file you'd want to read in record mode is probably usable in line mode.) -Non-VMS systems perform normal I/O, so it's safe to mix record and +Non-VMS systems do normal I/O, so it's safe to mix record and non-record reads of a file. -Also see C<$.>. +See also L<perlport/"Newlines">. Also see C<$.>. =item autoflush HANDLE EXPR @@ -284,7 +284,7 @@ Also see C<$.>. If set to nonzero, forces a flush right away and after every write or print on the currently selected output channel. Default is 0 -(regardless of whether the channel is actually buffered by the +(regardless of whether the channel is really buffered by the system or not; C<$|> tells you only whether you've asked Perl explicitly to flush after each write). STDOUT will typically be line buffered if output is to the terminal and block @@ -372,7 +372,7 @@ in L<perllol>. The output format for printed numbers. This variable is a half-hearted attempt to emulate B<awk>'s OFMT variable. There are times, however, -when B<awk> and Perl have differing notions of what is in fact +when B<awk> and Perl have differing notions of what counts as numeric. The initial value is "%.I<n>g", where I<n> is the value of the macro DBL_DIG from your system's F<float.h>. This is different from B<awk>'s default OFMT setting of "%.6g", so you need to set C<$#> @@ -422,8 +422,8 @@ Thus after a match against $_, $& coincides with C<substr $_, $-[0], $+[0] - $-[0]>. Similarly, C<$>I<n> coincides with C<substr $_, $-[>I<n>C<], $+[>I<n>C<] - $-[>I<n>C<]> if C<$-[>I<n>C<]> is defined, and $+ coincides with C<substr $_, $-[$#-], $+[$#-]>. One can use C<$#-> to find the last -matched subgroup in the last successful match. Note the difference with -C<$#+>, which is the number of subgroups in the regular expression. Compare +matched subgroup in the last successful match. Contrast with +C<$#+>, the number of subgroups in the regular expression. Compare with C<@+>. =item format_name HANDLE EXPR @@ -433,7 +433,7 @@ with C<@+>. =item $~ The name of the current report format for the currently selected output -channel. Default is name of the filehandle. (Mnemonic: brother to +channel. Default is the name of the filehandle. (Mnemonic: brother to C<$^>.) =item format_top_name HANDLE EXPR @@ -443,7 +443,7 @@ C<$^>.) =item $^ The name of the current top-of-page format for the currently selected -output channel. Default is name of the filehandle with _TOP +output channel. Default is the name of the filehandle with _TOP appended. (Mnemonic: points to top of page.) =item format_line_break_characters HANDLE EXPR @@ -463,7 +463,7 @@ poetry is a part of a line.) =item $^L -What formats output to perform a form feed. Default is \f. +What formats output as a form feed. Default is \f. =item $ACCUMULATOR @@ -472,7 +472,7 @@ What formats output to perform a form feed. Default is \f. The current value of the write() accumulator for format() lines. A format contains formline() calls that put their result into C<$^A>. After calling its format, write() prints out the contents of C<$^A> and empties. -So you never actually see the contents of C<$^A> unless you call +So you never really see the contents of C<$^A> unless you call formline() yourself and then look at it. See L<perlform> and L<perlfunc/formline()>. @@ -484,13 +484,13 @@ The status returned by the last pipe close, backtick (C<``>) command, successful call to wait() or waitpid(), or from the system() operator. This is just the 16-bit status word returned by the wait() system call (or else is made up to look like it). Thus, the -exit value of the subprocess is actually (C<$? E<gt>E<gt> 8>), and +exit value of the subprocess is really (C<$? E<gt>E<gt> 8>), and C<$? & 127> gives which signal, if any, the process died from, and C<$? & 128> reports whether there was a core dump. (Mnemonic: similar to B<sh> and B<ksh>.) Additionally, if the C<h_errno> variable is supported in C, its value -is returned via $? if any of the C<gethost*()> functions fail. +is returned via $? if any C<gethost*()> function fails. If you have installed a signal handler for C<SIGCHLD>, the value of C<$?> will usually be wrong outside that handler. @@ -602,7 +602,7 @@ The effective uid of this process. Example: ($<,$>) = ($>,$<); # swap real and effective uid (Mnemonic: it's the uid you went I<to>, if you're running setuid.) -Note: C<$E<lt>> and C<$E<gt>> can be swapped only on machines +C<$E<lt>> and C<$E<gt>> can be swapped only on machines supporting setreuid(). =item $REAL_GROUP_ID @@ -637,7 +637,7 @@ returned by getegid(), and the subsequent ones by getgroups(), one of which may be the same as the first number. Similarly, a value assigned to C<$)> must also be a space-separated -list of numbers. The first number is used to set the effective gid, and +list of numbers. The first number sets the effective gid, and the rest (if any) are passed to setgroups(). To get the effect of an empty list for setgroups(), just repeat the new effective gid; that is, to force an effective gid of 5 and an effectively empty setgroups() @@ -646,7 +646,7 @@ list, say C< $) = "5 5" >. (Mnemonic: parentheses are used to I<group> things. The effective gid is the group that's I<right> for you, if you're running setgid.) -Note: C<$E<lt>>, C<$E<gt>>, C<$(> and C<$)> can be set only on +C<$E<lt>>, C<$E<gt>>, C<$(> and C<$)> can be set only on machines that support the corresponding I<set[re][ug]id()> routine. C<$(> and C<$)> can be swapped only on machines supporting setregid(). @@ -830,7 +830,7 @@ contains the name of the current file when reading from E<lt>E<gt>. =item @ARGV The array @ARGV contains the command-line arguments intended for -the script. C<$#ARGV> is the generally number of arguments minus +the script. C<$#ARGV> is generally the number of arguments minus one, because C<$ARGV[0]> is the first argument, I<not> the program's command name itself. See C<$0> for the command name. @@ -858,7 +858,7 @@ subroutine. See L<perlsub>. The hash %INC contains entries for each filename included via the C<do>, C<require>, or C<use> operators. The key is the filename you specified (with module names converted to pathnames), and the -value is the location of the file actually found. The C<require> +value is the location of the file found. The C<require> operator uses this array to determine whether a particular file has already been included. @@ -874,8 +874,7 @@ you subsequently fork() off. =item $SIG{expr} -The hash %SIG is used to set signal handlers for various -signals. For example: +The hash %SIG contains signal handlers for signals. For example: sub handler { # 1st argument is signal name my($sig) = @_; @@ -1003,7 +1002,7 @@ C<errno> if one of these calls fails. Under a few operating systems, C<$^E> may contain a more verbose error indicator, such as in this case, "CDROM tray not closed." -Systems that do not support extended error mesages leave $C<$^E> +Systems that do not support extended error messages leave C<$^E> the same as C<$!>. Finally, C<$?> may be set to non-0 value if the external program |