This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Update perlhist
[perl5.git] / pod / perldelta.pod
index b411304..0846821 100644 (file)
 
 =head1 NAME
 
-perldelta - what is new for perl v5.25.2
+perldelta - what is new for perl v5.25.4
 
 =head1 DESCRIPTION
 
-This document describes differences between the 5.25.1 release and the 5.25.2
+This document describes differences between the 5.25.3 release and the 5.25.4
 release.
 
-If you are upgrading from an earlier release such as 5.25.0, first read
-L<perl5251delta>, which describes differences between 5.25.0 and 5.25.1.
+If you are upgrading from an earlier release such as 5.25.2, first read
+L<perl5253delta>, which describes differences between 5.25.2 and 5.25.3.
 
-=head1 Core Enhancements
+=head1 Performance Enhancements
 
-=head2 Perl can now do default collation in UTF-8 locales on platforms
-that support it
+=over 4
 
-Some platforms natively do a reasonable job of collating and sorting in
-UTF-8 locales.  Perl now works with those.  For portability and full
-control, L<Unicode::Collate> is still recommended, but now you may
-not need to do anything special to get good-enough results, depending on
-your application.  See
-L<perllocale/Category C<LC_COLLATE>: Collation: Text Comparisons and Sorting>
+=item *
 
-=head2 Better locale collation of strings containing embedded C<NUL>
-characters
+The rather slow implementation for the experimental subroutine signatures
+feature has been made much faster; it is now comparable in speed with the
+old-style C<my ($a, $b, @c) = @_>.
 
-In locales that have multi-level character weights, these are now
-ignored at the higher priority ones.  There are still some gotchas in
-some strings, though.  See
-L<perllocale/Collation of strings containing embedded C<NUL> characters>.
+=back
 
-=head2 Lexical subroutines are no longer experimental
+=head1 Documentation
 
-Using the C<lexical_subs> feature no longer emits a warning.  Existing code that disables the C<experimental::lexical_subs> warning category that the
-feature previously used will continue to work.  The C<lexical_subs> feature
-has no effect; all Perl code can use lexical subroutines, regardless of
-what feature declarations are in scope.
+=head2 Changes to Existing Documentation
 
-=head2 C<CORE> subroutines for hash and array functions callable via
-reference
+=head3 L<perlcall>
 
