This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
perldelta update
[perl5.git] / pod / perldelta.pod
CommitLineData
44691e6f
AB
1=encoding utf8
2
bbc28bfc
FC
3=for comment
4This has been completed up to 8367b6810 except for:
5747627ec455e0765e07733ece1545aa3f728a00a (Steffen Müller)
6dd35fa16610ef2fa0d46f5129e626b99cf350d77 (H. Merijn Brand)
7e64345f82d66a32f6da47acf482e7e6c9282b433 (Steffen Müller)
8f1d35e3443aa8451bf47be80983076fe28626113 (Karthik Rajagopalan)
9
44691e6f
AB
10=head1 NAME
11
5438d4b8
Z
12[ this is a template for a new perldelta file. Any text flagged as
13XXX needs to be processed before release. ]
f5938650 14
5438d4b8 15perldelta - what is new for perl v5.15.2
760696b8 16
5438d4b8 17=head1 DESCRIPTION
5cd408a2 18
5438d4b8
Z
19This document describes differences between the 5.15.1 release and
20the 5.15.2 release.
5cd408a2 21
5438d4b8
Z
22If you are upgrading from an earlier release such as 5.15.0, first read
23L<perl5151delta>, which describes differences between 5.15.0 and
245.15.1.
062678b2 25
5438d4b8 26=head1 Notice
062678b2 27
5438d4b8 28XXX Any important notices here
4185c919 29
5438d4b8 30=head1 Core Enhancements
4185c919 31
5438d4b8
Z
32XXX New core language features go here. Summarise user-visible core language
33enhancements. Particularly prominent performance optimisations could go
34here, but most should go in the L</Performance Enhancements> section.
82aed44a 35
5438d4b8 36[ List each enhancement as a =head2 entry ]
82aed44a 37
0afed34d
FC
38=head2 Subroutines in the CORE namespace
39
40Many Perl keywords are now available as subroutines in the CORE namespace.
41These cannot be called through references or via C<&foo> syntax yet, but
42must be called as barewords. In other words, you can now do this:
43
44 BEGIN { *entangle = \&CORE::tie }
45 entangle $variable, $package, @args;
46
0bbad748
FC
47This currently works for overridable keywords other than C<dump> and the
48infix operators.
0afed34d
FC
49
50Work is under way to allow these subroutines to be called through
51references.
52
135c0b08
FC
53=head2 C<__FILE__()> Syntax
54
55The C<__FILE__>, C<__LINE__> and C<__PACKAGE__> tokens can now be written
56with an empty pair of parentheses after them. This makes them parse the
57same way as C<time>, C<fork> and other built-in functions.
58
5438d4b8 59=head1 Security
2b679393 60
5438d4b8
Z
61XXX Any security-related notices go here. In particular, any security
62vulnerabilities closed should be noted here rather than in the
63L</Selected Bug Fixes> section.
2b679393 64
5438d4b8 65[ List each security issue as a =head2 entry ]
7818c927 66
5438d4b8 67=head1 Incompatible Changes
7818c927 68
5438d4b8 69XXX For a release on a stable branch, this section aspires to be:
760696b8 70
5438d4b8
Z
71 There are no changes intentionally incompatible with 5.XXX.XXX
72 If any exist, they are bugs and reports are welcome.
6693394d 73
5438d4b8 74[ List each incompatible change as a =head2 entry ]
6693394d 75
7b2b001e
FC
76=head2 C<UNIVERSAL::VERSION> now returns $VERSION
77
78C<UNIVERSAL::VERSION> now return whatever is in $VERSION, instead of
79returning $VERSION converted to a version object and then to a string.
80As a result, it no longer parses the version when called without arguments,
81so it no longer dies in that case for malformed versions. This allows
82custom version number parsers to use C<< ->VERSION >> to retrieve the
83version number, as was the case in Perl 5.8 [perl #95544].
84
5438d4b8 85=head1 Deprecations
92c695db 86
5438d4b8
Z
87XXX Any deprecated features, syntax, modules etc. should be listed here.
88In particular, deprecated modules should be listed here even if they are
89listed as an updated module in the L</Modules and Pragmata> section.
92c695db 90
5438d4b8 91[ List each deprecation as a =head2 entry ]
6693394d 92
5438d4b8 93=head1 Performance Enhancements
bfafcb9a 94
5438d4b8
Z
95XXX Changes which enhance performance without changing behaviour go here. There
96may well be none in a stable release.
bfafcb9a 97
5438d4b8 98[ List each enhancement as a =item entry ]
72de20cd 99
5438d4b8 100=over 4
72de20cd 101
93905212
FC
102=item *
103
5438d4b8 104XXX
93905212 105
6693394d
FC
106=back
107
0890f1a5 108=head1 Modules and Pragmata
bdb9ba77 109
5438d4b8
Z
110XXX All changes to installed files in F<cpan/>, F<dist/>, F<ext/> and F<lib/>
111go here. If Module::CoreList is updated, generate an initial draft of the
112following sections using F<Porting/corelist-perldelta.pl>, which prints stub
113entries to STDOUT. Results can be pasted in place of the '=head2' entries
114below. A paragraph summary for important changes should then be added by hand.
115In an ideal world, dual-life modules would have a F<Changes> file that could be
116cribbed.
117
118[ Within each section, list entries as a =item entry ]
119
0890f1a5 120=head2 New Modules and Pragmata
6693394d 121
0890f1a5 122=over 4
6693394d
FC
123
124=item *
125
5438d4b8 126XXX
6693394d
FC
127
128=back
129
0890f1a5 130=head2 Updated Modules and Pragmata
760696b8 131
0890f1a5 132=over 4
760696b8
FC
133
134=item *
135
115ff745
NC
136L<B> has been upgraded from version 1.30 to version 1.31
137
138The XS code has changed slightly, as it was too tightly coupled to
987f2729
RU
139the contents of the header F<embedvar.h>. Documentation in L<B::Terse>
140and L<B::Xref> has been improved, hence their versions have been increased.
115ff745
NC
141
142=item *
143
4ea805df
CBW
144L<CPAN> has been upgraded from version 1.9600 to version 1.9800
145
146=item *
147
1ba7a2fb
CBW
148L<CPANPLUS> has been upgraded from version 0.9108 to version 0.9109
149
150Fixed support for v-strings and x.y.z versions with v5.8.4
151
152=item *
153
730e5b5b
CBW
154L<CPAN::Meta> has been upgraded from version 2.110930_001 to version 2.112150
155
156Stringify any objects encountered during conversion.
157
158Clarified that file paths in the 'provides' section must be in
159Unix-style (i.e. forward slashes)
160
161=item *
162
37adef70 163L<DB_File> has been upgraded from version 1.822 to version 1.824
a30cae0b
CBW
164
165Will now croak if attempt to freeze/thaw DB_File object [RT #69985]
166
167=item *
168
bbc28bfc
FC
169L<diagnostics> has been upgraded from version 1.23 to 1.24.
170
171It now supports the %u formatting code. Previously it was unable to find
172descriptions for messages whose entries in L<perldiag> included that code
173[perl #94988].
174
175=item *
176
e46d9735
CBW
177L<Encode> has been upgraded from version 2.43 to version 2.44
178
179Addressed 'decode_xs n-byte heap-overflow' security bug in Unicode.xs
180
181=item *
182
57126352
DG
183L<ExtUtils::Install> has been upgraded from version 1.56 to version 1.57.
184
185There is no change to ExtUtils::Install other than the version number
186increase, but L<ExtUtils::Installed> has been upgraded from version 1.999_001
c493c0a1 187to version 1.999002 and a new C<skip_cwd> attribute has been added.
259925f6 188
6252d2e2
NC
189=item *
190
9840cdee
CBW
191L<ExtUtils::MakeMaker> has been upgraded from version 6.58 to version 6.59
192
193=item *
194
7b2b001e
FC
195L<IPC::Open3> has been upgraded from version 1.11 to 1.12.
196
197C<open3> with "-" for the program name works once more. This was broken in
198version 1.06 (and hence in Perl 5.14.0) [perl #95748].
199
200=item *
201
2df9265e
DG
202L<Module::Build> has been upgraded from version 0.3800 to version 0.39_01.
203
204Pod to HTML internals changed to support revisions to Pod::Html in core.
205Also fixes some minor bugs. [rt.cpan.org #68585] [rt.cpan.org #67893]
206[rt.cpan.org #67008]
207
208=item *
209
83b32788
CBW
210L<Module::Load> has been upgraded from version 0.18 to version 0.20
211
212=item *
213
4eb81ef2
CBW
214L<Module::Metadata> has been upgraded from version 1.000004 to version 1.000005
215
216Added C<new_from_handle()> method.
217
218=item *
219
cc48f4fe 220L<Params::Check> has been upgraded from version 0.28 to version 0.32
82eefd8a
CBW
221
222=item *
223
5213914c 224L<PerlIO::via> has been upgraded from version 0.11 to version 0.12.
6252d2e2
NC
225
226The only change is a correction in the documentation.
227
5213914c
CBW
228=item *
229
230L<Term::ANSIColor> has been upgraded from version 3.00 to version 3.01
231
232Only interpret an initial array reference as a list of colors, not any initial
233reference, allowing the colored function to work properly on objects with
234stringification defined.
235
17609435
CBW
236=item *
237
238L<Unicode::Collate> has been upgraded from version 0.77 to version 0.78
239
69f26f52
CBW
240=item *
241
242L<Unicode::Normalize> has been upgraded from version 1.12 to version 1.13
243
5438d4b8 244=back
77ccfaeb 245
5438d4b8 246=head2 Removed Modules and Pragmata
508236ce 247
5438d4b8 248=over 4
508236ce
CBW
249
250=item *
251
5438d4b8 252XXX
c69a30ec 253
5438d4b8 254=back
c69a30ec 255
5438d4b8 256=head1 Documentation
c69a30ec 257
5438d4b8
Z
258XXX Changes to files in F<pod/> go here. Consider grouping entries by
259file and be sure to link to the appropriate page, e.g. L<perlfunc>.
7c420290 260
5438d4b8 261=head2 New Documentation
7c420290 262
5438d4b8 263XXX Changes which create B<new> files in F<pod/> go here.
0cb4637e 264
bbc28bfc 265=head3 L<perlexperiment>
7818c927 266
bbc28bfc
FC
267This document is intended to provide a list of experimental features in
268Perl. It is still a work in progress.
7818c927 269
5438d4b8 270=head2 Changes to Existing Documentation
dd413713 271
5438d4b8
Z
272XXX Changes which significantly change existing files in F<pod/> go here.
273However, any changes to F<pod/perldiag.pod> should go in the L</Diagnostics>
274section.
7818c927 275
bbc28bfc 276=head3 L<perlsub>
7818c927 277
5438d4b8 278=over 4
7818c927
FC
279
280=item *
281
bbc28bfc
FC
282The ($;) prototype syntax, which has existed for rather a long time, is now
283documented in L<perlsub>. It allows a unary function to have the same
284precedence as a list operator.
5aeca1f7 285
5438d4b8 286=back
5aeca1f7 287
5438d4b8 288=head1 Diagnostics
0cb4637e 289
5438d4b8
Z
290The following additions or changes have been made to diagnostic output,
291including warnings and fatal error messages. For the complete list of
292diagnostic messages, see L<perldiag>.
0cb4637e 293
5438d4b8
Z
294XXX New or changed warnings emitted by the core's C<C> code go here. Also
295include any changes in L<perldiag> that reconcile it to the C<C> code.
00f02a57 296
5438d4b8
Z
297[ Within each section, list entries as a =item entry that links to perldiag,
298 e.g.
00f02a57 299
5438d4b8 300 =item *
00f02a57 301
5438d4b8
Z
302 L<Invalid version object|perldiag/"Invalid version object">
303]
8b00e523 304
5438d4b8 305=head2 New Diagnostics
4abaf918 306
5438d4b8 307XXX Newly added diagnostic messages go here
4abaf918 308
5438d4b8 309=head3 New Errors
4abaf918 310
5438d4b8 311=over 4
4abaf918
Z
312
313=item *
314
0afed34d
FC
315L<&CORE::%s cannot be called directly|perldiag/"&CORE::%s cannot be called directly">
316
317(F) You tried to call a subroutine in the C<CORE::> namespace
318with C<&foo> syntax or through a reference. The subroutines
319in this package cannot yet be called that way, but must be
320called as barewords. Something like this will work:
321
322 BEGIN { *shove = \&CORE::push; }
323 shove @array, 1,2,3; # pushes on to @array
8b00e523 324
e8e35311
FC
325=back
326
5438d4b8 327=head3 New Warnings
bdb9ba77 328
0890f1a5 329=over 4
bdb9ba77
DG
330
331=item *
332
5438d4b8 333XXX L<message|perldiag/"message">
bdb9ba77
DG
334
335=back
336
5438d4b8 337=head2 Changes to Existing Diagnostics
7818c927 338
5438d4b8 339XXX Changes (i.e. rewording) of diagnostic messages go here
0890f1a5 340
0890f1a5 341=over 4
6693394d
FC
342
343=item *
344
5438d4b8 345XXX Describe change here
259925f6 346
5438d4b8 347=back
7818c927 348
5438d4b8 349=head1 Utility Changes
7818c927 350
5438d4b8
Z
351XXX Changes to installed programs such as F<perlbug> and F<xsubpp> go
352here. Most of these are built within the directories F<utils> and F<x2p>.
7818c927 353
5438d4b8
Z
354[ List utility changes as a =head3 entry for each utility and =item
355entries for each change
356Use L<XXX> with program names to get proper documentation linking. ]
7818c927 357
71449ad0 358=head3 L<perlivp>
b908e258 359
5438d4b8 360=over 4
b908e258
Z
361
362=item *
363
71449ad0
DG
364Fixed a bug whereby other perls under the current directory could cause
365false positive failures.
366
367=item *
368
369Tests for .ph files have been removed, as these test have been optional since
3702005 and .ph files are no longer generated during installation.
b908e258 371
6693394d
FC
372=back
373
bbc28bfc
FC
374=head3 L<splain>
375
376See the entry for C<< diagnostics >> in L</Updated Modules and Pragmata>,
377above.
378
5438d4b8 379=head1 Configuration and Compilation
b7188eb5 380
5438d4b8
Z
381XXX Changes to F<Configure>, F<installperl>, F<installman>, and analogous tools
382go here. Any other changes to the Perl build process should be listed here.
383However, any platform-specific changes should be listed in the
384L</Platform Support> section, instead.
44691e6f 385
5438d4b8 386[ List changes as a =item entry ].
42a91c97 387
34dc2ec0 388=over 4
42a91c97 389
6693394d 390=item *
42a91c97 391
60a5fae4
NC
392F<makedef.pl> has been refactored. This should have no noticeable affect on
393any of the platforms that use it as part of their build (AIX, VMS, Win32).
42a91c97 394
34dc2ec0 395=back
42a91c97 396
0890f1a5 397=head1 Testing
bdab33d1 398
5438d4b8
Z
399XXX Any significant changes to the testing of a freshly built perl should be
400listed here. Changes which create B<new> files in F<t/> go here as do any
401large changes to the testing harness (e.g. when parallel testing was added).
402Changes to existing files in F<t/> aren't worth summarising, although the bugs
403that they represent may be covered elsewhere.
f5938650 404
5438d4b8 405[ List each test improvement as a =item entry ]
1fcb0052 406
5438d4b8 407=over 4
1fcb0052 408
b908e258
Z
409=item *
410
5438d4b8 411XXX
b908e258 412
f5938650 413=back
2fbb14a0 414
0890f1a5 415=head1 Platform Support
975dff8c 416
5438d4b8 417XXX Any changes to platform support should be listed in the sections below.
6693394d 418
5438d4b8
Z
419[ Within the sections, list each platform as a =item entry with specific
420changes as paragraphs below it. ]
6693394d 421
9cfd094e
MB
422=over 4
423
424=item HP-UX PA-RISC/64 now supports gcc-4.x
425
426A fix to correct the socketsize now makes the test suite pass on HP-UX
427PA-RISC for 64bitall builds.
428
429=back
430
5438d4b8 431=head2 New Platforms
1fcb0052 432
5438d4b8
Z
433XXX List any platforms that this version of perl compiles on, that previous
434versions did not. These will either be enabled by new files in the F<hints/>
435directories, or new subdirectories and F<README> files at the top level of the
436source tree.
6693394d 437
0890f1a5 438=over 4
f5938650 439
5438d4b8 440=item XXX-some-platform
c62f68e3 441
5438d4b8 442XXX
f5938650 443
0890f1a5 444=back
25aa614d 445
5438d4b8 446=head2 Discontinued Platforms
87d00a71 447
5438d4b8 448XXX List any platforms that this version of perl no longer compiles on.
87d00a71 449
5438d4b8 450=over 4
da507230 451
5438d4b8 452=item XXX-some-platform
fff96ff7 453
5438d4b8 454XXX
da507230 455
5438d4b8 456=back
bb3abb05 457
5438d4b8 458=head2 Platform-Specific Notes
d25b0d7b 459
5438d4b8
Z
460XXX List any changes for specific platforms. This could include configuration
461and compilation changes or changes in portability/compatibility. However,
462changes within modules for platforms should generally be listed in the
463L</Modules and Pragmata> section.
d25b0d7b 464
5438d4b8 465=over 4
4bee03f8 466
5438d4b8 467=item XXX-some-platform
4bee03f8 468
5438d4b8 469XXX
d9463c66 470
5438d4b8 471=back
d9463c66 472
5438d4b8 473=head1 Internal Changes
7c4c6e7c 474
5438d4b8
Z
475XXX Changes which affect the interface available to C<XS> code go here.
476Other significant internal changes for future core maintainers should
477be noted as well.
7c4c6e7c 478
5438d4b8 479[ List each change as a =item entry ]
777d9014 480
5438d4b8 481=over 4
95f7e41f
FC
482
483=item *
484
115ff745
NC
485F<embedvar.h> has been simplified, and one level of macro indirection for
486PL_* variables has been removed for the default (non-multiplicity)
487configuration. PERLVAR*() macros now directly expand their arguments to
488tokens such as C<PL_defgv>, instead of expanding to C<PL_Idefgv>, with
489F<embedvar.h> defining a macro to map C<PL_Idefgv> to C<PL_defgv>. XS code
490which has unwarranted chumminess with the implementation may need updating.
df5b44bd 491
5438d4b8 492=back
df5b44bd 493
5438d4b8 494=head1 Selected Bug Fixes
e22e289d 495
5438d4b8
Z
496XXX Important bug fixes in the core language are summarised here.
497Bug fixes in files in F<ext/> and F<lib/> are best summarised in
498L</Modules and Pragmata>.
7818c927 499
5438d4b8 500[ List each fix as a =item entry ]
7818c927 501
5438d4b8 502=over 4
7818c927
FC
503
504=item *
505
f79aa60b
FC
506Locking a subroutine (via C<lock &sub>) is no longer a compile-time error
507for regular subs. For lvalue subroutines, it no longer tries to return the
508sub as a scalar, resulting in strange side effects like C<ref \$_>
509returning "CODE" in some instances.
510
511C<lock &sub> is now a run-time error if L<threads::shared> is loaded (a
512no-op otherwise), but that may be rectified in a future version.
7818c927 513
3fdd840f
FC
514=item *
515
a67abb3a
FC
516The prototypes of several built-in functions--C<getprotobynumber>, C<lock>,
517C<not> and C<select>--have been corrected, or at least are now closer to
518reality than before.
3fdd840f 519
7ffa7e75
FC
520=item *
521
522Most dereferencing operators (C<${}>, etc.) used to call C<FETCH> twice on
523a tied operand when doing a symbolic dereference (looking up a variable by
524name, which is not permitted under C<use strict 'refs'>). Only C<&{}> did
525not have this problem. This has been fixed.
526
862b2c43
FC
527=item *
528
529A minor regression introduced in 5.15.0 has been fixed. Dereferencing a
530magical mortal (e.g., the return value of C<delete> on a tied hash element)
531explicitly returned from a subroutine called recursively was not calling
532C<FETCH>. This would affect code like C<@{ foo() }> where the C<foo> sub
533contains C<return delete $hash{elem}> and is calling itself.
534
c973bd4f
KW
535=item *
536
537A panic involving the combination of the regular expression modifiers
538C</aa> and the C<\b> escape sequence introduced in 5.14.0 has been
539fixed [perl #95964].
540
a6cefd81
TC
541=item *
542
543stat() would always return the inode number as an IV, even when the
544original was unsigned, or too large to fit in an IV. stat() now
545returns the inode number as the type that would best preserve the
546original value. [perl #84590]
547
c4499eff
KW
548=item *
549
550The combination of the regular expression modifiers C</aa> and the C<\b>
551and C<\B> escape sequences did not work properly on UTF-8 encoded
552strings. All non-ASCII characters under C</aa> should be treated as
553non-word characters, but what was happening was that Unicode rules were
554used to determine wordness/non-wordness for non-ASCII characters. This
555is now fixed [perl #95968].
556
bbc28bfc
FC
557=item *
558
559Infinite loops like C<1 while 1> used to stop C<strict 'subs'> mode from
560working for the rest of the block.t
561
562=item *
563
564The C<\h>, C<\H>, C<\v> and C<\V> regular expression metacharacters used to
565cause a panic error message when attempting to match at the end of the
566string [perl #96354].
567
568=item *
569
570For list assignments like C<($a,$b) = ($b,$a)>, Perl has to make a copy of
571the items on the right-hand side before assignment them to the left. For
572efficiency's sake, it assigns the values on the right straight to the items
573on the left no variable is mentioned on both sides, as in
574C<($a,$b) = ($c,$d)>. The logic for determining when it can cheat was
575faulty, in that C<&&> and C<||> on the right-hand side could fool it. So
576C<($a,$b) = $some_true_value && ($b,$a)> would end up assigning the value
577of C<$b> to both scalars.
578
579=item *
580
581Perl no longer tries to apply lvalue context to the string in
582C<("string", $variable) ||= 1> (which used to be an error). Since the
583left-hand side of C<||=> is evaluated in scalar context, that's a scalar
584comma operator, which gives all but the last item void context. There is
585no such thing as void lvalue context, so it was a mistake for Perl to try
586to force it [perl #96942].
587
5438d4b8 588=back
c62f68e3 589
5438d4b8 590=head1 Known Problems
c62f68e3 591
5438d4b8
Z
592XXX Descriptions of platform agnostic bugs we know we can't fix go here. Any
593tests that had to be C<TODO>ed for the release would be noted here, unless
594they were specific to a particular platform (see below).
c62f68e3 595
5438d4b8
Z
596This is a list of some significant unfixed bugs, which are regressions
597from either 5.XXX.XXX or 5.XXX.XXX.
e22e289d 598
5438d4b8 599[ List each fix as a =item entry ]
e22e289d 600
5438d4b8 601=over 4
e22e289d 602
b908e258
Z
603=item *
604
5438d4b8 605XXX
4ec40670 606
5438d4b8 607=back
4ec40670 608
5438d4b8 609=head1 Obituary
b908e258 610
5438d4b8
Z
611XXX If any significant core contributor has died, we've added a short obituary
612here.
42a91c97 613
44691e6f
AB
614=head1 Acknowledgements
615
f1c1ecab 616XXX Generate this with:
5438d4b8
Z
617
618 perl Porting/acknowledgements.pl v5.15.1..HEAD
29cf780c 619
44691e6f
AB
620=head1 Reporting Bugs
621
622If you find what you think is a bug, you might check the articles
34dc2ec0 623recently posted to the comp.lang.perl.misc newsgroup and the perl
44691e6f
AB
624bug database at http://rt.perl.org/perlbug/ . There may also be
625information at http://www.perl.org/ , the Perl Home Page.
626
627If you believe you have an unreported bug, please run the L<perlbug>
628program included with your release. Be sure to trim your bug down
629to a tiny but sufficient test case. Your bug report, along with the
630output of C<perl -V>, will be sent off to perlbug@perl.org to be
631analysed by the Perl porting team.
632
633If the bug you are reporting has security implications, which make it
634inappropriate to send to a publicly archived mailing list, then please send
34dc2ec0 635it to perl5-security-report@perl.org. This points to a closed subscription
b4707b2a
FC
636unarchived mailing list, which includes
637all the core committers, who will be able
44691e6f
AB
638to help assess the impact of issues, figure out a resolution, and help
639co-ordinate the release of patches to mitigate or fix the problem across all
34dc2ec0
DM
640platforms on which Perl is supported. Please only use this address for
641security issues in the Perl core, not for modules independently
44691e6f
AB
642distributed on CPAN.
643
644=head1 SEE ALSO
645
646The F<Changes> file for an explanation of how to view exhaustive details
647on what changed.
648
649The F<INSTALL> file for how to build Perl.
650
651The F<README> file for general stuff.
652
653The F<Artistic> and F<Copying> files for copyright information.
654
655=cut