3 [ this is a template for a new perldelta file. Any text flagged as
4 XXX needs to be processed before release. ]
6 perldelta - what is new for perl v5.11.3
10 This document describes differences between the 5.11.2 release and
13 If you are upgrading from an earlier release such as 5.11.3, first read
14 the L<perl5XXXdelta>, which describes differences between 5.11.3 and
19 XXX Any important notices here
21 =head1 Incompatible Changes
25 =item Filehandles are blessed directly into C<IO::Handle::>, as C<FileHandle> is merely a wrapper around C<IO::Handle>.
29 =head1 Core Enhancements
31 XXX New core language features go here. Summarise user-visible core language
32 enhancements. Particularly prominent performance optimisations could go
33 here, but most should go in the L</Performance Enhancements> section.
35 =head2 Unicode version
37 Perl is shipped with the latest Unicode version, 5.2, October 2009. See
38 L<http://www.unicode.org/versions/Unicode5.2.0> for details about this release
41 But, an installation can now fairly easily change Perl to operate on any
42 Unicode release. Perl is shipped with the latest official release, but
43 an installation can download and install any prior release from Unicode, and
44 cause Perl to work with that (or even multiple releases). Instructions are in
47 =head2 Unicode properties
49 Perl can now handle every Unicode character property. A new pod,
50 L<perluniprops>, lists all available non-Unihan character properties. By
51 default the Unihan properties and certain others (deprecated and Unicode
52 internal-only ones) are not exposed. See below for more details on
53 these; there is also a section in the pod listing them, and why they are
56 Perl now fully supports the Unicode compound-style of using C<=> and C<:>
57 in writing regular expressions: C<\p{property=value}> and
58 C<\p{property:value}> (both of which mean the same thing).
60 Perl now supports fully the Unicode loose matching rules for text
61 between the braces in C<\p{...}> constructs. In addition, Perl also allows
62 underscores between digits of numbers.
64 All the Unicode-defined synonyms for properties and property values are
67 C<qr/\X/>, which matches a Unicode logical character, has been expanded to work
68 better with various Asian languages. It now is defined as an C<extended
69 grapheme cluster>. (See L<http://www.unicode.org/reports/tr29/>). One change
70 due to this is that C<\X> will match the whole sequence C<S<CR LF>>. Another
71 change is that C<\X> will match an isolated mark. Marks generally come after a
72 base character, but it is possible in Unicode to have them in isolation, and
73 C<\X> will now handle that case. Otherwise, this change should be transparent
74 for the non-affected languages.
76 C<\p{...}> matches using the Canonical_Combining_Class property were
77 completely broken in previous Perls. This is now fixed.
79 In previous Perls, the Unicode Decomposition_Type=Compat property and a
80 Perl extension had the same name, which led to neither matching all the
81 correct values (with more than 100 mistakes in one, and several thousand
82 in the other). The Perl extension has now been renamed to be
83 Decomposition_Type=Noncanonical (short: dt=noncanon). It has the same
84 meaning as was previously intended, namely the union of all the
85 non-canonical Decomposition types, with Unicode Compat being just one of
88 C<\p{Uppercase}> and C<\p{Lowercase}> have been brought into line with the
89 Unicode definitions. This means they each match a few more characters
92 C<\p{Cntrl}> now matches the same characters as C<\p{Control}>. This means it
93 no longer will match Private Use (gc=co), Surrogates (gc=cs), nor Format
94 (gc=cf) code points. The Format code points represent the biggest
95 possible problem. All but 36 of them are either officially deprecated
96 or strongly discouraged from being used. Of those 36, likely the most
97 widely used are the soft hyphen (U+00AD), and BOM, ZWSP, ZWNJ, WJ, and
98 similar, plus Bi-directional controls.
100 C<\p{Alpha}> now matches the same characters as C<\p{Alphabetic}>. The Perl
101 definition included a number of things that aren't really alpha (all
102 marks), while omitting many that were. The Unicode definition is
103 clearly better, so we are switching to it. As a direct consequence, the
104 definitions of C<\p{Alnum}> and C<\p{Word}> which depend on Alpha also change.
106 C<\p{Word}> also now doesn't match certain characters it wasn't supposed
107 to, such as fractions.
109 C<\p{Print}> no longer matches the line control characters: tab, lf, cr,
110 ff, vt, and nel. This brings it in line with the documentation.
112 \p{Decomposition_Type=Canonical} now includes the Hangul syllables
114 The Numeric type property has been extended to include the Unihan
117 There is a new Perl extension, the 'Present_In', or simply 'In'
118 property. This is an extension of the Unicode Age property, but
119 C<\p{In=5.0}> matches any code point whose usage has been determined as of
120 Unicode version 5.0. The C<\p{Age=5.0}> only matches code points added in 5.0.
122 A number of properties did not have the correct values for unassigned
123 code points. This is now fixed. The affected properties are
124 Bidi_Class, East_Asian_Width, Joining_Type, Decomposition_Type,
125 Hangul_Syllable_Type, Numeric_Type, and Line_Break.
127 The Default_Ignorable_Code_Point, ID_Continue, and ID_Start properties
128 have been updated to their current definitions.
130 Certain properties that are supposed to be Unicode internal-only were
131 erroneously exposed by previous Perls. Use of these in regular
132 expressions will now generate a deprecated warning message, if those
133 warnings are enabled. The properties are: Other_Alphabetic,
134 Other_Default_Ignorable_Code_Point, Other_Grapheme_Extend,
135 Other_ID_Continue, Other_ID_Start, Other_Lowercase, Other_Math, and
138 An installation can now fairly easily change which Unicode properties
139 Perl understands. As mentioned above, certain properties are by default
140 turned off. These include all the Unihan properties (which should be
141 accessible via the CPAN module Unicode::Unihan) and any deprecated or
142 Unicode internal-only property that Perl has never exposed.
144 The files in the To directory are now more clearly marked as being
145 stable, directly usable by applications. New hash entries in them give
146 the format of the normal entries which allows for easier machine
147 parsing. Perl can generate files in this directory for any property,
148 though most are suppressed. An installation can choose to change which
149 get written. Instructions are in L<perluniprops>.
153 XXX List any platforms that this version of perl compiles on, that previous
154 versions did not. These will either be enabled by new files in the F<hints/>
155 directories, or new subdirectories and F<README> files at the top level of the
158 =head1 Modules and Pragmata
160 XXX All changes to installed files in F<cpan/>, F<dist/>, F<ext/> and F<lib/>
161 go here, in a list ordered by distribution name. Minimally it should be the
162 module version, but it's more useful to the end user to give a paragraph's
163 summary of the module's changes. In an ideal world, dual-life modules would
164 have a F<Changes> file that could be cribbed.
166 =head2 New Modules and Pragmata
170 =item C<warnings::fatal_enabled>
172 Add code and starting perldoc for warnings::fatal_enabled.
174 This is an analog for warnings::enabled, except it tests whether the
175 given category has been set fatal using "use warnings FATAL => foo".
176 This is mostly for symmetry.
178 Assumes that the fatal bit for a category will have an offset one higher
179 than the regular bit for the category, because otherwise much rewriting
180 of __chk would be required.
186 =head2 Pragmata Changes
190 =item C<use feature "unicode_strings">
192 This pragma turns on Unicode semantics for the case-changing operations
193 (uc/lc/ucfirst/lcfirst) on strings that don't have the internal UTF-8
194 flag set, but that however contain higher characters (between 128 and
199 The experimental C<legacy> pragma, introduced in 5.11.2, has been removed,
200 and its functionality replaced by a new feature pragma, C<use feature
205 =head2 Updated Modules
211 Updated CPANPLUS to cpan release 0.90
212 Bring up ExtUtils::MakeMaker to 6.56 - no functional changes from 6.55_03
213 Upgrade to threads 1.75
215 Import CPAN.pm 1.94_53 from CPAN
217 Updated Module::Build to 0.35_15
219 Update Cwd / PathTools to 3.31 to get us a non-devel version number based on a chat with Steffen. No code changes.
221 Updated to Pod::Simple 3.11 from CPAN [perl #71004]
224 Update Archive::Extract to cpan version 0.36
229 File::Find was not resolving paths of the form "/..////../" correctly.
230 Fixed by adding a quantifier to the substitution parameter in
233 =item ExtUtils::MakeMaker
235 New BUILD_REQUIRES key to indicate build-only prerequisites.
239 Support new "package NAME VERSION" syntax.
243 =head1 Utility Changes
245 XXX Changes to installed programs such as F<perlbug> and F<xsubpp> go
246 here. Most of these are built within the directories F<utils> and F<x2p>.
254 Perlbug no longer reports "Message sent" when it hasn't actually sent the message
258 =head1 New Documentation
260 XXX Changes which create B<new> files in F<pod/> go here.
270 =head1 Changes to Existing Documentation
272 XXX Changes which significantly change existing files in F<pod/> go here.
273 Any changes to F<pod/perldiag.pod> should go in L</New or Changed Diagnostics>.
276 The Pod specification (L<perlpodspec>) has been updated to bring the
277 specification in line with modern usage already supported by most Pod systems.
278 A parameter string may now follow the format name in a "begin/end" region.
279 Links to URIs with a text description are now allowed. The usage of
280 C<LE<lt>"section"E<gt>> has been marked as deprecated.
282 L<if.pm|if> has been documented in L<perlfunc/use> as a means to get
283 conditional loading of modules despite the implicit BEGIN block around C<use>.
287 =head1 Performance Enhancements
289 XXX Changes which enhance performance without changing behaviour go here. There
290 may well be none in a stable release.
300 =head1 Installation and Configuration Improvements
302 XXX Changes to F<Configure>, F<installperl>, F<installman>, and analogous tools
305 =head2 Configuration improvements
309 =head2 Compilation improvements
311 Make distclean work again
314 =head2 Testing improvements
318 =item It's now possible to override C<PERL5OPT> and friends in F<t/TEST>
322 =head2 Platform Specific Changes
332 Always add a manifest resource to C<perl.exe> to specify the <trustInfo>
333 settings for Windows Vista and later. Without this setting Windows
334 will treat C<perl.exe> as a legacy application and apply various
335 heuristics like redirecting access to protected file system areas
336 (like the "Program Files" folder) to the users "VirtualStore"
337 instead of generating a proper "permission denied" error.
339 For VC8 and VC9 this manifest setting is automatically generated by
340 the compiler/linker (together with the binding information for their
341 respective runtime libraries); for all other compilers we need to
342 embed the manifest resource explicitly in the external resource file.
344 This change also requests the Microsoft Common-Controls version 6.0
345 (themed controls introduced in Windows XP) via the dependency list
346 in the assembly manifest. For VC8 and VC9 this is specified using the
347 C</manifestdependency> linker commandline option instead.
355 =item Enable IPv6 support on cygwin 1.7 and newer
363 =item Make -UDEBUGGING the default on VMS for 5.12.0.
365 Like it has been everywhere else for ages and ages. Also make
366 command-line selection of -UDEBUGGING and -DDEBUGGING work in
367 configure.com; before the only way to turn it off was by saying
368 no in answer to the interactive question.
374 =head1 Selected Bug Fixes
376 XXX Important bug fixes in the core language are summarised here.
377 Bug fixes in files in F<ext/> and F<lib/> are best summarised in
378 L</Modules and Pragmata>.
384 Ensure that pp_qr returns a new regexp SV each time. Resolves RT #69852.
386 Instead of returning a(nother) reference to the (pre-compiled) regexp in the
387 optree, use reg_temp_copy() to create a copy of it, and return a reference to
388 that. This resolves issues about Regexp::DESTROY not being called in a timely
389 fashion (the original bug tracked by RT #69852), as well as bugs related to
390 blessing regexps, and of assigning to regexps, as described in correspondence
393 It transpires that we also need to undo the SvPVX() sharing when ithreads
394 cloning a Regexp SV, because mother_re is set to NULL, instead of a cloned
395 copy of the mother_re. This change might fix bugs with regexps and threads in
396 certain other situations, but as yet neither tests nor bug reports have
397 indicated any problems, so it might not actually be an edge case that it's
402 Several compilation errors and segfaults when perl was built with C<-Dmad> were fixed.
406 Fixes for lexer API changes in 5.11.2 which broke NYTProf's savesrc option.
410 =head1 New or Changed Diagnostics
412 XXX New or changed warnings emitted by the core's C<C> code go here.
418 Make split warn in void context
423 =head1 Changed Internals
425 XXX Changes which affect the interface available to C<XS> code go here.
437 XXX Changes which create B<new> files in F<t/> go here. Changes to
438 existing files in F<t/> aren't worth summarising, although the bugs that
439 they represent may be.
449 =head1 Known Problems
451 XXX Descriptions of platform agnostic bugs we know we can't fix go here. Any
452 tests that had to be C<TODO>ed for the release would be noted here, unless
453 they were specific to a particular platform (see below).
455 This is a list of some significant unfixed bugs, which are regressions
456 from either 5.11.3 or 5.11.3.
468 XXX Add any new known deprecations here.
470 The following items are now deprecated.
474 =item Use of "goto" to jump into a construct is deprecated
476 Using C<goto> to jump from an outer scope into an inner
477 scope is now deprecated. This rare use case was causing
478 problems in the implementation of scopes.
482 =head1 Platform Specific Notes
484 XXX Any changes specific to a particular platform. VMS and Win32 are the usual
485 stars here. It's probably best to group changes under the same section layout
486 as the main perldelta
490 XXX If any significant core contributor has died, we've added a short obituary
493 =head1 Acknowledgements
495 XXX The list of people to thank goes here.
498 =head1 Reporting Bugs
500 If you find what you think is a bug, you might check the articles
501 recently posted to the comp.lang.perl.misc newsgroup and the perl
502 bug database at http://rt.perl.org/perlbug/ . There may also be
503 information at http://www.perl.org/ , the Perl Home Page.
505 If you believe you have an unreported bug, please run the B<perlbug>
506 program included with your release. Be sure to trim your bug down
507 to a tiny but sufficient test case. Your bug report, along with the
508 output of C<perl -V>, will be sent off to perlbug@perl.org to be
509 analysed by the Perl porting team.
511 If the bug you are reporting has security implications, which make it
512 inappropriate to send to a publicly archived mailing list, then please send
513 it to perl5-security-report@perl.org. This points to a closed subscription
514 unarchived mailing list, which includes all the core committers, who be able
515 to help assess the impact of issues, figure out a resolution, and help
516 co-ordinate the release of patches to mitigate or fix the problem across all
517 platforms on which Perl is supported. Please only use this address for
518 security issues in the Perl core, not for modules independently
523 The F<Changes> file for an explanation of how to view exhaustive details
526 The F<INSTALL> file for how to build Perl.
528 The F<README> file for general stuff.
530 The F<Artistic> and F<Copying> files for copyright information.
537 All changes through commit b4178430270dbe109e7609d0b50d6d54bf9e95d8
538 One "triage" pass done.
540 A second triage pass is still needed to remove unimportant changes
542 commit 9307c420fad2f6f5bd314f9ed66dd53288703e09
543 Author: Jan Dubois <jand@activestate.com>
544 Date: Thu Dec 17 18:28:16 2009 -0800
546 Export PL_curinterp symbol for MULTIPLICITY without USE_ITHREADS
548 This is necessary for XS extensions that define PERL_CORE. In that
549 situation PERL_GET_CONTEXT will resolve to PL_curinterp, which is
550 normally not exported (extensions call Perl_Gcurinterp_ptr() to get a
551 pointer to PL_curinterp instead). With USE_ITHREADS defined
552 PERL_GET_CONTEXT will expand to Perl_get_context() even inside the
553 core because the context needs to be fetched from threadlocal storage.
555 commit 8703a9a4fd75723318bc4ba1afc42a215806f2d1
557 Correct some #ifdef USE_ITHREADS / USE_MULTI
559 Author: Jan Dubois <jand@activestate.com>
560 Date: Wed Dec 16 15:42:19 2009 -0800
562 -t should only return TRUE for file handles connected to a TTY
564 The Microsoft C version of isatty() returns TRUE for all
565 character mode devices, including the /dev/null style "nul"
566 device and printers like "lpt1".
568 The included test has only been tested on Windows and Linux;
569 the device names for OS/2 and VMS are just best guesses...
571 commit 0f907b96d618c97cd2e020841a70ae037954a616
573 [perl #70171] 5.10.0 -> 5.10.1 Regression in fafafbaf70 (Big slowdown in 5.10 @_ parameter passing)
575 commit 2ab54efd6265713df5cd4bd0927024245675c1c2
577 fix bug 67156: overload: nomethod(..., '!') return value inverted
579 commit 412147f664b7f5805591ad996d7e5a9e70b3d80f
581 [perl #71204] diagnostics.pm suppresses 'Use of uninitialized value in range (or flip)' warning
584 commit 69dc4b30f4725ad5f212d45d3c856ac1caaacf17
585 Author: Father Chrysostomos <sprout@cpan.org>
586 Date: Mon Dec 14 12:19:35 2009 +0100
588 [perl #70764] $' fails to initialized for pre-compiled regular expression matches
590 The match vars are associated with the regexp that last matched
591 successfully. In the case of $str =~ $qr or /$qr/, since the $qr could
592 be used in multiple scopes that need their own sets of match vars, the
593 $qr is cloned by Perl_reg_temp_copy as of change 30677/28d8d7f. This
594 happens in pp_regcomp before pp_match has stringified the LHS, hence the
595 bug. In short, /$gror/ is not equivalent to
596 ($which = !$which) ? /$gror/ : /$gror/, which is weird.
598 Author: Reini Urban <rurban@x-ray.at>
599 Date: Sun Dec 13 08:06:43 2009 +0100
601 Eliminate OP_SETSTATE from cop.h header
603 It had been added with change 3728 to track linenumbers in
604 optimized else, disabled by change 4309,
605 and removed with change 33072.
607 Bump copyright, latest change was "Fix MULTICALL in List-Util" 2009-03-07
611 Fix for [perl #70910] wrong line number in syntax error message
613 Document config_args limitations reported in [perl #70912]
615 proper error on "grep $x (1,2,3)". Solves [perl #37314]
617 commit 8a27a13e89107aaf68c0748b68ee71fbd86d774b
619 [perl #71076] sort with active sub (5.10 regression)
621 One of the tests in sort.t causes a bus error (or sometimes â
\80\98Undefined
622 subroutine calledâ
\80\99) if run multiple times. This is because sort
623 decreases the refcount of an active sub used as a comparison routine.
625 commit 69c3dccf5322a59cb855347c04712ba11b65328f
627 Fix [perl #71078] Smart match against @_ gives false negatives
629 @_ can contain NULLs for undefined elements
631 [perl #71000] Wrong variable name in warning ; Add a new warning "Missing argument in %s"
634 preserve readonly flag when saving and restoring magic flags
636 commit c9930541bfa04399c3b648e83c9b750cee1154fb
638 [perl #70802] -i'*' refuses to work
640 commit adab996997d7ef1b54d382f5ab4304f438cd1dd0
642 Cleanup all scopes before exiting a pseudo-forked process.
644 perl_destruct() contains an assertion that the scope stack
645 is empty. The remaining scopes are due to fork() being
646 called from within a BEGIN block.
648 commit 576b33a19ccaf98d4dfe201d529c55c3747f0cb6
650 [rt.cpan.org #51574] Safe.pm sort {} bug accessing $a and $b with -Dusethreads
652 commit ee6ba15dedda3e88eb66891eaf387c00a4c0a2fb
654 Fix -DPERL_NO_UTF16_FILTER
656 commit dfd167e94af611f6248e804cb228b35ca4123bd6
658 Handle $@ being assigned a read-only value (without error or busting the stack).
660 Discovered whilst investigating RT #70862.
662 commit f5fa9033b8c1fdcbd7710850b3b0380d6b937853
664 Fix RT #70862 by converting ERRSV to GvSVn() to ensure a non-NULL GvSV().
666 commit ff868e665bf85a829dc47bfa1243b26d4367cacd
668 Add error codes for getaddrinfo() and getnameinfo()
670 commit 61fc5122f0d8a509834282b8ecb3252d2e4c9f5d
672 Make unicode semantics the default
676 commit 021f53de09926928546378b3552f9240c9241dde
677 Author: Gerard Goossen <gerard@ggoossen.net>
678 Date: Mon Nov 16 13:58:24 2009 +0100
680 Force OP_REQUIRE to scalar context at the end of ck_require and don't let it become void context. Fixes problem with require not always being in scalar context.
682 commit 6a0e50422a84b53e998825128c56791913cd03aa
683 Author: Craig A. Berry <craigberry@mac.com>
684 Date: Sat Nov 21 11:17:38 2009 -0600