X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=pod%2Fperldelta.pod;h=f2505e8dac579486f941b427a3504899cef87e47;hb=f7686833794ab18a8c8729b0e836f6f14223ce97;hp=bd109ef1227c7b7c7798c5082be9beb92e904698;hpb=191d61a768175782efd32a263e82c70bcb0d1401;p=p5sagit%2Fp5-mst-13.2.git diff --git a/pod/perldelta.pod b/pod/perldelta.pod index bd109ef..f2505e8 100644 --- a/pod/perldelta.pod +++ b/pod/perldelta.pod @@ -1,2537 +1,2335 @@ =head1 NAME -perldelta - what's new for perl v5.6 (as of v5.005_64) +perldelta - what is new for perl v5.8.0 =head1 DESCRIPTION -This is an unsupported alpha release, meant for intrepid Perl -developers only. The included sources may not even build correctly on -some platforms. Subscribing to perl5-porters is the best way to -monitor and contribute to the progress of development releases (see -http://www.hut.fi/~jhi/perl5-porters.html for info). - -This document describes differences between the 5.005 release and this one. +This document describes differences between the 5.6.0 release and the +5.8.0 release. =head1 Incompatible Changes -=head2 Perl Source Incompatibilities +=over 4 -Beware that any new warnings that have been added or old ones -that have been enhanced are B considered incompatible changes. +=item * -Since all new warnings must be explicitly requested via the C<-w> -switch or the C pragma, it is ultimately the programmer's -responsibility to ensure that warnings are enabled judiciously. +The semantics of bless(REF, REF) were unclear and until someone proves +it to make some sense, it is forbidden. -=over 4 - -=item CHECK is a new keyword +=item * -In addition to C, C, C, C and C, -subroutines named C are now special. These are queued up during -compilation and behave similar to END blocks, except they are called at -the end of compilation rather than at the end of execution. They cannot -be called directly. +A reference to a reference now stringify as "REF(0x81485ec)" instead +of "SCALAR(0x81485ec)" in order to be more consistent with the return +value of ref(). -=item Treatment of list slices of undef has changed +=item * -When taking a slice of a literal list (as opposed to a slice of -an array or hash), Perl used to return an empty list if the -result happened to be composed of all undef values. +The very dusty examples in the eg/ directory have been removed. +Suggestions for new shiny examples welcome but the main issue is that +the examples need to be documented, tested and (most importantly) +maintained. -The new behavior is to produce an empty list if (and only if) -the original list was empty. Consider the following example: +=item * - @a = (1,undef,undef,2)[2,1,2]; +The obsolete chat2 library that should never have been allowed +to escape the laboratory has been decommissioned. -The old behavior would have resulted in @a having no elements. -The new behavior ensures it has three undefined elements. +=item * -Note in particular that the behavior of slices of the following -cases remains unchanged: +The unimplemented POSIX regex features [[.cc.]] and [[=c=]] are still +recognised but now cause fatal errors. The previous behaviour of +ignoring them by default and warning if requested was unacceptable +since it, in a way, falsely promised that the features could be used. - @a = ()[1,2]; - @a = (getpwent)[7,0]; - @a = (anything_returning_empty_list())[2,1,2]; - @a = @b[2,1,2]; - @a = @c{'a','b','c'}; +=item * -See L. +The (bogus) escape sequences \8 and \9 now give an optional warning +("Unrecognized escape passed through"). There is no need to \-escape +any C<\w> character. -=head2 Perl's version numbering has changed +=item * -Beginning with Perl version 5.6, the version number convention has been -changed to a "dotted integer" scheme that is more commonly found in open -source projects. +lstat(FILEHANDLE) now gives a warning because the operation makes no sense. +In future releases this may become a fatal error. -Maintenance versions of v5.6.0 will be released as v5.6.1, v5.6.2 etc. -The next development series following v5.6 will be numbered v5.7.x, -beginning with v5.7.0, and the next major production release following -v5.6 will be v5.8. +=item * -The English module now sets $PERL_VERSION to $^V (a string value) rather -than C<$]> (a numeric value). (This is a potential incompatibility. -Send us a report via perlbug if you are affected by this.) +The long deprecated uppercase aliases for the string comparison +operators (EQ, NE, LT, LE, GE, GT) have now been removed. -The v1.2.3 syntax is also now legal in Perl. -See L for more on that. +=item * -To cope with the new versioning system's use of at least three significant -digits for each version component, the method used for incrementing the -subversion number has also changed slightly. We assume that versions older -than v5.6 have been incrementing the subversion component in multiples of -10. Versions after v5.6.0 will increment them by 1. Thus, using the new -notation, 5.005_03 is the same as v5.5.30, and the first maintenance -version following v5.6.0 will be v5.6.1, which amounts to a floating point -value of 5.006_001). +The regular expression captured submatches ($1, $2, ...) are now +more consistently unset if the match fails, instead of leaving false +data lying around in them. -=item Literals of the form C<1.2.3> parse differently +=item * -Previously, numeric literals with more than one dot in them were -interpreted as a floating point number concatenated with one or more -numbers. Such "numbers" are now parsed as strings composed of the -specified ordinals. +The tr///C and tr///U features have been removed and will not return; +the interface was a mistake. Sorry about that. For similar +functionality, see pack('U0', ...) and pack('C0', ...). -For example, C used to output C<97.9899> in earlier -versions, but now prints C. +=item * -See L below. +Although "you shouldn't do that", it was possible to write code that +depends on Perl's hashed key order (Data::Dumper does this). The new +algorithm "One-at-a-Time" produces a different hashed key order. +More details are in L. -=item Possibly changed pseudo-random number generator +=item * -In 5.005_0x and earlier, perl's rand() function used the C library -rand(3) function. As of 5.005_52, Configure tests for drand48(), -random(), and rand() (in that order) and picks the first one it finds. -Perl programs that depend on reproducing a specific set of pseudo-random -numbers will now likely produce different output. You can use -C to obtain the old behavior. +The list of filenames from glob() (or <...>) is now by default sorted +alphabetically to be csh-compliant. (bsd_glob() does still sort platform +natively, ASCII or EBCDIC, unless GLOB_ALPHASORT is specified.) -=item Hashing function for hash keys has changed +=back -Perl hashes are not order preserving. The apparently random order -encountered when iterating on the contents of a hash is determined -by the hashing algorithm used. To improve the distribution of lower -bits in the hashed value, the algorithm has changed slightly as of -5.005_52. When iterating over hashes, this may yield a random order -that is B from that of previous versions. +=head2 64-bit platforms and malloc + +If your pointers are 64 bits wide, the Perl malloc is no more being +used because it simply does not work with 8-byte pointers. Also, +usually the system malloc on such platforms are much better optimized +for such large memory models than the Perl malloc. + +=head2 AIX Dynaloading + +The AIX dynaloading now uses in AIX releases 4.3 and newer the native +dlopen interface of AIX instead of the old emulated interface. This +change will probably break backward compatibility with compiled +modules. The change was made to make Perl more compliant with other +applications like modperl which are using the AIX native interface. + +=head2 Socket Extension Dynamic in VMS + +The Socket extension is now dynamically loaded instead of being +statically built in. This may or may not be a problem with ancient +TCP/IP stacks of VMS: we do not know since we weren't able to test +Perl in such configurations. + +=head2 Different Definition of the Unicode Character Classes \p{In...} + +As suggested by the Unicode consortium, the Unicode character classes +now prefer I as opposed to I (as defined by Unicode); +in Perl, when the C<\p{In....}> and the C<\p{In....}> regular expression +constructs are used. This has changed the definition of some of those +character classes. + +The difference between scripts and blocks is that scripts are the +glyphs used by a language or a group of languages, while the blocks +are more artificial groupings of 256 characters based on the Unicode +numbering. + +In general this change results in more inclusive Unicode character +classes, but changes to the other direction also do take place: +for example while the script C includes all the Latin +characters and their various diacritic-adorned versions, it +does not include the various punctuation or digits (since they +are not solely C). + +Changes in the character class semantics may have happened if a script +and a block happen to have the same name, for example C. +In such cases the script wins and C<\p{InHebrew}> now means the script +definition of Hebrew. The block definition in still available, +though, by appending C to the name: C<\p{InHebrewBlock}> means +what C<\p{InHebrew}> meant in perl 5.6.0. For the full list +of affected character classes, see L. + +=head2 Deprecations + +The current user-visible implementation of pseudo-hashes (the weird +use of the first array element) is deprecated starting from Perl 5.8.0 +and will be removed in Perl 5.10.0, and the feature will be +implemented differently. Not only is the current interface rather +ugly, but the current implementation slows down normal array and hash +use quite noticeably. The C pragma interface will remain +available. + +The syntaxes C<@a->[...]> and C<@h->{...}> have now been deprecated. + +The suidperl is also considered to be too much a risk to continue +maintaining and the suidperl code is likely to be removed in a future +release. -=item C fails on read only values +The C syntax (C without an argument has been +deprecated. Its semantics were never that clear and its +implementation even less so. If you have used that feature to +disallow all but fully qualified variables, C instead. -Using the C operator on a readonly value (such as $1) has -the same effect as assigning C to the readonly value--it -throws an exception. +The chdir(undef) and chdir('') behaviors to match chdir() has been +deprecated. In future versions, chdir(undef) and chdir('') will +simply fail. -=item Close-on-exec bit may be set on pipe and socket handles +=head1 Core Enhancements -On systems that support a close-on-exec flag on filehandles, the -flag will be set for any handles created by pipe(), socketpair(), -socket(), and accept(), if that is warranted by the value of $^F -that may be in effect. Earlier versions neglected to set the flag -for handles created with these operators. See L, -L, L, L, -and L. +=over 4 -=item Writing C<"$$1"> to mean C<"${$}1"> is unsupported +=item * -Perl 5.004 deprecated the interpretation of C<$$1> and -similar within interpolated strings to mean C<$$ . "1">, -but still allowed it. +C now works (previously one couldn't pass +in multiple arguments.) -In Perl 5.6 and later, C<"$$1"> always means C<"${$1}">. +=item * -=item delete(), values() and C<\(%h)> operate on aliases to values, not copies +my __PACKAGE__ $obj now works. -delete(), each(), values() and hashes in a list context return the actual -values in the hash, instead of copies (as they used to in earlier -versions). Typical idioms for using these constructs copy the -returned values, but this can make a significant difference when -creating references to the returned values. +=item * -Keys in the hash are still returned as copies when iterating on -a hash. +C now works even if there is no "sub unimport" in the Module. -=item vec(EXPR,OFFSET,BITS) enforces powers-of-two BITS +=item * -vec() generates a run-time error if the BITS argument is not -a valid power-of-two integer. +The numerical comparison operators return C if either operand +is a NaN. Previously the behaviour was unspecified. -=item Text of some diagnostic output has changed +=item * -Most references to internal Perl operations in diagnostics -have been changed to be more descriptive. This may be an -issue for programs that may incorrectly rely on the exact -text of diagnostics for proper functioning. +C can now be used to force a string to UTF8. -=item C<%@> has been removed +=item * -The undocumented special variable C<%@> that used to accumulate -"background" errors (such as those that happen in DESTROY()) -has been removed, because it could potentially result in memory -leaks. +prototype(\&) is now available. -=item Parenthesized not() behaves like a list operator +=item * -The C operator now falls under the "if it looks like a function, -it behaves like a function" rule. +There is now an UNTIE method. -As a result, the parenthesized form can be used with C and C. -The following construct used to be a syntax error before, but it works -as expected now: +=back - grep not($_), @things; +=head2 AUTOLOAD Is Now Lvaluable -On the other hand, using C with a literal list slice may not -work. The following previously allowed construct: +AUTOLOAD is now lvaluable, meaning that you can add the :lvalue attribute +to AUTOLOAD subroutines and you can assign to the AUTOLOAD return value. - print not (1,2,3)[0]; +=head2 PerlIO is Now The Default -needs to be written with additional parentheses now: +=over 4 - print not((1,2,3)[0]); +=item * -The behavior remains unaffected when C is not followed by parentheses. +IO is now by default done via PerlIO rather than system's "stdio". +PerlIO allows "layers" to be "pushed" onto a file handle to alter the +handle's behaviour. Layers can be specified at open time via 3-arg +form of open: -=item Semantics of bareword prototype C<(*)> have changed + open($fh,'>:crlf :utf8', $path) || ... -Arguments prototyped as C<*> will now be visible within the subroutine -as either a simple scalar or as a reference to a typeglob. Perl 5.005 -always coerced simple scalar arguments to a typeglob, which wasn't useful -in situations where the subroutine must distinguish between a simple -scalar and a typeglob. See L. +or on already opened handles via extended C: -=head2 On 64-bit platforms the semantics of bit operators have changed + binmode($fh,':encoding(iso-8859-7)'); -If your platform is either natively 64-bit or your Perl has been -configured to used 64-bit integers (say C and see what is -your ivsize: if it is 8, you are 64-bit) , be warned that the -semantics of all the bitwise numeric operators (& | ^ ~ << >>) have -been changed. They used to be forced to be 32 bits wide, but now in -the aforementioned platforms they are 64 bits wide. Most dramatically -this affects the unary ~: what used to be 32 bits wide, is now 64 bits -wide. If you depend on your integers being 32 bits wide, mask off the -excess bits with C<& 0xffffffff>. +The built-in layers are: unix (low level read/write), stdio (as in +previous Perls), perlio (re-implementation of stdio buffering in a +portable manner), crlf (does CRLF <=> "\n" translation as on Win32, +but available on any platform). A mmap layer may be available if +platform supports it (mostly UNIXes). -=back +Layers to be applied by default may be specified via the 'open' pragma. -=head2 C Source Incompatibilities +See L for the effects +of PerlIO on your architecture name. -=over 4 +=item * -=item C +File handles can be marked as accepting Perl's internal encoding of Unicode +(UTF-8 or UTF-EBCDIC depending on platform) by a pseudo layer ":utf8" : -Release 5.005 grandfathered old global symbol names by providing preprocessor -macros for extension source compatibility. As of release 5.6, these -preprocessor definitions are not available by default. You need to explicitly -compile perl with C<-DPERL_POLLUTE> to get these definitions. For -extensions still using the old symbols, this option can be -specified via MakeMaker: + open($fh,">:utf8","Uni.txt"); - perl Makefile.PL POLLUTE=1 +Note for EBCDIC users: the pseudo layer ":utf8" is erroneously named +for you since it's not UTF-8 what you will be getting but instead +UTF-EBCDIC. See L, L, and +http://www.unicode.org/unicode/reports/tr16/ for more information. +In future releases this naming may change. -=item C +=item * -PERL_IMPLICIT_CONTEXT is automatically enabled whenever Perl is built -with one of -Dusethreads, -Dusemultiplicity, or both. It is not -intended to be enabled by users at this time. +File handles can translate character encodings from/to Perl's internal +Unicode form on read/write via the ":encoding()" layer. -This new build option provides a set of macros for all API functions -such that an implicit interpreter/thread context argument is passed to -every API function. As a result of this, something like C -amounts to a macro invocation that actually translates to something like -C. While this is generally expected -to not have any significant source compatibility issues, the difference -between a macro and a real function call will need to be considered. +=item * -This means that there B a source compatibility issue as a result of -this if your extensions attempt to use pointers to any of the Perl API -functions. +File handles can be opened to "in memory" files held in Perl scalars via: -Note that the above issue is not relevant to the default build of -Perl, whose interfaces continue to match those of prior versions -(but subject to the other options described here). + open($fh,'>', \$variable) || ... -See L for detailed information on the -ramifications of building Perl using this option. +=item * -=item C +Anonymous temporary files are available without need to +'use FileHandle' or other module via -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, since by default they used the -same names. + open($fh,"+>", undef) || ... -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 behaviour to be suppressed with the HIDEMYMALLOC and -EMBEDMYMALLOC preprocessor definitions. +That is a literal undef, not an undefined value. -As of release 5.6, 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> to get the older behaviour. HIDEMYMALLOC -and EMBEDMYMALLOC have no effect, since the behaviour they enabled is now -the default. +=item * -Note that these functions do B constitute Perl's memory allocation API. -See L for further information about that. +The list form of C is now implemented for pipes (at least on UNIX): -=back + open($fh,"-|", 'cat', '/etc/motd') -=head2 Compatible C Source API Changes +creates a pipe, and runs the equivalent of exec('cat', '/etc/motd') in +the child process. -=over +=item * -=item C is now C +The following builtin functions are now overridable: chop(), chomp(), +each(), keys(), pop(), push(), shift(), splice(), unshift(). -The cpp macros C, C, and C -are now available by default from perl.h, and reflect the base revision, -patchlevel, and subversion respectively. C had no -prior equivalent, while C and C were -previously available as C and C. +=item * -The new names cause less pollution of the B namespace and reflect what -the numbers have come to stand for in common practice. For compatibility, -the old names are still supported when F is explicitly -included (as required before), so there is no source incompatibility -from the change. +Formats now support zero-padded decimal fields. -=item Support for C++ exceptions +=item * -change#3386, also needs perlguts documentation -[TODO - Chip Salzenberg ] +Perl now tries internally to use integer values in numeric conversions +and basic arithmetics (+ - * /) if the arguments are integers, and +tries also to keep the results stored internally as integers. +This change leads into often slightly faster and always less lossy +arithmetics. (Previously Perl always preferred floating point numbers +in its math.) -=back +=item * -=head2 Binary Incompatibilities +The printf() and sprintf() now support parameter reordering using the +C<%\d+\$> and C<*\d+\$> syntaxes. For example -In general, the default build of this release is expected to be binary -compatible for extensions built with the 5.005 release or its maintenance -versions. However, specific platforms may have broken binary compatibility -due to changes in the defaults used in hints files. Therefore, please be -sure to always check the platform-specific README files for any notes to -the contrary. + print "%2\$s %1\$s\n", "foo", "bar"; -The usethreads or usemultiplicity builds are B binary compatible -with the corresponding builds in 5.005. +will print "bar foo\n"; This feature helps in writing +internationalised software. -On platforms that require an explicit list of exports (AIX, OS/2 and Windows, -among others), purely internal symbols such as parser functions and the -run time opcodes are not exported by default. Perl 5.005 used to export -all functions irrespective of whether they were considered part of the -public API or not. +=item * -For the full list of public API functions, see L. +Unicode in general should be now much more usable. Unicode can be +used in hash keys, Unicode in regular expressions should work now, +Unicode in tr/// should work now (though tr/// seems to be a +particularly tricky to get right, so you have been warned) -=head1 Installation and Configuration Improvements +=item * -=head2 -Dusethreads means something different +The Unicode Character Database coming with Perl has been upgraded +to Unicode 3.1. For more information, see http://www.unicode.org/, +and http://www.unicode.org/unicode/reports/tr27/ -WARNING: Support for threads continues to be an experimental feature. -Interfaces and implementation are subject to sudden and drastic changes. +For developers interested in enhancing Perl's Unicode capabilities: +almost all the UCD files are included with the Perl distribution in +the lib/unicode subdirectory. The most notable omission, for space +considerations, is the Unihan database. -The -Dusethreads flag now enables the experimental interpreter-based thread -support by default. To get the flavor of experimental threads that was in -5.005 instead, you need to run Configure with "-Dusethreads -Duse5005threads". +=item * -As of v5.5.640, interpreter-threads support is still lacking a way to -create new threads from Perl (i.e., C will not work with -interpreter threads). C continues to be available when you -ask for use5005threads, bugs and all. +The Unicode character classes \p{Blank} and \p{SpacePerl} have been +added. "Blank" is like C isblank(), that is, it contains only +"horizontal whitespace" (the space character is, the newline isn't), +and the "SpacePerl" is the Unicode equivalent of C<\s> (\p{Space} +isn't, since that includes the vertical tabulator character, whereas +C<\s> doesn't.) -=head2 New Configure flags +=back -The following new flags may be enabled on the Configure command line -by running Configure with C<-Dflag>. +=head2 Signals Are Now Safe - usemultiplicity - usethreads useithreads (new interpreter threads: no Perl API yet) - usethreads use5005threads (threads as they were in 5.005) +Perl used to be fragile in that signals arriving at inopportune moments +could corrupt Perl's internal state. - use64bitint (equal to now deprecated 'use64bits') - use64bitall +=head2 Understanding of Numbers - uselongdouble - usemorebits - uselargefiles - usesocks (only SOCKS v5 supported) +In general a lot of fixing has happened in the area of Perl's +understanding of numbers, both integer and floating point. Since in +many systems the standard number parsing functions like C +and C seem to have bugs, Perl tries to work around their +deficiencies. This results hopefully in more accurate numbers. -=head2 Threadedness and 64-bitness now more daring +=over 4 -The Configure options enabling the use of threads and the use of -64-bitness are now more daring in the sense that they no more have an -explicit list of operating systems of known threads/64-bit -capabilities. In other words: if your operating system has the -necessary APIs and datatypes, you should be able just to go ahead and -use them, for threads by Configure -Dusethreads, and for 64 bits -either explicitly by Configure -Duse64bitint or implicitly if your -system has 64 bit wide datatypes. See also L<"64-bit support">. +=item * -=head2 Long Doubles +The rules for allowing underscores (underbars) in numeric constants +have been relaxed and simplified: now you can have an underscore +B. -Some platforms have "long doubles", floating point numbers of even -larger range than ordinary "doubles". To enable using long doubles for -Perl's scalars, use -Duselongdouble. +=item * -=head2 -Dusemorebits +GMAGIC (right-hand side magic) could in many cases such as string +concatenation be invoked too many times. -You can enable both -Duse64bitint and -Dlongdouble by -Dusemorebits. -See also L<"64-bit support">. +=item * -=head2 -Duselargefiles +Lexicals I: lexicals outside an eval "" weren't resolved +correctly inside a subroutine definition inside the eval "" if they +were not already referenced in the top level of the eval""ed code. -Some platforms support large files, files larger than two gigabytes. -See L<"Large file support"> for more information. +=item * -=head2 installusrbinperl +Lexicals II: lexicals leaked at file scope into subroutines that +were declared before the lexicals. -You can use "Configure -Uinstallusrbinperl" which causes installperl -to skip installing perl also as /usr/bin/perl. This is useful if you -prefer not to modify /usr/bin for some reason or another but harmful -because many scripts assume to find Perl in /usr/bin/perl. +=item * -=head2 SOCKS support +Lvalue subroutines can now return C in list context. -You can use "Configure -Dusesocks" which causes Perl to probe -for the SOCKS (v5, not v4) proxy protocol library, -http://www.socks.nec.com/ +=item * -=head2 C<-A> flag +The C and C are now exported. -You can "post-edit" the Configure variables using the Configure C<-A> -flag. The editing happens immediately after the platform specific -hints files have been processed but before the actual configuration -process starts. Run C to find out the full C<-A> syntax. +=item * -=head2 Enhanced Installation Directories +A new special regular expression variable has been introduced: +C<$^N>, which contains the most-recently closed group (submatch). -The installation structure has been enriched to improve the support -for maintaining multiple versions of perl, to provide locations for -vendor-supplied modules, scripts, and manpages, and to ease maintenance -of locally-added modules, scripts, and manpages. See the section on -Installation Directories in the INSTALL file for complete details. -For most users building and installing from source, the defaults should -be fine. +=item * -If you previously used C or C<-Dsitearch> to set -special values for library directories, you might wish to consider using -the new C<-Dsiteprefix> setting instead. Also, if you wish to re-use a -config.sh file from an earlier version of perl, you should be sure to -check that Configure makes sensible choices for the new directories. -See INSTALL for complete details. +L now supports C to change the +file timestamps to the current time. -=head1 Core Changes +=item * -=head2 Unicode and UTF-8 support +The Perl parser has been stress tested using both random input and +Markov chain input. -Perl can optionally use UTF-8 as its internal representation for character -strings. The C and C pragmas are used to control this support -in the current lexical scope. See L, L and L for -more information. +=item * -=head2 Interpreter cloning, threads, and concurrency +C now works. -WARNING: This is an experimental feature in a pre-alpha state. Use -at your own risk. +=item * -Perl 5.005_63 introduces the beginnings of support for running multiple -interpreters concurrently in different threads. In conjunction with -the perl_clone() API call, which can be used to selectively duplicate -the state of any given interpreter, it is possible to compile a -piece of code once in an interpreter, clone that interpreter -one or more times, and run all the resulting interpreters in distinct -threads. +VMS now works under PerlIO. -On Windows, this feature is used to emulate fork() at the interpreter -level. See L. - -This feature is still in evolution. It is eventually meant to be used -to selectively clone a subroutine and data reachable from that -subroutine in a separate interpreter and run the cloned subroutine -in a separate thread. Since there is no shared data between the -interpreters, little or no locking will be needed (unless parts of -the symbol table are explicitly shared). This is obviously intended -to be an easy-to-use replacement for the existing threads support. - -Support for cloning interpreters and interpreter concurrency can be -enabled using the -Dusethreads Configure option (see win32/Makefile for -how to enable it on Windows.) The resulting perl executable will be -functionally identical to one that was built with -Dmultiplicity, but -the perl_clone() API call will only be available in the former. - --Dusethreads enables, the cpp macros USE_ITHREADS by default, which enables -Perl source code changes that provide a clear separation between the op tree -and the data it operates with. The former is considered immutable, and can -therefore be shared between an interpreter and all of its clones, while the -latter is considered local to each interpreter, and is therefore copied for -each clone. +=item * -Note that building Perl with the -Dusemultiplicity Configure option -is adequate if you wish to run multiple B interpreters -concurrently in different threads. -Dusethreads only provides the -additional functionality of the perl_clone() API call and other -support for running B interpreters concurrently. +END blocks are now run even if you exit/die in a BEGIN block. +The execution of END blocks is now controlled by +PL_exit_flags & PERL_EXIT_DESTRUCT_END. This enables the new +behaviour for perl embedders. This will default in 5.10. See +L. -[XXX TODO - the Compiler backends may be broken when USE_ITHREADS is -enabled.] +=back -=head2 Lexically scoped warning categories - -You can now control the granularity of warnings emitted by perl at a finer -level using the C pragma. See L and L -for details. - -=head2 Lvalue subroutines - -WARNING: This is an experimental feature. - -change#4081 -[TODO - Ilya Zakharevich , -Tuomas Lukka )] - -=head2 "our" declarations - -An "our" declaration introduces a value that can be best understood -as a lexically scoped symbolic alias to a global variable in the -package that was current where the variable was declared. This is -mostly useful as an alternative to the C pragma, but also provides -the opportunity to introduce typing and other attributes for such -variables. See L. - -=head2 Support for strings represented as a vector of ordinals - -Literals of the form C are now parsed as a string composed of -of characters with the specified ordinals. This is an alternative, more -readable way to construct (possibly unicode) strings instead of -interpolating characters, as in C<"\x{1}\x{2}\x{3}\x{4}">. The leading -C may be omitted if there are more than two ordinals, so C<1.2.3> is -parsed the same as C. - -Strings written in this form are also useful to represent version "numbers". -It is easy to compare such version "numbers" (which are really just plain -strings) using any of the usual string comparison operators C, C, -C, C, etc., or perform bitwise string operations on them using C<|>, -C<&>, etc. - -In conjunction with the new C<$^V> magic variable (which contains -the perl version as a string), such literals can be used as a readable way -to check if you're running a particular version of Perl: - - # this will parse in older versions of Perl also - if ($^V and $^V gt v5.5.640) { - # new features supported - } +=head1 Modules and Pragmata -C and C also have some special magic to support such literals. -They will be interpreted as a version rather than as a module name: +=head2 New Modules - require v5.6.0; # croak if $^V lt v5.6.0 - use v5.6.0; # same, but croaks at compile-time +=over 4 -Alternatively, the C may be omitted if there is more than one dot: +=item * - require 5.6.0; - use 5.6.0; +File::Temp allows one to create temporary files and directories in an +easy, portable, and secure way. -Also, C and C support the Perl-specific format flag C<%v> -to print ordinals of characters in arbitrary strings: +=item * - printf "v%vd", $^V; # prints current version, such as "v5.5.650" - printf "%*vX", ":", $addr; # formats IPv6 address - printf "%*vb", " ", $bits; # displays bitstring +Storable gives persistence to Perl data structures by allowing the +storage and retrieval of Perl data to and from files in a fast and +compact binary format. -See L for additional information. +=item * -=head2 Weak references +B::Concise, by Stephen McCamant, is a new compiler backend for +walking the Perl syntax tree, printing concise info about ops. +The output is highly customisable. -WARNING: This is an experimental feature. +See L for more information. -In previous versions of Perl, you couldn't cache objects so as -to allow them to be deleted if the last reference from outside -the cache is deleted. The reference in the cache would hold a -reference count on the object and the objects would never be -destroyed. +=item * -Another familiar problem is with circular references. When an -object references itself, its reference count would never go -down to zero, and it would not get destroyed until the program -is about to exit. +Class::ISA, by Sean Burke, for reporting the search path for a +class's ISA tree, has been added. -Weak references solve this by allowing you to "weaken" any -reference, that is, make it not count towards the reference count. -When the last non-weak reference to an object is deleted, the object -is destroyed and all the weak references to the object are -automatically undef-ed. +See L for more information. -To use this feature, you need the WeakRef package from CPAN, which -contains additional documentation. +=item * -change#3385, also need perlguts documentation -[TODO - Tuomas Lukka ] +Cwd has now a split personality: if possible, an extension is used, +(this will hopefully be both faster and more secure and robust) but +if not possible, the familiar Perl library implementation is used. -=head2 File globbing implemented internally +=item * -WARNING: This is currently an experimental feature. Interfaces and -implementation are likely to change. +Digest, a frontend module for calculating digests (checksums), +from Gisle Aas, has been added. -Perl now uses the File::Glob implementation of the glob() operator -automatically. This avoids using an external csh process and the -problems associated with it. +See L for more information. -=head2 Binary numbers supported +=item * -Binary numbers are now supported as literals, in s?printf formats, and -C: +Digest::MD5 for calculating MD5 digests (checksums), by Gisle Aas, +has been added. - $answer = 0b101010; - printf "The answer is: %b\n", oct("0b101010"); + use Digest::MD5 'md5_hex'; -=head2 Some arrows may be omitted in calls through references + $digest = md5_hex("Thirsty Camel"); -Perl now allows the arrow to be omitted in many constructs -involving subroutine calls through references. For example, -C<$foo[10]-E('foo')> may now be written C<$foo[10]('foo')>. -This is rather similar to how the arrow may be omitted from -C<$foo[10]-E{'foo'}>. Note however, that the arrow is still -required for C('bar')>. + print $digest, "\n"; # 01d19d9d2045e005c3f1b80e8b164de1 -=head2 exists() is supported on subroutine names +NOTE: the MD5 backward compatibility module is deliberately not +included since its use is discouraged. -The exists() builtin now works on subroutine names. A subroutine -is considered to exist if it has been declared (even if implicitly). -See L for examples. +See L for more information. -=head2 exists() and delete() are supported on array elements +=item * -The exists() and delete() builtins now work on simple arrays as well. -The behavior is similar to that on hash elements. +Encode, by Nick Ing-Simmons, provides a mechanism to translate +between different character encodings. Support for Unicode, +ISO-8859-*, ASCII, CP*, KOI8-R, and three variants of EBCDIC are +compiled in to the module. Several other encodings (like Japanese, +Chinese, and MacIntosh encodings) are included and will be loaded at +runtime. -exists() can be used to check whether an array element has been -initialized. This avoids autovivifying array elements that don't exist. -If the array is tied, the EXISTS() method in the corresponding tied -package will be invoked. +Any encoding supported by Encode module is also available to the +":encoding()" layer if PerlIO is used. -delete() may be used to remove an element from the array and return -it. The array element at that position returns to its unintialized -state, so that testing for the same element with exists() will return -false. If the element happens to be the one at the end, the size of -the array also shrinks up to the highest element that tests true for -exists(), or 0 if none such is found. If the array is tied, the DELETE() -method in the corresponding tied package will be invoked. +See L for more information. -See L and L for examples. +=item * -=head2 syswrite() ease-of-use +Filter::Simple is an easy-to-use frontend to Filter::Util::Call, +from Damian Conway. -The length argument of C has become optional. + # in MyFilter.pm: -=head2 File and directory handles can be autovivified + package MyFilter; -Similar to how constructs such as C<$x-E[0]> autovivify a reference, -handle constructors (open(), opendir(), pipe(), socketpair(), sysopen(), -socket(), and accept()) now autovivify a file or directory handle -if the handle passed to them is an uninitialized scalar variable. This -allows the constructs such as C and C -to be used to create filehandles that will conveniently be closed -automatically when the scope ends, provided there are no other references -to them. This largely eliminates the need for typeglobs when opening -filehandles that must be passed around, as in the following example: + use Filter::Simple sub { + while (my ($from, $to) = splice @_, 0, 2) { + s/$from/$to/g; + } + }; - sub myopen { - open my $fh, "@_" - or die "Can't open '@_': $!"; - return $fh; - } + 1; - { - my $f = myopen("; - # $f implicitly closed here - } + # in user's code: -[TODO - this idiom needs more pod penetration] + use MyFilter qr/red/ => 'green'; -=head2 64-bit support + print "red\n"; # this code is filtered, will print "green\n" + print "bored\n"; # this code is filtered, will print "bogreen\n" - NOTE: The Configure flags -Duselonglong and -Duse64bits - have been deprecated. Use -Duse64bitint instead. + no MyFilter; -Any platform that has 64-bit integers either (a) natively as longs or -ints (b) via special compiler flags (c) using long long are able to -use "quads" (64-integers) as follows: + print "red\n"; # this code is not filtered, will print "red\n" -=over 4 +See L for more information. =item * -constants (decimal, hexadecimal, octal, binary) in the code +Filter::Util::Call, by Paul Marquess, provides you with the +framework to write I in Perl. For most uses +the frontend Filter::Simple is to be preferred. +See L for more information. =item * -arguments to oct() and hex() +Locale::Constants, Locale::Country, Locale::Currency, and Locale::Language, +from Neil Bowers, have been added. They provide the codes for various +locale standards, such as "fr" for France, "usd" for US Dollar, and +"jp" for Japanese. -=item * + use Locale::Country; -arguments to print(), printf() and sprintf() (flag prefixes ll, L, q) + $country = code2country('jp'); # $country gets 'Japan' + $code = country2code('Norway'); # $code gets 'no' + +See L, L, L, +and L for more information. =item * -printed as such +MIME::Base64, by Gisle Aas, allows you to encode data in base64. -=item * + use MIME::Base64; + + $encoded = encode_base64('Aladdin:open sesame'); + $decoded = decode_base64($encoded); -pack() and unpack() "q" and "Q" formats + print $encoded, "\n"; # "QWxhZGRpbjpvcGVuIHNlc2FtZQ==" + +See L for more information. =item * -in basic arithmetics: + - * / % (NOTE: operating close to the limits -of the integer values may produce surprising results) +MIME::QuotedPrint, by Gisle Aas, allows you to encode data in +quoted-printable encoding. + + use MIME::QuotedPrint; + + $encoded = encode_qp("Smiley in Unicode: \x{263a}"); + $decoded = decode_qp($encoded); + + print $encoded, "\n"; # "Smiley in Unicode: =263A" + +MIME::QuotedPrint has been enhanced to provide the basic methods +necessary to use it with PerlIO::Via as in : + + use MIME::QuotedPrint; + open($fh,">Via(MIME::QuotedPrint)",$path) + +See L for more information. =item * -in bit arithmetics: & | ^ ~ << >> (NOTE: these used to be forced -to be 32 bits wide.) +PerlIO::Scalar, by Nick Ing-Simmons, provides the implementation of +IO to "in memory" Perl scalars as discussed above. It also serves as +an example of a loadable layer. Other future possibilities include +PerlIO::Array and PerlIO::Code. See L for more +information. =item * -vec() +PerlIO::Via, by Nick Ing-Simmons, acts as a PerlIO layer and wraps +PerlIO layer functionality provided by a class (typically implemented +in perl code). -=back + use MIME::QuotedPrint; + open($fh,">Via(MIME::QuotedPrint)",$path) + +This will automatically convert everything output to C<$fh> +to Quoted-Printable. See L for more information. -Note that unless you have the case (a) you will have to configure -and compile Perl using the -Duse64bitint Configure flag. +=item * -There are actually two modes of 64-bitness: the first one is achieved -using Configure -Duse64bitint and the second one using Configure --Duse64bitall. The difference is that the first one is minimal and -the second one maximal. The first one does only as much as is -required to get 64-bit integers into Perl (this may mean, for example, -using "long longs") while your memory may still be limited to 2 -gigabytes (because your pointers most likely are 32-bit); the second -one goes all the way by attempting to switch also longs (and pointers) -being 64-bit. This may create an even more binary incompatible Perl -than -Duse64bitint: the resulting executable may not run at all in a -CPU-bit box, or you may have to reboot/reconfigure/rebuild your -operating system to be 64-bit aware. +Pod::Text::Overstrike, by Joe Smith, has been added. +It converts POD data to formatted overstrike text. +See L for more information. -Natively 64-bit systems like Alpha and Cray need neither -Duse64bitint -nor -Duse64bitall. +=item * -Last but not least: note that due to Perl's habit of always using -floating point numbers the quads are still not true integers. -When quads overflow their limits (0...18_446_744_073_709_551_615 unsigned, --9_223_372_036_854_775_808...9_223_372_036_854_775_807 signed), they -are silently promoted to floating point numbers, after which they will -start losing precision (their lower digits). +Switch from Damian Conway has been added. Just by saying -=head2 Large file support + use Switch; -If you have filesystems that support "large files" (files larger than -2 gigabytes), you may now also be able to create and access them from -Perl. You have to use Configure -Duselargefiles. Turning on the -large file support turns on also the 64-bit support on many platforms. -Beware that unless your filesystem also supports "sparse files" seeking -to umpteen petabytes may be unadvisable. +you have C and C available in Perl. -Note that in addition to requiring a proper file system to do large -files you may also need to adjust your per-process (or your -per-system, or per-process-group, or per-user-group) maximum filesize -limits before running Perl scripts that try to handle large files, -especially if you intend to write such files. + use Switch; -Finally, in addition to your process/process group maximum filesize -limits, you may have quota limits on your filesystems that stop you -(your user id or your user group id) from using large files. + switch ($val) { -Adjusting your process/user/group/file system/operating system limits -is outside the scope of Perl core language. For process limits, you -may try increasing the limits using your shell's limits/limit/ulimit -command before running Perl. The BSD::Resource extension (not -included with the standard Perl distribution) may also be of use, it -offers the getrlimit/setrlimit interface that can be used to adjust -process resource usage limits, including the maximum filesize limit. + case 1 { print "number 1" } + case "a" { print "string a" } + case [1..10,42] { print "number in list" } + case (@array) { print "number in list" } + case /\w+/ { print "pattern" } + case qr/\w+/ { print "pattern" } + case (%hash) { print "entry in hash" } + case (\%hash) { print "entry in hash" } + case (\&sub) { print "arg to subroutine" } + else { print "previous case not true" } + } -=head2 Long doubles +See L for more information. -In some systems you may be able to use long doubles to enhance the -range and precision of your double precision floating point numbers -(that is, Perl's numbers). Use Configure -Duselongdouble to enable -this support (if it is available). +=item * -=head2 "more bits" +Text::Balanced from Damian Conway has been added, for +extracting delimited text sequences from strings. -You can "Configure -Dusemorebits" to turn on both the 64-bit support -and the long double support. + use Text::Balanced 'extract_delimited'; -=head2 Enhanced support for sort() subroutines + ($a, $b) = extract_delimited("'never say never', he never said", "'", ''); -Perl subroutines with a prototype of C<($$)> and XSUBs in general can -now be used as sort subroutines. In either case, the two elements to -be compared are passed as normal parameters in @_. See L. +$a will be "'never say never'", $b will be ', he never said'. -For unprototyped sort subroutines, the historical behavior of passing -the elements to be compared as the global variables $a and $b remains -unchanged. +In addition to extract_delimited() there are also extract_bracketed(), +extract_quotelike(), extract_codeblock(), extract_variable(), +extract_tagged(), extract_multiple(), gen_delimited_pat(), and +gen_extract_tagged(). With these you can implement rather advanced +parsing algorithms. See L for more information. -=head2 Better syntax checks on parenthesized unary operators +=item * -Expressions such as: +Tie::RefHash::Nestable, by Edward Avis, allows storing hash references +(unlike the standard Tie::RefHash) The module is contained within +Tie::RefHash. - print defined(&foo,&bar,&baz); - print uc("foo","bar","baz"); - undef($foo,&bar); +=item * -used to be accidentally allowed in earlier versions, and produced -unpredictable behaviour. Some produced ancillary warnings -when used in this way; others silently did the wrong thing. +XS::Typemap, by Tim Jenness, is a test extension that exercises XS +typemaps. Nothing gets installed but for extension writers the code +is worth studying. -The parenthesized forms of most unary operators that expect a single -argument now ensure that they are not called with more than one -argument, making the cases shown above syntax errors. The usual -behaviour of: +=item * - print defined &foo, &bar, &baz; - print uc "foo", "bar", "baz"; - undef $foo, &bar; +L - Simpler definition of attribute handlers -remains unchanged. See L. +=item * -=head2 POSIX character class syntax [: :] supported +L - generate XS code to import C header constants -For example to match alphabetic characters use /[[:alpha:]]/. -See L for details. +=item * -=head2 Improved C operator +L - query locale information -The C operator is now evaluated at compile time into a true list -instead of being replaced with a run time call to C. This -removes the confusing misbehaviour of C in scalar context, which -had inherited that behaviour from split(). +=item * -Thus: +L - functions for dealing with RFC3066-style language tags - $foo = ($bar) = qw(a b c); print "$foo|$bar\n"; +=item * -now correctly prints "3|a", instead of "2|a". +L - a collection of perl5 modules related to network programming -=head2 pack() format 'Z' supported +Perl installation leaves libnet unconfigured, use F to configure. -The new format type 'Z' is useful for packing and unpacking null-terminated -strings. See L. +=item * -=head2 pack() format modifier '!' supported +L - selection of general-utility list subroutines -The new format type modifier '!' is useful for packing and unpacking -native shorts, ints, and longs. See L. +=item * -=head2 pack() and unpack() support counted strings +L - framework for localization -The template character '/' can be used to specify a counted string -type to be packed or unpacked. See L. +=item * -=head2 Comments in pack() templates +L - Make your functions faster by trading space for time -The '#' character in a template introduces a comment up to -end of the line. This facilitates documentation of pack() -templates. +=item * -=head2 $^X variables may now have names longer than one character +L - pseudo-class for method redispatch -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 be written with explicit braces, as C<${^XY}> for example. -C<${^XYZ}> is synonymous with ${"\cXYZ"}. Variable names with more -than one control character, such as C<${^XY^Z}>, are illegal. +=item * -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. +L - selection of general-utility scalar subroutines -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'. All such variables -are reserved for future extensions, except those that begin with -C<^_>, which may be used by user programs and are guaranteed not to -acquire special meaning in any future version of Perl. +=item * -=head2 C implicit in subroutine attributes +L - yet another framework for writing test scripts -Formerly, if you wanted to mark a subroutine as being a method call or -as requiring an automatic lock() when it is entered, you had to declare -that with a C pragma in the body of the subroutine. -That can now be accomplished with declaration syntax, like this: +=item * - sub mymethod : locked method ; - ... - sub mymethod : locked method { - ... - } +L - Basic utilities for writing tests - sub othermethod :locked :method ; - ... - sub othermethod :locked :method { - ... - } +=item * +L - high resolution ualarm, usleep, and gettimeofday -(Note how only the first C<:> is mandatory, and whitespace surrounding -the C<:> is optional.) +=item * -F and F have been updated to keep the attributes -with the stubs they provide. See L. +L - Object Oriented time objects -=head2 Regular expression improvements +(Previously known as L.) -change#2827,2373,2372,2365,1813,1800,4112,4158,4215,4301 -[TODO - Ilya Zakharevich ] +=item * -=head2 Overloading improvements +L - a simple API to convert seconds to other date values -change#2150 -[TODO - Ilya Zakharevich ] +=item * -=head2 open() with more than two arguments +L - Unicode Character Database -[TODO - Ilya Zakharevich ] +=back -=head2 Support for interpolating named characters +=head2 Updated And Improved Modules and Pragmata -change#4052 -[TODO - Ilya Zakharevich ] +=over 4 -=head2 Experimental support for user-hooks in @INC +=item * -[TODO - Ken Fox ] +The following independently supported modules have been updated to +newer versions from CPAN: CGI, CPAN, DB_File, File::Spec, Getopt::Long, +the podlators bundle, Pod::LaTeX, Pod::Parser, Term::ANSIColor, Test. -=head2 C and C may be overridden +=item * -C and C operations may be overridden locally -by importing subroutines of the same name into the current package -(or globally by importing them into the CORE::GLOBAL:: namespace). -Overriding C will also affect C, provided the override -is visible at compile-time. -See L. +Bug fixes and minor enhancements have been applied to B::Deparse, +Data::Dumper, IO::Poll, IO::Socket::INET, Math::BigFloat, +Math::Complex, Math::Trig, Net::protoent, the re pragma, SelfLoader, +Sys::SysLog, Test::Harness, Text::Wrap, UNIVERSAL, and the warnings +pragma. -=head2 New variable $^C reflects C<-c> switch +=item * -C<$^C> has a boolean value that reflects whether perl is being run -in compile-only mode (i.e. via the C<-c> switch). Since -BEGIN blocks are executed under such conditions, this variable -enables perl code to determine whether actions that make sense -only during normal running are warranted. See L. +The attributes::reftype() now works on tied arguments. -=head2 New variable $^V contains Perl version in v5.6.0 format +=item * -C<$^V> contains the Perl version number as a string composed of -characters whose ordinals match the version numbers, so that it may -be used in string comparisons. +AutoLoader can now be disabled with C, -See C for an -example. +=item * -=head2 Optional Y2K warnings +The English module can now be used without the infamous performance +hit by saying -If Perl is built with the cpp macro C defined, -it emits optional warnings when concatenating the number 19 -with another number. + use English '-no_performance_hit'; -This behavior must be specifically enabled when running Configure. -See F and F. +(Assuming, of course, that one doesn't need the troublesome variables +C<$`>, C<$&>, or C<$'>.) Also, introduced C<@LAST_MATCH_START> and +C<@LAST_MATCH_END> English aliases for C<@-> and C<@+>. -=head1 Significant bug fixes +=item * -=head2 EHANDLEE on empty files +File::Find now has pre- and post-processing callbacks. It also +correctly changes directories when chasing symbolic links. Callbacks +(naughtily) exiting with "next;" instead of "return;" now work. -With C<$/> set to C, "slurping" an empty file returns a string of -zero length (instead of C, as it used to) the first time the -HANDLE is read after C<$/> is set to C. Further reads yield -C. +=item * -This means that the following will append "foo" to an empty file (it used -to do nothing): +File::Glob::glob() renamed to File::Glob::bsd_glob() to avoid +prototype mismatch with CORE::glob(). - perl -0777 -pi -e 's/^/foo/' empty_file +=item * -The behaviour of: +IPC::Open3 now allows the use of numeric file descriptors. - perl -pi -e 's/^/foo/' empty_file +=item * -is unchanged (it continues to leave the file empty). +use lib now works identically to @INC. Removing directories +with 'no lib' now works. -=head2 C improvements +=item * -Line numbers (as reflected by caller() and most diagnostics) within -C were often incorrect when here documents were involved. -This has been corrected. +C<%INC> now localised in a Safe compartment so that use/require work. -Lexical lookups for variables appearing in C within -functions that were themselves called within an C were -searching the wrong place for lexicals. The lexical search now -correctly ends at the subroutine's block boundary. +=item * -Parsing of here documents used to be flawed when they appeared as -the replacement expression in C. This has -been fixed. +The Shell module now has an OO interface. -=head2 All compilation errors are true errors +=item * -Some "errors" encountered at compile time were by neccessity -generated as warnings followed by eventual termination of the -program. This enabled more such errors to be reported in a -single run, rather than causing a hard stop at the first error -that was encountered. +B::Deparse should be now more robust. It still far from providing a full +round trip for any random piece of Perl code, though, and is under active +development: expect more robustness in 5.7.2. -The mechanism for reporting such errors has been reimplemented -to queue compile-time errors and report them at the end of the -compilation as true errors rather than as warnings. This fixes -cases where error messages leaked through in the form of warnings -when code was compiled at run time using C, and -also allows such errors to be reliably trapped using __DIE__ hooks. +=item * -=head2 Automatic flushing of output buffers +Class::Struct can now define the classes in compile time. -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 -handles I/O. +=item * -=head2 Better diagnostics on meaningless filehandle operations +Math::BigFloat has undergone much fixing, and in addition the fmod() +function now supports modulus operations. -Constructs such as CFHE)> and CFHE)> -are compile time errors. Attempting to read from filehandles that -were opened only for writing will now produce warnings (just as -writing to read-only filehandles does). +(The fixed Math::BigFloat module is also available in CPAN for those +who can't upgrade their Perl: http://www.cpan.org/authors/id/J/JP/JPEACOCK/) -=head2 Where possible, buffered data discarded from duped input filehandle +=item * -C&OLD")> now attempts to discard any data that -was previously read and buffered in C before duping the handle. -On platforms where doing this is allowed, the next read operation -on C will return the same data as the corresponding operation -on C. Formerly, it would have returned the data from the start -of the following disk block instead. +Devel::Peek now has an interface for the Perl memory statistics +(this works only if you are using perl's malloc, and if you have +compiled with debugging). -=head2 eof() has the same old magic as <> +=item * -C would return true if no attempt to read from CE> had -yet been made. C has been changed to have a little magic of its -own, it now opens the CE> files. +IO::Socket has now atmark() method, which returns true if the socket +is positioned at the out-of-band mark. The method is also exportable +as a sockatmark() function. -=head2 system(), backticks and pipe open now reflect exec() failure +=item * -On Unix and similar platforms, system(), qx() and open(FOO, "cmd |") -etc., are implemented via fork() and exec(). When the underlying -exec() fails, earlier versions did not report the error properly, -since the exec() happened to be in a different process. +IO::Socket::INET has support for ReusePort option (if your platform +supports it). The Reuse option now has an alias, ReuseAddr. For clarity +you may want to prefer ReuseAddr. -The child process now communicates with the parent about the -error in launching the external command, which allows these -constructs to return with their usual error value and set $!. +=item * -=head2 Implicitly closed filehandles are safer +Net::Ping has been enhanced. There is now "external" protocol which +uses Net::Ping::External module which runs external ping(1) and parses +the output. An alpha version of Net::Ping::External is available in +CPAN and in 5.7.2 the Net::Ping::External may be integrated to Perl. -Sometimes implicitly closed filehandles (as when they are localized, -and Perl automatically closes them on exiting the scope) could -inadvertently set $? or $!. This has been corrected. +=item * -=head2 C<(\$)> prototype and C<$foo{a}> +The C pragma allows layers other than ":raw" and ":crlf" when +using PerlIO. -An scalar reference prototype now correctly allows a hash or -array element in that slot. +=item * -=head2 Pseudo-hashes work better +POSIX::sigaction() is now much more flexible and robust. +You can now install coderef handlers, 'DEFAULT', and 'IGNORE' +handlers, installing new handlers was not atomic. -Dereferencing some types of reference values in a pseudo-hash, -such as C<$ph-E{foo}[1]>, was accidentally disallowed. This has -been corrected. +=item * -When applied to a pseudo-hash element, exists() now reports whether -the specified value exists, not merely if the key is valid. +The Test module has been significantly enhanced. Its use is +greatly recommended for module writers. -delete() now works on pseudo-hashes. When given a pseudo-hash element -or slice it deletes the values corresponding to the keys (but not the keys -themselves). See L. +=item * -Pseudo-hash slices with constant keys are now optimized to array lookups -at compile-time. +The utf8:: name space (as in the pragma) provides various +Perl-callable functions to provide low level access to Perl's +internal Unicode representation. At the moment only length() +has been implemented. -The C pragma now provides ways to create pseudo-hashes, via -fields::new() and fields::phash(). See L. +=back -=head2 C and AUTOLOAD +The following modules have been upgraded from the versions at CPAN: +CPAN, CGI, DB_File, File::Temp, Getopt::Long, Pod::Man, Pod::Text, +Storable, Text-Tabs+Wrap. -The C construct works correctly when C<&sub> happens -to be autoloaded. +=item * -=head2 C<-bareword> allowed under C +L module has been significantly enhanced. It now +can deparse almost all of the standard test suite (so that the +tests still succeed). There is a make target "test.deparse" +for trying this out. -The autoquoting of barewords preceded by C<-> did not work -in prior versions when the C pragma was enabled. -This has been fixed. +=item * -=head2 Boolean assignment operators are legal lvalues +L now assigns the array/hash element if the accessor +is called with an array/hash element as the B argument. -Constructs such as C<($a ||= 2) += 1> are now allowed. +=item * -=head2 C allowed +L extension is now (even) faster. -sort() did not accept a subroutine reference as the comparison -function in earlier versions. This is now permitted. +=item * -=head2 Failures in DESTROY() +L extension has been updated to version 1.77. -When code in a destructor threw an exception, it went unnoticed -in earlier versions of Perl, unless someone happened to be -looking in $@ just after the point the destructor happened to -run. Such failures are now visible as warnings when warnings are -enabled. +=item * -=head2 Locale bugs fixed +L, L, and L have been rewritten to use the +new-style constant dispatch section (see L). -printf() and sprintf() previously reset the numeric locale -back to the default "C" locale. This has been fixed. +=item * -Numbers formatted according to the local numeric locale -(such as using a decimal comma instead of a decimal dot) caused -"isn't numeric" warnings, even while the operations accessing -those numbers produced correct results. The warnings are gone. +L is now (again) reentrant. It also has been made +more portable. -=head2 Memory leaks +=item * -The C construct could sometimes leak -memory. This has been fixed. +L now supports C constant to limit the +size of the returned list of filenames. -Operations that aren't filehandle constructors used to leak memory -when used on invalid filehandles. This has been fixed. +=item * -Constructs that modified C<@_> could fail to deallocate values -in C<@_> and thus leak memory. This has been corrected. +L now supports C of zero (usually meaning +that the operating system will make one up.) -=head2 Spurious subroutine stubs after failed subroutine calls +=item * -Perl could sometimes create empty subroutine stubs when a -subroutine was not found in the package. Such cases stopped -later method lookups from progressing into base packages. -This has been corrected. +The L pragma now supports declaring fully qualified variables. +(Something that C does not and will not support.) -=head2 Consistent numeric conversions +=back -change#3378,3318 -[TODO - Ilya Zakharevich ] +=head1 Utility Changes -=head2 Taint failures under C<-U> +=over 4 -When running in unsafe mode, taint violations could sometimes -cause silent failures. This has been fixed. +=item * -=head2 END blocks and the C<-c> switch +The Emacs perl mode (emacs/cperl-mode.el) has been updated to version +4.31. -Prior versions used to run BEGIN B END blocks when Perl was -run in compile-only mode. Since this is typically not the expected -behavior, END blocks are not executed anymore when the C<-c> switch -is used. +=item * -See L for how to run things when the compile phase ends. +Perlbug is now much more robust. It also sends the bug report to +perl.org, not perl.com. -=head2 Potential to leak DATA filehandles +=item * -Using the C<__DATA__> token creates an implicit filehandle to -the file that contains the token. It is the program's -responsibility to close it when it is done reading from it. +The perlcc utility has been rewritten and its user interface (that is, +command line) is much more like that of the UNIX C compiler, cc. -This caveat is now better explained in the documentation. -See L. +=item * -=head2 Diagnostics follow STDERR +The xsubpp utility for extension writers now understands POD +documentation embedded in the *.xs files. -Diagnostic output now goes to whichever file the C handle -is pointing at, instead of always going to the underlying C runtime -library's C. +=item * -=head2 Other fixes for better diagnostics +h2xs now produces template README. -Line numbers are no longer suppressed (under most likely circumstances) -during the global destruction phase. +=item * -Diagnostics emitted from code running in threads other than the main -thread are now accompanied by the thread ID. +s2p has been completely rewritten in Perl. (It is in fact a full +implementation of sed in Perl.) -Embedded null characters in diagnostics now actually show up. They -used to truncate the message in prior versions. +=item * -$foo::a and $foo::b are now exempt from "possible typo" warnings only -if sort() is encountered in package foo. +xsubpp now supports OUT keyword. -Unrecognized alphabetic escapes encountered when parsing quote -constructs now generate a warning, since they may take on new -semantics in later versions of Perl. +=item * -=head1 Performance enhancements +The F is now much faster. -=head2 Simple sort() using { $a <=> $b } and the like are optimized +=item * -Many common sort() operations using a simple inlined block are now -optimized for faster performance. +L now supports C trigraphs. -=head2 Optimized assignments to lexical variables +=item * -Certain operations in the RHS of assignment statements have been -optimized to directly set the lexical variable on the LHS, -eliminating redundant copying overheads. +L uses the new L module which will affect +newly created extensions that define constants. Since the new code is +more correct (if you have two constants where the first one is a +prefix of the second one, the first constant B gets defined), +less lossy (it uses integers for integer constant, as opposed to the +old code that used floating point numbers even for integer constants), +and slightly faster, you might want to consider regenerating your +extension code (the new scheme makes regenerating easy). +L now also supports C trigraphs. -=head2 Method lookups optimized +=item * -[TODO - Chip Salzenberg ] +L has been added to configure the libnet. -=head2 Faster mechanism to invoke XSUBs +=item * -change#4044,4125 -[TODO - Ilya Zakharevich ] +The F (and thusly L) now allows specifying +a cache directory. -=head2 Perl_malloc() improvements +=back -change#4237 -[TODO - Ilya Zakharevich ] +=head1 New Documentation -=head2 Faster subroutine calls +=over 4 -Minor changes in how subroutine calls are handled internally -provide marginal improvements in performance. +=item * -=head1 Platform specific changes +perl56delta details the changes between the 5.005 release and the +5.6.0 release. -=head2 Additional supported platforms +=item * -=over 4 +perldebtut is a Perl debugging tutorial. =item * -VM/ESA is now supported. +perlebcdic contains considerations for running Perl on EBCDIC platforms. +Note that unfortunately EBCDIC platforms that used to supported back in +Perl 5.005 are still unsupported by Perl 5.7.0; the plan, however, is to +bring them back to the fold. =item * -Siemens BS2000 is now supported under the POSIX Shell. +perlnewmod tells about writing and submitting a new module. =item * -The Mach CThreads (NEXTSTEP, OPENSTEP) are now supported by the Thread -extension. +perlposix-bc explains using Perl on the POSIX-BC platform +(an EBCDIC mainframe platform). =item * -GNU/Hurd is now supported. +perlretut is a regular expression tutorial. =item * -Rhapsody is now supported. +perlrequick is a regular expressions quick-start guide. +Yes, much quicker than perlretut. =item * -EPOC is is now supported (on Psion 5). +perlutil explains the command line utilities packaged with the Perl +distribution. =back -=head2 DOS +=head2 perlclib + +Internal replacements for standard C library functions. +(Interesting only for extension writers and Perl core hackers.) + +=head2 perliol + +Internals of PerlIO with layers. + +=head2 README.aix + +Documentation on compiling Perl on AIX has been added. AIX has +several different C compilers and getting the right patch level +is essential. On install README.aix will be installed as L. + +=head2 README.bs2000 + +Documentation on compiling Perl on the POSIX-BC platform (an EBCDIC +mainframe environment) has been added. + +This was formerly known as README.posix-bc but the name was considered +to be too confusing (it has nothing to do with the POSIX module or the +POSIX standard). On install README.bs2000 will be installed as L. + +=head2 README.macos + +In perl 5.7.1 (and in the 5.6.1) the MacPerl sources have been +synchronised with the standard Perl sources. To compile MacPerl +some additional steps are required, and this file documents those +steps. On install README.macos will be installed as L. + +=head2 README.mpeix + +The README.mpeix has been podified, which means that this information +about compiling and using Perl on the MPE/iX miniframe platform will +be installed as L. + +=head2 README.solaris + +README.solaris has been created and Solaris wisdom from elsewhere +in the Perl documentation has been collected there. On install +README.solaris will be installed as L. + +=head2 README.vos + +The README.vos has been podified, which means that this information +about compiling and using Perl on the Stratus VOS miniframe platform +will be installed as L. + +=head2 Porting/repository.pod + +Documentation on how to use the Perl source repository has been added. =over 4 =item * -Perl now works with djgpp 2.02 (and 2.03 alpha). +L is an article about software localization, +originally published in The Perl Journal #13, republished here with +kind permission. =item * -Environment variable names are not converted to uppercase any more. +More README.$PLATFORM files have been converted into pod, which also +means that they also be installed as perl$PLATFORM documentation +files. The new files are L, L, L, +L, L, L, L, L, +and L. =item * -Wrong exit code from backticks now fixed. +The F and F files have been merged into L. =item * -This port is still using its own builtin globbing. +Use of the F tool to profile Perl has been documented in +L. There is a make target "perl.gprof" for generating a +gprofiled Perl executable. =back -=head2 OS/2 +=head1 Performance Enhancements -[TODO - Ilya Zakharevich ] +=over 4 -=head2 VMS +=item * -[TODO - Charles Bailey ] +map() that changes the size of the list should now work faster. -=head2 Win32 +=item * -Site library searches failed to look for ".../site/5.XXX/lib" -if ".../site/5.XXXYY/lib" wasn't found. This has been corrected. +sort() has been changed to use mergesort internally as opposed to the +earlier quicksort. For very small lists this may result in slightly +slower sorting times, but in general the speedup should be at least +20%. Additional bonuses are that the worst case behaviour of sort() +is now better (in computer science terms it now runs in time O(N log N), +as opposed to quicksort's Theta(N**2) worst-case run time behaviour), +and that sort() is now stable (meaning that elements with identical +keys will stay ordered as they were before the sort). -When given a pathname that consists only of a drivename, such -as C, opendir() and stat() now use the current working -directory for the drive rather than the drive root. +=item * -The builtin XSUB functions in the Win32:: namespace are -documented. See L. +Hashes now use Bob Jenkins "One-at-a-Time" hashing key algorithm +(http://burtleburtle.net/bob/hash/doobs.html). This algorithm is +reasonably fast while producing a much better spread of values than +the old hashing algorithm (originally by Chris Torek, later tweaked by +Ilya Zakharevich). Hash values output from the algorithm on a hash of +all 3-char printable ASCII keys comes much closer to passing the +DIEHARD random number generation tests. According to perlbench, this +change has not affected the overall speed of Perl. -$^X now contains the full path name of the running executable. +=item * -A Win32::GetLongPathName() function is provided to complement -Win32::GetFullPathName() and Win32::GetShortPathName(). See L. +unshift() should now be noticeably faster. -POSIX::uname() is supported. +=back -system(1,...) now returns true process IDs rather than process -handles. kill() accepts any real process id, rather than strictly -return values from system(1,...). +=head1 Installation and Configuration Improvements -For better compatibility with Unix, C can now be used to -test whether a process exists. +=head2 Generic Improvements -The C module is supported. +=over 4 -Rudimentary support for building under command.com in Windows 95 -has been added. +=item * -Scripts are read in binary mode by default to allow ByteLoader (and -the filter mechanism in general) to work properly. For compatibility, -the DATA filehandle will be set to text mode if a carriage return is -detected at the end of the line containing the __END__ or __DATA__ -token; if not, the DATA filehandle will be left open in binary mode. -Earlier versions always opened the DATA filehandle in text mode. +INSTALL now explains how you can configure Perl to use 64-bit +integers even on non-64-bit platforms. -The glob() operator is implemented via the C extension, -which supports glob syntax of the C shell. This increases the flexibility -of the glob() operator, but there may be compatibility issues for -programs that relied on the older globbing syntax. If you want to -preserve compatibility with the older syntax, you might want to put -a C in your program. For details and compatibility -information, see L. +=item * -[TODO - GSAR] +Policy.sh policy change: if you are reusing a Policy.sh file +(see INSTALL) and you use Configure -Dprefix=/foo/bar and in the old +Policy $prefix eq $siteprefix and $prefix eq $vendorprefix, all of +them will now be changed to the new prefix, /foo/bar. (Previously +only $prefix changed.) If you do not like this new behaviour, +specify prefix, siteprefix, and vendorprefix explicitly. -=head1 New tests +=item * -=over 4 +A new optional location for Perl libraries, otherlibdirs, is available. +It can be used for example for vendor add-ons without disturbing Perl's +own library directories. -=item lib/attrs +=item * -Compatibility tests for C vs the older C. +In many platforms the vendor-supplied 'cc' is too stripped-down to +build Perl (basically, 'cc' doesn't do ANSI C). If this seems +to be the case and 'cc' does not seem to be the GNU C compiler +'gcc', an automatic attempt is made to find and use 'gcc' instead. -=item lib/env +=item * -Tests for new environment scalar capability (e.g., C). +gcc needs to closely track the operating system release to avoid +build problems. If Configure finds that gcc was built for a different +operating system release than is running, it now gives a clearly visible +warning that there may be trouble ahead. -=item lib/env-array +=item * -Tests for new environment array capability (e.g., C). +If binary compatibility with the 5.005 release is not wanted, Configure +no longer suggests including the 5.005 modules in @INC. -=item lib/io_const +=item * -IO constants (SEEK_*, _IO*). +Configure C<-S> can now run non-interactively. -=item lib/io_dir +=item * -Directory-related IO methods (new, read, close, rewind, tied delete). +configure.gnu now works with options with whitespace in them. -=item lib/io_multihomed +=item * -INET sockets with multi-homed hosts. +installperl now outputs everything to STDERR. -=item lib/io_poll +=item * -IO poll(). +$Config{byteorder} is now computed dynamically (this is more robust +with "fat binaries" where an executable image contains binaries for +more than one binary platform.) -=item lib/io_unix +=item * + +Because PerlIO is now the default on most platforms, "-perlio" doesn't +get appended to the $Config{archname} (also known as $^O) anymore. +Instead, if you explicitly choose not to use perlio (Configure command +line option -Uuseperlio), you will get "-stdio" appended. + +=item * + +Another change related to the architecture name is that "-64all" +(-Duse64bitall, or "maximally 64-bit") is appended only if your +pointers are 64 bits wide. (To be exact, the use64bitall is ignored.) + +=item * + +APPLLIB_EXP, a less-know configuration-time definition, has been +documented. It can be used to prepend site-specific directories +to Perl's default search path (@INC), see INSTALL for information. + +=item * + +Building Berkeley DB3 for compatibility modes for DB, NDBM, and ODBM +has been documented in INSTALL. + +=item * -UNIX sockets. +If you are on IRIX or Tru64 platforms, new profiling/debugging options +have been added, see L for more information about pixie and +Third Degree. -=item op/attrs +=item * -Regression tests for C and . +In AFS installations one can configure the root of the AFS to be +somewhere else than the default F by using the Configure +parameter C<-Dafsroot=/some/where/else>. -=item op/filetest +=item * -File test operators. +The version of Berkeley DB used when the Perl (and, presumably, the +DB_File extension) was built is now available as +C<@Config{qw(db_version_major db_version_minor db_version_patch)}> +from Perl and as C from C. -=item op/lex_assign +=item * -Verify operations that access pad objects (lexicals and temporaries). +The Thread extension is now not built at all under ithreads +(C) because it wouldn't work anyway (the +Thread extension requires being Configured with C<-Duse5005threads>). -=item op/exists_sub +=item * -Verify C operations. +The C compiler backend has been so significantly improved +that almost the whole Perl test suite passes after being deparsed. A +make target has been added to help in further testing: C. =back -=head1 Modules and Pragmata +=head2 New Or Improved Platforms -=head2 Modules +For the list of platforms known to support Perl, +see L. =over 4 -=item attributes +=item * -While used internally by Perl as a pragma, this module also -provides a way to fetch subroutine and variable attributes. -See L. +AIX dynamic loading should be now better supported. -=item B +=item * -The Perl Compiler suite has been extensively reworked for this -release. +After a long pause, AmigaOS has been verified to be happy with Perl. -[TODO - Vishal Bhatia , -Nick Ing-Simmons ] +=item * -=item ByteLoader +EBCDIC platforms (z/OS, also known as OS/390, POSIX-BC, and VM/ESA) +have been regained. Many test suite tests still fail and the +co-existence of Unicode and EBCDIC isn't quite settled, but the +situation is much better than with Perl 5.6. See L, +L (for POSIX-BC), and L for more information. -The ByteLoader is a dedicated extension to generate and run -Perl bytecode. See L. +=item * -=item constant +Building perl with -Duseithreads or -Duse5005threads now works under +HP-UX 10.20 (previously it only worked under 10.30 or later). You will +need a thread library package installed. See README.hpux. -References can now be used. +=item * -The new version also allows a leading underscore in constant names, but -disallows a double leading underscore (as in "__LINE__"). Some other names -are disallowed or warned against, including BEGIN, END, etc. Some names -which were forced into main:: used to fail silently in some cases; now they're -fatal (outside of main::) and an optional warning (inside of main::). -The ability to detect whether a constant had been set with a given name has -been added. +MacOS Classic (MacPerl has of course been available since +perl 5.004 but now the source code bases of standard Perl +and MacPerl have been synchronised) -See L. +=item * -=item charnames +NCR MP-RAS is now supported. -change#4052 -[TODO - Ilya Zakharevich ] +=item * -=item Data::Dumper +NonStop-UX is now supported. -A C setting can be specified to avoid venturing -too deeply into deep data structures. See L. +=item * -Dumping C objects works correctly. +Amdahl UTS is now supported. -=item DB +=item * -C is an experimental module that exposes a clean abstraction -to Perl's debugging API. +z/OS (formerly known as OS/390, formerly known as MVS OE) has now +support for dynamic loading. This is not selected by default, +however, you must specify -Dusedl in the arguments of Configure. -=item DB_File +=item * -DB_File can now be built with Berkeley DB versions 1, 2 or 3. -See C. +AIX should now work better with gcc, threads, and 64-bitness. Also the +long doubles support in AIX should be better now. See L. -=item Devel::DProf +=item * -Devel::DProf, a Perl source code profiler has been added. See -L and L. +AtheOS (http://www.atheos.cx/) is a new platform. -=item Dumpvalue +=item * -The Dumpvalue module provides screen dumps of Perl data. +DG/UX platform now supports the 5.005-style threads. See L. -=item Benchmark +=item * -Overall, Benchmark results exhibit lower average error and better timing -accuracy. +DYNIX/ptx platform (a.k.a. dynixptx) is supported at or near osvers 4.5.2. -You can now run tests for I seconds instead of guessing the right -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: +=item * - use Benchmark;$x=3;timethese(-5,{a=>sub{$x*$x},b=>sub{$x**2}}) +Several MacOS (Classic) portability patches have been applied. We +hope to get a fully working port by 5.8.0. (The remaining problems +relate to the changed IO model of Perl.) See L. -will now output something like this: +=item * - Benchmark: running a, b, each for at least 5 CPU seconds... - a: 5 wallclock secs ( 5.77 usr + 0.00 sys = 5.77 CPU) @ 200551.91/s (n=1156516) - b: 4 wallclock secs ( 5.00 usr + 0.02 sys = 5.02 CPU) @ 159605.18/s (n=800686) +MacOS X (or Darwin) should now be able to build Perl even on HFS+ +filesystems. (The case-insensitivity confused the Perl build process.) -New features: "each for at least N CPU seconds...", "wallclock secs", -and the "@ operations/CPU second (n=operations)". +=item * -timethese() now returns a reference to a hash of Benchmark objects containing -the test results, keyed on the names of the tests. +NetWare from Novell is now supported. See L. -timethis() now returns the iterations field in the Benchmark result object -instead of 0. +=item * -timethese(), timethis(), and the new cmpthese() (see below) can also take -a format specifier of 'none' to suppress output. +The Amdahl UTS UNIX mainframe platform is now supported. -A new function countit() is just like timeit() except that it takes a -TIME instead of a COUNT. +=back -A new function cmpthese() prints a chart comparing the results of each test -returned from a timethese() call. For each possible pair of tests, the -percentage speed difference (iters/sec or seconds/iter) is shown. +=head1 Selected Bug Fixes -For other details, see L. +=over 4 -=item Devel::Peek +=item * -The Devel::Peek module provides access to the internal representation -of Perl variables and data. It is a data debugging tool for the XS programmer. +Several debugger fixes: exit code now reflects the script exit code, +condition C<"0"> now treated correctly, the C command now checks +line number, the C<$.> no longer gets corrupted, all debugger output now +goes correctly to the socket if RemotePort is set. -=item English +=item * -$PERL_VERSION now stands for C<$^V> (a string value) rather than for C<$]> -(a numeric value). +C<*foo{FORMAT}> now works. -=item Env +=item * -Env now supports accessing environment variables like PATH as array -variables. +Lexical warnings now propagating correctly between scopes. -=item ExtUtils::MakeMaker +=item * -change#4135, also needs docs in module pod -[TODO - Ilya Zakharevich ] +Line renumbering with eval and C<#line> now works. -=item Fcntl +=item * -More Fcntl constants added: F_SETLK64, F_SETLKW64, O_LARGEFILE for -large file (more than 4GB) access Note that the O_LARGEFILE is -automatically/transparently added to sysopen() flags if large file -support has been configured), Free/Net/OpenBSD locking behaviour flags -F_FLOCK, F_POSIX, Linux F_SHLCK, and O_ACCMODE: the combined mask of -O_RDONLY, O_WRONLY, and O_RDWR. The seek()/sysseek() constants -SEEK_SET, SEEK_CUR, and SEEK_END are available via the C<:seek> tag. -The chmod()/stat() S_IF* constants and S_IS* functions are available -via the C<:mode> tag. +Fixed numerous memory leaks, especially in eval "". +=item * -=item File::Compare +Modulus of unsigned numbers now works (4063328477 % 65535 used to +return 27406, instead of 27047). -A compare_text() function has been added, which allows custom -comparison functions. See L. +=item * -=item File::Find +Some "not a number" warnings introduced in 5.6.0 eliminated to be +more compatible with 5.005. Infinity is now recognised as a number. -File::Find now works correctly when the wanted() function is either -autoloaded or is a symbolic reference. +=item * -A bug that caused File::Find to lose track of the working directory -when pruning top-level directories has been fixed. +our() variables will not cause "will not stay shared" warnings. -File::Find now also supports several other options to control its -behavior. It can follow symbolic links if the C option is -specified. Enabling the C option will make File::Find skip -changing the current directory when walking directories. The C -flag can be useful when running with taint checks enabled. +=item * -See L. +pack "Z" now correctly terminates the string with "\0". -=item File::Glob +=item * -This extension implements BSD-style file globbing. By default, -it will also be used for the internal implementation of the glob() -operator. See L. +Fix password routines which in some shadow password platforms +(e.g. HP-UX) caused getpwent() to return every other entry. -=item File::Spec +=item * -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 -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 -have been added. +printf() no longer resets the numeric locale to "C". -=item File::Spec::Functions +=item * -The new File::Spec::Functions modules provides a function interface -to the File::Spec module. Allows shorthand +C now parses correctly as C<'a\\b'>. - $fullname = catfile($dir1, $dir2, $file); +=item * -instead of +Printing quads (64-bit integers) with printf/sprintf now works +without the q L ll prefixes (assuming you are on a quad-capable platform). - $fullname = File::Spec->catfile($dir1, $dir2, $file); +=item * -=item Getopt::Long +Regular expressions on references and overloaded scalars now work. -Getopt::Long licensing has changed to allow the Perl Artistic License -as well as the GPL. It used to be GPL only, which got in the way of -non-GPL applications that wanted to use Getopt::Long. +=item * -Getopt::Long encourages the use of Pod::Usage to produce help -messages. For example: +scalar() now forces scalar context even when used in void context. - use Getopt::Long; - use Pod::Usage; - my $man = 0; - my $help = 0; - GetOptions('help|?' => \$help, man => \$man) or pod2usage(2); - pod2usage(1) if $help; - pod2usage(-exitstatus => 0, -verbose => 2) if $man; +=item * - __END__ +sort() arguments are now compiled in the right wantarray context +(they were accidentally using the context of the sort() itself). - =head1 NAME +=item * - sample - Using GetOpt::Long and Pod::Usage +Changed the POSIX character class C<[[:space:]]> to include the (very +rare) vertical tab character. Added a new POSIX-ish character class +C<[[:blank:]]> which stands for horizontal whitespace (currently, +the space and the tab). - =head1 SYNOPSIS +=item * - sample [options] [file ...] +$AUTOLOAD, sort(), lock(), and spawning subprocesses +in multiple threads simultaneously are now thread-safe. - Options: - -help brief help message - -man full documentation +=item * - =head1 OPTIONS +Allow read-only string on left hand side of non-modifying tr///. - =over 8 +=item * - =item B<-help> +Several Unicode fixes (but still not perfect). - Print a brief help message and exits. +=over 8 - =item B<-man> +=item * - Prints the manual page and exits. +BOMs (byte order marks) in the beginning of Perl files +(scripts, modules) should now be transparently skipped. +UTF-16 (UCS-2) encoded Perl files should now be read correctly. - =back +=item * - =head1 DESCRIPTION +The character tables have been updated to Unicode 3.0.1. - B will read the given input file(s) and do someting - useful with the contents thereof. +=item * - =cut +chr() for values greater than 127 now create utf8 when under use +utf8. -See L for details. +=item * -A bug that prevented the non-option call-back EE from being -specified as the first argument has been fixed. +Comparing with utf8 data does not magically upgrade non-utf8 data into +utf8. -To specify the characters E and E as option starters, use -EE. Note, however, that changing option starters is strongly -deprecated. +=item * -=item IO +C, C, and C now match titlecase. -write() and syswrite() will now accept a single-argument -form of the call, for consistency with Perl's syswrite(). +=item * -You can now create a TCP-based IO::Socket::INET without forcing -a connect attempt. This allows you to configure its options -(like making it non-blocking) and then call connect() manually. +Concatenation with the C<.> operator or via variable interpolation, +C, C, C, C, the C operator, +substitution with C, single-quoted UTF8, should now work--in +theory. -A bug that prevented the IO::Socket::protocol() accessor -from ever returning the correct value has been corrected. +=item * -=item JPL +The C operator now works I better but is still rather +broken. Note that the C functionality has been removed (but +see pack('U0', ...)). -Java Perl Lingo is now distributed with Perl. See jpl/README -for more information. +=item * + +vec() now refuses to deal with characters >255. -=item lib +=item * -C now weeds out any trailing duplicate entries. -C removes all named entries. +Zero entries were missing from the Unicode classes like C. -=item Math::BigInt +=back -The bitwise operations CE>, CE>, C<&>, C<|>, -and C<~> are now supported on bigints. +=item * -=item Math::Complex +UNIVERSAL::isa no longer caches methods incorrectly. (This broke +the Tk extension with 5.6.0.) -The accessor methods Re, Im, arg, abs, rho, and theta can now also -act as mutators (accessor $z->Re(), mutator $z->Re(3)). +=item * -=item Math::Trig +Configure no longer includes the DBM libraries (dbm, gdbm, db, ndbm) +when building the Perl binary. The only exception to this is SunOS 4.x, +which needs them. -A little bit of radial trigonometry (cylindrical and spherical), -radial coordinate conversions, and the great circle distance were added. +=item * -=item Pod::Parser, Pod::InputObjects +Some new Configure symbols, useful for extension writers: -Pod::Parser is a base class for parsing and selecting sections of -pod documentation from an input stream. This module takes care of -identifying pod paragraphs and commands in the input and hands off the -parsed paragraphs and commands to user-defined methods which are free -to interpret or translate them as they see fit. +=over 8 -Pod::InputObjects defines some input objects needed by Pod::Parser, and -for advanced users of Pod::Parser that need more about a command besides -its name and text. +=item d_cmsghdr -As of release 5.6 of Perl, Pod::Parser is now the officially sanctioned -"base parser code" recommended for use by all pod2xxx translators. -Pod::Text (pod2text) and Pod::Man (pod2man) have already been converted -to use Pod::Parser and efforts to convert Pod::HTML (pod2html) are already -underway. For any questions or comments about pod parsing and translating -issues and utilities, please use the pod-people@perl.org mailing list. +For struct cmsghdr. -For further information, please see L and L. +=item d_fcntl_can_lock -=item Pod::Checker, podchecker +Whether fcntl() can be used for file locking. -This utility checks pod files for correct syntax, according to -L. Obvious errors are flagged as such, while warnings are -printed for mistakes that can be handled gracefully. The checklist is -not complete yet. See L. +=item d_fsync -=item Pod::ParseUtils, Pod::Find +=item d_getitimer -These modules provide a set of gizmos that are useful mainly for pod -translators. L traverses directory structures and -returns found pod files, along with their canonical names (like -C). L contains -B (useful for storing pod list information), B -(for parsing the contents of CE> sequences) and B -(for caching information about pod files, e.g. link nodes). +=item d_getpagsz -=item Pod::Select, podselect +For getpagesize(), though you should prefer POSIX::sysconf(_SC_PAGE_SIZE)) -Pod::Select is a subclass of Pod::Parser which provides a function -named "podselect()" to filter out user-specified sections of raw pod -documentation from an input stream. podselect is a script that provides -access to Pod::Select from other scripts to be used as a filter. -See L. +=item d_msghdr_s -=item Pod::Usage, pod2usage +For struct msghdr. -Pod::Usage provides the function "pod2usage()" to print usage messages for -a Perl script based on its embedded pod documentation. The pod2usage() -function is generally useful to all script authors since it lets them -write and maintain a single source (the pods) for documentation, thus -removing the need to create and maintain redundant usage message text -consisting of information already in the pods. +=item need_va_copy -There is also a pod2usage script which can be used from other kinds of -scripts to print usage messages from pods (even for non-Perl scripts -with pods embedded in comments). +Whether one needs to use Perl_va_copy() to copy varargs. -For details and examples, please see L. +=item d_readv -=item Pod::Text and Pod::Man +=item d_recvmsg -[TODO - Russ Allbery ] +=item d_sendmsg -=item SDBM_File +=item sig_size -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 -runtime error. +The number of elements in an array needed to hold all the available signals. -A bug that may have caused data loss when more than one disk block -happens to be read from the database in a single FETCH() has been -fixed. +=item d_sockatmark -=item Sys::Syslog +=item d_strtoq -Sys::Syslog now uses XSUBs to access facilities from syslog.h so it -no longer requires syslog.ph to exist. +=item d_u32align -=item Sys::Hostname +Whether one needs to access character data aligned by U32 sized pointers. -Sys::Hostname now uses XSUBs to call the C library's gethostname() or -uname() if they exist. +=item d_ualarm -=item Time::Local +=item d_usleep -The timelocal() and timegm() functions used to silently return bogus -results when the date fell outside the machine's integer range. They -now consistently croak() if the date falls in an unsupported range. +=back -=item Win32 +=item * -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 if an error occurred. Now these functions -return the empty list in these situations. This applies to the following -functions: +Removed Configure symbols: the PDP-11 memory model settings: huge, +large, medium, models. - Win32::FsType - Win32::GetOSVersion +=item * -The remaining functions are unchanged and continue to return C on -error even in list context. +SOCKS support is now much more robust. -The Win32::SetLastError(ERROR) function has been added as a complement -to the Win32::GetLastError() function. +=item * -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 -the filename. See L. +If your file system supports symbolic links you can build Perl outside +of the source directory by -=item DBM Filters + mkdir /tmp/perl/build/directory + cd /tmp/perl/build/directory + sh /path/to/perl/source/Configure -Dmksymlinks ... -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 DBM module: +This will create in /tmp/perl/build/directory a tree of symbolic links +pointing to files in /path/to/perl/source. The original files are left +unaffected. After Configure has finished you can just say - filter_store_key - filter_store_value - filter_fetch_key - filter_fetch_value + make all test -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 for further information. +and Perl will be built and tested, all in /tmp/perl/build/directory. =back -=head2 Pragmata - -C is now obsolete, and is only provided for -backward-compatibility. It's been replaced by the C -syntax. See L and L. +=head2 Platform Specific Changes and Fixes -C to enable UTF-8 and Unicode support. +=over 4 -Lexical warnings pragma, C, to control optional warnings. -See L. +=item * -C to control the behaviour of filetests (C<-r> C<-w> -...). Currently only one subpragma implemented, "use filetest -'access';", that uses 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, -but access(2) knows better. +BSDI 4.* -=head1 Utility Changes +Perl now works on post-4.0 BSD/OSes. -=head2 h2ph +=item * -[TODO - Kurt Starsinic ] +All BSDs -=head2 perlcc +Setting C<$0> now works (as much as possible; see perlvar for details). -C now supports the C and Bytecode backends. By default, -it generates output from the simple C backend rather than the -optimized C backend. +=item * -Support for non-Unix platforms has been improved. +Cygwin -=head2 h2xs +Numerous updates; currently synchronised with Cygwin 1.1.4. -change#4232 -[TODO - Ilya Zakharevich ] +=item * -=head1 Documentation Changes +EPOC -=over 4 +EPOC update after Perl 5.6.0. See README.epoc. -=item perlapi.pod +=item * -The official list of public Perl API functions. +FreeBSD 3.* -=item perlcompile.pod +Perl now works on post-3.0 FreeBSDs. -An introduction to using the Perl Compiler suite. +=item * -=item perlfilter.pod +HP-UX -An introduction to writing Perl source filters. +README.hpux updated; C now almost works. -=item perlhack.pod +=item * -Some guidelines for hacking the Perl source code. +IRIX -=item perlintern.pod +Numerous compilation flag and hint enhancements; accidental mixing +of 32-bit and 64-bit libraries (a doomed attempt) made much harder. -A list of internal functions in the Perl source code. -(List is currently empty.) +=item * -=item perlopentut.pod +Linux -A tutorial on using open() effectively. +Long doubles should now work (see INSTALL). -=item perlreftut.pod +=item * -A tutorial that introduces the essentials of references. +MacOS Classic -=item perlboot.pod +Compilation of the standard Perl distribution in MacOS Classic should +now work if you have the Metrowerks development environment and +the missing Mac-specific toolkit bits. Contact the macperl mailing +list for details. -A tutorial for beginners on object-oriented Perl. +=item * -=item perltootc.pod +MPE/iX -A tutorial on managing class data for object modules. +MPE/iX update after Perl 5.6.0. See README.mpeix. -=item perlunicode.pod +=item * -An introduction to Unicode support features in Perl. +NetBSD/sparc -=back +Perl now works on NetBSD/sparc. -=head1 New or Changed Diagnostics +=item * -=over 4 +OS/2 -=item "%s" variable %s masks earlier declaration in same %s +Now works with usethreads (see INSTALL). -(W) A "my" or "our" variable has been redeclared in the current scope or statement, -effectively eliminating all access to the previous instance. This is almost -always a typographical error. Note that the earlier variable will still exist -until the end of the scope or until all closure referents to it are -destroyed. +=item * -=item "my sub" not yet implemented +Solaris -(F) Lexically scoped subroutines are not yet implemented. Don't try that -yet. +64-bitness using the Sun Workshop compiler now works. -=item "our" variable %s redeclared +=item * -(W) You seem to have already declared the same global once before in the -current lexical scope. +Tru64 (aka Digital UNIX, aka DEC OSF/1) -=item '!' allowed only after types %s +The operating system version letter now recorded in $Config{osvers}. +Allow compiling with gcc (previously explicitly forbidden). Compiling +with gcc still not recommended because buggy code results, even with +gcc 2.95.2. -(F) The '!' is allowed in pack() and unpack() only after certain types. -See L. +=item * -=item / cannot take a count +Unicos -(F) You had an unpack template indicating a counted-length string, -but you have also specified an explicit size for the string. -See L. +Fixed various alignment problems that lead into core dumps either +during build or later; no longer dies on math errors at runtime; +now using full quad integers (64 bits), previously was using +only 46 bit integers for speed. -=item / must be followed by a, A or Z +=item * -(F) You had an unpack template indicating a counted-length string, -which must be followed by one of the letters a, A or Z -to indicate what sort of string is to be unpacked. -See L. +VMS -=item / must be followed by a*, A* or Z* +chdir() now works better despite a CRT bug; now works with MULTIPLICITY +(see INSTALL); now works with Perl's malloc. -(F) You had a pack template indicating a counted-length string, -Currently the only things that can have their length counted are a*, A* or Z*. -See L. +=item * -=item / must follow a numeric type +Windows -(F) You had an unpack template that contained a '#', -but this did not follow some numeric unpack specification. -See L. +=over 8 -=item /%s/: Unrecognized escape \\%c passed through +=item * -(W) You used a backslash-character combination which is not recognized -by Perl. This combination appears in an interpolated variable or a -C<'>-delimited regular expression. The character was understood literally. +accept() no longer leaks memory. -=item /%s/: Unrecognized escape \\%c in character class passed through +=item * -(W) You used a backslash-character combination which is not recognized -by Perl inside character classes. The character was understood literally. +Better chdir() return value for a non-existent directory. -=item /%s/ should probably be written as "%s" +=item * -(W) You have used a pattern where Perl expected to find a string, -as in the first argument to C. Perl will treat the true -or false result of matching the pattern against $_ as the string, -which is probably not what you had in mind. +New %ENV entries now propagate to subprocesses. -=item %s() called too early to check prototype +=item * -(W) You've called a function that has a prototype before the parser saw a -definition or declaration for it, and Perl could not check that the call -conforms to the prototype. You need to either add an early prototype -declaration for the subroutine in question, or move the subroutine -definition ahead of the call to get proper prototype checking. Alternatively, -if you are certain that you're calling the function correctly, you may put -an ampersand before the name to avoid the warning. See L. +$ENV{LIB} now used to search for libs under Visual C. -=item %s argument is not a HASH or ARRAY element +=item * -(F) The argument to exists() must be a hash or array element, such as: +A failed (pseudo)fork now returns undef and sets errno to EAGAIN. - $foo{$bar} - $ref->[12]->["susie"] +=item * -=item %s argument is not a HASH or ARRAY element or slice +Allow REG_EXPAND_SZ keys in the registry. -(F) The argument to delete() must be either a hash or array element, such as: +=item * - $foo{$bar} - $ref->[12]->["susie"] +Can now send() from all threads, not just the first one. -or a hash or array slice, such as: +=item * - @foo[$bar, $baz, $xyzzy] - @{$ref->[12]}{"susie", "queue"} +Fake signal handling reenabled, bugs and all. -=item %s argument is not a subroutine name +=item * -(F) The argument to exists() for C must be a subroutine -name, and not a subroutine call. C will generate this error. +Less stack reserved per thread so that more threads can run +concurrently. (Still 16M per thread.) -=item %s package attribute may clash with future reserved word: %s +=item * -(W) A lowercase attribute name was used that had a package-specific handler. -That name might have a meaning to Perl itself some day, even though it -doesn't yet. Perhaps you should use a mixed-case attribute name, instead. -See L. +Ctmpdir()> now prefers C:/temp over /tmp +(works better when perl is running as service). -=item (in cleanup) %s +=item * -(W) This prefix usually indicates that a DESTROY() method raised -the indicated exception. Since destructors are usually called by -the system at arbitrary points during execution, and often a vast -number of times, the warning is issued only once for any number -of failures that would otherwise result in the same message being -repeated. +Better UNC path handling under ithreads. -Failure of user callbacks dispatched using the C flag -could also result in this warning. See L. +=item * -=item <> should be quotes +wait() and waitpid() now work much better. -(F) You wrote CfileE> when you should have written -C. +=item * -=item Attempt to join self +winsock handle leak fixed. -(F) You tried to join a thread from within itself, which is an -impossible task. You may be joining the wrong thread, or you may -need to move the join() to some other thread. +=back -=item Bad evalled substitution pattern +=back -(F) You've used the /e switch to evaluate the replacement for a -substitution, but perl found a syntax error in the code to evaluate, -most likely an unexpected right brace '}'. +=head1 New or Changed Diagnostics -=item Bad realloc() ignored +All regular expression compilation error messages are now hopefully +easier to understand both because the error message now comes before +the failed regex and because the point of failure is now clearly +marked. -(S) An internal routine called realloc() on something that had never been -malloc()ed in the first place. Mandatory, but can be disabled by -setting environment variable C to 1. +The various "opened only for", "on closed", "never opened" warnings +drop the C prefix for filehandles in the C
package, +for example C instead of . -=item Bareword found in conditional +The "Unrecognized escape" warning has been extended to include C<\8>, +C<\9>, and C<\_>. There is no need to escape any of the C<\w> characters. -(W) The compiler found a bareword where it expected a conditional, -which often indicates that an || or && was parsed as part of the -last argument of the previous construct, for example: +=over 4 - open FOO || die; +Two new debugging options have been added: if you have compiled your +Perl with debugging, you can use the -DT and -DR options to trace +tokenising and to add reference counts to displaying variables, +respectively. -It may also indicate a misspelled constant that has been interpreted -as a bareword: +=item * - use constant TYPO => 1; - if (TYOP) { print "foo" } +If an attempt to use a (non-blessed) reference as an array index +is made, a warning is given. -The C pragma is useful in avoiding such errors. +=item * -=item Binary number > 0b11111111111111111111111111111111 non-portable +C and C (with no values to push or unshift) +now give a warning. This may be a problem for generated and evaled +code. -(W) The binary number you specified is larger than 2**32-1 -(4294967295) and therefore non-portable between systems. See -L for more on portability concerns. +=back -=item Bit vector size > 32 non-portable +=head1 Changed Internals -(W) Using bit vector sizes larger than 32 is non-portable. +=over 4 -=item Buffer overflow in prime_env_iter: %s +=item * -(W) A warning peculiar to VMS. While Perl was preparing to iterate over -%ENV, it encountered a logical name or symbol definition which was too long, -so it was truncated to the string shown. +perlapi.pod (a companion to perlguts) now attempts to document the +internal API. -=item Can't check filesystem of script "%s" +=item * -(P) For some reason you can't check the filesystem of the script for nosuid. +You can now build a really minimal perl called microperl. +Building microperl does not require even running Configure; +C should be enough. Beware: microperl makes +many assumptions, some of which may be too bold; the resulting +executable may crash or otherwise misbehave in wondrous ways. +For careful hackers only. -=item Can't declare class for non-scalar %s in "%s" +=item * -(S) Currently, only scalar variables can declared with a specific class -qualifier in a "my" or "our" declaration. The semantics may be extended -for other types of variables in future. +Added rsignal(), whichsig(), do_join() to the publicised API. -=item Can't declare %s in "%s" +=item * -(F) Only scalar, array, and hash variables may be declared as "my" or -"our" variables. They must have ordinary identifiers as names. +Made possible to propagate customised exceptions via croak()ing. -=item Can't ignore signal CHLD, forcing to default +=item * -(W) Perl has detected that it is being run with the SIGCHLD signal -(sometimes known as SIGCLD) disabled. Since disabling this signal -will interfere with proper determination of exit status of child -processes, Perl has reset the signal to its default value. -This situation typically indicates that the parent program under -which Perl may be running (e.g. cron) is being very careless. +Added is_utf8_char(), is_utf8_string(), bytes_to_utf8(), and utf8_to_bytes(). -=item Can't modify non-lvalue subroutine call +=item * -(F) Subroutines meant to be used in lvalue context should be declared as -such, see L. +Now xsubs can have attributes just like subs. -=item Can't read CRTL environ +=item * -(S) A warning peculiar to VMS. Perl tried to read an element of %ENV -from the CRTL's internal environment array and discovered the array was -missing. You need to figure out where your CRTL misplaced its environ -or define F (see L) so that environ is not searched. +Some new APIs: ptr_table_clear(), ptr_table_free(), sv_setref_uv(). +For the full list of the available APIs see L. -=item Can't remove %s: %s, skipping file +=item * -(S) You requested an inplace edit without creating a backup file. Perl -was unable to remove the original file to replace it with the modified -file. The file was left unmodified. +dTHR and djSP have been obsoleted; the former removed (because it's +a no-op) and the latter replaced with dSP. -=item Can't return %s from lvalue subroutine +=item * -(F) Perl detected an attempt to return illegal lvalues (such -as temporary or readonly values) from a subroutine used as an lvalue. -This is not allowed. +Perl now uses system malloc instead of Perl malloc on all 64-bit +platforms, and even in some not-always-64-bit platforms like AIX, +IRIX, and Solaris. This change breaks backward compatibility but +Perl's malloc has problems with large address spaces and also the +speed of vendors' malloc is generally better in large address space +machines (Perl's malloc is mostly tuned for space). -=item Can't weaken a nonreference +=back -(F) You attempted to weaken something that was not a reference. Only -references can be weakened. +=head1 Security Vulnerability Closed -=item Character class [:%s:] unknown +(This change was already made in 5.7.0 but bears repeating here.) -(F) The class in the character class [: :] syntax is unknown. -See L. +A potential security vulnerability in the optional suidperl component +of Perl was identified in August 2000. suidperl is neither built nor +installed by default. As of November 2001 the only known vulnerable +platform is Linux, most likely all Linux distributions. CERT and +various vendors and distributors have been alerted about the vulnerability. +See http://www.cpan.org/src/5.0/sperl-2000-08-05/sperl-2000-08-05.txt +for more information. -=item Character class syntax [%s] belongs inside character classes +The problem was caused by Perl trying to report a suspected security +exploit attempt using an external program, /bin/mail. On Linux +platforms the /bin/mail program had an undocumented feature which +when combined with suidperl gave access to a root shell, resulting in +a serious compromise instead of reporting the exploit attempt. If you +don't have /bin/mail, or if you have 'safe setuid scripts', or if +suidperl is not installed, you are safe. + +The exploit attempt reporting feature has been completely removed from +Perl 5.8.0 (and the maintenance release 5.6.1, and it was removed also +from all the Perl 5.7 releases), so that particular vulnerability +isn't there anymore. However, further security vulnerabilities are, +unfortunately, always possible. The suidperl code is being reviewed +and if deemed too risky to continue to be supported, it may be +completely removed from future releases. In any case, suidperl should +only be used by security experts who know exactly what they are doing +and why they are using suidperl instead of some other solution such as +sudo (see http://www.courtesan.com/sudo/). + +=head1 Selected Bug Fixes + +Numerous memory leaks and uninitialized memory accesses have been hunted down. +Most importantly anonymous subs used to leak quite a bit. -(W) The character class constructs [: :], [= =], and [. .] go -I character classes, the [] are part of the construct, -for example: /[012[:alpha:]345]/. Note that [= =] and [. .] -are not currently implemented; they are simply placeholders for -future extensions. +=over 4 -=item Constant is not %s reference +=item * -(F) A constant value (perhaps declared using the C pragma) -is being dereferenced, but it amounts to the wrong type of reference. The -message indicates the type of reference that was expected. This usually -indicates a syntax error in dereferencing the constant value. -See L and L. +chop(@list) in list context returned the characters chopped in +reverse order. This has been reversed to be in the right order. -=item constant(%s): %%^H is not localized +=item * -(F) When setting compile-time-lexicalized hash %^H one should set the -corresponding bit of $^H as well. +The order of DESTROYs has been made more predictable. -=item constant(%s): %s +=item * -(F) Compile-time-substitutions (such as overloaded constants and -character names) were not correctly set up. +mkdir() now ignores trailing slashes in the directory name, +as mandated by POSIX. -=item defined(@array) is deprecated +=item * -(D) defined() is not usually useful on arrays because it checks for an -undefined I value. If you want to see if the array is empty, -just use C for example. +Attributes (like :shared) didn't work with our(). -=item defined(%hash) is deprecated +=item * -(D) defined() is not usually useful on hashes because it checks for an -undefined I value. If you want to see if the hash is empty, -just use C for example. +The PERL5OPT environment variable (for passing command line arguments +to Perl) didn't work for more than a single group of options. -=item Did not produce a valid header +=item * -See Server error. +The tainting behaviour of sprintf() has been rationalized. It does +not taint the result of floating point formats anymore, making the +behaviour consistent with that of string interpolation. -=item Did you mean "local" instead of "our"? +=item * -(W) Remember that "our" does not localize the declared global variable. -You have declared it again in the same lexical scope, which seems superfluous. +All but the first argument of the IO syswrite() method are now optional. -=item Document contains no data +=item * -See Server error. +Tie::ARRAY SPLICE method was broken. -=item entering effective %s failed +=item * -(F) While under the C pragma, switching the real and -effective uids or gids failed. +vec() now tries to work with characters <= 255 when possible, but it leaves +higher character values in place. In that case, if vec() was used to modify +the string, it is no longer considered to be utf8-encoded. -=item false [] range "%s" in regexp +=item * -(W) A character class range must start and end at a literal character, not -another character class like C<\d> or C<[:alpha:]>. The "-" in your false -range is interpreted as a literal "-". Consider quoting the "-", "\-". -See L. +The autouse pragma didn't work for Multi::Part::Function::Names. -=item Filehandle %s opened only for output +=item * -(W) You tried to read from a filehandle opened only for writing. If you -intended it to be a read/write filehandle, you needed to open it with -"+E" or "+E" or "+EE" instead of with "E" or nothing. If -you intended only to read from the file, use "E". See -L. +The behaviour of non-decimal but numeric string constants such as +"0x23" was platform-dependent: in some platforms that was seen as 35, +in some as 0, in some as a floating point number (don't ask). This +was caused by Perl using the operating system libraries in a situation +where the result of the string to number conversion is undefined: now +Perl consistently handles such strings as zero in numeric contexts. -=item flock() on closed filehandle %s +=item * -(W) The filehandle you're attempting to flock() got itself closed some -time before now. Check your logic flow. flock() operates on filehandles. -Are you attempting to call flock() on a dirhandle by the same name? +L -R didn't work. -=item Global symbol "%s" requires explicit package name +=item * -(F) You've said "use strict vars", which indicates that all variables -must either be lexically scoped (using "my"), declared beforehand using -"our", or explicitly qualified to say which package the global variable -is in (using "::"). +PERL5OPT with embedded spaces didn't work. -=item Hexadecimal number > 0xffffffff non-portable +=item * -(W) The hexadecimal number you specified is larger than 2**32-1 -(4294967295) and therefore non-portable between systems. See -L for more on portability concerns. +L ignored the C constant. -=item Ill-formed CRTL environ value "%s" +=back -(W) A warning peculiar to VMS. Perl tried to read the CRTL's internal -environ array, and encountered an element without the C<=> delimiter -used to spearate keys from values. The element is ignored. +=head2 Platform Specific Changes and Fixes -=item Ill-formed message in prime_env_iter: |%s| +=over 4 -(W) A warning peculiar to VMS. Perl tried to read a logical name -or CLI symbol definition when preparing to iterate over %ENV, and -didn't see the expected delimiter between key and value, so the -line was ignored. +=item * -=item Illegal binary digit %s +Some versions of glibc have a broken modfl(). This affects builds +with C<-Duselongdouble>. This version of Perl detects this brokenness +and has a workaround for it. The glibc release 2.2.2 is known to have +fixed the modfl() bug. -(F) You used a digit other than 0 or 1 in a binary number. +=back -=item Illegal binary digit %s ignored +=head2 Platform Specific Changes and Fixes -(W) You may have tried to use a digit other than 0 or 1 in a binary number. -Interpretation of the binary number stopped before the offending digit. +=over 4 -=item Illegal number of bits in vec +=item * -(F) The number of bits in vec() (the third argument) must be a power of -two from 1 to 32 (or 64, if your platform supports that). +Linux previously had problems related to sockaddrlen when using +accept(), revcfrom() (in Perl: recv()), getpeername(), and getsockname(). -=item Integer overflow in %s number +=item * -(W) The hexadecimal, octal or binary number you have specified either -as a literal or as an argument to hex() or oct() is too big for your -architecture, and has been converted to a floating point number. On a -32-bit architecture the largest hexadecimal, octal or binary number -representable without overflow is 0xFFFFFFFF, 037777777777, or -0b11111111111111111111111111111111 respectively. Note that Perl -transparently promotes all numbers to a floating point representation -internally--subject to loss of precision errors in subsequent -operations. +Previously DYNIX/ptx had problems in its Configure probe for non-blocking I/O. -=item Invalid %s attribute: %s +=item * -The indicated attribute for a subroutine or variable was not recognized -by Perl or by a user-supplied handler. See L. +Windows -=item Invalid %s attributes: %s +=over 8 -The indicated attributes for a subroutine or variable were not recognized -by Perl or by a user-supplied handler. See L. +=item * -=item invalid [] range "%s" in regexp +Borland C++ v5.5 is now a supported compiler that can build Perl. +However, the generated binaries continue to be incompatible with those +generated by the other supported compilers (GCC and Visual C++). -The offending range is now explicitly displayed. +=item * -=item Invalid separator character %s in attribute list +Win32::GetCwd() correctly returns C:\ instead of C: when at the drive root. +Other bugs in chdir() and Cwd::cwd() have also been fixed. -(F) Something other than a colon or whitespace was seen between the -elements of an attribute list. If the previous attribute -had a parenthesised parameter list, perhaps that list was terminated -too soon. See L. +=item * -=item Invalid separator character %s in subroutine attribute list +Duping socket handles with open(F, ">&MYSOCK") now works under Windows 9x. -(F) Something other than a colon or whitespace was seen between the -elements of a subroutine attribute list. If the previous attribute -had a parenthesised parameter list, perhaps that list was terminated -too soon. +=item * -=item leaving effective %s failed +HTML files will be installed in c:\perl\html instead of c:\perl\lib\pod\html -(F) While under the C pragma, switching the real and -effective uids or gids failed. +=item * -=item Lvalue subs returning %s not implemented yet +The makefiles now provide a single switch to bulk-enable all the features +enabled in ActiveState ActivePerl (a popular binary distribution). -(F) Due to limitations in the current implementation, array and hash -values cannot be returned in subroutines used in lvalue context. -See L. +=back -=item Method %s not permitted +=head1 New Tests -See Server error. +Several new tests have been added, especially for the F subsection. -=item Missing %sbrace%s on \N{} +The tests are now reported in a different order than in earlier Perls. +(This happens because the test scripts from under t/lib have been moved +to be closer to the library/extension they are testing.) -(F) Wrong syntax of character name literal C<\N{charname}> within -double-quotish context. +=head1 New or Changed Diagnostics -=item Missing command in piped open +=over 4 -(W) You used the C or C -construction, but the command was missing or blank. +=item * -=item Missing name in "my sub" +In the regular expression diagnostics the CE HERE> marker +introduced in 5.7.0 has been changed to be C-- HERE> since too +many people found the CE> to be too similar to here-document +starters. -(F) The reserved syntax for lexically scoped subroutines requires that they -have a name with which they can be found. +=item * -=item No %s specified for -%c +If you try to L a number less than 0 or larger than 255 +using the C<"C"> format you will get an optional warning. Similarly +for the C<"c"> format and a number less than -128 or more than 127. -(F) The indicated command line switch needs a mandatory argument, but -you haven't specified one. +=item * -=item No package name allowed for variable %s in "our" +Certain regex modifiers such as C<(?o)> make sense only if applied to +the entire regex. You will an optional warning if you try to do otherwise. -(F) Fully qualified variable names are not allowed in "our" declarations, -because that doesn't make much sense under existing semantics. Such -syntax is reserved for future extensions. +=item * -=item No space allowed after -%c +Using arrays or hashes as references (e.g. C<%foo->{bar}> has been +deprecated for a while. Now you will get an optional warning. -(F) The argument to the indicated command line switch must follow immediately -after the switch, without intervening spaces. +=back -=item no UTC offset information; assuming local time is UTC +=head1 Source Code Enhancements -(S) A warning peculiar to VMS. Perl was unable to find the local -timezone offset, so it's assuming that local system time is equivalent -to UTC. If it's not, define the logical name F -to translate to the number of seconds which need to be added to UTC to -get local time. +=head2 MAGIC constants -=item Octal number > 037777777777 non-portable +The MAGIC constants (e.g. C<'P'>) have been macrofied +(e.g. C) for better source code readability +and maintainability. -(W) The octal number you specified is larger than 2**32-1 (4294967295) -and therefore non-portable between systems. See L for more -on portability concerns. +=head2 Better commented code -See also L for writing portable code. +F, F, and F have now been extensively commented. -=item panic: del_backref +=head2 Regex pre-/post-compilation items matched up -(P) Failed an internal consistency check while trying to reset a weak -reference. +The regex compiler now maintains a structure that identifies nodes in +the compiled bytecode with the corresponding syntactic features of the +original regex expression. The information is attached to the new +C member of the C. See L for more +complete information. -=item panic: kid popen errno read +=head2 gcc -Wall -(F) forked child returned an incomprehensible message about its errno. +The C code has been made much more C clean. Some warning +messages still remain, though, so if you are compiling with gcc you +will see some warnings about dubious practices. The warnings are +being worked on. -=item panic: magic_killbackrefs +=head1 Known Problems -(P) Failed an internal consistency check while trying to reset all weak -references to an object. +Note that unlike other sections in this document (which describe +changes since 5.7.0) this section is cumulative containing known +problems for all the 5.7 releases. -=item Parentheses missing around "%s" list +=head2 AIX -(W) You said something like +=over 4 - my $foo, $bar = @_; +=item * -when you meant +In AIX 4.2 Perl extensions that use C++ functions that use statics +may have problems in that the statics are not getting initialized. +In newer AIX releases this has been solved by linking Perl with +the libC_r library, but unfortunately in AIX 4.2 the said library +has an obscure bug where the various functions related to time +(such as time() and gettimeofday()) return broken values, and +therefore in AIX 4.2 Perl is not linked against the libC_r. - my ($foo, $bar) = @_; +=item * -Remember that "my", "our", and "local" bind tighter than comma. +vac 5.0.0.0 May Produce Buggy Code For Perl -=item Possible Y2K bug: %s +The AIX C compiler vac version 5.0.0.0 may produce buggy code, +resulting in few random tests failing, but when the failing tests +are run by hand, they succeed. We suggest upgrading to at least +vac version 5.0.1.0, that has been known to compile Perl correctly. +"lslpp -L|grep vac.C" will tell you the vac version. -(W) You are concatenating the number 19 with another number, which -could be a potential Year 2000 problem. +=back -=item Premature end of script headers +=head2 Amiga Perl Invoking Mystery -See Server error. +One cannot call Perl using the C syntax, that is, C +works, but for example C doesn't. The exact reason is +known but the current suspect is the F library. -=item Repeat count in pack overflows +=head2 lib/ftmp-security tests warn 'system possibly insecure' -(F) You can't specify a repeat count so large that it overflows -your signed integers. See L. +Don't panic. Read INSTALL 'make test' section instead. -=item Repeat count in unpack overflows +=head2 Cygwin intermittent failures of lib/Memoize/t/expire_file 11 and 12 -(F) You can't specify a repeat count so large that it overflows -your signed integers. See L. +The subtests 11 and 12 sometimes fail and sometimes work. -=item realloc() of freed memory ignored +=head2 HP-UX lib/io_multihomed Fails When LP64-Configured -(S) An internal routine called realloc() on something that had already -been freed. +The lib/io_multihomed test may hang in HP-UX if Perl has been +configured to be 64-bit. Because other 64-bit platforms do not hang in +this test, HP-UX is suspect. All other tests pass in 64-bit HP-UX. The +test attempts to create and connect to "multihomed" sockets (sockets +which have multiple IP addresses). -=item Reference is already weak +=head2 HP-UX lib/posix Subtest 9 Fails When LP64-Configured -(W) You have attempted to weaken a reference that is already weak. -Doing so has no effect. +If perl is configured with -Duse64bitall, the successful result of the +subtest 10 of lib/posix may arrive before the successful result of the +subtest 9, which confuses the test harness so much that it thinks the +subtest 9 failed. -=item setpgrp can't take arguments +=head2 Linux With Sfio Fails op/misc Test 48 -(F) Your system has the setpgrp() from BSD 4.2, which takes no arguments, -unlike POSIX setpgid(), which takes a process ID and process group ID. +No known fix. -=item Strange *+?{} on zero-length expression +=head2 OS/390 -(W) You applied a regular expression quantifier in a place where it -makes no sense, such as on a zero-width assertion. -Try putting the quantifier inside the assertion instead. For example, -the way to match "abc" provided that it is followed by three -repetitions of "xyz" is C, not C. +OS/390 has rather many test failures but the situation is actually +better than it was in 5.6.0, it's just that so many new modules and +tests have been added. -=item switching effective %s is not implemented + Failed Test Stat Wstat Total Fail Failed List of Failed + ----------------------------------------------------------------------------- + ../ext/B/Deparse.t 14 1 7.14% 14 + ../ext/B/Showlex.t 1 1 100.00% 1 + ../ext/Encode/Encode/Tcl.t 610 13 2.13% 592 594 596 598 + 600 602 604-610 + ../ext/IO/lib/IO/t/io_unix.t 113 28928 5 3 60.00% 3-5 + ../ext/POSIX/POSIX.t 29 1 3.45% 14 + ../ext/Storable/t/lock.t 255 65280 5 3 60.00% 3-5 + ../lib/locale.t 129 33024 117 19 16.24% 99-117 + ../lib/warnings.t 434 1 0.23% 75 + ../lib/ExtUtils.t 27 1 3.70% 25 + ../lib/Math/BigInt/t/bigintpm.t 1190 1 0.08% 1145 + ../lib/Unicode/UCD.t 81 48 59.26% 1-16 49-64 66-81 + ../lib/User/pwent.t 9 1 11.11% 4 + op/pat.t 660 6 0.91% 242-243 424-425 + 626-627 + op/split.t 0 9 ?? ?? % ?? + op/taint.t 174 3 1.72% 156 162 168 + op/tr.t 70 3 4.29% 50 58-59 + Failed 16/422 test scripts, 96.21% okay. 105/23251 subtests failed, 99.55% okay. -(F) While under the C pragma, we cannot switch the -real and effective uids or gids. +=head2 op/sprintf tests 129 and 130 -=item This Perl can't reset CRTL environ elements (%s) +The op/sprintf tests 129 and 130 are known to fail on some platforms. +Examples include any platform using sfio, and Compaq/Tandem's NonStop-UX. +The failing platforms do not comply with the ANSI C Standard, line +19ff on page 134 of ANSI X3.159 1989 to be exact. (They produce +something other than "1" and "-1" when formatting 0.6 and -0.6 using +the printf format "%.0f", most often they produce "0" and "-0".) -=item This Perl can't set CRTL environ elements (%s=%s) +=head2 Failure of Thread tests -(W) Warnings peculiar to VMS. You tried to change or delete an element -of the CRTL's internal environ array, but your copy of Perl wasn't -built with a CRTL that contained the setenv() function. You'll need to -rebuild Perl with a CRTL that does, or redefine F (see -L) so that the environ array isn't the target of the change to -%ENV which produced the warning. +B -=item Unknown open() mode '%s' +The following tests are known to fail due to fundamental problems in +the 5.005 threading implementation. These are not new failures--Perl +5.005_0x has the same bugs, but didn't have these tests. -(F) The second argument of 3-argument open() is not among the list -of valid modes: C>, C>, CE>, C<+E>, -C<+E>, C<+EE>, C<-|>, C<|E<45>>. + lib/autouse.t 4 + t/lib/thr5005.t 19-20 -=item Unknown process %x sent message to prime_env_iter: %s +=head2 UNICOS -(P) An error peculiar to VMS. Perl was reading values for %ENV before -iterating over it, and someone else stuck a message in the stream of -data Perl expected. Someone's very confused, or perhaps trying to -subvert Perl's population of %ENV for nefarious purposes. +=over 4 -=item Unrecognized escape \\%c passed through +=item * -(W) You used a backslash-character combination which is not recognized -by Perl. The character was understood literally. +ext/POSIX/sigaction subtests 6 and 13 may fail. -=item Unterminated attribute parameter in attribute list +=item * -(F) The lexer saw an opening (left) parenthesis character while parsing an -attribute list, but the matching closing (right) parenthesis -character was not found. You may need to add (or remove) a backslash -character to get your parentheses to balance. See L. +lib/ExtUtils may spuriously claim that subtest 28 failed, +which is interesting since the test only has 27 tests. -=item Unterminated attribute list +=item * -(F) The lexer found something other than a simple identifier at the start -of an attribute, and it wasn't a semicolon or the start of a -block. Perhaps you terminated the parameter list of the previous attribute -too soon. See L. +Numerous numerical test failures -=item Unterminated attribute parameter in subroutine attribute list + op/numconvert 209,210,217,218 + op/override 7 + ext/Time/HiRes/HiRes 9 + lib/Math/BigInt/t/bigintpm 1145 + lib/Math/Trig 25 -(F) The lexer saw an opening (left) parenthesis character while parsing a -subroutine attribute list, but the matching closing (right) parenthesis -character was not found. You may need to add (or remove) a backslash -character to get your parentheses to balance. +These tests fail because of yet unresolved floating point inaccuracies. -=item Unterminated subroutine attribute list +=back -(F) The lexer found something other than a simple identifier at the start -of a subroutine attribute, and it wasn't a semicolon or the start of a -block. Perhaps you terminated the parameter list of the previous attribute -too soon. +=head2 UTS -=item Value of CLI symbol "%s" too long +There are a few known test failures, see L. -(W) A warning peculiar to VMS. Perl tried to read the value of an %ENV -element from a CLI symbol table, and found a resultant string longer -than 1024 characters. The return value has been truncated to 1024 -characters. +=head2 VMS -=item Version number must be a constant number +Rather many tests are failing in VMS but that actually more tests +succeed in VMS than they used to, it's just that there are many, +many more tests than there used to be. + +Here are the known failures from some compiler/platform combinations. + +DEC C V5.3-006 on OpenVMS VAX V6.2 + + [-.ext.list.util.t]tainted..............FAILED on test 3 + [-.ext.posix]sigaction..................FAILED on test 7 + [-.ext.time.hires]hires.................FAILED on test 14 + [-.lib.file.find]taint..................FAILED on test 17 + [-.lib.math.bigint.t]bigintpm...........FAILED on test 1183 + [-.lib.test.simple.t]exit...............FAILED on test 1 + [.lib]vmsish............................FAILED on test 13 + [.op]sprintf............................FAILED on test 12 + Failed 8/399 tests, 91.23% okay. + +DEC C V6.0-001 on OpenVMS Alpha V7.2-1 and +Compaq C V6.2-008 on OpenVMS Alpha V7.1 + + [-.ext.list.util.t]tainted..............FAILED on test 3 + [-.lib.file.find]taint..................FAILED on test 17 + [-.lib.test.simple.t]exit...............FAILED on test 1 + [.lib]vmsish............................FAILED on test 13 + Failed 4/399 tests, 92.48% okay. + +Compaq C V6.4-005 on OpenVMS Alpha 7.2.1 + + [-.ext.b]showlex........................FAILED on test 1 + [-.ext.list.util.t]tainted..............FAILED on test 3 + [-.lib.file.find]taint..................FAILED on test 17 + [-.lib.test.simple.t]exit...............FAILED on test 1 + [.lib]vmsish............................FAILED on test 13 + [.op]misc...............................FAILED on test 49 + Failed 6/401 tests, 92.77% okay. -(P) The attempt to translate a C statement into -its equivalent C block found an internal inconsistency with -the version number. +=head2 Win32 -=back +In multi-CPU boxes there are some problems with the I/O buffering: +some output may appear twice. -=head1 Obsolete Diagnostics +=head2 Localising a Tied Variable Leaks Memory -=over 4 + use Tie::Hash; + tie my %tie_hash => 'Tie::StdHash'; -=item Character class syntax [: :] is reserved for future extensions + ... -(W) Within regular expression character classes ([]) the syntax beginning -with "[:" and ending with ":]" is reserved for future extensions. -If you need to represent those character sequences inside a regular -expression character class, just quote the square brackets with the -backslash: "\[:" and ":\]". + local($tie_hash{Foo}) = 1; # leaks -=item Ill-formed logical name |%s| in prime_env_iter +Code like the above is known to leak memory every time the local() +is executed. -(W) A warning peculiar to VMS. A logical name was encountered when preparing -to iterate over %ENV which violates the syntactic rules governing logical -names. Because it cannot be translated normally, it is skipped, and will not -appear in %ENV. This may be a benign occurrence, as some software packages -might directly modify logical name tables and introduce nonstandard names, -or it may indicate that a logical name table has been corrupted. +=head2 Self-tying of Arrays and Hashes Is Forbidden -=item Probable precedence problem on %s +Self-tying of arrays and hashes is broken in rather deep and +hard-to-fix ways. As a stop-gap measure to avoid people from getting +frustrated at the mysterious results (core dumps, most often) it is +for now forbidden (you will get a fatal error even from an attempt). -(W) The compiler found a bareword where it expected a conditional, -which often indicates that an || or && was parsed as part of the -last argument of the previous construct, for example: +=head2 Variable Attributes are not Currently Usable for Tieing - open FOO || die; +This limitation will hopefully be fixed in future. (Subroutine +attributes work fine for tieing, see L). -=item regexp too big +=head2 Building Extensions Can Fail Because Of Largefiles -(F) The current implementation of regular expressions uses shorts as -address offsets within a string. Unfortunately this means that if -the regular expression compiles to longer than 32767, it'll blow up. -Usually when you want a regular expression this big, there is a better -way to do it with multiple statements. See L. +Some extensions like mod_perl are known to have issues with +`largefiles', a change brought by Perl 5.6.0 in which file offsets +default to 64 bits wide, where supported. Modules may fail to compile +at all or compile and work incorrectly. Currently there is no good +solution for the problem, but Configure now provides appropriate +non-largefile ccflags, ldflags, libswanted, and libs in the %Config +hash (e.g., $Config{ccflags_nolargefiles}) so the extensions that are +having problems can try configuring themselves without the +largefileness. This is admittedly not a clean solution, and the +solution may not even work at all. One potential failure is whether +one can (or, if one can, whether it's a good idea) link together at +all binaries with different ideas about file offsets, all this is +platform-dependent. -=item Use of "$$" to mean "${$}" is deprecated +=head2 The Compiler Suite Is Still Experimental -(D) Perl versions before 5.004 misinterpreted any type marker followed -by "$" and a digit. For example, "$$0" was incorrectly taken to mean -"${$}0" instead of "${$0}". This bug is (mostly) fixed in Perl 5.004. +The compiler suite is slowly getting better but is nowhere near +working order yet. -However, the developers of Perl 5.004 could not fix this bug completely, -because at least two widely-used modules depend on the old meaning of -"$$0" in a string. So Perl 5.004 still interprets "$$" in the -old (broken) way inside strings; but it generates this message as a -warning. And in Perl 5.005, this special treatment will cease. +=head2 The Long Double Support is Still Experimental -=back +The ability to configure Perl's numbers to use "long doubles", +floating point numbers of hopefully better accuracy, is still +experimental. The implementations of long doubles are not yet +widespread and the existing implementations are not quite mature +or standardised, therefore trying to support them is a rare +and moving target. The gain of more precision may also be offset +by slowdown in computations (more bits to move around, and the +operations are more likely to be executed by less optimised +libraries). -=head1 BUGS +=head1 Reporting Bugs -If you find what you think is a bug, you might check the -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 find what you think is a bug, you might check the articles +recently posted to the comp.lang.perl.misc newsgroup and the perl +bug database at http://bugs.perl.org. 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 -program included with your release. Make sure to trim your bug down +program included with your release. Be sure to trim your bug down to a tiny but sufficient test case. Your bug report, along with the -output of C, will be sent off to perlbug@perl.com to be +output of C, will be sent off to perlbug@perl.org to be analysed by the Perl porting team. =head1 SEE ALSO @@ -2546,9 +2344,6 @@ The F and F files for copyright information. =head1 HISTORY -Written by Gurusamy Sarathy >, with many -contributions from The Perl Porters. - -Send omissions or corrections to >. +Written by Jarkko Hietaniemi >. =cut