From: Rafael Garcia-Suarez Date: Sun, 21 Oct 2007 16:38:36 +0000 (+0000) Subject: More perldelta entries from 5.9.3 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=bd3831ee36b38be31ca6d539b023015187107907;p=p5sagit%2Fp5-mst-13.2.git More perldelta entries from 5.9.3 p4raw-id: //depot/perl@32155 --- diff --git a/pod/perl5100delta.pod b/pod/perl5100delta.pod index a11a652..321eaa2 100644 --- a/pod/perl5100delta.pod +++ b/pod/perl5100delta.pod @@ -1,5 +1,3 @@ -TODO: perl591delta and further - =head1 NAME perldelta - what is new for perl 5.10.0 @@ -616,13 +614,41 @@ C, by Richard Clamp, is a small handy module that tells you what versions of core modules ship with any versions of Perl 5. It comes with a command-line frontend, C. +=item * + +C is an XS-enabled, and thus faster, version of +C. + +=item * + +C is an interface to the zlib compression library. It +comes with a bundled version of zlib, so having a working zlib is not a +prerequisite to install it. It's used by C (see below). + +=item * + +C is an C-style interface to C. + +=item * + +C is a module to manipulate C archives. + +=item * + +C is a module used to calculate many types of SHA digests, +has been included for SHA support in the CPAN module. + +=item * + +C and C have been added. + =back =head1 Utility Changes =over 4 -=item * +=item perl -d The Perl debugger can now save all debugger commands for sourcing later; notably, it can now emulate stepping backwards, by restarting and @@ -634,17 +660,45 @@ C command. Perl has a new -dt command-line flag, which enables threads support in the debugger. -=item * +=item ptar + +C is a pure perl implementation of C, that comes with +C. + +=item ptardiff + +C is a small script used to generate a diff between the contents +of a tar archive and a directory tree. Like C, it comes with +C. + +=item shasum + +C is a command-line utility, used to print or to check SHA +digests. It comes with the new C module. + +=item corelist The C utility is now installed with perl (see L above). -=item * +=item h2ph and h2xs C and C have been made a bit more robust with regard to "modern" C code. -=item * +C implements a new option C<--use-xsloader> to force use of +C even in backwards compatible modules. + +The handling of authors' names that had apostrophes has been fixed. + +Any enums with negative values are now skipped. + +=item perlivp + +C no longer checks for F<*.ph> files by default. Use the new C<-a> +option to run I tests. + +=item find2perl C now assumes C<-print> as a default action. Previously, it needed to be specified explicitly. @@ -657,6 +711,10 @@ added. =head1 New Documentation +The new L manpage is a glossary of terms used in the Perl +documentation, technical and otherwise, kindly provided by O'Reilly Media, +Inc. + The long-existing feature of C regexps setting C<$_> and pos() is now documented. @@ -664,7 +722,7 @@ is now documented. =over 4 -=item * +=item In-place sorting Sorting arrays in place (C<@a = sort @a>) is now optimized to avoid making a temporary copy of the array. @@ -672,22 +730,62 @@ making a temporary copy of the array. Likewise, C is now optimized to sort in reverse, avoiding the generation of a temporary intermediate list. -=item * +=item Lexical array access Access to elements of lexical arrays via a numeric constant between 0 and 255 is now faster. (This used to be only the case for global arrays.) -=item * +=item Trie optimization The regexp engine now implements the trie optimization : it's able to factorize common prefixes and suffixes in regular expressions. A new special variable, ${^RE_TRIE_MAXBUF}, has been added to fine-tune this optimization. +=item XS-assisted SWASHGET + +Some pure-perl code that perl was using to retrieve Unicode properties and +transliteration mappings has been reimplemented in XS. + +=item Constant subroutines + +The interpreter internals now support a far more memory efficient form of +inlineable constants. Storing a reference to a constant value in a symbol +table is equivalent to a full typeglob referencing a constant subroutine, +but using about 400 bytes less memory. This proxy constant subroutine is +automatically upgraded to a real typeglob with subroutine if necessary. +The approach taken is analogous to the existing space optimisation for +subroutine stub declarations, which are stored as plain scalars in place +of the full typeglob. + +Several of the core modules have been converted to use this feature for +their system dependent constants - as a result C now takes about +200K less memory. + +=item C + +The new compilation flag C, introduced as an option +in perl 5.8.8, is turned on by default in perl 5.9.3. It prevents perl +from creating an empty scalar with every new typeglob. See L +for details. + +=item Weak references are cheaper + +Weak reference creation is now I rather than I, courtesy of +Nicholas Clark. Weak reference deletion remains I, but if deletion only +happens at program exit, it may be skipped completely. + +=item sort() enhancements + +Salvador Fandiño provided improvements to reduce the memory usage of C +and to speed up some cases. + =back =head1 Installation and Configuration Improvements +=head2 Compilation improvements + Run-time customization of @INC can be enabled by passing the C<-Dusesitecustomize> flag to configure. When enabled, this will make perl run F<$sitelibexp/sitecustomize.pl> before anything else. This script can @@ -695,14 +793,93 @@ then be set up to add additional entries to @INC. There is alpha support for relocatable @INC entries. +Parallel makes should work properly now, although there may still be problems +if C is instructed to run in parallel. + +Building with Borland's compilers on Win32 should work more smoothly. In +particular Steve Hay has worked to side step many warnings emitted by their +compilers and at least one C compiler internal error. + +Perl extensions on Windows now can be statically built into the Perl DLL, +thanks to a work by Vadim Konovalov. + +=head2 New Or Improved Platforms + +Perl is being ported to Symbian OS. See L for more +information. + +The VMS port has been improved. See L. + +DynaLoader::dl_unload_file() now works on Windows. + +Portability of Perl on various recent compilers on Windows has been +improved (Borland C++, Visual C++ 7.0). + +=head2 Module auxiliary files + +README files and changelogs for CPAN modules bundled with perl are no +longer installed. + =head1 Selected Bug Fixes +=over 4 + +=item strictures in regexp-eval blocks + C wasn't in effect in regexp-eval blocks (C). -C<$Foo::_> was wrongly forced as C<$main::_>. +=item C + +C was ignoring taking a hard reference in an argument +to defined(), as in : + + use strict "refs"; + my $x = "foo"; + if (defined $$x) {...} + +This now correctly produces the run-time error C. + +=item Calling CORE::require() + +CORE::require() and CORE::do() were always parsed as require() and do() +when they were overridden. This is now fixed. + +=item Subscripts of slices + +You can now use a non-arrowed form for chained subscripts after a list +slice, like in: + + ({foo => "bar"})[0]{foo} + +This used to be a syntax error; a C<< -> >> was required. + +=item C works correctly with -w + +Previously when running with warnings enabled globally via C<-w>, selective +disabling of specific warning categories would actually turn off all warnings. +This is now fixed; now C will only turn off warnings in the +C class. Previously it would erroneously turn off all warnings. + +=item threads and memory usage + +Several memory leaks in ithreads were closed. Also, ithreads were made +less memory-intensive. + +=item chr() and negative values + +chr() on a negative value now gives C<\x{FFFD}>, the Unicode replacement +character, unless when the C pragma is in effect, where the low +eight bytes of the value are used. + +=back =head1 New or Changed Diagnostics +=over 4 + +=item Deprecated use of my() in false conditional + A new deprecation warning, I, has been added, to warn against the use of the dubious and deprecated construct @@ -711,20 +888,54 @@ construct See L. Use C variables instead. +=item !=~ should be !~ + A new warning, C, is emitted to prevent this misspelling of the non-matching operator. +=item Newline in left-justified string + The warning I has been removed. +=item Too late for "-T" option + The error I has been reformulated to be more descriptive. +=item "%s" variable %s masks earlier declaration + +This warning is now emitted in more consistent cases; in short, when one +of the declarations involved is a C variable: + + my $x; my $x; # warns + my $x; our $x; # warns + our $x; my $x; # warns + +On the other hand, the following: + + our $x; our $x; + +now gives a C<"our" variable %s redeclared> warning. + +=item readdir()/closedir()/etc. attempted on invalid dirhandle + +These new warnings are now emitted when a dirhandle is used but is +either closed or not really a dirhandle. + +=item perl -V + C has several improvements, making it more useable from shell scripts to get the value of configuration variables. See L for details. +=back + =head1 Changed Internals +In general, the source code of perl has been refactored, tied up, and +optimized in many places. Also, memory management and allocation has been +improved in a couple of points. + =head2 Reordering of SVt_* constants The relative ordering of constants that define the various types of C @@ -754,6 +965,36 @@ method anymore.) perl's parser is now generated by bison (it used to be generated by byacc.) As a result, it seems to be a bit more robust. +Also, Dave Mitchell improved the lexer debugging output under C<-DT>. + +=head2 Use of C + +Andy Lester supplied many improvements to determine which function +parameters and local variables could actually be declared C to the C +compiler. Steve Peters provided new C<*_set> macros and reworked the core to +use these rather than assigning to macros in LVALUE context. + +=head2 Mathoms + +A new file, F, has been added. It contains functions that are +no longer used in the perl core, but that remain available for binary or +source compatibility reasons. However, those functions will not be +compiled in if you add C<-DNO_MATHOMS> in the compiler flags. + +=head2 C has been removed + +The C macro has been removed. + +=head2 C changes + +The C functions, used to manipulate arrays, no longer accept null +C parameters. + +=head2 B:: modules inheritance changed + +The inheritance hierarchy of C modules has changed; C now +inherits from C (it used to inherit from C). + =head1 New Tests =head1 Known Problems