-The hash and array functions in the C<CORE> namespace--C<keys>, C<each>,
-C<values>, C<push>, C<pop>, C<shift>, C<unshift> and C<splice>--, can now
-be called with ampersand syntax (C<&CORE::keys(\%hash>) and via reference
-(C<<my $k = \&CORE::keys; $k->(\%hash) >>).  Previously they could only be
-used when inlined.
+=over 4
 
-=head1 Security
+=item *
 
-=head2 C<-Di> switch is now required for PerlIO debugging output
+Removed redundant C<dSP> from an example.
 
-Previously PerlIO debugging output would be sent to the file specified
-by the C<PERLIO_DEBUG> environment variable if perl wasn't running
-setuid and the C<-T> or C<-t> switches hadn't been parsed yet.
+=back
 
-If perl performed output at a point where it hadn't yet parsed its
-switches this could result in perl creating or overwriting the file
-named by C<PERLIO_DEBUG> even when the C<-T> switch had been supplied.
+=head1 Modules and Pragmata
 
-Perl now requires the C<-Di> switch to produce PerlIO debugging
-output.  By default this is written to C<stderr>, but can optionally
-be redirected to a file by setting the C<PERLIO_DEBUG> environment
-variable.
+=head2 Updated Modules and Pragmata
 
-If perl is running setuid or the C<-T> switch has supplied
-C<PERLIO_DEBUG> is ignored and the debugging output is sent to
-C<stderr> as for any other C<-D> switch.
+=over 4
 
-=head1 Incompatible Changes
+=item *
 
-=head2 C<keys> returned from an lvalue subroutine
+L<Archive::Tar> has been upgraded from version 2.08 to 2.10.
 
-C<keys> returned from an lvalue subroutine can no longer be assigned
-to in list context.
+=item *
 
-    sub foo : lvalue { keys(%INC) }
-    (foo) = 3; # death
-    sub bar : lvalue { keys(@_) }
-    (bar) = 3; # also an error
+L<arybase> has been upgraded from version 0.11 to 0.12.
 
-This makes the lvalue sub case consistent with C<(keys %hash) = ...> and
-C<(keys @_) = ...>, which are also errors.  [perl #128187]
+=item *
 
-=head1 Modules and Pragmata
+L<B> has been upgraded from version 1.62 to 1.63.
 
-XXX All changes to installed files in F<cpan/>, F<dist/>, F<ext/> and F<lib/>
-go here.  If Module::CoreList is updated, generate an initial draft of the
-following sections using F<Porting/corelist-perldelta.pl>.  A paragraph summary
-for important changes should then be added by hand.  In an ideal world,
-dual-life modules would have a F<Changes> file that could be cribbed.
+=item *
 
-[ Within each section, list entries as a =item entry ]
+L<B::Concise> has been upgraded from version 0.996 to 0.998.
 
-=head2 New Modules and Pragmata
+=item *
 
-=over 4
+L<B::Deparse> has been upgraded from version 1.37 to 1.38.
 
 =item *
 
-XXX
+L<base> has been upgraded from version 2.23 to 2.24.
 
-=back
+=item *
 
-=head2 Updated Modules and Pragmata
+L<bignum> has been upgraded from version 0.43 to 0.43_01.
 
-=over 4
+=item *
+
+L<Carp> has been upgraded from version 1.41 to 1.42.
 
 =item *
 
-L<XXX> has been upgraded from version A.xx to B.yy.
+L<Config::Perl::V> has been upgraded from version 0.26 to 0.27.
 
 =item *
 
-L<Module::CoreList> has been upgraded from 5.20160520 to 5.20160620.
+L<CPAN> has been upgraded from version 2.14 to 2.14_01.
 
-=back
+=item *
 
-=head2 Removed Modules and Pragmata
+L<CPAN::Meta> has been upgraded from version 2.150005 to 2.150010.
 
-=over 4
+=item *
+
+L<Digest> has been upgraded from version 1.17 to 1.17_01.
 
 =item *
 
-XXX
+L<Digest::SHA> has been upgraded from version 5.95 to 5.96.
 
-=back
+=item *
 
-=head1 Documentation
+L<Encode> has been upgraded from version 2.84 to 2.86.
 
-=head2 Changes to Existing Documentation
+=item *
 
-=head3 L<perllocale>
+L<encoding> has been upgraded from version 2.17_01 to 2.18.
 
-=over 4
+=item *
+
+L<Errno> has been upgraded from version 1.25 to 1.26.
 
 =item *
 
-Document NUL collation handling.
+L<ExtUtils::MakeMaker> has been upgraded from version 7.18 to 7.24.
 
-=back
+=item *
 
-=head3 L<perlmodlib>
+L<File::Fetch> has been upgraded from version 0.48 to 0.52.
 
-=over 4
+=item *
+
+L<File::Spec> has been upgraded from version 3.64 to 3.65.
 
 =item *
 
-Updated the mirror list.
+L<Hash::Util> has been upgraded from version 0.20 to 0.21.
 
-=back
+=item *
 
-=head1 Diagnostics
+L<HTTP::Tiny> has been upgraded from version 0.058 to 0.064.
 
-The following additions or changes have been made to diagnostic output,
-including warnings and fatal error messages.  For the complete list of
-diagnostic messages, see L<perldiag>.
+=item *
 
-=head2 New Diagnostics
+L<I18N::LangTags> has been upgraded from version 0.40 to 0.41.
 
-=head3 New Errors
+=item *
 
-=over 4
+L<IO> has been upgraded from version 1.36 to 1.37.
 
 =item *
 
-L<Version control conflict marker|perldiag/"Version control conflict marker">
+L<IO-Compress> has been upgraded from version 2.069 to 2.069_01.
 
-(F) The parser found a line starting with C<E<lt><<<<<<>,
-C<E<gt>E<gt>E<gt>E<gt>E<gt>E<gt>E<gt>>, or C<=======>. These may be left by a
-version control system to mark conflicts after a failed merge operation.
+=item *
+
+L<IO::Socket::IP> has been upgraded from version 0.37 to 0.38.
 
 =item *
 
-L<%s: command not found|perldiag/"%s: command not found">
+L<IPC::Cmd> has been upgraded from version 0.94 to 0.96.
 
-(A) You've accidentally run your script through B<bash> or another shell
-instead of Perl.  Check the #! line, or manually feed your script into
-Perl yourself.  The #! line at the top of your file could look like
+=item *
 
-  #!/usr/bin/perl
+L<JSON::PP> has been upgraded from version 2.27400 to 2.27400_01.
 
 =item *
 
-L<%s: command not found: %s|perldiag/"%s: command not found: %s">
+L<Locale::Maketext> has been upgraded from version 1.27 to 1.28.
 
-(A) You've accidentally run your script through B<zsh> or another shell
-instead of Perl.  Check the #! line, or manually feed your script into
-Perl yourself.  The #! line at the top of your file could look like
+=item *
 
-  #!/usr/bin/perl
+L<Locale::Maketext::Simple> has been upgraded from version 0.21 to 0.21_01.
 
 =item *
 
-L<Unescaped left brace in regex is deprecated here, passed through in regex; marked by S<<-- HERE> in mE<sol>%sE<sol>|perldiag/"Unescaped left brace in regex is deprecated here, passed through in regex; marked by S<<-- HERE> in m/%s/">
+L<Memoize> has been upgraded from version 1.03 to 1.03_01.
 
-Unescaped left braces are already illegal in some contexts in regular
-expression patterns, but, due to an oversight, no deprecation warning
-was raised in other contexts where they are intended to become illegal.
-This warning is now raised in these contexts.
+=item *
 
-=back
+L<Module::CoreList> has been upgraded from version 5.20160720 to 5.20160820.
 
-=head2 Changes to Existing Diagnostics
+=item *
 
-=over 4
+L<Module::Load::Conditional> has been upgraded from version 0.64 to 0.68.
 
 =item *
 
-L<Unescaped left brace in regex is illegal here in regex; marked by S<<-- HERE> in mE<sol>%sE<sol>|perldiag/"Unescaped left brace in regex is illegal here in regex; marked by S<<-- HERE> in m/%s/">
+L<Module::Metadata> has been upgraded from version 1.000032 to 1.000033.
 
-The word "here" has been added to the message that was raised in
-v5.25.1.  This is to indicate that there are contexts in which unescaped
-left braces are not (yet) illegal.
+=item *
 
-=back
+L<Net::Ping> has been upgraded from version 2.43 to 2.44.
 
-=head1 Configuration and Compilation
+=item *
 
-=over 4
+L<NEXT> has been upgraded from version 0.65 to 0.67.
+
+=item *
+
+L<Opcode> has been upgraded from version 1.35 to 1.37.
 
 =item *
 
-F<make_ext.pl> no longer updates a module's F<pm_to_blib> file when no
-files require updates.  This could cause dependencies, F<perlmain.c>
-in particular, to be rebuilt unnecessarily.  [perl #126710]
+L<Pod::Html> has been upgraded from version 1.22 to 1.2201.
 
 =item *
 
-The output of C<perl -V> has been reformatted so that each configuration
-and compile-time option is now listed one per line, to improve
-readability.
+L<Pod::Perldoc> has been upgraded from version 3.25_02 to 3.27.
+
+=item *
+
+L<POSIX> has been upgraded from version 1.70 to 1.71.
+
+=item *
+
+L<Storable> has been upgraded from version 2.56 to 2.57.
+
+=item *
+
+L<Sys::Syslog> has been upgraded from version 0.34 to 0.34_01.
+
+=item *
+
+L<Test> has been upgraded from version 1.28 to 1.29.
+
+=item *
+
+L<Test::Harness> has been upgraded from version 3.36 to 3.36_01.
+
+=item *
+
+L<Test::Simple> has been upgraded from version 1.302045 to 1.302052.
+
+=item *
+
+L<Tie::Hash::NamedCapture> has been upgraded from version 0.09 to 0.10.
+
+=item *
+
+L<Time::Local> has been upgraded from version 1.2300 to 1.24.
 
 =back
 
-=head1 Testing
+=head1 Configuration and Compilation
 
 =over 4
 
 =item *
 
-F<t/harness> now tries really hard not to run tests outside of the Perl
-source tree. [perl #124050]
+A probe for C<gai_strerror> was added to F<Configure> that checks if the
+the gai_strerror() routine is available and can be used to
+translate error codes returned by getaddrinfo() into human
+readable strings.
+
+=back
+
+=head1 Platform Support
+
+=head2 Platform-Specific Notes
+
+=over 4
+
+=item Hurd
+
+The hints for Hurd have been improved enabling malloc wrap and reporting the
+GNU libc used (previously it was an empty string when reported).
 
 =back
 
@@ -252,8 +262,9 @@ source tree. [perl #124050]
 
 =item *
 
-Perl no longer panics when switching into some locales on machines with
-buggy C<strxfrm()> implementations in their libc. [perl #121734]
+Three new ops, C<OP_ARGELEM>, C<OP_ARGDEFELEM> and C<OP_ARGCHECK> have
+been added. These are intended principally to implement the individual
+elements of a subroutine signature, plus any overall checking required.
 
 =back
 
@@ -263,44 +274,130 @@ buggy C<strxfrm()> implementations in their libc. [perl #121734]
 
 =item *
 
-C< until ($x = 1) { ... } > and C< ... until $x = 1 > now properly
-warn when syntax warnings are enabled.  [perl #127333]
+Problems with in-place array sorts: code like C<@a = sort { ... } @a>,
+where the source and destination of the sort are the same plain array, are
+optimised to do less copying around. Two side-effects of this optimisation
+were that the contents of C<@a> as visible to to sort routine were
+partially sorted, and under some circumstances accessing C<@a> during the
+sort could crash the interpreter. Both these issues have been fixed, and
+Sort functions see the original value of C<@a>.
+
+=item *
+
+Non-ASCII string delimiters are now reported correctly in error messages
+for unterminated strings.  [perl #128701]
+
+=item *
+
+C<pack("p", ...)> used to emit its warning ("Attempt to pack pointer to
+temporary value") erroneously in some cases, but has been fixed.
 
 =item *
 
-socket() now leaves the error code returned by the system in C<$!> on
-failure.  [perl #128316]
+C<@DB::args> is now exempt from "used once" warnings.  The warnings only
+occurred under B<-w>, because F<warnings.pm> itself uses C<@DB::args>
+multiple times.
 
 =item *
 
-Assignment variants of any bitwise ops under the C<bitwise> feature would
-crash if the left-hand side was an array or hash.  [perl #128204]
+The use of built-in arrays or hash slices in a double-quoted string no
+longer issues a warning ("Possible unintended interpolation...") if the
+variable has not been mentioned before.  This affected code like
+C<qq|@DB::args|> and C<qq|@SIG{'CHLD', 'HUP'}|>.  (The special variables
+C<@-> and C<@+> were already exempt from the warning.)
 
 =item *
 
-C<require> followed by a single colon (as in C<foo() ? require : ...> is
-now parsed correctly as C<require> with implicit $_, rather than
-C<require "">.  [perl #128307]
+C<gethostent> and similar functions now perform a null check internally, to
+avoid crashing with torsocks.  This was a regression from 5.22.  [perl
+#128740]
 
 =item *
 
-Scalar C<keys %hash> can now be assigned to consistently in all scalar
-lvalue contexts.  Previously it worked for some contexts but not others.
+C<defined *{'!'}>, C<defined *{'['}>, and C<defined *{'-'}> no longer leak
+memory if the typeglob in question has never been accessed before.
 
 =item *
 
-List assignment to C<vec> or C<substr> with an array or hash for its first
-argument used to result in crashes or "Can't coerce" error messages at run
-time, unlike scalar assignment, which would give an error at compile time.
-List assignment now gives a compile-time error, too.  [perl #128260]
+In 5.25.4 fchown() was changed not to accept negative one as an argument
+because in some platforms that is an error.  However, in some other platforms
+that is an acceptable argument.  This change has been reverted [perl #128967].
+
+=item *
+
+Mentioning the same constant twice in a row (which is a syntax error) no
+longer fails an assertion under debugging builds.  This was a regression
+from 5.20.  [perl #126482]
+
+=item *
+
+Many issues relating to C<printf "%a"> of hexadecimal floating point
+were fixed.  In addition, the "subnormals" (formerly known as "denormals")
+floating point anumbers are now supported both with the plain IEEE 754
+floating point numbers (64-bit or 128-bit) and the x86 80-bit
+"extended precision".  Note that subnormal hexadecimal floating
+point literals will give a warning about "exponent underflow".
+[perl #128843, #128889, #128890, #128893, #128909, #128919]
+
+=item *
+
+A regression in 5.24 with C<tr/\N{U+...}/foo/> when the code point was between
+128 and 255 has been fixed. [perl #128734].
+
+=item *
+
+A regression from the previous development release, 5.23.3, where
+compiling a regular expression could crash the interpreter has been
+fixed. [perl #128686].
+
+=item *
+
+Use of a string delimiter whose code point is above 2**31 now works
+correctly on platforms that allow this.  Previously, certain characters,
+due to truncation, would be confused with other delimiter characters
+with special meaning (such as C<?> in C<m?...?>), resulting
+in inconsistent behaviour.  Note that this is non-portable,
+and is based on Perl's extension to UTF-8, and is probably not
+displayable nor enterable by any editor. [perl #128738]
+
+=item *
+
+C<@{x> followed by a newline where C<x> represents a control or non-ASCII
+character no longer produces a garbled syntax error message or a crash.
+[perl #128951]
 
 =back
 
 =head1 Acknowledgements
 
-XXX Generate this with:
+Perl 5.25.4 represents approximately 4 weeks of development since Perl 5.25.3
+and contains approximately 18,000 lines of changes across 820 files from 23
+authors.
+
+Excluding auto-generated files, documentation and release tools, there were
+approximately 9,200 lines of changes to 660 .pm, .t, .c and .h files.
+
+Perl continues to flourish into its third decade thanks to a vibrant community
+of users and developers. The following people are known to have contributed the
+improvements that became Perl 5.25.4:
+
+Chris 'BinGOs' Williams, Craig A. Berry, Dagfinn Ilmari MannsÃ¥ker, Dan
+Collins, Daniel Dragan, David Mitchell, Father Chrysostomos, H.Merijn Brand,
+James E Keenan, Jarkko Hietaniemi, Karen Etheridge, Karl Williamson, Lukas Mai,
+Neil Bowers, Nicolas R., Pino Toscano, Rafael Garcia-Suarez, Richard Levitte,
+Shlomi Fish, Smylers, Steve Hay, Tony Cook, Yves Orton.
+
+The list above is almost certainly incomplete as it is automatically generated
+from version control history. In particular, it does not include the names of
+the (very much appreciated) contributors who reported issues to the Perl bug
+tracker.
+
+Many of the changes included in this version originated in the CPAN modules
+included in Perl's core. We're grateful to the entire CPAN community for
+helping Perl to flourish.
 
-  perl Porting/acknowledgements.pl v5.25.1..HEAD
+For a more complete list of all of Perl's historical contributors, please see
+the F<AUTHORS> file in the Perl source distribution.
 
 =head1 Reporting Bugs