=encoding utf8 =head1 NAME perl5355delta - what is new for perl v5.35.5 =head1 DESCRIPTION This document describes differences between the 5.35.4 release and the 5.35.5 release. If you are upgrading from an earlier release such as 5.35.3, first read L, which describes differences between 5.35.3 and 5.35.4. =head1 Core Enhancements =head2 iterating over multiple values at a time As of Perl 5.36, you can iterate over multiple values at a time by specifying a list of lexicals within parentheses. For example, for my ($key, $value) (%hash) { ... } for my ($left, $right, $gripping) (@moties) { ... } Attempting to specify a list after C was previously a syntax error. For more detail see L. =head1 Incompatible Changes There are no changes intentionally incompatible with 5.35.4 If any exist, they are bugs, and we request that you submit a report. See L below. =head1 Modules and Pragmata =head2 Updated Modules and Pragmata =over 4 =item * L has been upgraded from version 1.005 to 1.006. =item * L has been upgraded from version 1.58 to 1.59. =item * L has been upgraded from version 1.19 to 1.20. =item * L has been upgraded from version 1.51 to 1.52. =item * L has been upgraded from version 3.12 to 3.16. =item * L has been upgraded from version 1.34 to 1.35. =item * L has been upgraded from version 0.024 to 0.025. =item * L has been upgraded from version 2.36 to 2.37. =item * L has been upgraded from version 1.52 to 1.53. =item * L has been upgraded from version 1.20 to 1.21. =item * L has been upgraded from version 0.076 to 0.078. =item * L has been upgraded from version 0.20 to 0.21. =item * L has been upgraded from version 5.20210920 to 5.20211020. =item * L has been upgraded from version 1.99 to 2.01. =item * L has been upgraded from version 1.56_001 to 1.60. =item * L has been upgraded from version 1.302185 to 1.302188. =item * L has been upgraded from version 4.2 to 4.3. =item * L has been upgraded from version 1.05 to 1.06. =item * L has been upgraded from version 1.05 to 1.06. =item * L has been upgraded from version 1.54 to 1.55. =item * L has been upgraded from version 1.19 to 1.20. =back =head1 Documentation =head2 Changes to Existing Documentation We have attempted to update the documentation to reflect the changes listed in this document. If you find any we have missed, open an issue at L. Additionally, the following selected changes have been made: =head3 L =over 4 =item * The election process has been finetuned to allow the vote to be skipped if there are no more candidates than open seats. =item * A special election is now allowed to be postponed for up to twelve weeks, for example until a normal election. =back =head1 Diagnostics 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. =head2 New Diagnostics =head3 New Errors =over 4 =item * L The parser failed an internal consistency check while trying to parse a C loop. =back =head3 New Warnings =over 4 =item * L This warning is emitted if you use C to iterate multiple values at a time. This syntax is currently experimental and its behaviour may change in future releases of Perl. =back =head2 Changes to Existing Diagnostics =over 4 =item * L<'E' does not take a repeat count in %s|perldiag/"'/' does not take a repeat count in %s"> This warning used to not include the C. =back =head1 Configuration and Compilation =over 4 =item * The Perl C source code now uses some C99 features, which we have verified are supported by all compilers we target. This means that Perl's headers now contain some code that is legal in C99 but not C89. This may cause problems for some XS modules that unconditionally add C<-Werror=declaration-after-statement> to their C compiler flags if compiling with gcc or clang. Earlier versions of Perl support long obsolete compilers that are strict in rejecting certain C99 features, particularly mixed declarations and code, and hence it makes sense for XS module authors to audit that their code does not violate this. However, doing this is now only possible on these earlier versions of Perl, hence these modules need to be changed to only add this flag for C<<$] < 5.035005>>. =back =head1 Testing Tests were added and changed to reflect the other additions and changes in this release. Furthermore, these significant changes were made: =over 4 =item * t/op/for-many.t was added This tests for looping of multiple values as the same time =back =head1 Platform Support =head2 Discontinued Platforms =over 4 =item NetWare Support code for Novell NetWare has been removed. NetWare was a server operating system by Novell. The port was last updated in July 2002, and the platform itself in May 2009. Unrelated changes accidentally broke the build for the NetWare port in September 2009, and in 12 years no-one has reported this. =back =head2 Platform-Specific Notes =over 4 =item Windows Support for old MSVC++ (pre-VC12) has been removed These did not support C99 and hence can no longer be used to compile perl. =back =head1 Internal Changes =over 4 =item * Memory for hash iterator state (C) is now allocated as part of the hash body, instead of as part of the block of memory allocated for the main hash array. Nothing else changes - memory for this structure is still allocated only when needed, is still accessed via the C macro, and the macro should only be called when C is true. Hashes are still always of type C, hash bodies are still allocated from arenas, and the address of the hash doesn't change, because the address is the pointer to the head structure, which never moves. Internally, a second arena (the arena with index 1) is used to allocate larger bodies with space for C, the body "upgraded", and the "head" structure updated to reflect this (much the same way that the bodies of scalars are upgraded). We already re-purpose arenas - arena with index 0 is used for Cs. None of this affects documented public XS interfaces. The only code changes are in F and F. As the rest of the core itself uses these macros but needed no changes, likely no code on CPAN will be affected either. =back =head1 Selected Bug Fixes =over 4 =item * Calling C on a tied hash that is partway through iteration now frees the iteration state immediately. Iterating a tied hash causes perl to store a copy of the current hash key to track the iteration state, with this stored copy passed as the second parameter to C. This internal state is freed immediately when tie hash iteration completes, or if the hash is destroyed, but due to an implementation oversight, it was not freed if the hash was untied. In that case, the internal copy of the key would persist until the earliest of =over 4 =item 1 C was called again on the same hash =item 2 The (now untied) hash was iterated (ie passed to any of C, C or C) =item 3 The hash was destroyed. =back This inconsistency is now fixed - the internal state is now freed immediately by C. As the precise timing of this behaviour can be observed with pure Perl code (the timing of C on objects returned from C and C) it's just possible that some code is sensitive to it. =item * The C function added for bootstrapping miniperl in perl 5.30.0 is now only available in miniperl. [github #19122] =back =head1 Acknowledgements Perl 5.35.5 represents approximately 4 weeks of development since Perl 5.35.4 and contains approximately 32,000 lines of changes across 380 files from 22 authors. Excluding auto-generated files, documentation and release tools, there were approximately 17,000 lines of changes to 260 .pm, .t, .c and .h files. Perl continues to flourish into its fourth decade thanks to a vibrant community of users and developers. The following people are known to have contributed the improvements that became Perl 5.35.5: Andrew Fresh, Chris 'BinGOs' Williams, Dagfinn Ilmari Mannsåker, Dan Book, Dan Kogai, David Mitchell, E. Choroba, Hugo van der Sanden, James E Keenan, Karl Williamson, Leon Timmermans, Matthew Horsfall, Nicholas Clark, Olaf Alders, Paul Evans, Ricardo Signes, Richard Leach, Sergey Poznyakoff, Steve Hay, TAKAI Kousuke, Tomasz Konojacki, Tony Cook. 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. For a more complete list of all of Perl's historical contributors, please see the F file in the Perl source distribution. =head1 Reporting Bugs If you find what you think is a bug, you might check the perl bug database at L. There may also be information at L, the Perl Home Page. If you believe you have an unreported bug, please open an issue at L. Be sure to trim your bug down to a tiny but sufficient test case. If the bug you are reporting has security implications which make it inappropriate to send to a public issue tracker, then see L for details of how to report the issue. =head1 Give Thanks If you wish to thank the Perl 5 Porters for the work we had done in Perl 5, you can do so by running the C program: perlthanks This will send an email to the Perl 5 Porters list with your show of thanks. =head1 SEE ALSO The F file for an explanation of how to view exhaustive details on what changed. The F file for how to build Perl. The F file for general stuff. The F and F files for copyright information. =cut