This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Move more URLs from http:// to https://
[perl5.git] / pod / perldelta.pod
index 2b85e2b..211ee4a 100644 (file)
@@ -5,15 +5,15 @@
 [ this is a template for a new perldelta file.  Any text flagged as XXX needs
 to be processed before release. ]
 
-perldelta - what is new for perl v5.31.1
+perldelta - what is new for perl v5.31.5
 
 =head1 DESCRIPTION
 
-This document describes differences between the 5.31.0 release and the 5.31.1
+This document describes differences between the 5.31.4 release and the 5.31.5
 release.
 
-If you are upgrading from an earlier release such as 5.30.0, first read
-L<perl5310delta>, which describes differences between 5.30.0 and 5.31.0.
+If you are upgrading from an earlier release such as 5.31.3, first read
+L<perl5314delta>, which describes differences between 5.31.3 and 5.31.4.
 
 =head1 Notice
 
@@ -45,6 +45,24 @@ XXX For a release on a stable branch, this section aspires to be:
 
 [ List each incompatible change as a =head2 entry ]
 
+=head2 Modifiable variables are no longer permitted in constants
+
+Code like:
+
+    my $var;
+    $sub = sub () { $var };
+
+where C<$var> is referenced elsewhere in some sort of modiable context
+now produces an exception when the sub is defined.
+
+This error can be avoided by adding a return to the sub definition:
+
+    $sub = sub () { return $var };
+
+This has been deprecated since perl 5.22.
+
+[perl #131138]
+
 =head1 Deprecations
 
 XXX Any deprecated features, syntax, modules etc. should be listed here.
@@ -125,11 +143,9 @@ XXX Remove this section if not applicable.
 
 =item *
 
-L<Storable> has been upgraded from version 3.15 to 3.16.
+L<XXX> has been upgraded from version A.xx to B.yy.
 
-Regular expressions objects weren't properly counted for object id
-purposes on retrieve.  This would corrupt the resulting structure, or
-cause a runtime error in some cases.  [perl #134179]
+If there was something important to note about this change, include that here.
 
 =back
 
@@ -139,9 +155,7 @@ cause a runtime error in some cases.  [perl #134179]
 
 =item *
 
-Pod::Parser has been removed from the core distribution.
-It still is available for download from CPAN.  This resolves [perl
-#119439].
+XXX
 
 =back
 
@@ -258,7 +272,9 @@ L</Platform Support> section, instead.
 
 =item *
 
-XXX
+Perl now no longer probes for C<d_u32align>, defaulting to C<define>
+on all platforms.  This check was error prone when it was done, which
+was on 32-bit platforms only.  [perl #133495]
 
 =back
 
@@ -352,8 +368,19 @@ well.
 
 =item *
 
-L<eval_pv()|perlapi/eval_pv> no longer stringifies the exception when
-C<croak_on_error> is true.  [perl #134175]
+Added the C<<PL_curstackinfo->si_cxsubix>> field. This records the stack
+index of the most recently pushed sub/format/eval context.  It is set and
+restored automatically by C<cx_pushsub()>, C<cx_popsub()> etc., but would
+need to be manually managed if you do any unusual manipulation of the
+context stack.
+
+=item *
+
+Various macros dealing with character type classification and changing
+case where the input is encoded in UTF-8 now require an extra parameter
+to prevent potential reads beyond the end of the buffer.  Use of these
+has generated a deprecation warning since 5.26.  Details are in
+L<perldeprecation/In XS code, use of various macros dealing with UTF-8.>
 
 =back
 
@@ -368,77 +395,7 @@ files in F<ext/> and F<lib/> are best summarized in L</Modules and Pragmata>.
 
 =item *
 
-close() on a pipe now preemptively clears the PerlIO object from the
-IO SV.  This prevents a second attempt to close the already closed
-PerlIO object if a signal handler calls die() or exit() while close()
-is waiting for the child process to complete.  [perl #122112]
-
-=item *
-
-C<< sprintf("%.*a", -10000, $x) >> would cause a buffer overflow due
-to mishandling of the negative precision value.  [perl #134008]
-
-=item *
-
-scalar() on a reference could cause an erroneous assertion failure
-during compilation.  [perl #134045]
-
-=item *
-
-Extraordinarily large (over 2GB) floating point format widths could
-cause an integer overflow in the underlying call to snprintf(),
-resulting in an assertion.  Formatted floating point widths are now
-limited to the range of int, the return value of snprintf().  [perl
-#133913]
-
-=item *
-
-Parsing the following constructs within a sub-parse (such as with
-C<"${code here}"> or C<s/.../code here/e>) has changed to match how
-they're parsed normally:
-
-=over
-
-=item *
-
-C<print $fh ...> no longer produces a syntax error.
-
-=item *
-
-Code like C<s/.../ ${time} /e> now properly produces an "Ambiguous use
-of ${time} resolved to $time at ..." warning when warnings are enabled.
-
-=item *
-
-C<@x {"a"}> (with the space) in a sub-parse now properly produces a
-"better written as" warning when warnings are enabled.
-
-=item *
-
-attributes can now be used in a sub-parse.
-
-=back
-
-[perl #133850]
-
-=item *
-
-Incomplete hex and binary literals like C<0x> and C<0b> are now
-treated as if the C<x> or C<b> is part of the next token.  [perl
-#134125]
-
-=item *
-
-A spurious C<)> in a subparse, such as in C<s/.../code here/e> or
-C<"...${code here}">, no longer confuses the parser.
-
-Previously a subparse was bracketed with generated C<(> and C<)>
-tokens, so a spurious C<)> would close the construct without doing the
-normal subparse clean up, confusing the parser and possible causing an
-assertion failure.
-
-Such constructs are now surrounded by artificial tokens that can't be
-included in the source.  [perl #130585]
+XXX
 
 =back
 
@@ -478,13 +435,13 @@ died, add a short obituary here.
 
 XXX Generate this with:
 
-  perl Porting/acknowledgements.pl v5.31.0..HEAD
+  perl Porting/acknowledgements.pl v5.31.4..HEAD
 
 =head1 Reporting Bugs
 
 If you find what you think is a bug, you might check the perl bug database
 at L<https://rt.perl.org/>.  There may also be information at
-L<http://www.perl.org/>, the Perl Home Page.
+L<https://www.perl.org/>, the Perl Home Page.
 
 If you believe you have an unreported bug, please run the L<perlbug> program
 included with your release.  Be sure to trim your bug down to a tiny but