This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
perldelta for 6190dd991505e
[perl5.git] / pod / perldelta.pod
CommitLineData
44691e6f
AB
1=encoding utf8
2
3=head1 NAME
4
4dc623f0
CBW
5[ this is a template for a new perldelta file. Any text flagged as XXX needs
6to be processed before release. ]
7
8perldelta - what is new for perl v5.21.7
c68523cb 9
238894db 10=head1 DESCRIPTION
c68523cb 11
4dc623f0 12This document describes differences between the 5.21.6 release and the 5.21.7
238894db 13release.
c68523cb 14
4dc623f0
CBW
15If you are upgrading from an earlier release such as 5.21.5, first read
16L<perl5216delta>, which describes differences between 5.21.5 and 5.21.6.
8435afd1 17
4dc623f0 18=head1 Notice
4cad5dc8 19
4dc623f0 20XXX Any important notices here
518159a1 21
4dc623f0 22=head1 Core Enhancements
518159a1 23
4dc623f0
CBW
24XXX New core language features go here. Summarize user-visible core language
25enhancements. Particularly prominent performance optimisations could go
26here, but most should go in the L</Performance Enhancements> section.
518159a1 27
4dc623f0 28[ List each enhancement as a =head2 entry ]
518159a1 29
67f2cc75
AC
30=head2 C<fileno> now works on directory handles
31
32When the relevant support is available in the operating system, the
33C<fileno> builtin now works on directory handles, yielding the
34underlying file descriptor in the same way as for filehandles. On
35operating systems without such support, C<fileno> on a directory handle
36continues to return the undefined value, as before, but also sets C<$!> to
37indicate that the operation is not supported.
38
39Currently, this uses either a C<dd_fd> member in the OS C<DIR>
40structure, or a dirfd(3) function as specified by POSIX.1-2008.
41
4dc623f0 42=head1 Security
fe609065 43
4dc623f0
CBW
44XXX Any security-related notices go here. In particular, any security
45vulnerabilities closed should be noted here rather than in the
46L</Selected Bug Fixes> section.
fe609065 47
4dc623f0 48[ List each security issue as a =head2 entry ]
295f7815 49
4dc623f0 50=head1 Incompatible Changes
295f7815 51
4dc623f0 52XXX For a release on a stable branch, this section aspires to be:
bb8c7e27 53
4dc623f0
CBW
54 There are no changes intentionally incompatible with 5.XXX.XXX
55 If any exist, they are bugs, and we request that you submit a
56 report. See L</Reporting Bugs> below.
9f122eef 57
4dc623f0 58[ List each incompatible change as a =head2 entry ]
5cfa0642 59
aafa61ee 60=head2 C<&> and C<\&> prototypes accepts only subs
3f22ed99
FC
61
62The C<&> prototype character now accepts only anonymous subs (C<sub {...}>)
63and things beginning with C<\&>. Formerly it erroneously also allowed
64C<undef> and references to array, hashes, and lists. [perl #4539]
65[perl #123062]
66
aafa61ee
FC
67The C<\&> prototype was allowing subroutine calls, whereas now it only
68allows subroutines. C<&foo> is permitted. C<&foo()> and C<foo()> are not.
69[perl #77860]
70
ef8784b7
FC
71=head2 C<use encoding> is now lexical
72
73The L<encoding> pragma's effect is now limited to lexical scope. This
74pragma is deprecated, but in the meantime, it could adversely affect
75unrelated modules that are included in the same program.
76
4dc623f0 77=head1 Deprecations
5b306eef 78
4dc623f0 79XXX Any deprecated features, syntax, modules etc. should be listed here.
5b306eef 80
4dc623f0 81=head2 Module removals
ef7051ba 82
4dc623f0 83XXX Remove this section if inapplicable.
ef7051ba 84
4dc623f0
CBW
85The following modules will be removed from the core distribution in a
86future release, and will at that time need to be installed from CPAN.
87Distributions on CPAN which require these modules will need to list them as
88prerequisites.
b450ee68 89
4dc623f0
CBW
90The core versions of these modules will now issue C<"deprecated">-category
91warnings to alert you to this fact. To silence these deprecation warnings,
92install the modules in question from CPAN.
b450ee68 93
4dc623f0
CBW
94Note that these are (with rare exceptions) fine modules that you are encouraged
95to continue to use. Their disinclusion from core primarily hinges on their
96necessity to bootstrapping a fully functional, CPAN-capable Perl installation,
97not usually on concerns over their design.
1e461e16 98
4dc623f0 99=over
1e461e16 100
4dc623f0 101=item XXX
aa95859b 102
4dc623f0
CBW
103XXX Note that deprecated modules should be listed here even if they are listed
104as an updated module in the L</Modules and Pragmata> section.
aa95859b 105
86372193 106=back
357205d5 107
4dc623f0 108[ List each other deprecation as a =head2 entry ]
6ed80d55 109
c0659f73
KW
110=head2 Setting C<${^ENCODING}> to anything but C<undef>
111
112This variable allows Perl scripts to be written in a non-ASCII,
113non-UTF-8 encoding. However, it affects all modules globally, leading
114to wrong answers and segmentation faults. New scripts should be written
115in UTF-8; old scripts should be converted to UTF-8, which is easily done
116with the L<encoding> pragma.
117
4dc623f0 118=head1 Performance Enhancements
6ed80d55 119
4dc623f0
CBW
120XXX Changes which enhance performance without changing behaviour go here.
121There may well be none in a stable release.
6ed80d55 122
4dc623f0 123[ List each enhancement as a =item entry ]
6ed80d55 124
4dc623f0 125=over 4
6ed80d55
CBW
126
127=item *
128
2adef77e
DD
129Win32 Perl uses 8 KB less of per-process memory than before for every perl
130process of this version. This data is now memory mapped from disk and shared
131between perl processes from the same perl binary.
6ed80d55 132
4dc623f0 133=back
f4e81f96 134
4dc623f0 135=head1 Modules and Pragmata
bb6a367a 136
4dc623f0
CBW
137XXX All changes to installed files in F<cpan/>, F<dist/>, F<ext/> and F<lib/>
138go here. If Module::CoreList is updated, generate an initial draft of the
139following sections using F<Porting/corelist-perldelta.pl>. A paragraph summary
140for important changes should then be added by hand. In an ideal world,
141dual-life modules would have a F<Changes> file that could be cribbed.
f348c3d8 142
4dc623f0 143[ Within each section, list entries as a =item entry ]
f348c3d8 144
4dc623f0 145=head2 New Modules and Pragmata
6ed80d55 146
4dc623f0 147=over 4
f348c3d8
A
148
149=item *
150
4dc623f0 151XXX
7635ad4d 152
4dc623f0 153=back
7635ad4d 154
4dc623f0 155=head2 Updated Modules and Pragmata
7635ad4d 156
4dc623f0 157=over 4
f348c3d8 158
6ed80d55 159=item *
f348c3d8 160
cd3802ac
FC
161L<B> has been upgraded from version 1.53 to 1.54.
162
163Nulled COPs are now of class C<B::COP>, rather than C<B::OP>.
164
d6c13051
FC
165B::REGEXP objects now provide a C<qr_anoncv> method for accessing the
166implicit CV associated with C<qr//> things containing code blocks.
167
cd3802ac
FC
168=item *
169
7cf50cd1
FC
170L<B::Deparse> has been upgraded from version 1.30 to 1.31.
171
172BEGIN blocks at the end of the enclosing scope are now deparsed in the
173right place. [perl #77452]
174
73fc9720
FC
175Lexical subroutines are now fully deparsed. [perl #116553]
176
7cf50cd1
FC
177=item *
178
7de6b801
TC
179L<ExtUtils::ParseXS> has been upgraded from version 3.26 to 3.27.
180
181Only declare C<file> unused if we actually define it.
182
183Improve generated C<RETVAL> code generation to avoid repeated
184references to C<ST(0)>. [perl #123278]
f4eedc6b 185
190f5bb6
TC
186=item *
187
188The PathTools module collection has been upgraded from 3.52 to 3.53.
189
190Don't turn leading C<//> into C</> on Cygwin. [perl #122635]
191
ba31029d
TR
192=item *
193
194L<Locale::Maketext> has been upgraded from version 1.25 to 1.26.
195
4c7a0d98
DD
196=item *
197
198L<XSLoader> has been upgraded from version 0.19 to 0.20
199
200Don't test twice for bootstrap file.
201
4dc623f0 202=back
f4eedc6b 203
4dc623f0 204=head2 Removed Modules and Pragmata
f4eedc6b 205
4dc623f0 206=over 4
f348c3d8 207
6ed80d55
CBW
208=item *
209
4dc623f0 210XXX
f348c3d8 211
4dc623f0 212=back
f348c3d8 213
4dc623f0 214=head1 Documentation
f348c3d8 215
4dc623f0
CBW
216XXX Changes to files in F<pod/> go here. Consider grouping entries by
217file and be sure to link to the appropriate page, e.g. L<perlfunc>.
f348c3d8 218
4dc623f0 219=head2 New Documentation
f348c3d8 220
4dc623f0 221XXX Changes which create B<new> files in F<pod/> go here.
f348c3d8 222
4dc623f0 223=head3 L<XXX>
6ed80d55 224
4dc623f0 225XXX Description of the purpose of the new file here
f348c3d8 226
6ed80d55 227=head2 Changes to Existing Documentation
f348c3d8 228
4dc623f0
CBW
229XXX Changes which significantly change existing files in F<pod/> go here.
230However, any changes to F<pod/perldiag.pod> should go in the L</Diagnostics>
231section.
232
233=head3 L<XXX>
84d03adf 234
86372193 235=over 4
ff433f2d 236
4cd408ba
TC
237=item *
238
4dc623f0 239XXX Description of the change here
f348c3d8 240
86372193 241=back
f348c3d8 242
6ed80d55
CBW
243=head1 Diagnostics
244
245The following additions or changes have been made to diagnostic output,
246including warnings and fatal error messages. For the complete list of
247diagnostic messages, see L<perldiag>.
248
4dc623f0
CBW
249XXX New or changed warnings emitted by the core's C<C> code go here. Also
250include any changes in L<perldiag> that reconcile it to the C<C> code.
6ed80d55 251
4dc623f0 252=head2 New Diagnostics
f348c3d8 253
4dc623f0
CBW
254XXX Newly added diagnostic messages go under here, separated into New Errors
255and New Warnings
ab0b796c 256
4dc623f0 257=head3 New Errors
8c6180a9
KW
258
259=over 4
260
261=item *
262
4dc623f0 263XXX L<message|perldiag/"message">
ab0b796c 264
86372193 265=back
0561e60b 266
4dc623f0 267=head3 New Warnings
dd200dff 268
4dc623f0 269=over 4
dd200dff 270
73e793fc
FC
271=item *
272
4dc623f0 273XXX L<message|perldiag/"message">
73e793fc 274
8c6180a9
KW
275=back
276
86372193 277=head2 Changes to Existing Diagnostics
0561e60b 278
4dc623f0 279XXX Changes (i.e. rewording) of diagnostic messages go here
4a328228 280
4dc623f0 281=over 4
4cd408ba 282
1861205d
FC
283=item *
284
4dc623f0 285XXX Describe change here
1861205d 286
86372193 287=back
40a81b59 288
4dc623f0 289=head1 Utility Changes
2a395b86 290
4dc623f0
CBW
291XXX Changes to installed programs such as F<perlbug> and F<xsubpp> go here.
292Most of these are built within the directory F<utils>.
2a395b86 293
4dc623f0
CBW
294[ List utility changes as a =head2 entry for each utility and =item
295entries for each change
296Use L<XXX> with program names to get proper documentation linking. ]
12d22d1f 297
4dc623f0 298=head2 L<XXX>
2a395b86 299
8c8d6154 300=over 4
2a395b86
PM
301
302=item *
303
4dc623f0 304XXX
bb8c7e27 305
86372193 306=back
bb8c7e27 307
4dc623f0 308=head1 Configuration and Compilation
bb8c7e27 309
4dc623f0
CBW
310XXX Changes to F<Configure>, F<installperl>, F<installman>, and analogous tools
311go here. Any other changes to the Perl build process should be listed here.
312However, any platform-specific changes should be listed in the
313L</Platform Support> section, instead.
aa292ef2 314
4dc623f0 315[ List changes as a =item entry ].
83b69bfd
DD
316
317=over 4
318
319=item *
320
4dc623f0 321XXX
13adb056 322
83b69bfd
DD
323=back
324
4dc623f0 325=head1 Testing
391823f2 326
4dc623f0
CBW
327XXX Any significant changes to the testing of a freshly built perl should be
328listed here. Changes which create B<new> files in F<t/> go here as do any
329large changes to the testing harness (e.g. when parallel testing was added).
330Changes to existing files in F<t/> aren't worth summarizing, although the bugs
331that they represent may be covered elsewhere.
6ff8f256 332
4dc623f0 333[ List each test improvement as a =item entry ]
80cc3290 334
86372193 335=over 4
db98db4e 336
8818afe8
TC
337=item *
338
4dc623f0 339XXX
9d22ccf6 340
4dc623f0 341=back
480961b6 342
4dc623f0 343=head1 Platform Support
480961b6 344
4dc623f0 345XXX Any changes to platform support should be listed in the sections below.
94c9bf90 346
4dc623f0
CBW
347[ Within the sections, list each platform as a =item entry with specific
348changes as paragraphs below it. ]
94c9bf90 349
4dc623f0 350=head2 New Platforms
8af808bf 351
4dc623f0
CBW
352XXX List any platforms that this version of perl compiles on, that previous
353versions did not. These will either be enabled by new files in the F<hints/>
354directories, or new subdirectories and F<README> files at the top level of the
355source tree.
8af808bf 356
4dc623f0 357=over 4
fdcaecb7 358
4dc623f0 359=item XXX-some-platform
fdcaecb7 360
4dc623f0 361XXX
2af7c6b6 362
4dc623f0 363=back
2af7c6b6 364
4dc623f0 365=head2 Discontinued Platforms
c0b32823 366
4dc623f0 367XXX List any platforms that this version of perl no longer compiles on.
c0b32823 368
4dc623f0 369=over 4
b1a4e8b3 370
4dc623f0 371=item XXX-some-platform
b1a4e8b3 372
4dc623f0 373XXX
9e26817d 374
4dc623f0 375=back
9e26817d 376
4dc623f0 377=head2 Platform-Specific Notes
70cee83f 378
312159d9 379=head3 Win32
70cee83f 380
312159d9 381=over
e5fbfbc1 382
312159d9 383=item *
e5fbfbc1 384
312159d9 385Intel C builds are now always built with C99 mode on.
353075a0 386
4dc623f0 387=back
353075a0 388
4dc623f0 389=head1 Internal Changes
9f122eef 390
4dc623f0
CBW
391XXX Changes which affect the interface available to C<XS> code go here. Other
392significant internal changes for future core maintainers should be noted as
393well.
9f122eef 394
4dc623f0 395[ List each change as a =item entry ]
9f122eef 396
4dc623f0 397=over 4
9f122eef
FC
398
399=item *
400
4dc623f0 401XXX
c7f058f0 402
4dc623f0 403=back
c7f058f0 404
4dc623f0 405=head1 Selected Bug Fixes
0ef4323a 406
4dc623f0
CBW
407XXX Important bug fixes in the core language are summarized here. Bug fixes in
408files in F<ext/> and F<lib/> are best summarized in L</Modules and Pragmata>.
0ef4323a 409
4dc623f0 410[ List each fix as a =item entry ]
c263379c 411
4dc623f0 412=over 4
c263379c 413
ff90be78
TC
414=item *
415
452466a5
FC
416On Win32, restoring in a child pseudo-process a variable that was
417C<local()>ed in a parent pseudo-process before the C<fork> happened caused
418memory corruption and a crash in the child pseudo-process (and therefore OS
419process).
ff90be78 420
3e669301
KW
421=item *
422
279aef25
TC
423Calling C<write> on a format with a C<^**> field could produce a panic
424in sv_chop() if there were insufficient arguments or if the variable
425used to fill the field was empty. [perl #123245]
426
00ba25b8
FC
427=item *
428
429Non-ASCII lexical sub names (use in error messages) on longer have extra
430junk on the end.
431
567291b6
FC
432=item *
433
434The C<\@> subroutine prototype no longer flattens parenthesized arrays
435(taking a reference to each element), but takes a reference to the array
436itself. [perl #47363]
437
fcfb7b86
FC
438=item *
439
440A block containing nothing except a C-style C<for> loop could corrupt the
441stack, causing lists outside the block to lose elements or have elements
442overwritten. This could happen with C<map { for(...){...} } ...> and with
443lists containing C<do { for(...){...} }>. [perl #123286]
444
8bb83ec2
FC
445=item *
446
447C<scalar()> now propagates lvalue context, so that
448C<for(scalar($#foo)) { ... }> can modify C<$#foo> through C<$_>.
449
86372193 450=back
bb8c7e27 451
86372193 452=head1 Known Problems
bb8c7e27 453
4dc623f0
CBW
454XXX Descriptions of platform agnostic bugs we know we can't fix go here. Any
455tests that had to be C<TODO>ed for the release would be noted here. Unfixed
456platform specific bugs also go here.
28a42920 457
4dc623f0 458[ List each fix as a =item entry ]
28a42920 459
6ed80d55
CBW
460=over 4
461
462=item *
463
4dc623f0 464XXX
6ed80d55
CBW
465
466=back
467
86372193 468=head1 Errata From Previous Releases
28a42920 469
86372193 470=over 4
28a42920
A
471
472=item *
473
4dc623f0
CBW
474XXX Add anything here that we forgot to add, or were mistaken about, in
475the perldelta of a previous release.
f5630681 476
8c8d6154 477=back
3a085d00 478
4dc623f0 479=head1 Obituary
01d42a22 480
4dc623f0
CBW
481XXX If any significant core contributor has died, we've added a short obituary
482here.
6ed80d55 483
4dc623f0 484=head1 Acknowledgements
01d42a22 485
4dc623f0 486XXX Generate this with:
01d42a22 487
4dc623f0 488 perl Porting/acknowledgements.pl v5.21.6..HEAD
f5b73711 489
44691e6f
AB
490=head1 Reporting Bugs
491
e08634c5
SH
492If you find what you think is a bug, you might check the articles recently
493posted to the comp.lang.perl.misc newsgroup and the perl bug database at
238894db 494https://rt.perl.org/ . There may also be information at
7ef8b31d 495http://www.perl.org/ , the Perl Home Page.
44691e6f 496
e08634c5
SH
497If you believe you have an unreported bug, please run the L<perlbug> program
498included with your release. Be sure to trim your bug down to a tiny but
499sufficient test case. Your bug report, along with the output of C<perl -V>,
500will be sent off to perlbug@perl.org to be analysed by the Perl porting team.
44691e6f
AB
501
502If the bug you are reporting has security implications, which make it
e08634c5
SH
503inappropriate to send to a publicly archived mailing list, then please send it
504to perl5-security-report@perl.org. This points to a closed subscription
505unarchived mailing list, which includes all the core committers, who will be
506able to help assess the impact of issues, figure out a resolution, and help
f9001595 507co-ordinate the release of patches to mitigate or fix the problem across all
e08634c5
SH
508platforms on which Perl is supported. Please only use this address for
509security issues in the Perl core, not for modules independently distributed on
510CPAN.
44691e6f
AB
511
512=head1 SEE ALSO
513
e08634c5
SH
514The F<Changes> file for an explanation of how to view exhaustive details on
515what changed.
44691e6f
AB
516
517The F<INSTALL> file for how to build Perl.
518
519The F<README> file for general stuff.
520
521The F<Artistic> and F<Copying> files for copyright information.
522
523=cut