5 [ this is a template for a new perldelta file. Any text flagged as XXX needs
6 to be processed before release. ]
8 perldelta - what is new for perl v5.19.4
12 This document describes differences between the 5.19.3 release and the 5.19.4
15 If you are upgrading from an earlier release such as 5.19.2, first read
16 L<perl5193delta>, which describes differences between 5.19.2 and 5.19.3.
20 XXX Any important notices here
22 =head1 Core Enhancements
24 XXX New core language features go here. Summarize user-visible core language
25 enhancements. Particularly prominent performance optimisations could go
26 here, but most should go in the L</Performance Enhancements> section.
28 [ List each enhancement as a =head2 entry ]
30 =head2 rand() now uses a consistent random number generator
32 Previously perl would use a platform specific random number generator,
33 varying between the libc C<rand()>, C<random()> or C<drand48()>.
35 This meant that the quality of perl's random numbers would vary from
36 platform to platform, from the 15 bits of C<rand()> on Win32 to
37 48-bits on POSIX platforms such as Linux with C<drand48()>.
39 Perl now uses its own internal C<drand48()> implementation on all
40 platforms. [perl #115928]
42 =head2 Better 64-bit support
44 On 64-bit platforms, the internal array functions now use 64-bit offsets,
45 allowing Perl arrays to hold more than 2**31 elements, if you have the
48 The regular expression engine now supporst strings longer than 2**31
49 characters. [perl #112790, #116907]
53 XXX Any security-related notices go here. In particular, any security
54 vulnerabilities closed should be noted here rather than in the
55 L</Selected Bug Fixes> section.
57 [ List each security issue as a =head2 entry ]
59 =head1 Incompatible Changes
61 =head2 Locale decimal point character no longer leaks outside of
62 S<C<use locale>> scope (with the exception of C<$!>)
64 This is actually a bug fix, but some code has come to rely on the bug being
65 present, so this change is listed here. The current locale that the program is
66 running under is not supposed to be visible to Perl code except within the
67 scope of a S<C<use locale>>. However, until now under certain circumstances,
68 the character used for a decimal point (often a comma) leaked outside the
71 This continues the work released in Perl 5.19.1. It turns out that that did
72 not catch all the leaks, including C<printf> and C<sprintf> not respecting
73 S<C<use locale>>. If your code is affected by this change, simply add a
76 Now, the only known place where C<'use locale'> is not respected is in the
77 stringification of L<$!|perlvar/$!>.
81 XXX Any deprecated features, syntax, modules etc. should be listed here.
83 =head2 Module removals
85 XXX Remove this section if inapplicable.
87 The following modules will be removed from the core distribution in a
88 future release, and will at that time need to be installed from CPAN.
89 Distributions on CPAN which require these modules will need to list them as
92 The core versions of these modules will now issue C<"deprecated">-category
93 warnings to alert you to this fact. To silence these deprecation warnings,
94 install the modules in question from CPAN.
96 Note that these are (with rare exceptions) fine modules that you are encouraged
97 to continue to use. Their disinclusion from core primarily hinges on their
98 necessity to bootstrapping a fully functional, CPAN-capable Perl installation,
99 not usually on concerns over their design.
103 XXX Note that deprecated modules should be listed here even if they are listed
104 as an updated module in the L</Modules and Pragmata> section.
108 [ List each other deprecation as a =head2 entry ]
110 =head1 Performance Enhancements
116 The trie performance enhancement for regular expressions has now been extended
117 to those compiled under C</iaa>.
121 =head1 Modules and Pragmata
123 XXX All changes to installed files in F<cpan/>, F<dist/>, F<ext/> and F<lib/>
124 go here. If Module::CoreList is updated, generate an initial draft of the
125 following sections using F<Porting/corelist-perldelta.pl>, which prints stub
126 entries to STDOUT. Results can be pasted in place of the '=head2' entries
127 below. A paragraph summary for important changes should then be added by hand.
128 In an ideal world, dual-life modules would have a F<Changes> file that could be
131 [ Within each section, list entries as a =item entry ]
133 =head2 New Modules and Pragmata
143 =head2 Updated Modules and Pragmata
149 L<autodie> has been upgraded from version 2.20 to 2.21.
151 Numerous improvements have been made, many speed-related. See the F<Changes>
152 file in the CPAN distribution for full details.
156 L<B> has been upgraded from version 1.45 to 1.46.
158 The fix for [perl #118525] introduced a regression in the behaviour of
159 C<B::CV::GV>, changing the return value from a C<B::SPECIAL> object on a
160 C<NULL> C<CvGV> to C<undef>. C<B::CV::GV> again returns a C<B::SPECIAL>
161 object in this case. [perl #119351]
165 L<B::Concise> has been upgraded from version 0.98 to 0.99.
167 The handling of the C<glob> operator, broken since Perl 5.17.6, has been fixed.
171 L<Carp> has been upgraded from version 1.31 to 1.32.
177 In stack traces, subroutine arguments that are strings are now quoted in a
178 consistent manner, regardless of what characters they contain and how they're
179 internally represented.
183 C<Carp> now won't vivify the C<overload::StrVal> glob or subroutine or the
188 C<Carp> now avoids some unwanted Unicode warnings on older Perls. This doesn't
189 affect behaviour with current Perl.
193 C<Carp::Heavy> detects version mismatch with C<Carp>, to give a good error
194 message if a current (stub) C<Carp::Heavy> gets loaded by an old C<Carp> that
195 expects C<Carp::Heavy> to provide subroutines.
201 L<charnames> has been upgraded from version 1.38 to 1.39.
203 This module now works on EBCDIC platforms.
207 L<CPAN::Meta> has been upgraded from version 2.132140 to 2.132510.
209 No changes have been made to the installed code other than the version bump to
210 keep in sync with the latest CPAN release.
214 L<CPAN::Meta::Requirements> has been upgraded from version 2.122 to 2.123.
216 No changes have been made to the installed code other than the version bump to
217 keep in sync with the latest CPAN release.
221 L<Data::Dumper> has been upgraded from version 2.148 to 2.149.
223 This upgrade is part of a larger change to make the array interface 64-bit safe
224 by using SSize_t instead of I32 for array indices.
226 In addition, an EBCDIC fix has been applied.
230 L<Devel::Peek> has been upgraded from version 1.13 to 1.14.
232 This upgrade is part of a larger change to preserve referential identity when
233 passing C<undef> to a subroutine by using NULL rather than &PL_sv_undef for
234 nonexistent array elements.
236 In addition, C<Dump> with no args was broken in Perl 5.19.3, but has now been
241 L<DynaLoader> has been upgraded from version 1.19 to 1.20.
243 The documentation now makes it clear, as has always been the case, that
244 C<dl_unload_file> is only called automatically to unload all loaded shared
245 objects if the perl interpreter was built with the C macro
246 DL_UNLOAD_ALL_AT_EXIT defined. Support for GNU DLD has also been removed.
250 L<Encode> has been upgraded from version 2.52 to 2.55.
252 An erroneous early return in C<decode_utf8> has been removed, and a bug in
253 C<_utf8_on> under COW has been fixed. Encode also now uses L<parent> rather
254 than L<base> throughout.
258 L<Exporter> has been upgraded from version 5.69 to 5.70.
260 A number of typos have been corrected in the documentation.
264 L<ExtUtils::CBuilder> has been upgraded from version 0.280205 to 0.280212.
266 No changes have been made to the installed code other than the version bump to
267 keep in sync with the latest CPAN release.
271 L<ExtUtils::Command> has been upgraded from version 1.17 to 1.18.
273 No changes have been made to the installed code other than the version bump to
274 keep in sync with the latest CPAN release.
278 L<ExtUtils::MakeMaker> has been upgraded from version 6.72 to 6.76.
280 Numerous updates and bug fixes are incorporated. See the F<Changes> file for
285 L<ExtUtils::ParseXS> has been upgraded from version 3.21 to 3.22.
287 No changes have been made to the installed code other than the version bump to
288 keep in sync with the latest CPAN release.
292 L<File::Find> has been upgraded from version 1.24 to 1.25.
294 Better diagnostics are now provided in the case of a failed C<chdir>.
298 L<File::Glob> has been upgraded from version 1.20 to 1.21.
300 C<glob()> now warns in the context of C<use warnings "syscalls";> if the
301 supplied pattern has an internal NUL (C<"\0">) character.
305 L<HTTP::Tiny> has been upgraded from version 0.034 to 0.035.
307 Encoded data from C<post_form> now preserves term order if data is provided as
308 an array reference. (They are still sorted for consistency if provided as a
313 L<I18N::LangTags> has been upgraded from version 0.39 to 0.40.
315 Bosnian has now joined Croatian and Serbian in the lists of mutually
316 intelligible Slavic languages. [perl #72594]
320 L<IO> has been upgraded from version 1.28 to 1.29.
322 A minor internals-only change has been made to the XS code.
326 L<IPC::Open3> has been upgraded from version 1.15 to 1.16.
328 This upgrade is part of a larger change to preserve referential identity when
329 passing C<undef> to a subroutine by using NULL rather than &PL_sv_undef for
330 nonexistent array elements.
334 L<Locale::Codes> has been upgraded from version 3.26 to 3.27.
336 New codes have been added and the (deprecated) set of FIPS-10 country codes has
341 L<Math::BigInt> has been upgraded from version 1.9992 to 1.9993.
343 Cleaned up the L<Math::BigInt> and L<Math::BigFloat> documentation to be more
344 consistent with other perl documentation. [perl #86686]
346 Added a bint() method for rounding towards zero. [perl #85296]
350 L<Math::BigInt::FastCalc> has been upgraded from version 0.30 to 0.31.
352 This upgrade is part of a larger change to make the array interface 64-bit safe
353 by using SSize_t instead of I32 for array indices.
357 L<Module::CoreList> has been upgraded from version 2.97 to 2.98.
359 The list of Perl versions covered has been updated.
363 L<Module::Load::Conditional> has been upgraded from version 0.54 to 0.58.
365 C<requires> has been made more robust. [cpan #83728]
369 L<Module::Metadata> has been upgraded from version 1.000014 to 1.000018.
371 The module's DESCRIPTION has been re-worded regarding safety/security to
372 satisfy CVE-2013-1437. Also, versions are now detainted if needed. [cpan
377 L<mro> has been upgraded from version 1.13 to 1.14.
379 This upgrade is part of a larger change to make the array interface 64-bit safe
380 by using SSize_t instead of I32 for array indices.
384 L<parent> has been upgraded from version 0.226 to 0.227.
386 No changes have been made to the installed code other than the version bump to
387 keep in sync with the latest CPAN release.
391 L<Parse::CPAN::Meta> has been upgraded from version 1.4405 to 1.4407.
393 No changes have been made to the installed code other than the version bump to
394 keep in sync with the latest CPAN release.
398 L<Perl::OSType> has been upgraded from version 1.003 to 1.005.
400 The Unix OSType 'bitrig' has been added.
404 L<perlfaq> has been upgraded from version 5.0150043 to 5.0150044.
406 The use of C<gensym> in a number of examples has been removed, the use of C<&>
407 in subroutine calls is now clarified and several new questions have been
412 L<re> has been upgraded from version 0.25 to 0.26.
414 A function signature has been corrected in the XS implementation.
418 L<Scalar::Util> has been upgraded from version 1.31 to 1.32.
420 The documentation of C<blessed> has been improved to mention the fact that
421 package "0" is defined but false.
425 L<Socket> has been upgraded from version 2.011 to 2.012.
427 Syntax errors when building on the WinCE platform have been fixed. [cpan #87389]
431 L<Storable> has been upgraded from version 2.46 to 2.47.
433 This upgrade is part of a larger change to preserve referential identity when
434 passing C<undef> to a subroutine by using NULL rather than &PL_sv_undef for
435 nonexistent array elements.
439 L<Term::ReadLine> has been upgraded from version 1.10 to 1.14.
441 Term::ReadLine::EditLine support has been added.
445 L<Time::Piece> has been upgraded from version 1.22 to 1.23.
447 Day of year parsing (like "%y%j") has been fixed.
451 L<Unicode::Collate> has been upgraded from version 0.98 to 0.99.
453 By default, out-of-range values are replaced with C<U+FFFD> (REPLACEMENT
454 CHARACTER) when C<UCA_Version> E<gt>= 22, or ignored when C<UCA_Version> E<lt>=
455 20. When C<UCA_Version> E<gt>= 22, the weights of out-of-range values can be
460 L<Unicode::UCD> has been upgraded from version 0.53 to 0.54.
462 This module now works on EBCDIC platforms.
466 L<version> has been upgraded from version 0.9903 to 0.9904.
468 No changes have been made to the installed code other than the version bump to
469 keep in sync with the latest CPAN release.
473 L<warnings> has been upgraded from version 1.18 to 1.19.
475 The C<syscalls> warnings category has been added to check for embedded NUL
476 (C<"\0">) characters in pathnames and string arguments to other system calls.
480 L<XS::Typemap> has been upgraded from version 0.10 to 0.11.
484 =head2 Removed Modules and Pragmata
496 XXX Changes to files in F<pod/> go here. Consider grouping entries by
497 file and be sure to link to the appropriate page, e.g. L<perlfunc>.
499 =head2 New Documentation
501 XXX Changes which create B<new> files in F<pod/> go here.
505 XXX Description of the purpose of the new file here
507 =head2 Changes to Existing Documentation
509 XXX Changes which significantly change existing files in F<pod/> go here.
510 However, any changes to F<pod/perldiag.pod> should go in the L</Diagnostics>
519 XXX Description of the change here
525 The following additions or changes have been made to diagnostic output,
526 including warnings and fatal error messages. For the complete list of
527 diagnostic messages, see L<perldiag>.
529 XXX New or changed warnings emitted by the core's C<C> code go here. Also
530 include any changes in L<perldiag> that reconcile it to the C<C> code.
532 =head2 New Diagnostics
534 XXX Newly added diagnostic messages go under here, separated into New Errors
543 XXX L<message|perldiag/"message">
553 L<Invalid \0 character in %s for %s: %s\0%s|perldiag/"Invalid \0 character in %s for %s: %s\0%s">
555 (W syscalls) Embedded \0 characters in pathnames or other system call arguments
556 produce a warning as of 5.20. The parts after the \0 were formerly ignored by
561 =head2 Changes to Existing Diagnostics
563 XXX Changes (i.e. rewording) of diagnostic messages go here
569 Warnings and errors from the regexp engine are now UTF-8 clean
573 The "Unknown switch condition" error message has some slight changes.
574 This error triggers when there is an unknown condition in a (?(foo))
575 conditional; The error message used to read:
577 Unknown switch condition (?(%s in regex;
579 But what %s could be was mostly up to luck; For (?(foobar)), you
580 might've seen "fo" or "f". For Unicode characters, you'd generally
581 get a corrupted string.
582 The message was changed to read:
584 Unknown switch condition (?(...)) in regex;
586 And additionally, the '<-- HERE' marker in the error will now point
587 to the correct spot in the regex.
591 =head1 Utility Changes
593 XXX Changes to installed programs such as F<perlbug> and F<xsubpp> go here.
594 Most of these are built within the directories F<utils> and F<x2p>.
596 [ List utility changes as a =head3 entry for each utility and =item
597 entries for each change
598 Use L<XXX> with program names to get proper documentation linking. ]
606 L<find2perl> now handles C<?> wildcards correctly. [perl #113054]
610 =head1 Configuration and Compilation
612 XXX Changes to F<Configure>, F<installperl>, F<installman>, and analogous tools
613 go here. Any other changes to the Perl build process should be listed here.
614 However, any platform-specific changes should be listed in the
615 L</Platform Support> section, instead.
617 [ List changes as a =item entry ].
623 The F<Makefile.PL> for C<SDBM_File> now generates a better F<Makefile>, which
624 avoids a race condition during parallel makes, which could cause the build to
625 fail. This is the last known parallel make problem (on *nix platforms), and
626 therefore we believe that a parallel make should now always be error free.
630 Strictly only for a build where build files such as F<Makefile.SH> have not
631 been updated by C<git> in an already configured and built tree.
637 XXX Any significant changes to the testing of a freshly built perl should be
638 listed here. Changes which create B<new> files in F<t/> go here as do any
639 large changes to the testing harness (e.g. when parallel testing was added).
640 Changes to existing files in F<t/> aren't worth summarizing, although the bugs
641 that they represent may be covered elsewhere.
643 [ List each test improvement as a =item entry ]
649 The test script F<t/bigmem/regexp.t> has been added to test that regular
650 expression matches on very large strings now succeed as expected.
654 Various cases of C<die>, C<last>, C<goto> and C<exit> triggering C<DESTROY> are
655 now tested by the new test script F<t/op/rt119311.t>.
659 The new test script F<t/win32/signal.t> tests that C<$!> and C<$^E> are now
660 preserved across signal handlers by the Win32 signal emulation code.
664 The test script F<t/x2p/find2perl.t> has been added to test the F<find2perl>
665 program on platforms where it is practical to do so.
669 =head1 Platform Support
671 XXX Any changes to platform support should be listed in the sections below.
673 [ Within the sections, list each platform as a =item entry with specific
674 changes as paragraphs below it. ]
678 XXX List any platforms that this version of perl compiles on, that previous
679 versions did not. These will either be enabled by new files in the F<hints/>
680 directories, or new subdirectories and F<README> files at the top level of the
687 Compile support has been added for Bitrig, a fork of OpenBSD.
691 =head2 Discontinued Platforms
693 XXX List any platforms that this version of perl no longer compiles on.
695 Configure hints and conditional code for several very old platforms
696 has been removed. We have not received reports for these in many years,
697 typically not since perl-5.6.0.
703 Configure support for the 3b1, also known as the AT&T Unix PC (and the
704 similar AT&T 7300), has been removed.
708 =head2 Platform-Specific Notes
710 XXX List any changes for specific platforms. This could include configuration
711 and compilation changes or changes in portability/compatibility. However,
712 changes within modules for platforms should generally be listed in the
713 L</Modules and Pragmata> section.
719 The building of XS modules has largely been restored. Several still cannot
720 (yet) be built but it is now possible to build Perl on WinCE with only a couple
721 of further patches (to L<Socket> and L<ExtUtils::MakeMaker>), hopefully to be
726 =head1 Internal Changes
728 XXX Changes which affect the interface available to C<XS> code go here. Other
729 significant internal changes for future core maintainers should be noted as
732 [ List each change as a =item entry ]
738 The internal representation has changed for the match variables C<$1>, C<$2>
739 I<etc.>, C<$`>, C<$&>, C<$'>, C<${^PREMATCH}>, C<${^MATCH}> and
740 C<${^POSTMATCH>. It uses slightly less memory, avoids string comparisons
741 and numeric conversions during lookup, and uses 23 fewer lines of C. This
742 change should not affect any external code.
746 Arrays now use NULL internally to represent unused slots, instead of
747 C<&PL_sv_undef>. C<&PL_sv_undef> is no longer treated as a special value,
748 so C<av_store(av, 0, &PL_sv_undef)> will cause element 0 of that array to
749 hold a read-only undefined scalar. C<$array[0] = anything> will croak and
750 C<\$array[0]> will compare equal to C<\undef>.
754 =head1 Selected Bug Fixes
756 XXX Important bug fixes in the core language are summarized here. Bug fixes in
757 files in F<ext/> and F<lib/> are best summarized in L</Modules and Pragmata>.
759 [ List each fix as a =item entry ]
765 The value of C<$^E> is now saved across signal handlers on Win32. [perl #85104]
769 A lexical filehandle (as in C<open my $fh...>) is usually given a name
770 based on the current package and the name of the variable; e.g.,
771 "main::$fh". Under recursion, the filehandle was losing the "$fh" part of
772 the name. This has been fixed.
776 Perl 5.19.3 accidentally extended the previous bug to all closures, even
777 when not called recursively; i.e., lexical handles in closure would always
778 be called "main::" or "MyPackage::" etc. This has been fixed.
782 Uninitialized values returned by XSUBs are no longer exempt from
783 uninitialized warnings. [perl #118693]
787 C<elsif ("")> no longer erroneous produces a warning about void context.
792 Passing C<undef> to a subroutine now causes @_ to contain the same read-only undefined scalar that C<undef> returns. Furthermore, C<exists $_[0]> will now return true if C<undef> was the first argument.
793 [perl #7508, #109726].
797 Passing a nonexistent array element to a subroutine does not usually
798 autovivify it unless the subroutine modifies its argument. This did not
799 work correctly with negative indices and with nonexistent elements within
800 the array. The element would be vivified immediately. The delayed
801 vivification has been extended to work with those. [perl #118691]
805 Assigning references or globs to the scalar returned by C<$#foo> after the
806 @foo array has been freed no longer causes assertion failures on debugging
807 builds and memory leaks on regular builds.
811 Perl 5.19.2 threw line numbers off after some cases of line breaks
812 following keywords, such as
817 This has been fixed. [perl #118931]
821 On 64-bit platforms, large ranges like 1..1000000000000 no longer crash,
822 but eat up all your memory instead. [perl #119161]
826 C<__DATA__> now puts the C<DATA> handle in the right package, even if the
827 current package has been renamed through glob assignment.
831 The string position set by C<pos> could shift if the string changed
832 representation internally to or from utf8. This could happen, e.g., with
833 references to objects with string overloading.
837 Taking references to the return values of two C<pos> calls with the same
838 argument, and then assigning a reference to one and C<undef> to the other,
839 could result in assertion failures or memory leaks.
843 Elements of C<@-> and C<@+> now update correctly when they refer to
844 nonexistent captures. Previously, a referenced element (C<$ref = \$-[1]>)
845 could refer to the wrong match after subsequent matches.
849 =head1 Known Problems
851 XXX Descriptions of platform agnostic bugs we know we can't fix go here. Any
852 tests that had to be C<TODO>ed for the release would be noted here. Unfixed
853 platform specific bugs also go here.
855 [ List each fix as a =item entry ]
867 XXX If any significant core contributor has died, we've added a short obituary
870 =head1 Acknowledgements
872 XXX Generate this with:
874 perl Porting/acknowledgements.pl v5.19.3..HEAD
876 =head1 Reporting Bugs
878 If you find what you think is a bug, you might check the articles recently
879 posted to the comp.lang.perl.misc newsgroup and the perl bug database at
880 http://rt.perl.org/perlbug/ . There may also be information at
881 http://www.perl.org/ , the Perl Home Page.
883 If you believe you have an unreported bug, please run the L<perlbug> program
884 included with your release. Be sure to trim your bug down to a tiny but
885 sufficient test case. Your bug report, along with the output of C<perl -V>,
886 will be sent off to perlbug@perl.org to be analysed by the Perl porting team.
888 If the bug you are reporting has security implications, which make it
889 inappropriate to send to a publicly archived mailing list, then please send it
890 to perl5-security-report@perl.org. This points to a closed subscription
891 unarchived mailing list, which includes all the core committers, who will be
892 able to help assess the impact of issues, figure out a resolution, and help
893 co-ordinate the release of patches to mitigate or fix the problem across all
894 platforms on which Perl is supported. Please only use this address for
895 security issues in the Perl core, not for modules independently distributed on
900 The F<Changes> file for an explanation of how to view exhaustive details on
903 The F<INSTALL> file for how to build Perl.
905 The F<README> file for general stuff.
907 The F<Artistic> and F<Copying> files for copyright information.