1PERL5120DELTA(1)       Perl Programmers Reference Guide       PERL5120DELTA(1)
2
3
4

NAME

6       perl5120delta - what is new for perl v5.12.0
7

DESCRIPTION

9       This document describes differences between the 5.10.0 release and the
10       5.12.0 release.
11
12       Many of the bug fixes in 5.12.0 are already included in the 5.10.1
13       maintenance release.
14
15       You can see the list of those changes in the 5.10.1 release notes
16       (perl5101delta).
17

Core Enhancements

19   New "package NAME VERSION" syntax
20       This new syntax allows a module author to set the $VERSION of a
21       namespace when the namespace is declared with 'package'. It eliminates
22       the need for "our $VERSION = ..." and similar constructs. E.g.
23
24             package Foo::Bar 1.23;
25             # $Foo::Bar::VERSION == 1.23
26
27       There are several advantages to this:
28
29       ·   $VERSION is parsed in exactly the same way as "use NAME VERSION"
30
31       ·   $VERSION is set at compile time
32
33       ·   $VERSION is a version object that provides proper overloading of
34           comparison operators so comparing $VERSION to decimal (1.23) or
35           dotted-decimal (v1.2.3) version numbers works correctly.
36
37       ·   Eliminates "$VERSION = ..." and "eval $VERSION" clutter
38
39       ·   As it requires VERSION to be a numeric literal or v-string literal,
40           it can be statically parsed by toolchain modules without "eval" the
41           way MM->parse_version does for "$VERSION = ..."
42
43       It does not break old code with only "package NAME", but code that uses
44       "package NAME VERSION" will need to be restricted to perl 5.12.0 or
45       newer This is analogous to the change to "open" from two-args to three-
46       args.  Users requiring the latest Perl will benefit, and perhaps after
47       several years, it will become a standard practice.
48
49       However, "package NAME VERSION" requires a new, 'strict' version number
50       format. See "Version number formats" for details.
51
52   The "..." operator
53       A new operator, "...", nicknamed the Yada Yada operator, has been
54       added.  It is intended to mark placeholder code that is not yet
55       implemented.  See "Yada Yada Operator" in perlop.
56
57   Implicit strictures
58       Using the "use VERSION" syntax with a version number greater or equal
59       to 5.11.0 will lexically enable strictures just like "use strict" would
60       do (in addition to enabling features.) The following:
61
62           use 5.12.0;
63
64       means:
65
66           use strict;
67           use feature ':5.12';
68
69   Unicode improvements
70       Perl 5.12 comes with Unicode 5.2, the latest version available to us at
71       the time of release.  This version of Unicode was released in October
72       2009. See <http://www.unicode.org/versions/Unicode5.2.0> for further
73       details about what's changed in this version of the standard.  See
74       perlunicode for instructions on installing and using other versions of
75       Unicode.
76
77       Additionally, Perl's developers have significantly improved Perl's
78       Unicode implementation. For full details, see "Unicode overhaul" below.
79
80   Y2038 compliance
81       Perl's core time-related functions are now Y2038 compliant. (It may not
82       mean much to you, but your kids will love it!)
83
84   qr overloading
85       It is now possible to overload the "qr//" operator, that is, conversion
86       to regexp, like it was already possible to overload conversion to
87       boolean, string or number of objects. It is invoked when an object
88       appears on the right hand side of the "=~" operator or when it is
89       interpolated into a regexp. See overload.
90
91   Pluggable keywords
92       Extension modules can now cleanly hook into the Perl parser to define
93       new kinds of keyword-headed expression and compound statement. The
94       syntax following the keyword is defined entirely by the extension. This
95       allow a completely non-Perl sublanguage to be parsed inline, with the
96       correct ops cleanly generated.
97
98       See "PL_keyword_plugin" in perlapi for the mechanism. The Perl core
99       source distribution also includes a new module XS::APItest::KeywordRPN,
100       which implements reverse Polish notation arithmetic via pluggable
101       keywords. This module is mainly used for test purposes, and is not
102       normally installed, but also serves as an example of how to use the new
103       mechanism.
104
105       Perl's developers consider this feature to be experimental. We may
106       remove it or change it in a backwards-incompatible way in Perl 5.14.
107
108   APIs for more internals
109       The lowest layers of the lexer and parts of the pad system now have C
110       APIs available to XS extensions. These are necessary to support proper
111       use of pluggable keywords, but have other uses too. The new APIs are
112       experimental, and only cover a small proportion of what would be
113       necessary to take full advantage of the core's facilities in these
114       areas. It is intended that the Perl 5.13 development cycle will see the
115       addition of a full range of clean, supported interfaces.
116
117       Perl's developers consider this feature to be experimental. We may
118       remove it or change it in a backwards-incompatible way in Perl 5.14.
119
120   Overridable function lookup
121       Where an extension module hooks the creation of rv2cv ops to modify the
122       subroutine lookup process, this now works correctly for bareword
123       subroutine calls. This means that prototypes on subroutines referenced
124       this way will be processed correctly. (Previously bareword subroutine
125       names were initially looked up, for parsing purposes, by an unhookable
126       mechanism, so extensions could only properly influence subroutine names
127       that appeared with an "&" sigil.)
128
129   A proper interface for pluggable Method Resolution Orders
130       As of Perl 5.12.0 there is a new interface for plugging and using
131       method resolution orders other than the default linear depth first
132       search.  The C3 method resolution order added in 5.10.0 has been re-
133       implemented as a plugin, without changing its Perl-space interface. See
134       perlmroapi for more information.
135
136   "\N" experimental regex escape
137       Perl now supports "\N", a new regex escape which you can think of as
138       the inverse of "\n". It will match any character that is not a newline,
139       independently from the presence or absence of the single line match
140       modifier "/s". It is not usable within a character class.  "\N{3}"
141       means to match 3 non-newlines; "\N{5,}" means to match at least 5.
142       "\N{NAME}" still means the character or sequence named "NAME", but
143       "NAME" no longer can be things like 3, or "5,".
144
145       This will break a custom charnames translator which allows numbers for
146       character names, as "\N{3}" will now mean to match 3 non-newline
147       characters, and not the character whose name is 3. (No name defined by
148       the Unicode standard is a number, so only custom translators might be
149       affected.)
150
151       Perl's developers are somewhat concerned about possible user confusion
152       with the existing "\N{...}" construct which matches characters by their
153       Unicode name. Consequently, this feature is experimental. We may remove
154       it or change it in a backwards-incompatible way in Perl 5.14.
155
156   DTrace support
157       Perl now has some support for DTrace. See "DTrace support" in INSTALL.
158
159   Support for "configure_requires" in CPAN module metadata
160       Both "CPAN" and "CPANPLUS" now support the "configure_requires" keyword
161       in the META.yml metadata file included in most recent CPAN
162       distributions.  This allows distribution authors to specify
163       configuration prerequisites that must be installed before running
164       Makefile.PL or Build.PL.
165
166       See the documentation for "ExtUtils::MakeMaker" or "Module::Build" for
167       more on how to specify "configure_requires" when creating a
168       distribution for CPAN.
169
170   "each", "keys", "values" are now more flexible
171       The "each", "keys", "values" function can now operate on arrays.
172
173   "when" as a statement modifier
174       "when" is now allowed to be used as a statement modifier.
175
176   $, flexibility
177       The variable $, may now be tied.
178
179   // in when clauses
180       // now behaves like || in when clauses
181
182   Enabling warnings from your shell environment
183       You can now set "-W" from the "PERL5OPT" environment variable
184
185   "delete local"
186       "delete local" now allows you to locally delete a hash entry.
187
188   New support for Abstract namespace sockets
189       Abstract namespace sockets are Linux-specific socket type that live in
190       AF_UNIX family, slightly abusing it to be able to use arbitrary
191       character arrays as addresses: They start with nul byte and are not
192       terminated by nul byte, but with the length passed to the socket()
193       system call.
194
195   32-bit limit on substr arguments removed
196       The 32-bit limit on "substr" arguments has now been removed. The full
197       range of the system's signed and unsigned integers is now available for
198       the "pos" and "len" arguments.
199

Potentially Incompatible Changes

201   Deprecations warn by default
202       Over the years, Perl's developers have deprecated a number of language
203       features for a variety of reasons.  Perl now defaults to issuing a
204       warning if a deprecated language feature is used. Many of the
205       deprecations Perl now warns you about have been deprecated for many
206       years.  You can find a list of what was deprecated in a given release
207       of Perl in the "perl5xxdelta.pod" file for that release.
208
209       To disable this feature in a given lexical scope, you should use "no
210       warnings 'deprecated';" For information about which language features
211       are deprecated and explanations of various deprecation warnings, please
212       see perldiag. See "Deprecations" below for the list of features and
213       modules Perl's developers have deprecated as part of this release.
214
215   Version number formats
216       Acceptable version number formats have been formalized into "strict"
217       and "lax" rules. "package NAME VERSION" takes a strict version number.
218       "UNIVERSAL::VERSION" and the version object constructors take lax
219       version numbers. Providing an invalid version will result in a fatal
220       error. The version argument in "use NAME VERSION" is first parsed as a
221       numeric literal or v-string and then passed to "UNIVERSAL::VERSION"
222       (and must then pass the "lax" format test).
223
224       These formats are documented fully in the version module. To a first
225       approximation, a "strict" version number is a positive decimal number
226       (integer or decimal-fraction) without exponentiation or else a dotted-
227       decimal v-string with a leading 'v' character and at least three
228       components. A "lax" version number allows v-strings with fewer than
229       three components or without a leading 'v'. Under "lax" rules, both
230       decimal and dotted-decimal versions may have a trailing "alpha"
231       component separated by an underscore character after a fractional or
232       dotted-decimal component.
233
234       The version module adds "version::is_strict" and "version::is_lax"
235       functions to check a scalar against these rules.
236
237   @INC reorganization
238       In @INC, "ARCHLIB" and "PRIVLIB" now occur after after the current
239       version's "site_perl" and "vendor_perl".  Modules installed into
240       "site_perl" and "vendor_perl" will now be loaded in preference to those
241       installed in "ARCHLIB" and "PRIVLIB".
242
243   REGEXPs are now first class
244       Internally, Perl now treates compiled regular expressions (such as
245       those created with "qr//") as first class entities. Perl modules which
246       serialize, deserialize or otherwise have deep interaction with Perl's
247       internal data structures need to be updated for this change.  Most
248       affected CPAN modules have already been updated as of this writing.
249
250   Switch statement changes
251       The "given"/"when" switch statement handles complex statements better
252       than Perl 5.10.0 did (These enhancements are also available in 5.10.1
253       and subsequent 5.10 releases.) There are two new cases where "when" now
254       interprets its argument as a boolean, instead of an expression to be
255       used in a smart match:
256
257       flip-flop operators
258           The ".." and "..." flip-flop operators are now evaluated in boolean
259           context, following their usual semantics; see "Range Operators" in
260           perlop.
261
262           Note that, as in perl 5.10.0, "when (1..10)" will not work to test
263           whether a given value is an integer between 1 and 10; you should
264           use "when ([1..10])" instead (note the array reference).
265
266           However, contrary to 5.10.0, evaluating the flip-flop operators in
267           boolean context ensures it can now be useful in a "when()", notably
268           for implementing bistable conditions, like in:
269
270               when (/^=begin/ .. /^=end/) {
271                 # do something
272               }
273
274       defined-or operator
275           A compound expression involving the defined-or operator, as in
276           "when (expr1 // expr2)", will be treated as boolean if the first
277           expression is boolean. (This just extends the existing rule that
278           applies to the regular or operator, as in "when (expr1 || expr2)".)
279
280   Smart match changes
281       Since Perl 5.10.0, Perl's developers have made a number of changes to
282       the smart match operator. These, of course, also alter the behaviour of
283       the switch statements where smart matching is implicitly used.  These
284       changes were also made for the 5.10.1 release, and will remain in
285       subsequent 5.10 releases.
286
287       Changes to type-based dispatch
288
289       The smart match operator "~~" is no longer commutative. The behaviour
290       of a smart match now depends primarily on the type of its right hand
291       argument. Moreover, its semantics have been adjusted for greater
292       consistency or usefulness in several cases. While the general backwards
293       compatibility is maintained, several changes must be noted:
294
295       ·   Code references with an empty prototype are no longer treated
296           specially.  They are passed an argument like the other code
297           references (even if they choose to ignore it).
298
299       ·   "%hash ~~ sub {}" and "@array ~~ sub {}" now test that the
300           subroutine returns a true value for each key of the hash (or
301           element of the array), instead of passing the whole hash or array
302           as a reference to the subroutine.
303
304       ·   Due to the commutativity breakage, code references are no longer
305           treated specially when appearing on the left of the "~~" operator,
306           but like any vulgar scalar.
307
308       ·   "undef ~~ %hash" is always false (since "undef" can't be a key in a
309           hash). No implicit conversion to "" is done (as was the case in
310           perl 5.10.0).
311
312       ·   "$scalar ~~ @array" now always distributes the smart match across
313           the elements of the array. It's true if one element in @array
314           verifies "$scalar ~~ $element". This is a generalization of the old
315           behaviour that tested whether the array contained the scalar.
316
317       The full dispatch table for the smart match operator is given in "Smart
318       matching in detail" in perlsyn.
319
320       Smart match and overloading
321
322       According to the rule of dispatch based on the rightmost argument type,
323       when an object overloading "~~" appears on the right side of the
324       operator, the overload routine will always be called (with a 3rd
325       argument set to a true value, see overload.) However, when the object
326       will appear on the left, the overload routine will be called only when
327       the rightmost argument is a simple scalar. This way, distributivity of
328       smart match across arrays is not broken, as well as the other
329       behaviours with complex types (coderefs, hashes, regexes). Thus,
330       writers of overloading routines for smart match mostly need to worry
331       only with comparing against a scalar, and possibly with stringification
332       overloading; the other common cases will be automatically handled
333       consistently.
334
335       "~~" will now refuse to work on objects that do not overload it (in
336       order to avoid relying on the object's underlying structure). (However,
337       if the object overloads the stringification or the numification
338       operators, and if overload fallback is active, it will be used instead,
339       as usual.)
340
341   Other potentially incompatible changes
342       ·   The definitions of a number of Unicode properties have changed to
343           match those of the current Unicode standard. These are listed above
344           under "Unicode overhaul". This change may break code that expects
345           the old definitions.
346
347       ·   The boolkeys op has moved to the group of hash ops. This breaks
348           binary compatibility.
349
350       ·   Filehandles are now always blessed into "IO::File".
351
352           The previous behaviour was to bless Filehandles into FileHandle (an
353           empty proxy class) if it was loaded into memory and otherwise to
354           bless them into "IO::Handle".
355
356       ·   The semantics of "use feature :5.10*" have changed slightly.  See
357           "Modules and Pragmata" for more information.
358
359       ·   Perl's developers now use git, rather than Perforce.  This should
360           be a purely internal change only relevant to people actively
361           working on the core.  However, you may see minor difference in perl
362           as a consequence of the change.  For example in some of details of
363           the output of "perl -V". See perlrepository for more information.
364
365       ·   As part of the "Test::Harness" 2.x to 3.x upgrade, the experimental
366           "Test::Harness::Straps" module has been removed.  See "Modules and
367           Pragmata" for more details.
368
369       ·   As part of the "ExtUtils::MakeMaker" upgrade, the
370           "ExtUtils::MakeMaker::bytes" and "ExtUtils::MakeMaker::vmsish"
371           modules have been removed from this distribution.
372
373       ·   "Module::CoreList" no longer contains the %:patchlevel hash.
374
375       ·   "length undef" now returns undef.
376
377       ·   Unsupported private C API functions are now declared "static" to
378           prevent leakage to Perl's public API.
379
380       ·   To support the bootstrapping process, miniperl no longer builds
381           with UTF-8 support in the regexp engine.
382
383           This allows a build to complete with PERL_UNICODE set and a UTF-8
384           locale.  Without this there's a bootstrapping problem, as miniperl
385           can't load the UTF-8 components of the regexp engine, because
386           they're not yet built.
387
388       ·   miniperl's @INC is now restricted to just "-I...", the split of
389           $ENV{PERL5LIB}, and "".""
390
391       ·   A space or a newline is now required after a "#line XXX" directive.
392
393       ·   Tied filehandles now have an additional method EOF which provides
394           the EOF type.
395
396       ·   To better match all other flow control statements, "foreach" may no
397           longer be used as an attribute.
398
399       ·   Perl's command-line switch "-P", which was deprecated in version
400           5.10.0, has now been removed.
401

Deprecations

403       From time to time, Perl's developers find it necessary to deprecate
404       features or modules we've previously shipped as part of the core
405       distribution. We are well aware of the pain and frustration that a
406       backwards-incompatible change to Perl can cause for developers building
407       or maintaining software in Perl. You can be sure that when we deprecate
408       a functionality or syntax, it isn't a choice we make lightly.
409       Sometimes, we choose to deprecate functionality or syntax because it
410       was found to be poorly designed or implemented. Sometimes, this is
411       because they're holding back other features or causing performance
412       problems. Sometimes, the reasons are more complex. Wherever possible,
413       we try to keep deprecated functionality available to developers in its
414       previous form for at least one major release. So long as a deprecated
415       feature isn't actively disrupting our ability to maintain and extend
416       Perl, we'll try to leave it in place as long as possible.
417
418       The following items are now deprecated:
419
420       suidperl
421           "suidperl" is no longer part of Perl. It used to provide a
422           mechanism to emulate setuid permission bits on systems that don't
423           support it properly.
424
425       Use of ":=" to mean an empty attribute list
426           An accident of Perl's parser meant that these constructions were
427           all equivalent:
428
429               my $pi := 4;
430               my $pi : = 4;
431               my $pi :  = 4;
432
433           with the ":" being treated as the start of an attribute list, which
434           ends before the "=". As whitespace is not significant here, all are
435           parsed as an empty attribute list, hence all the above are
436           equivalent to, and better written as
437
438               my $pi = 4;
439
440           because no attribute processing is done for an empty list.
441
442           As is, this meant that ":=" cannot be used as a new token, without
443           silently changing the meaning of existing code. Hence that
444           particular form is now deprecated, and will become a syntax error.
445           If it is absolutely necessary to have empty attribute lists (for
446           example, because of a code generator) then avoid the warning by
447           adding a space before the "=".
448
449       "UNIVERSAL->import()"
450           The method "UNIVERSAL->import()" is now deprecated. Attempting to
451           pass import arguments to a "use UNIVERSAL" statement will result in
452           a deprecation warning.
453
454       Use of "goto" to jump into a construct
455           Using "goto" to jump from an outer scope into an inner scope is now
456           deprecated. This rare use case was causing problems in the
457           implementation of scopes.
458
459       Custom character names in \N{name} that don't look like names
460           In "\N{name}", name can be just about anything. The standard
461           Unicode names have a very limited domain, but a custom name
462           translator could create names that are, for example, made up
463           entirely of punctuation symbols. It is now deprecated to make names
464           that don't begin with an alphabetic character, and aren't
465           alphanumeric or contain other than a very few other characters,
466           namely spaces, dashes, parentheses and colons. Because of the added
467           meaning of "\N" (See ""\N" experimental regex escape"), names that
468           look like curly brace -enclosed quantifiers won't work. For
469           example, "\N{3,4}" now means to match 3 to 4 non-newlines; before a
470           custom name "3,4" could have been created.
471
472       Deprecated Modules
473           The following modules will be removed from the core distribution in
474           a future release, and should be installed from CPAN instead.
475           Distributions on CPAN which require these should add them to their
476           prerequisites. The core versions of these modules warnings will
477           issue a deprecation warning.
478
479           If you ship a packaged version of Perl, either alone or as part of
480           a larger system, then you should carefully consider the
481           reprecussions of core module deprecations. You may want to consider
482           shipping your default build of Perl with packages for some or all
483           deprecated modules which install into "vendor" or "site" perl
484           library directories. This will inhibit the deprecation warnings.
485
486           Alternatively, you may want to consider patching lib/deprecate.pm
487           to provide deprecation warnings specific to your packaging system
488           or distribution of Perl, consistent with how your packaging system
489           or distribution manages a staged transition from a release where
490           the installation of a single package provides the given
491           functionality, to a later release where the system administrator
492           needs to know to install multiple packages to get that same
493           functionality.
494
495           You can silence these deprecation warnings by installing the
496           modules in question from CPAN.  To install the latest version of
497           all of them, just install "Task::Deprecations::5_12".
498
499           Class::ISA
500           Pod::Plainer
501           Shell
502           Switch
503               Switch is buggy and should be avoided. You may find Perl's new
504               "given"/"when" feature a suitable replacement.  See "Switch
505               statements" in perlsyn for more information.
506
507       Assignment to $[
508       Use of the attribute :locked on subroutines
509       Use of "locked" with the attributes pragma
510       Use of "unique" with the attributes pragma
511       Perl_pmflag
512           "Perl_pmflag" is no longer part of Perl's public API. Calling it
513           now generates a deprecation warning, and it will be removed in a
514           future release. Although listed as part of the API, it was never
515           documented, and only ever used in toke.c, and prior to 5.10,
516           regcomp.c. In core, it has been replaced by a static function.
517
518       Numerous Perl 4-era libraries
519           termcap.pl, tainted.pl, stat.pl, shellwords.pl, pwd.pl, open3.pl,
520           open2.pl, newgetopt.pl, look.pl, find.pl, finddepth.pl,
521           importenv.pl, hostname.pl, getopts.pl, getopt.pl, getcwd.pl,
522           flush.pl, fastcwd.pl, exceptions.pl, ctime.pl, complete.pl,
523           cacheout.pl, bigrat.pl, bigint.pl, bigfloat.pl, assert.pl,
524           abbrev.pl, dotsh.pl, and timelocal.pl are all now deprecated.
525           Earlier, Perl's developers intended to remove these libraries from
526           Perl's core for the 5.14.0 release.
527
528           During final testing before the release of 5.12.0, several
529           developers discovered current production code using these ancient
530           libraries, some inside the Perl core itself.  Accordingly, the
531           pumpking granted them a stay of execution. They will begin to warn
532           about their deprecation in the 5.14.0 release and will be removed
533           in the 5.16.0 release.
534

Unicode overhaul

536       Perl's developers have made a concerted effort to update Perl to be in
537       sync with the latest Unicode standard. Changes for this include:
538
539       Perl can now handle every Unicode character property. New
540       documentation, perluniprops, lists all available non-Unihan character
541       properties. By default, perl does not expose Unihan, deprecated or
542       Unicode-internal properties.  See below for more details on these;
543       there is also a section in the pod listing them, and explaining why
544       they are not exposed.
545
546       Perl now fully supports the Unicode compound-style of using "=" and ":"
547       in writing regular expressions: "\p{property=value}" and
548       "\p{property:value}" (both of which mean the same thing).
549
550       Perl now fully supports the Unicode loose matching rules for text
551       between the braces in "\p{...}" constructs. In addition, Perl allows
552       underscores between digits of numbers.
553
554       Perl now accepts all the Unicode-defined synonyms for properties and
555       property values.
556
557       "qr/\X/", which matches a Unicode logical character, has been expanded
558       to work better with various Asian languages. It now is defined as an
559       extended grapheme cluster. (See
560       <http://www.unicode.org/reports/tr29/>).  Anything matched previously
561       and that made sense will continue to be accepted.   Additionally:
562
563       ·   "\X" will not break apart a "CR LF" sequence.
564
565       ·   "\X" will now match a sequence which includes the "ZWJ" and "ZWNJ"
566           characters.
567
568       ·   "\X" will now always match at least one character, including an
569           initial mark.  Marks generally come after a base character, but it
570           is possible in Unicode to have them in isolation, and "\X" will now
571           handle that case, for example at the beginning of a line, or after
572           a "ZWSP". And this is the part where "\X" doesn't match the things
573           that it used to that don't make sense. Formerly, for example, you
574           could have the nonsensical case of an accented LF.
575
576       ·   "\X" will now match a (Korean) Hangul syllable sequence, and the
577           Thai and Lao exception cases.
578
579       Otherwise, this change should be transparent for the non-affected
580       languages.
581
582       "\p{...}" matches using the Canonical_Combining_Class property were
583       completely broken in previous releases of Perl.  They should now work
584       correctly.
585
586       Before Perl 5.12, the Unicode "Decomposition_Type=Compat" property and
587       a Perl extension had the same name, which led to neither matching all
588       the correct values (with more than 100 mistakes in one, and several
589       thousand in the other). The Perl extension has now been renamed to be
590       "Decomposition_Type=Noncanonical" (short: "dt=noncanon"). It has the
591       same meaning as was previously intended, namely the union of all the
592       non-canonical Decomposition types, with Unicode "Compat" being just one
593       of those.
594
595       "\p{Decomposition_Type=Canonical}" now includes the Hangul syllables.
596
597       "\p{Uppercase}" and "\p{Lowercase}" now work as the Unicode standard
598       says they should.  This means they each match a few more characters
599       than they used to.
600
601       "\p{Cntrl}" now matches the same characters as "\p{Control}". This
602       means it no longer will match Private Use (gc=co), Surrogates (gc=cs),
603       nor Format (gc=cf) code points. The Format code points represent the
604       biggest possible problem. All but 36 of them are either officially
605       deprecated or strongly discouraged from being used. Of those 36, likely
606       the most widely used are the soft hyphen (U+00AD), and BOM, ZWSP, ZWNJ,
607       WJ, and similar characters, plus bidirectional controls.
608
609       "\p{Alpha}" now matches the same characters as "\p{Alphabetic}". Before
610       5.12, Perl's definition definition included a number of things that
611       aren't really alpha (all marks) while omitting many that were. The
612       definitions of "\p{Alnum}" and "\p{Word}" depend on Alpha's definition
613       and have changed accordingly.
614
615       "\p{Word}" no longer incorrectly matches non-word characters such as
616       fractions.
617
618       "\p{Print}" no longer matches the line control characters: Tab, LF, CR,
619       FF, VT, and NEL. This brings it in line with standards and the
620       documentation.
621
622       "\p{XDigit}" now matches the same characters as "\p{Hex_Digit}". This
623       means that in addition to the characters it currently matches,
624       "[A-Fa-f0-9]", it will also match the 22 fullwidth equivalents, for
625       example U+FF10: FULLWIDTH DIGIT ZERO.
626
627       The Numeric type property has been extended to include the Unihan
628       characters.
629
630       There is a new Perl extension, the 'Present_In', or simply 'In',
631       property. This is an extension of the Unicode Age property, but
632       "\p{In=5.0}" matches any code point whose usage has been determined as
633       of Unicode version 5.0. The "\p{Age=5.0}" only matches code points
634       added in precisely version 5.0.
635
636       A number of properties now have the correct values for unassigned code
637       points. The affected properties are Bidi_Class, East_Asian_Width,
638       Joining_Type, Decomposition_Type, Hangul_Syllable_Type, Numeric_Type,
639       and Line_Break.
640
641       The Default_Ignorable_Code_Point, ID_Continue, and ID_Start properties
642       are now up to date with current Unicode definitions.
643
644       Earlier versions of Perl erroneously exposed certain properties that
645       are supposed to be Unicode internal-only.  Use of these in regular
646       expressions will now generate, if enabled, a deprecation warning
647       message.  The properties are: Other_Alphabetic,
648       Other_Default_Ignorable_Code_Point, Other_Grapheme_Extend,
649       Other_ID_Continue, Other_ID_Start, Other_Lowercase, Other_Math, and
650       Other_Uppercase.
651
652       It is now possible to change which Unicode properties Perl understands
653       on a per-installation basis. As mentioned above, certain properties are
654       turned off by default.  These include all the Unihan properties (which
655       should be accessible via the CPAN module Unicode::Unihan) and any
656       deprecated or Unicode internal-only property that Perl has never
657       exposed.
658
659       The generated files in the "lib/unicore/To" directory are now more
660       clearly marked as being stable, directly usable by applications.  New
661       hash entries in them give the format of the normal entries, which
662       allows for easier machine parsing. Perl can generate files in this
663       directory for any property, though most are suppressed.  You can find
664       instructions for changing which are written in perluniprops.
665

Modules and Pragmata

667   New Modules and Pragmata
668       "autodie"
669           "autodie" is a new lexically-scoped alternative for the "Fatal"
670           module.  The bundled version is 2.06_01. Note that in this release,
671           using a string eval when "autodie" is in effect can cause the
672           autodie behaviour to leak into the surrounding scope. See "BUGS" in
673           autodie for more details.
674
675           Version 2.06_01 has been added to the Perl core.
676
677       "Compress::Raw::Bzip2"
678           Version 2.024 has been added to the Perl core.
679
680       "overloading"
681           "overloading" allows you to lexically disable or enable overloading
682           for some or all operations.
683
684           Version 0.001 has been added to the Perl core.
685
686       "parent"
687           "parent" establishes an ISA relationship with base classes at
688           compile time. It provides the key feature of "base" without further
689           unwanted behaviors.
690
691           Version 0.223 has been added to the Perl core.
692
693       "Parse::CPAN::Meta"
694           Version 1.40 has been added to the Perl core.
695
696       "VMS::DCLsym"
697           Version 1.03 has been added to the Perl core.
698
699       "VMS::Stdio"
700           Version 2.4 has been added to the Perl core.
701
702       "XS::APItest::KeywordRPN"
703           Version 0.003 has been added to the Perl core.
704
705   Updated Pragmata
706       "base"
707           Upgraded from version 2.13 to 2.15.
708
709       "bignum"
710           Upgraded from version 0.22 to 0.23.
711
712       "charnames"
713           "charnames" now contains the Unicode NameAliases.txt database file.
714           This has the effect of adding some extra "\N" character names that
715           formerly wouldn't have been recognised; for example, "\N{LATIN
716           CAPITAL LETTER GHA}".
717
718           Upgraded from version 1.06 to 1.07.
719
720       "constant"
721           Upgraded from version 1.13 to 1.20.
722
723       "diagnostics"
724           "diagnostics" now supports %.0f formatting internally.
725
726           "diagnostics" no longer suppresses "Use of uninitialized value in
727           range (or flip)" warnings. [perl #71204]
728
729           Upgraded from version 1.17 to 1.19.
730
731       "feature"
732           In "feature", the meaning of the ":5.10" and ":5.10.X" feature
733           bundles has changed slightly. The last component, if any (i.e. "X")
734           is simply ignored.  This is predicated on the assumption that new
735           features will not, in general, be added to maintenance releases. So
736           ":5.10" and ":5.10.X" have identical effect. This is a change to
737           the behaviour documented for 5.10.0.
738
739           "feature" now includes the "unicode_strings" feature:
740
741               use feature "unicode_strings";
742
743           This pragma turns on Unicode semantics for the case-changing
744           operations ("uc", "lc", "ucfirst", "lcfirst") on strings that don't
745           have the internal UTF-8 flag set, but that contain single-byte
746           characters between 128 and 255.
747
748           Upgraded from version 1.11 to 1.16.
749
750       "less"
751           "less" now includes the "stash_name" method to allow subclasses of
752           "less" to pick where in %^H to store their stash.
753
754           Upgraded from version 0.02 to 0.03.
755
756       "lib"
757           Upgraded from version 0.5565 to 0.62.
758
759       "mro"
760           "mro" is now implemented as an XS extension. The documented
761           interface has not changed. Code relying on the implementation
762           detail that some "mro::" methods happened to be available at all
763           times gets to "keep both pieces".
764
765           Upgraded from version 1.00 to 1.02.
766
767       "overload"
768           "overload" now allow overloading of 'qr'.
769
770           Upgraded from version 1.06 to 1.10.
771
772       "threads"
773           Upgraded from version 1.67 to 1.75.
774
775       "threads::shared"
776           Upgraded from version 1.14 to 1.32.
777
778       "version"
779           "version" now has support for "Version number formats" as described
780           earlier in this document and in its own documentation.
781
782           Upgraded from version 0.74 to 0.82.
783
784       "warnings"
785           "warnings" has a new "warnings::fatal_enabled()" function.  It also
786           includes a new "illegalproto" warning category. See also "New or
787           Changed Diagnostics" for this change.
788
789           Upgraded from version 1.06 to 1.09.
790
791   Updated Modules
792       "Archive::Extract"
793           Upgraded from version 0.24 to 0.38.
794
795       "Archive::Tar"
796           Upgraded from version 1.38 to 1.54.
797
798       "Attribute::Handlers"
799           Upgraded from version 0.79 to 0.87.
800
801       "AutoLoader"
802           Upgraded from version 5.63 to 5.70.
803
804       "B::Concise"
805           Upgraded from version 0.74 to 0.78.
806
807       "B::Debug"
808           Upgraded from version 1.05 to 1.12.
809
810       "B::Deparse"
811           Upgraded from version 0.83 to 0.96.
812
813       "B::Lint"
814           Upgraded from version 1.09 to 1.11_01.
815
816       "CGI"
817           Upgraded from version 3.29 to 3.48.
818
819       "Class::ISA"
820           Upgraded from version 0.33 to 0.36.
821
822           NOTE: "Class::ISA" is deprecated and may be removed from a future
823           version of Perl.
824
825       "Compress::Raw::Zlib"
826           Upgraded from version 2.008 to 2.024.
827
828       "CPAN"
829           Upgraded from version 1.9205 to 1.94_56.
830
831       "CPANPLUS"
832           Upgraded from version 0.84 to 0.90.
833
834       "CPANPLUS::Dist::Build"
835           Upgraded from version 0.06_02 to 0.46.
836
837       "Data::Dumper"
838           Upgraded from version 2.121_14 to 2.125.
839
840       "DB_File"
841           Upgraded from version 1.816_1 to 1.820.
842
843       "Devel::PPPort"
844           Upgraded from version 3.13 to 3.19.
845
846       "Digest"
847           Upgraded from version 1.15 to 1.16.
848
849       "Digest::MD5"
850           Upgraded from version 2.36_01 to 2.39.
851
852       "Digest::SHA"
853           Upgraded from version 5.45 to 5.47.
854
855       "Encode"
856           Upgraded from version 2.23 to 2.39.
857
858       "Exporter"
859           Upgraded from version 5.62 to 5.64_01.
860
861       "ExtUtils::CBuilder"
862           Upgraded from version 0.21 to 0.27.
863
864       "ExtUtils::Command"
865           Upgraded from version 1.13 to 1.16.
866
867       "ExtUtils::Constant"
868           Upgraded from version 0.2 to 0.22.
869
870       "ExtUtils::Install"
871           Upgraded from version 1.44 to 1.55.
872
873       "ExtUtils::MakeMaker"
874           Upgraded from version 6.42 to 6.56.
875
876       "ExtUtils::Manifest"
877           Upgraded from version 1.51_01 to 1.57.
878
879       "ExtUtils::ParseXS"
880           Upgraded from version 2.18_02 to 2.21.
881
882       "File::Fetch"
883           Upgraded from version 0.14 to 0.24.
884
885       "File::Path"
886           Upgraded from version 2.04 to 2.08_01.
887
888       "File::Temp"
889           Upgraded from version 0.18 to 0.22.
890
891       "Filter::Simple"
892           Upgraded from version 0.82 to 0.84.
893
894       "Filter::Util::Call"
895           Upgraded from version 1.07 to 1.08.
896
897       "Getopt::Long"
898           Upgraded from version 2.37 to 2.38.
899
900       "IO"
901           Upgraded from version 1.23_01 to 1.25_02.
902
903       "IO::Zlib"
904           Upgraded from version 1.07 to 1.10.
905
906       "IPC::Cmd"
907           Upgraded from version 0.40_1 to 0.54.
908
909       "IPC::SysV"
910           Upgraded from version 1.05 to 2.01.
911
912       "Locale::Maketext"
913           Upgraded from version 1.12 to 1.14.
914
915       "Locale::Maketext::Simple"
916           Upgraded from version 0.18 to 0.21.
917
918       "Log::Message"
919           Upgraded from version 0.01 to 0.02.
920
921       "Log::Message::Simple"
922           Upgraded from version 0.04 to 0.06.
923
924       "Math::BigInt"
925           Upgraded from version 1.88 to 1.89_01.
926
927       "Math::BigInt::FastCalc"
928           Upgraded from version 0.16 to 0.19.
929
930       "Math::BigRat"
931           Upgraded from version 0.21 to 0.24.
932
933       "Math::Complex"
934           Upgraded from version 1.37 to 1.56.
935
936       "Memoize"
937           Upgraded from version 1.01_02 to 1.01_03.
938
939       "MIME::Base64"
940           Upgraded from version 3.07_01 to 3.08.
941
942       "Module::Build"
943           Upgraded from version 0.2808_01 to 0.3603.
944
945       "Module::CoreList"
946           Upgraded from version 2.12 to 2.29.
947
948       "Module::Load"
949           Upgraded from version 0.12 to 0.16.
950
951       "Module::Load::Conditional"
952           Upgraded from version 0.22 to 0.34.
953
954       "Module::Loaded"
955           Upgraded from version 0.01 to 0.06.
956
957       "Module::Pluggable"
958           Upgraded from version 3.6 to 3.9.
959
960       "Net::Ping"
961           Upgraded from version 2.33 to 2.36.
962
963       "NEXT"
964           Upgraded from version 0.60_01 to 0.64.
965
966       "Object::Accessor"
967           Upgraded from version 0.32 to 0.36.
968
969       "Package::Constants"
970           Upgraded from version 0.01 to 0.02.
971
972       "PerlIO"
973           Upgraded from version 1.04 to 1.06.
974
975       "Pod::Parser"
976           Upgraded from version 1.35 to 1.37.
977
978       "Pod::Perldoc"
979           Upgraded from version 3.14_02 to 3.15_02.
980
981       "Pod::Plainer"
982           Upgraded from version 0.01 to 1.02.
983
984           NOTE: "Pod::Plainer" is deprecated and may be removed from a future
985           version of Perl.
986
987       "Pod::Simple"
988           Upgraded from version 3.05 to 3.13.
989
990       "Safe"
991           Upgraded from version 2.12 to 2.22.
992
993       "SelfLoader"
994           Upgraded from version 1.11 to 1.17.
995
996       "Storable"
997           Upgraded from version 2.18 to 2.22.
998
999       "Switch"
1000           Upgraded from version 2.13 to 2.16.
1001
1002           NOTE: "Switch" is deprecated and may be removed from a future
1003           version of Perl.
1004
1005       "Sys::Syslog"
1006           Upgraded from version 0.22 to 0.27.
1007
1008       "Term::ANSIColor"
1009           Upgraded from version 1.12 to 2.02.
1010
1011       "Term::UI"
1012           Upgraded from version 0.18 to 0.20.
1013
1014       "Test"
1015           Upgraded from version 1.25 to 1.25_02.
1016
1017       "Test::Harness"
1018           Upgraded from version 2.64 to 3.17.
1019
1020       "Test::Simple"
1021           Upgraded from version 0.72 to 0.94.
1022
1023       "Text::Balanced"
1024           Upgraded from version 2.0.0 to 2.02.
1025
1026       "Text::ParseWords"
1027           Upgraded from version 3.26 to 3.27.
1028
1029       "Text::Soundex"
1030           Upgraded from version 3.03 to 3.03_01.
1031
1032       "Thread::Queue"
1033           Upgraded from version 2.00 to 2.11.
1034
1035       "Thread::Semaphore"
1036           Upgraded from version 2.01 to 2.09.
1037
1038       "Tie::RefHash"
1039           Upgraded from version 1.37 to 1.38.
1040
1041       "Time::HiRes"
1042           Upgraded from version 1.9711 to 1.9719.
1043
1044       "Time::Local"
1045           Upgraded from version 1.18 to 1.1901_01.
1046
1047       "Time::Piece"
1048           Upgraded from version 1.12 to 1.15.
1049
1050       "Unicode::Collate"
1051           Upgraded from version 0.52 to 0.52_01.
1052
1053       "Unicode::Normalize"
1054           Upgraded from version 1.02 to 1.03.
1055
1056       "Win32"
1057           Upgraded from version 0.34 to 0.39.
1058
1059       "Win32API::File"
1060           Upgraded from version 0.1001_01 to 0.1101.
1061
1062       "XSLoader"
1063           Upgraded from version 0.08 to 0.10.
1064
1065   Removed Modules and Pragmata
1066       "attrs"
1067           Removed from the Perl core.  Prior version was 1.02.
1068
1069       "CPAN::API::HOWTO"
1070           Removed from the Perl core.  Prior version was 'undef'.
1071
1072       "CPAN::DeferedCode"
1073           Removed from the Perl core.  Prior version was 5.50.
1074
1075       "CPANPLUS::inc"
1076           Removed from the Perl core.  Prior version was 'undef'.
1077
1078       "DCLsym"
1079           Removed from the Perl core.  Prior version was 1.03.
1080
1081       "ExtUtils::MakeMaker::bytes"
1082           Removed from the Perl core.  Prior version was 6.42.
1083
1084       "ExtUtils::MakeMaker::vmsish"
1085           Removed from the Perl core.  Prior version was 6.42.
1086
1087       "Stdio"
1088           Removed from the Perl core.  Prior version was 2.3.
1089
1090       "Test::Harness::Assert"
1091           Removed from the Perl core.  Prior version was 0.02.
1092
1093       "Test::Harness::Iterator"
1094           Removed from the Perl core.  Prior version was 0.02.
1095
1096       "Test::Harness::Point"
1097           Removed from the Perl core.  Prior version was 0.01.
1098
1099       "Test::Harness::Results"
1100           Removed from the Perl core.  Prior version was 0.01.
1101
1102       "Test::Harness::Straps"
1103           Removed from the Perl core.  Prior version was 0.26_01.
1104
1105       "Test::Harness::Util"
1106           Removed from the Perl core.  Prior version was 0.01.
1107
1108       "XSSymSet"
1109           Removed from the Perl core.  Prior version was 1.1.
1110
1111   Deprecated Modules and Pragmata
1112       See "Deprecated Modules" above.
1113

Documentation

1115   New Documentation
1116       ·   perlhaiku contains instructions on how to build perl for the Haiku
1117           platform.
1118
1119       ·   perlmroapi describes the new interface for pluggable Method
1120           Resolution Orders.
1121
1122       ·   perlperf, by Richard Foley, provides an introduction to the use of
1123           performance and optimization techniques which can be used with
1124           particular reference to perl programs.
1125
1126       ·   perlrepository describes how to access the perl source using the
1127           git version control system.
1128
1129       ·   perlpolicy extends the "Social contract about contributed modules"
1130           into the beginnings of a document on Perl porting policies.
1131
1132   Changes to Existing Documentation
1133       ·   The various large Changes* files (which listed every change made to
1134           perl over the last 18 years) have been removed, and replaced by a
1135           small file, also called Changes, which just explains how that same
1136           information may be extracted from the git version control system.
1137
1138       ·   Porting/patching.pod has been deleted, as it mainly described
1139           interacting with the old Perforce-based repository, which is now
1140           obsolete.  Information still relevant has been moved to
1141           perlrepository.
1142
1143       ·   The syntax "unless (EXPR) BLOCK else BLOCK" is now documented as
1144           valid, as is the syntax "unless (EXPR) BLOCK elsif (EXPR) BLOCK ...
1145           else BLOCK", although actually using the latter may not be the best
1146           idea for the readability of your source code.
1147
1148       ·   Documented -X overloading.
1149
1150       ·   Documented that "when()" treats specially most of the filetest
1151           operators
1152
1153       ·   Documented "when" as a syntax modifier.
1154
1155       ·   Eliminated "Old Perl threads tutorial", which described 5005
1156           threads.
1157
1158           pod/perlthrtut.pod is the same material reworked for ithreads.
1159
1160       ·   Correct previous documentation: v-strings are not deprecated
1161
1162           With version objects, we need them to use MODULE VERSION syntax.
1163           This patch removes the deprecation notice.
1164
1165       ·   Security contact information is now part of perlsec.
1166
1167       ·   A significant fraction of the core documentation has been updated
1168           to clarify the behavior of Perl's Unicode handling.
1169
1170           Much of the remaining core documentation has been reviewed and
1171           edited for clarity, consistent use of language, and to fix the
1172           spelling of Tom Christiansen's name.
1173
1174       ·   The Pod specification (perlpodspec) has been updated to bring the
1175           specification in line with modern usage already supported by most
1176           Pod systems. A parameter string may now follow the format name in a
1177           "begin/end" region. Links to URIs with a text description are now
1178           allowed. The usage of "L<"section">" has been marked as deprecated.
1179
1180       ·   if.pm has been documented in "use" in perlfunc as a means to get
1181           conditional loading of modules despite the implicit BEGIN block
1182           around "use".
1183
1184       ·   The documentation for $1 in perlvar.pod has been clarified.
1185
1186       ·   "\N{U+wide hex char}" is now documented.
1187

Selected Performance Enhancements

1189       ·   A new internal cache means that "isa()" will often be faster.
1190
1191       ·   The implementation of "C3" Method Resolution Order has been
1192           optimised - linearisation for classes with single inheritance is
1193           40% faster. Performance for multiple inheritance is unchanged.
1194
1195       ·   Under "use locale", the locale-relevant information is now cached
1196           on read-only values, such as the list returned by "keys %hash".
1197           This makes operations such as "sort keys %hash" in the scope of
1198           "use locale" much faster.
1199
1200       ·   Empty "DESTROY" methods are no longer called.
1201
1202       ·   "Perl_sv_utf8_upgrade()" is now faster.
1203
1204       ·   "keys" on empty hash is now faster.
1205
1206       ·   "if (%foo)" has been optimized to be faster than "if (keys %foo)".
1207
1208       ·   The string repetition operator ("$str x $num") is now several times
1209           faster when $str has length one or $num is large.
1210
1211       ·   Reversing an array to itself (as in "@a = reverse @a") in void
1212           context now happens in-place and is several orders of magnitude
1213           faster than it used to be. It will also preserve non-existent
1214           elements whenever possible, i.e. for non magical arrays or tied
1215           arrays with "EXISTS" and "DELETE" methods.
1216

Installation and Configuration Improvements

1218       ·   perlapi, perlintern, perlmodlib and perltoc are now all generated
1219           at build time, rather than being shipped as part of the release.
1220
1221       ·   If "vendorlib" and "vendorarch" are the same, then they are only
1222           added to @INC once.
1223
1224       ·   $Config{usedevel} and the C-level "PERL_USE_DEVEL" are now defined
1225           if perl is built with  "-Dusedevel".
1226
1227       ·   Configure will enable use of "-fstack-protector", to provide
1228           protection against stack-smashing attacks, if the compiler supports
1229           it.
1230
1231       ·   Configure will now determine the correct prototypes for re-entrant
1232           functions and for "gconvert" if you are using a C++ compiler rather
1233           than a C compiler.
1234
1235       ·   On Unix, if you build from a tree containing a git repository, the
1236           configuration process will note the commit hash you have checked
1237           out, for display in the output of "perl -v" and "perl -V". Unpushed
1238           local commits are automatically added to the list of local patches
1239           displayed by "perl -V".
1240
1241       ·   Perl now supports SystemTap's "dtrace" compatibility layer and an
1242           issue with linking "miniperl" has been fixed in the process.
1243
1244       ·   perldoc now uses "less -R" instead of "less" for improved behaviour
1245           in the face of "groff"'s new usage of ANSI escape codes.
1246
1247       ·   "perl -V" now reports use of the compile-time options
1248           "USE_PERL_ATOF" and "USE_ATTRIBUTES_FOR_PERLIO".
1249
1250       ·   As part of the flattening of ext, all extensions on all platforms
1251           are built by make_ext.pl. This replaces the Unix-specific
1252           ext/util/make_ext, VMS-specific make_ext.com and Win32-specific
1253           win32/buildext.pl.
1254

Internal Changes

1256       Each release of Perl sees numerous internal changes which shouldn't
1257       affect day to day usage but may still be notable for developers working
1258       with Perl's source code.
1259
1260       ·   The J.R.R. Tolkien quotes at the head of C source file have been
1261           checked and proper citations added, thanks to a patch from Tom
1262           Christiansen.
1263
1264       ·   The internal structure of the dual-life modules traditionally found
1265           in the lib/ and ext/ directories in the perl source has changed
1266           significantly. Where possible, dual-lifed modules have been
1267           extracted from lib/ and ext/.
1268
1269           Dual-lifed modules maintained by Perl's developers as part of the
1270           Perl core now live in dist/.  Dual-lifed modules maintained
1271           primarily on CPAN now live in cpan/.  When reporting a bug in a
1272           module located under cpan/, please send your bug report directly to
1273           the module's bug tracker or author, rather than Perl's bug tracker.
1274
1275       ·   "\N{...}" now compiles better, always forces UTF-8 internal
1276           representation
1277
1278           Perl's developers have fixed several problems with the recognition
1279           of "\N{...}" constructs.  As part of this, perl will store any
1280           scalar or regex containing "\N{name}" or "\N{U+wide hex char}" in
1281           its definition in UTF-8 format. (This was true previously for all
1282           occurences of "\N{name}" that did not use a custom translator, but
1283           now it's always true.)
1284
1285       ·   Perl_magic_setmglob now knows about globs, fixing RT #71254.
1286
1287       ·   "SVt_RV" no longer exists. RVs are now stored in IVs.
1288
1289       ·   "Perl_vcroak()" now accepts a null first argument. In addition, a
1290           full audit was made of the "not NULL" compiler annotations, and
1291           those for several other internal functions were corrected.
1292
1293       ·   New macros "dSAVEDERRNO", "dSAVE_ERRNO", "SAVE_ERRNO",
1294           "RESTORE_ERRNO" have been added to formalise the temporary saving
1295           of the "errno" variable.
1296
1297       ·   The function "Perl_sv_insert_flags" has been added to augment
1298           "Perl_sv_insert".
1299
1300       ·   The function "Perl_newSV_type(type)" has been added, equivalent to
1301           "Perl_newSV()" followed by "Perl_sv_upgrade(type)".
1302
1303       ·   The function "Perl_newSVpvn_flags()" has been added, equivalent to
1304           "Perl_newSVpvn()" and then performing the action relevant to the
1305           flag.
1306
1307           Two flag bits are currently supported.
1308
1309           ·   "SVf_UTF8" will call "SvUTF8_on()" for you. (Note that this
1310               does not convert an sequence of ISO 8859-1 characters to
1311               UTF-8). A wrapper, "newSVpvn_utf8()" is available for this.
1312
1313           ·   "SVs_TEMP" now calls "Perl_sv_2mortal()" on the new SV.
1314
1315           There is also a wrapper that takes constant strings,
1316           "newSVpvs_flags()".
1317
1318       ·   The function "Perl_croak_xs_usage" has been added as a wrapper to
1319           "Perl_croak".
1320
1321       ·   Perl now exports the functions "PerlIO_find_layer" and
1322           "PerlIO_list_alloc".
1323
1324       ·   "PL_na" has been exterminated from the core code, replaced by local
1325           STRLEN temporaries, or "*_nolen()" calls. Either approach is faster
1326           than "PL_na", which is a pointer dereference into the interpreter
1327           structure under ithreads, and a global variable otherwise.
1328
1329       ·   "Perl_mg_free()" used to leave freed memory accessible via
1330           "SvMAGIC()" on the scalar. It now updates the linked list to remove
1331           each piece of magic as it is freed.
1332
1333       ·   Under ithreads, the regex in "PL_reg_curpm" is now reference
1334           counted. This eliminates a lot of hackish workarounds to cope with
1335           it not being reference counted.
1336
1337       ·   "Perl_mg_magical()" would sometimes incorrectly turn on
1338           "SvRMAGICAL()".  This has been fixed.
1339
1340       ·   The public IV and NV flags are now not set if the string value has
1341           trailing "garbage". This behaviour is consistent with not setting
1342           the public IV or NV flags if the value is out of range for the
1343           type.
1344
1345       ·   Uses of "Nullav", "Nullcv", "Nullhv", "Nullop", "Nullsv" etc have
1346           been replaced by "NULL" in the core code, and non-dual-life
1347           modules, as "NULL" is clearer to those unfamiliar with the core
1348           code.
1349
1350       ·   A macro MUTABLE_PTR(p) has been added, which on (non-pedantic) gcc
1351           will not cast away "const", returning a "void *". Macros
1352           "MUTABLE_SV(av)", "MUTABLE_SV(cv)" etc build on this, casting to
1353           "AV *" etc without casting away "const". This allows proper
1354           compile-time auditing of "const" correctness in the core, and
1355           helped picked up some errors (now fixed).
1356
1357       ·   Macros "mPUSHs()" and "mXPUSHs()" have been added, for pushing SVs
1358           on the stack and mortalizing them.
1359
1360       ·   Use of the private structure "mro_meta" has changed slightly.
1361           Nothing outside the core should be accessing this directly anyway.
1362
1363       ·   A new tool, Porting/expand-macro.pl has been added, that allows you
1364           to view how a C preprocessor macro would be expanded when compiled.
1365           This is handy when trying to decode the macro hell that is the perl
1366           guts.
1367

Testing

1369   Testing improvements
1370       Parallel tests
1371           The core distribution can now run its regression tests in parallel
1372           on Unix-like platforms. Instead of running "make test", set
1373           "TEST_JOBS" in your environment to the number of tests to run in
1374           parallel, and run "make test_harness". On a Bourne-like shell, this
1375           can be done as
1376
1377               TEST_JOBS=3 make test_harness  # Run 3 tests in parallel
1378
1379           An environment variable is used, rather than parallel make itself,
1380           because TAP::Harness needs to be able to schedule individual non-
1381           conflicting test scripts itself, and there is no standard interface
1382           to "make" utilities to interact with their job schedulers.
1383
1384           Note that currently some test scripts may fail when run in parallel
1385           (most notably "ext/IO/t/io_dir.t"). If necessary run just the
1386           failing scripts again sequentially and see if the failures go away.
1387
1388       Test harness flexibility
1389           It's now possible to override "PERL5OPT" and friends in t/TEST
1390
1391       Test watchdog
1392           Several tests that have the potential to hang forever if they fail
1393           now incorporate a "watchdog" functionality that will kill them
1394           after a timeout, which helps ensure that "make test" and "make
1395           test_harness" run to completion automatically.
1396
1397   New Tests
1398       Perl's developers have added a number of new tests to the core.  In
1399       addition to the items listed below, many modules updated from CPAN
1400       incorporate new tests.
1401
1402       ·   Significant cleanups to core tests to ensure that language and
1403           interpreter features are not used before they're tested.
1404
1405       ·   "make test_porting" now runs a number of important pre-commit
1406           checks which might be of use to anyone working on the Perl core.
1407
1408       ·   t/porting/podcheck.t automatically checks the well-formedness of
1409           POD found in all .pl, .pm and .pod files in the MANIFEST, other
1410           than in dual-lifed modules which are primarily maintained outside
1411           the Perl core.
1412
1413       ·   t/porting/manifest.t now tests that all files listed in MANIFEST
1414           are present.
1415
1416       ·   t/op/while_readdir.t tests that a bare readdir in while loop sets
1417           $_.
1418
1419       ·   t/comp/retainedlines.t checks that the debugger can retain source
1420           lines from "eval".
1421
1422       ·   t/io/perlio_fail.t checks that bad layers fail.
1423
1424       ·   t/io/perlio_leaks.t checks that PerlIO layers are not leaking.
1425
1426       ·   t/io/perlio_open.t checks that certain special forms of open work.
1427
1428       ·   t/io/perlio.t includes general PerlIO tests.
1429
1430       ·   t/io/pvbm.t checks that there is no unexpected interaction between
1431           the internal types "PVBM" and "PVGV".
1432
1433       ·   t/mro/package_aliases.t checks that mro works properly in the
1434           presence of aliased packages.
1435
1436       ·   t/op/dbm.t tests "dbmopen" and "dbmclose".
1437
1438       ·   t/op/index_thr.t tests the interaction of "index" and threads.
1439
1440       ·   t/op/pat_thr.t tests the interaction of esoteric patterns and
1441           threads.
1442
1443       ·   t/op/qr_gc.t tests that "qr" doesn't leak.
1444
1445       ·   t/op/reg_email_thr.t tests the interaction of regex recursion and
1446           threads.
1447
1448       ·   t/op/regexp_qr_embed_thr.t tests the interaction of patterns with
1449           embedded "qr//" and threads.
1450
1451       ·   t/op/regexp_unicode_prop.t tests Unicode properties in regular
1452           expressions.
1453
1454       ·   t/op/regexp_unicode_prop_thr.t tests the interaction of Unicode
1455           properties and threads.
1456
1457       ·   t/op/reg_nc_tie.t tests the tied methods of
1458           "Tie::Hash::NamedCapture".
1459
1460       ·   t/op/reg_posixcc.t checks that POSIX character classes behave
1461           consistently.
1462
1463       ·   t/op/re.t checks that exportable "re" functions in universal.c
1464           work.
1465
1466       ·   t/op/setpgrpstack.t checks that "setpgrp" works.
1467
1468       ·   t/op/substr_thr.t tests the interaction of "substr" and threads.
1469
1470       ·   t/op/upgrade.t checks that upgrading and assigning scalars works.
1471
1472       ·   t/uni/lex_utf8.t checks that Unicode in the lexer works.
1473
1474       ·   t/uni/tie.t checks that Unicode and "tie" work.
1475
1476       ·   t/comp/final_line_num.t tests whether line numbers are correct at
1477           EOF
1478
1479       ·   t/comp/form_scope.t tests format scoping.
1480
1481       ·   t/comp/line_debug.t tests whether "@{"_<$file"}" works.
1482
1483       ·   t/op/filetest_t.t tests if -t file test works.
1484
1485       ·   t/op/qr.t tests "qr".
1486
1487       ·   t/op/utf8cache.t tests malfunctions of the utf8 cache.
1488
1489       ·   t/re/uniprops.t test unicodes "\p{}" regex constructs.
1490
1491       ·   t/op/filehandle.t tests some suitably portable filetest operators
1492           to check that they work as expected, particularly in the light of
1493           some internal changes made in how filehandles are blessed.
1494
1495       ·   t/op/time_loop.t tests that unix times greater than "2**63", which
1496           can now be handed to "gmtime" and "localtime", do not cause an
1497           internal overflow or an excessively long loop.
1498

New or Changed Diagnostics

1500   New Diagnostics
1501       ·   SV allocation tracing has been added to the diagnostics enabled by
1502           "-Dm".  The tracing can alternatively output via the "PERL_MEM_LOG"
1503           mechanism, if that was enabled when the perl binary was compiled.
1504
1505       ·   Smartmatch resolution tracing has been added as a new diagnostic.
1506           Use "-DM" to enable it.
1507
1508       ·   A new debugging flag "-DB" now dumps subroutine definitions,
1509           leaving "-Dx" for its original purpose of dumping syntax trees.
1510
1511       ·   Perl 5.12 provides a number of new diagnostic messages to help you
1512           write better code.  See perldiag for details of these new messages.
1513
1514           ·   "Bad plugin affecting keyword '%s'"
1515
1516           ·   "gmtime(%.0f) too large"
1517
1518           ·   "Lexing code attempted to stuff non-Latin-1 character into
1519               Latin-1 input"
1520
1521           ·   "Lexing code internal error (%s)"
1522
1523           ·   "localtime(%.0f) too large"
1524
1525           ·   "Overloaded dereference did not return a reference"
1526
1527           ·   "Overloaded qr did not return a REGEXP"
1528
1529           ·   "Perl_pmflag() is deprecated, and will be removed from the XS
1530               API"
1531
1532           ·   "lvalue attribute ignored after the subroutine has been
1533               defined"
1534
1535               This new warning is issued when one attempts to mark a
1536               subroutine as lvalue after it has been defined.
1537
1538           ·   Perl now warns you if "++" or "--" are unable to change the
1539               value because it's beyond the limit of representation.
1540
1541               This uses a new warnings category: "imprecision".
1542
1543           ·   "lc", "uc", "lcfirst", and "ucfirst" warn when passed undef.
1544
1545           ·   "Show constant in "Useless use of a constant in void context""
1546
1547           ·   "Prototype after '%s'"
1548
1549           ·   "panic: sv_chop %s"
1550
1551               This new fatal error occurs when the C routine "Perl_sv_chop()"
1552               was passed a position that is not within the scalar's string
1553               buffer. This could be caused by buggy XS code, and at this
1554               point recovery is not possible.
1555
1556           ·   The fatal error "Malformed UTF-8 returned by \N" is now
1557               produced if the "charnames" handler returns malformed UTF-8.
1558
1559           ·   If an unresolved named character or sequence was encountered
1560               when compiling a regex pattern then the fatal error "\N{NAME}
1561               must be resolved by the lexer" is now produced. This can
1562               happen, for example, when using a single-quotish context like
1563               "$re = '\N{SPACE}'; /$re/;". See perldiag for more examples of
1564               how the lexer can get bypassed.
1565
1566           ·   "Invalid hexadecimal number in \N{U+...}" is a new fatal error
1567               triggered when the character constant represented by "..." is
1568               not a valid hexadecimal number.
1569
1570           ·   The new meaning of "\N" as "[^\n]" is not valid in a bracketed
1571               character class, just like "." in a character class loses its
1572               special meaning, and will cause the fatal error "\N in a
1573               character class must be a named character: \N{...}".
1574
1575           ·   The rules on what is legal for the "..." in "\N{...}" have been
1576               tightened up so that unless the "..." begins with an alphabetic
1577               character and continues with a combination of alphanumerics,
1578               dashes, spaces, parentheses or colons then the warning
1579               "Deprecated character(s) in \N{...} starting at '%s'" is now
1580               issued.
1581
1582           ·   The warning "Using just the first characters returned by \N{}"
1583               will be issued if the "charnames" handler returns a sequence of
1584               characters which exceeds the limit of the number of characters
1585               that can be used. The message will indicate which characters
1586               were used and which were discarded.
1587
1588   Changed Diagnostics
1589       A number of existing diagnostic messages have been improved or
1590       corrected:
1591
1592       ·   A new warning category "illegalproto" allows finer-grained control
1593           of warnings around function prototypes.
1594
1595           The two warnings:
1596
1597           "Illegal character in prototype for %s : %s"
1598           "Prototype after '%c' for %s : %s"
1599
1600           have been moved from the "syntax" top-level warnings category into
1601           a new first-level category, "illegalproto". These two warnings are
1602           currently the only ones emitted during parsing of an
1603           invalid/illegal prototype, so one can now use
1604
1605             no warnings 'illegalproto';
1606
1607           to suppress only those, but not other syntax-related warnings.
1608           Warnings where prototypes are changed, ignored, or not met are
1609           still in the "prototype" category as before.
1610
1611       ·   "Deep recursion on subroutine "%s""
1612
1613           It is now possible to change the depth threshold for this warning
1614           from the default of 100, by recompiling the perl binary, setting
1615           the C pre-processor macro "PERL_SUB_DEPTH_WARN" to the desired
1616           value.
1617
1618       ·   "Illegal character in prototype" warning is now more precise when
1619           reporting illegal characters after _
1620
1621       ·   mro merging error messages are now very similar to those produced
1622           by Algorithm::C3.
1623
1624       ·   Amelioration of the error message "Unrecognized character %s in
1625           column %d"
1626
1627           Changes the error message to "Unrecognized character %s; marked by
1628           <-- HERE after %s<-- HERE near column %d". This should make it a
1629           little simpler to spot and correct the suspicious character.
1630
1631       ·   Perl now explicitly points to $. when it causes an uninitialized
1632           warning for ranges in scalar context.
1633
1634       ·   "split" now warns when called in void context.
1635
1636       ·   "printf"-style functions called with too few arguments will now
1637           issue the warning "Missing argument in %s" [perl #71000]
1638
1639       ·   Perl now properly returns a syntax error instead of segfaulting if
1640           "each", "keys", or "values" is used without an argument.
1641
1642       ·   "tell()" now fails properly if called without an argument and when
1643           no previous file was read.
1644
1645           "tell()" now returns "-1", and sets errno to "EBADF", thus
1646           restoring the 5.8.x behaviour.
1647
1648       ·   "overload" no longer implicitly unsets fallback on repeated 'use
1649           overload' lines.
1650
1651       ·   POSIX::strftime() can now handle Unicode characters in the format
1652           string.
1653
1654       ·   The "syntax" category was removed from 5 warnings that should only
1655           be in "deprecated".
1656
1657       ·   Three fatal "pack"/"unpack" error messages have been normalized to
1658           "panic: %s"
1659
1660       ·   "Unicode character is illegal" has been rephrased to be more
1661           accurate
1662
1663           It now reads "Unicode non-character is illegal in interchange" and
1664           the perldiag documentation has been expanded a bit.
1665
1666       ·   Currently, all but the first of the several characters that the
1667           "charnames" handler may return are discarded when used in a regular
1668           expression pattern bracketed character class. If this happens then
1669           the warning "Using just the first character returned by \N{} in
1670           character class" will be issued.
1671
1672       ·   The warning "Missing right brace on \N{} or unescaped left brace
1673           after \N.  Assuming the latter" will be issued if Perl encounters a
1674           "\N{" but doesn't find a matching "}". In this case Perl doesn't
1675           know if it was mistakenly omitted, or if "match non-newline"
1676           followed by "match a "{"" was desired.  It assumes the latter
1677           because that is actually a valid interpretation as written, unlike
1678           the other case.  If you meant the former, you need to add the
1679           matching right brace.  If you did mean the latter, you can silence
1680           this warning by writing instead "\N\{".
1681
1682       ·   "gmtime" and "localtime" called with numbers smaller than they can
1683           reliably handle will now issue the warnings "gmtime(%.0f) too
1684           small" and "localtime(%.0f) too small".
1685
1686       The following diagnostic messages have been removed:
1687
1688       ·   "Runaway format"
1689
1690       ·   "Can't locate package %s for the parents of %s"
1691
1692           In general this warning it only got produced in conjunction with
1693           other warnings, and removing it allowed an ISA lookup optimisation
1694           to be added.
1695
1696       ·   "v-string in use/require is non-portable"
1697

Utility Changes

1699       ·   h2ph now looks in "include-fixed" too, which is a recent addition
1700           to gcc's search path.
1701
1702       ·   h2xs no longer incorrectly treats enum values like macros.  It also
1703           now handles C++ style comments ("//") properly in enums.
1704
1705       ·   perl5db.pl now supports "LVALUE" subroutines.  Additionally, the
1706           debugger now correctly handles proxy constant subroutines, and
1707           subroutine stubs.
1708
1709       ·   perlbug now uses %Module::CoreList::bug_tracker to print out
1710           upstream bug tracker URLs.  If a user identifies a particular
1711           module as the topic of their bug report and we're able to divine
1712           the URL for its upstream bug tracker, perlbug now provide a message
1713           to the user explaining that the core copies the CPAN version
1714           directly, and provide the URL for reporting the bug directly to the
1715           upstream author.
1716
1717           perlbug no longer reports "Message sent" when it hasn't actually
1718           sent the message
1719
1720       ·   perlthanks is a new utility for sending non-bug-reports to the
1721           authors and maintainers of Perl. Getting nothing but bug reports
1722           can become a bit demoralising. If Perl 5.12 works well for you,
1723           please try out perlthanks. It will make the developers smile.
1724
1725       ·   Perl's developers have fixed bugs in a2p having to do with the
1726           "match()" operator in list context.  Additionally, a2p no longer
1727           generates code that uses the $[ variable.
1728

Selected Bug Fixes

1730       ·   U+0FFFF is now a legal character in regular expressions.
1731
1732       ·   pp_qr now always returns a new regexp SV. Resolves RT #69852.
1733
1734           Instead of returning a(nother) reference to the (pre-compiled)
1735           regexp in the optree, use reg_temp_copy() to create a copy of it,
1736           and return a reference to that. This resolves issues about
1737           Regexp::DESTROY not being called in a timely fashion (the original
1738           bug tracked by RT #69852), as well as bugs related to blessing
1739           regexps, and of assigning to regexps, as described in
1740           correspondence added to the ticket.
1741
1742           It transpires that we also need to undo the SvPVX() sharing when
1743           ithreads cloning a Regexp SV, because mother_re is set to NULL,
1744           instead of a cloned copy of the mother_re. This change might fix
1745           bugs with regexps and threads in certain other situations, but as
1746           yet neither tests nor bug reports have indicated any problems, so
1747           it might not actually be an edge case that it's possible to reach.
1748
1749       ·   Several compilation errors and segfaults when perl was built with
1750           "-Dmad" were fixed.
1751
1752       ·   Fixes for lexer API changes in 5.11.2 which broke NYTProf's savesrc
1753           option.
1754
1755       ·   "-t" should only return TRUE for file handles connected to a TTY
1756
1757           The Microsoft C version of "isatty()" returns TRUE for all
1758           character mode devices, including the /dev/null-style "nul" device
1759           and printers like "lpt1".
1760
1761       ·   Fixed a regression caused by commit fafafbaf which caused a panic
1762           during parameter passing [perl #70171]
1763
1764       ·   On systems which in-place edits without backup files, -i'*' now
1765           works as the documentation says it does [perl #70802]
1766
1767       ·   Saving and restoring magic flags no longer loses readonly flag.
1768
1769       ·   The malformed syntax "grep EXPR LIST" (note the missing comma) no
1770           longer causes abrupt and total failure.
1771
1772       ·   Regular expressions compiled with "qr{}" literals properly set "$'"
1773           when matching again.
1774
1775       ·   Using named subroutines with "sort" should no longer lead to bus
1776           errors [perl #71076]
1777
1778       ·   Numerous bugfixes catch small issues caused by the recently-added
1779           Lexer API.
1780
1781       ·   Smart match against @_ sometimes gave false negatives. [perl
1782           #71078]
1783
1784       ·   $@ may now be assigned a read-only value (without error or busting
1785           the stack).
1786
1787       ·   "sort" called recursively from within an active comparison
1788           subroutine no longer causes a bus error if run multiple times.
1789           [perl #71076]
1790
1791       ·   Tie::Hash::NamedCapture::* will not abort if passed bad input (RT
1792           #71828)
1793
1794       ·   @_ and $_ no longer leak under threads (RT #34342 and #41138, also
1795           #70602, #70974)
1796
1797       ·   "-I" on shebang line now adds directories in front of @INC as
1798           documented, and as does "-I" when specified on the command-line.
1799
1800       ·   "kill" is now fatal when called on non-numeric process identifiers.
1801           Previously, an "undef" process identifier would be interpreted as a
1802           request to kill process 0, which would terminate the current
1803           process group on POSIX systems. Since process identifiers are
1804           always integers, killing a non-numeric process is now fatal.
1805
1806       ·   5.10.0 inadvertently disabled an optimisation, which caused a
1807           measurable performance drop in list assignment, such as is often
1808           used to assign function parameters from @_. The optimisation has
1809           been re-instated, and the performance regression fixed. (This fix
1810           is also present in 5.10.1)
1811
1812       ·   Fixed memory leak on "while (1) { map 1, 1 }" [RT #53038].
1813
1814       ·   Some potential coredumps in PerlIO fixed [RT #57322,54828].
1815
1816       ·   The debugger now works with lvalue subroutines.
1817
1818       ·   The debugger's "m" command was broken on modules that defined
1819           constants [RT #61222].
1820
1821       ·   "crypt" and string complement could return tainted values for
1822           untainted arguments [RT #59998].
1823
1824       ·   The "-i".suffix command-line switch now recreates the file using
1825           restricted permissions, before changing its mode to match the
1826           original file. This eliminates a potential race condition [RT
1827           #60904].
1828
1829       ·   On some Unix systems, the value in $? would not have the top bit
1830           set ("$? & 128") even if the child core dumped.
1831
1832       ·   Under some circumstances, $^R could incorrectly become undefined
1833           [RT #57042].
1834
1835       ·   In the XS API, various hash functions, when passed a pre-computed
1836           hash where the key is UTF-8, might result in an incorrect lookup.
1837
1838       ·   XS code including XSUB.h before perl.h gave a compile-time error
1839           [RT #57176].
1840
1841       ·   "$object->isa('Foo')" would report false if the package "Foo"
1842           didn't exist, even if the object's @ISA contained "Foo".
1843
1844       ·   Various bugs in the new-to 5.10.0 mro code, triggered by
1845           manipulating @ISA, have been found and fixed.
1846
1847       ·   Bitwise operations on references could crash the interpreter, e.g.
1848           "$x=\$y; $x |= "foo"" [RT #54956].
1849
1850       ·   Patterns including alternation might be sensitive to the internal
1851           UTF-8 representation, e.g.
1852
1853               my $byte = chr(192);
1854               my $utf8 = chr(192); utf8::upgrade($utf8);
1855               $utf8 =~ /$byte|X}/i;       # failed in 5.10.0
1856
1857       ·   Within UTF8-encoded Perl source files (i.e. where "use utf8" is in
1858           effect), double-quoted literal strings could be corrupted where a
1859           "\xNN", "\0NNN" or "\N{}" is followed by a literal character with
1860           ordinal value greater than 255 [RT #59908].
1861
1862       ·   "B::Deparse" failed to correctly deparse various constructs:
1863           "readpipe STRING" [RT #62428], "CORE::require(STRING)" [RT #62488],
1864           "sub foo(_)" [RT #62484].
1865
1866       ·   Using "setpgrp" with no arguments could corrupt the perl stack.
1867
1868       ·   The block form of "eval" is now specifically trappable by "Safe"
1869           and "ops". Previously it was erroneously treated like string
1870           "eval".
1871
1872       ·   In 5.10.0, the two characters "[~" were sometimes parsed as the
1873           smart match operator ("~~") [RT #63854].
1874
1875       ·   In 5.10.0, the "*" quantifier in patterns was sometimes treated as
1876           "{0,32767}" [RT #60034, #60464]. For example, this match would
1877           fail:
1878
1879               ("ab" x 32768) =~ /^(ab)*$/
1880
1881       ·   "shmget" was limited to a 32 bit segment size on a 64 bit OS [RT
1882           #63924].
1883
1884       ·   Using "next" or "last" to exit a "given" block no longer produces a
1885           spurious warning like the following:
1886
1887               Exiting given via last at foo.pl line 123
1888
1889       ·   Assigning a format to a glob could corrupt the format; e.g.:
1890
1891                *bar=*foo{FORMAT}; # foo format now bad
1892
1893       ·   Attempting to coerce a typeglob to a string or number could cause
1894           an assertion failure. The correct error message is now generated,
1895           "Can't coerce GLOB to $type".
1896
1897       ·   Under "use filetest 'access'", "-x" was using the wrong access
1898           mode. This has been fixed [RT #49003].
1899
1900       ·   "length" on a tied scalar that returned a Unicode value would not
1901           be correct the first time. This has been fixed.
1902
1903       ·   Using an array "tie" inside in array "tie" could SEGV. This has
1904           been fixed. [RT #51636]
1905
1906       ·   A race condition inside "PerlIOStdio_close()" has been identified
1907           and fixed. This used to cause various threading issues, including
1908           SEGVs.
1909
1910       ·   In "unpack", the use of "()" groups in scalar context was
1911           internally placing a list on the interpreter's stack, which
1912           manifested in various ways, including SEGVs. This is now fixed [RT
1913           #50256].
1914
1915       ·   Magic was called twice in "substr", "\&$x", "tie $x, $m" and
1916           "chop".  These have all been fixed.
1917
1918       ·   A 5.10.0 optimisation to clear the temporary stack within the
1919           implicit loop of "s///ge" has been reverted, as it turned out to be
1920           the cause of obscure bugs in seemingly unrelated parts of the
1921           interpreter [commit ef0d4e17921ee3de].
1922
1923       ·   The line numbers for warnings inside "elsif" are now correct.
1924
1925       ·   The ".." operator now works correctly with ranges whose ends are at
1926           or close to the values of the smallest and largest integers.
1927
1928       ·   "binmode STDIN, ':raw'" could lead to segmentation faults on some
1929           platforms.  This has been fixed [RT #54828].
1930
1931       ·   An off-by-one error meant that "index $str, ..." was effectively
1932           being executed as "index "$str\0", ...". This has been fixed [RT
1933           #53746].
1934
1935       ·   Various leaks associated with named captures in regexes have been
1936           fixed [RT #57024].
1937
1938       ·   A weak reference to a hash would leak. This was affecting "DBI" [RT
1939           #56908].
1940
1941       ·   Using (?|) in a regex could cause a segfault [RT #59734].
1942
1943       ·   Use of a UTF-8 "tr//" within a closure could cause a segfault [RT
1944           #61520].
1945
1946       ·   Calling "Perl_sv_chop()" or otherwise upgrading an SV could result
1947           in an unaligned 64-bit access on the SPARC architecture [RT
1948           #60574].
1949
1950       ·   In the 5.10.0 release, "inc_version_list" would incorrectly list
1951           "5.10.*" after "5.8.*"; this affected the @INC search order [RT
1952           #67628].
1953
1954       ·   In 5.10.0, "pack "a*", $tainted_value" returned a non-tainted value
1955           [RT #52552].
1956
1957       ·   In 5.10.0, "printf" and "sprintf" could produce the fatal error
1958           "panic: utf8_mg_pos_cache_update" when printing UTF-8 strings [RT
1959           #62666].
1960
1961       ·   In the 5.10.0 release, a dynamically created "AUTOLOAD" method
1962           might be missed (method cache issue) [RT #60220,60232].
1963
1964       ·   In the 5.10.0 release, a combination of "use feature" and "//ee"
1965           could cause a memory leak [RT #63110].
1966
1967       ·   "-C" on the shebang ("#!") line is once more permitted if it is
1968           also specified on the command line. "-C" on the shebang line used
1969           to be a silent no-op if it was not also on the command line, so
1970           perl 5.10.0 disallowed it, which broke some scripts. Now perl
1971           checks whether it is also on the command line and only dies if it
1972           is not [RT #67880].
1973
1974       ·   In 5.10.0, certain types of re-entrant regular expression could
1975           crash, or cause the following assertion failure [RT #60508]:
1976
1977               Assertion rx->sublen >= (s - rx->subbeg) + i failed
1978
1979       ·   Perl now includes previously missing files from the Unicode
1980           Character Database.
1981
1982       ·   Perl now honors "TMPDIR" when opening an anonymous temporary file.
1983

Platform Specific Changes

1985       Perl is incredibly portable. In general, if a platform has a C
1986       compiler, someone has ported Perl to it (or will soon).  We're happy to
1987       announce that Perl 5.12 includes support for several new platforms.  At
1988       the same time, it's time to bid farewell to some (very) old friends.
1989
1990   New Platforms
1991       Haiku
1992           Perl's developers have merged patches from Haiku's maintainers.
1993           Perl should now build on Haiku.
1994
1995       MirOS BSD
1996           Perl should now build on MirOS BSD.
1997
1998   Discontinued Platforms
1999       Domain/OS
2000       MiNT
2001       Tenon MachTen
2002
2003   Updated Platforms
2004       AIX
2005           ·   Removed libbsd for AIX 5L and 6.1. Only "flock()" was used from
2006               libbsd.
2007
2008           ·   Removed libgdbm for AIX 5L and 6.1 if libgdbm < 1.8.3-5 is
2009               installed.  The libgdbm is delivered as an optional package
2010               with the AIX Toolbox.  Unfortunately the versions below 1.8.3-5
2011               are broken.
2012
2013           ·   Hints changes mean that AIX 4.2 should work again.
2014
2015       Cygwin
2016           ·   Perl now supports IPv6 on Cygwin 1.7 and newer.
2017
2018           ·   On Cygwin we now strip the last number from the DLL. This has
2019               been the behaviour in the cygwin.com build for years. The hints
2020               files have been updated.
2021
2022       Darwin (Mac OS X)
2023           ·   Skip testing the be_BY.CP1131 locale on Darwin 10 (Mac OS X
2024               10.6), as it's still buggy.
2025
2026           ·   Correct infelicities in the regexp used to identify buggy
2027               locales on Darwin 8 and 9 (Mac OS X 10.4 and 10.5,
2028               respectively).
2029
2030       DragonFly BSD
2031           ·   Fix thread library selection [perl #69686]
2032
2033       FreeBSD
2034           ·   The hints files now identify the correct threading libraries on
2035               FreeBSD 7 and later.
2036
2037       Irix
2038           ·   We now work around a bizarre preprocessor bug in the Irix 6.5
2039               compiler: "cc -E -" unfortunately goes into K&R mode, but "cc
2040               -E file.c" doesn't.
2041
2042       NetBSD
2043           ·   Hints now supports versions 5.*.
2044
2045       OpenVMS
2046           ·   "-UDEBUGGING" is now the default on VMS.
2047
2048               Like it has been everywhere else for ages and ages. Also make
2049               command-line selection of -UDEBUGGING and -DDEBUGGING work in
2050               configure.com; before the only way to turn it off was by saying
2051               no in answer to the interactive question.
2052
2053           ·   The default pipe buffer size on VMS has been updated to 8192 on
2054               64-bit systems.
2055
2056           ·   Reads from the in-memory temporary files of "PerlIO::scalar"
2057               used to fail if $/ was set to a numeric reference (to indicate
2058               record-style reads).  This is now fixed.
2059
2060           ·   VMS now supports "getgrgid".
2061
2062           ·   Many improvements and cleanups have been made to the VMS file
2063               name handling and conversion code.
2064
2065           ·   Enabling the "PERL_VMS_POSIX_EXIT" logical name now encodes a
2066               POSIX exit status in a VMS condition value for better
2067               interaction with GNV's bash shell and other utilities that
2068               depend on POSIX exit values. See "$?" in perlvms for details.
2069
2070           ·   "File::Copy" now detects Unix compatibility mode on VMS.
2071
2072       Stratus VOS
2073           ·   Various changes from Stratus have been merged in.
2074
2075       Symbian
2076           ·   There is now support for Symbian S60 3.2 SDK and S60 5.0 SDK.
2077
2078       Windows
2079           ·   Perl 5.12 supports Windows 2000 and later. The supporting code
2080               for legacy versions of Windows is still included, but will be
2081               removed during the next development cycle.
2082
2083           ·   Initial support for building Perl with MinGW-w64 is now
2084               available.
2085
2086           ·   perl.exe now includes a manifest resource to specify the
2087               "trustInfo" settings for Windows Vista and later. Without this
2088               setting Windows would treat perl.exe as a legacy application
2089               and apply various heuristics like redirecting access to
2090               protected file system areas (like the "Program Files" folder)
2091               to the users "VirtualStore" instead of generating a proper
2092               "permission denied" error.
2093
2094               The manifest resource also requests the Microsoft Common-
2095               Controls version 6.0 (themed controls introduced in Windows
2096               XP).  Check out the Win32::VisualStyles module on CPAN to
2097               switch back to old style unthemed controls for legacy
2098               applications.
2099
2100           ·   The "-t" filetest operator now only returns true if the
2101               filehandle is connected to a console window.  In previous
2102               versions of Perl it would return true for all character mode
2103               devices, including NUL and LPT1.
2104
2105           ·   The "-p" filetest operator now works correctly, and the
2106               Fcntl::S_IFIFO constant is defined when Perl is compiled with
2107               Microsoft Visual C.  In previous Perl versions "-p" always
2108               returned a false value, and the Fcntl::S_IFIFO constant was not
2109               defined.
2110
2111               This bug is specific to Microsoft Visual C and never affected
2112               Perl binaries built with MinGW.
2113
2114           ·   The socket error codes are now more widely supported:  The
2115               POSIX module will define the symbolic names, like
2116               POSIX::EWOULDBLOCK, and stringification of socket error codes
2117               in $! works as well now;
2118
2119                 C:\>perl -MPOSIX -E "$!=POSIX::EWOULDBLOCK; say $!"
2120                 A non-blocking socket operation could not be completed immediately.
2121
2122           ·   flock() will now set sensible error codes in $!.  Previous Perl
2123               versions copied the value of $^E into $!, which caused much
2124               confusion.
2125
2126           ·   select() now supports all empty "fd_set"s more correctly.
2127
2128           ·   '.\foo' and '..\foo'  were treated differently than './foo' and
2129               '../foo' by "do" and "require" [RT #63492].
2130
2131           ·   Improved message window handling means that "alarm" and "kill"
2132               messages will no longer be dropped under race conditions.
2133
2134           ·   Various bits of Perl's build infrastructure are no longer
2135               converted to win32 line endings at release time. If this hurts
2136               you, please report the problem with the perlbug program
2137               included with perl.
2138

Known Problems

2140       This is a list of some significant unfixed bugs, which are regressions
2141       from either 5.10.x or 5.8.x.
2142
2143       ·   Some CPANPLUS tests may fail if there is a functioning file
2144           ../../cpanp-run-perl outside your build directory. The failure
2145           shouldn't imply there's a problem with the actual functional
2146           software. The bug is already fixed in [RT #74188] and is scheduled
2147           for inclusion in perl-v5.12.1.
2148
2149       ·   "List::Util::first" misbehaves in the presence of a lexical $_
2150           (typically introduced by "my $_" or implicitly by "given"). The
2151           variable which gets set for each iteration is the package variable
2152           $_, not the lexical $_ [RT #67694].
2153
2154           A similar issue may occur in other modules that provide functions
2155           which take a block as their first argument, like
2156
2157               foo { ... $_ ...} list
2158
2159       ·   Some regexes may run much more slowly when run in a child thread
2160           compared with the thread the pattern was compiled into [RT #55600].
2161
2162       ·   Things like ""\N{LATIN SMALL LIGATURE FF}" =~ /\N{LATIN SMALL
2163           LETTER F}+/" will appear to hang as they get into a very long
2164           running loop [RT #72998].
2165
2166       ·   Several porters have reported mysterious crashes when Perl's entire
2167           test suite is run after a build on certain Windows 2000 systems.
2168           When run by hand, the individual tests reportedly work fine.
2169

Errata

2171       ·   This one is actually a change introduced in 5.10.0, but it was
2172           missed from that release's perldelta, so it is mentioned here
2173           instead.
2174
2175           A bugfix related to the handling of the "/m" modifier and "qr"
2176           resulted in a change of behaviour between 5.8.x and 5.10.0:
2177
2178               # matches in 5.8.x, doesn't match in 5.10.0
2179               $re = qr/^bar/; "foo\nbar" =~ /$re/m;
2180

Acknowledgements

2182       Perl 5.12.0 represents approximately two years of development since
2183       Perl 5.10.0 and contains over 750,000 lines of changes across over
2184       3,000 files from over 200 authors and committers.
2185
2186       Perl continues to flourish into its third decade thanks to a vibrant
2187       community of users and developers.  The following people are known to
2188       have contributed the improvements that became Perl 5.12.0:
2189
2190       Aaron Crane, Abe Timmerman, Abhijit Menon-Sen, Abigail, Adam Russell,
2191       Adriano Ferreira, var Arnfjoerd` Bjarmason, Alan Grover, Alexandr
2192       Ciornii, Alex Davies, Alex Vandiver, Andreas Koenig, Andrew Rodland,
2193       andrew@sundale.net, Andy Armstrong, Andy Dougherty, Jose AUGUSTE-
2194       ETIENNE, Benjamin Smith, Ben Morrow, bharanee rathna, Bo Borgerson, Bo
2195       Lindbergh, Brad Gilbert, Bram, Brendan O'Dea, brian d foy, Charles
2196       Bailey, Chip Salzenberg, Chris 'BinGOs' Williams, Christoph Lamprecht,
2197       Chris Williams, chromatic, Claes Jakobsson, Craig A. Berry, Dan
2198       Dascalescu, Daniel Frederick Crisman, Daniel M. Quinlan, Dan Jacobson,
2199       Dan Kogai, Dave Mitchell, Dave Rolsky, David Cantrell, David Dick,
2200       David Golden, David Mitchell, David M. Syzdek, David Nicol, David
2201       Wheeler, Dennis Kaarsemaker, Dintelmann, Peter, Dominic Dunlop,
2202       Dr.Ruud, Duke Leto, Enrico Sorcinelli, Eric Brine, Father Chrysostomos,
2203       Florian Ragwitz, Frank Wiegand, Gabor Szabo, Gene Sullivan, Geoffrey T.
2204       Dairiki, George Greer, Gerard Goossen, Gisle Aas, Goro Fuji, Graham
2205       Barr, Green, Paul, Hans Dieter Pearcey, Harmen, H. Merijn Brand, Hugo
2206       van der Sanden, Ian Goodacre, Igor Sutton, Ingo Weinhold, James Bence,
2207       James Mastros, Jan Dubois, Jari Aalto, Jarkko Hietaniemi, Jay Hannah,
2208       Jerry Hedden, Jesse Vincent, Jim Cromie, Jody Belka, John E. Malmberg,
2209       John Malmberg, John Peacock, John Peacock via RT, John P. Linderman,
2210       John Wright, Josh ben Jore, Jos I. Boumans, Karl Williamson, Kenichi
2211       Ishigaki, Ken Williams, Kevin Brintnall, Kevin Ryde, Kurt Starsinic,
2212       Leon Brocard, Lubomir Rintel, Luke Ross, Marcel Gruenauer, Marcus
2213       Holland-Moritz, Mark Jason Dominus, Marko Asplund, Martin Hasch,
2214       Mashrab Kuvatov, Matt Kraai, Matt S Trout, Max Maischein, Michael
2215       Breen, Michael Cartmell, Michael G Schwern, Michael Witten, Mike
2216       Giroux, Milosz Tanski, Moritz Lenz, Nicholas Clark, Nick Cleaton, Niko
2217       Tyni, Offer Kaye, Osvaldo Villalon, Paul Fenwick, Paul Gaborit, Paul
2218       Green, Paul Johnson, Paul Marquess, Philip Hazel, Philippe Bruhat,
2219       Rafael Garcia-Suarez, Rainer Tammer, Rajesh Mandalemula, Reini Urban,
2220       Renee Baecker, Ricardo Signes, Ricardo SIGNES, Richard Foley, Rich
2221       Rauenzahn, Rick Delaney, Risto Kankkunen, Robert May, Roberto C.
2222       Sanchez, Robin Barker, SADAHIRO Tomoyuki, Salvador Ortiz Garcia, Sam
2223       Vilain, Scott Lanning, Sebastien Aperghis-Tramoni, Sergio Durigan
2224       Junior, Shlomi Fish, Simon 'corecode' Schubert, Sisyphus, Slaven Rezic,
2225       Smylers, Steffen Mueller, Steffen Ullrich, Stepan Kasal, Steve Hay,
2226       Steven Schubiger, Steve Peters, Tels, The Doctor, Tim Bunce, Tim
2227       Jenness, Todd Rinaldo, Tom Christiansen, Tom Hukins, Tom Wyant, Tony
2228       Cook, Torsten Schoenfeld, Tye McQueen, Vadim Konovalov, Vincent Pit,
2229       Hio YAMASHINA, Yasuhiro Matsumoto, Yitzchak Scott-Thoennes, Yuval
2230       Kogman, Yves Orton, Zefram, Zsban Ambrus
2231
2232       This is woefully incomplete as it's automatically generated from
2233       version control history.  In particular, it doesn't include the names
2234       of the (very much appreciated) contributors who reported issues in
2235       previous versions of Perl that helped make Perl 5.12.0 better. For a
2236       more complete list of all of Perl's historical contributors, please see
2237       the "AUTHORS" file in the Perl 5.12.0 distribution.
2238
2239       Our "retired" pumpkings Nicholas Clark and Rafael Garcia-Suarez deserve
2240       special thanks for their brilliant and substantive ongoing
2241       contributions. Nicholas personally authored over 30% of the patches
2242       since 5.10.0. Rafael comes in second in patch authorship with 11%, but
2243       is first by a long shot in committing patches authored by others,
2244       pushing 44% of the commits since 5.10.0 in this category, often after
2245       providing considerable coaching to the patch authors. These statistics
2246       in no way comprise all of their contributions, but express in shorthand
2247       that we couldn't have done it without them.
2248
2249       Many of the changes included in this version originated in the CPAN
2250       modules included in Perl's core. We're grateful to the entire CPAN
2251       community for helping Perl to flourish.
2252

Reporting Bugs

2254       If you find what you think is a bug, you might check the articles
2255       recently posted to the comp.lang.perl.misc newsgroup and the perl bug
2256       database at <http://rt.perl.org/perlbug/>. There may also be
2257       information at <http://www.perl.org/>, the Perl Home Page.
2258
2259       If you believe you have an unreported bug, please run the perlbug
2260       program included with your release. Be sure to trim your bug down to a
2261       tiny but sufficient test case. Your bug report, along with the output
2262       of "perl -V", will be sent off to perlbug@perl.org to be analyzed by
2263       the Perl porting team.
2264
2265       If the bug you are reporting has security implications, which make it
2266       inappropriate to send to a publicly archived mailing list, then please
2267       send it to perl5-security-report@perl.org. This points to a closed
2268       subscription unarchived mailing list, which includes all the core
2269       committers, who be able to help assess the impact of issues, figure out
2270       a resolution, and help co-ordinate the release of patches to mitigate
2271       or fix the problem across all platforms on which Perl is supported.
2272       Please only use this address for security issues in the Perl core, not
2273       for modules independently distributed on CPAN.
2274

SEE ALSO

2276       The Changes file for an explanation of how to view exhaustive details
2277       on what changed.
2278
2279       The INSTALL file for how to build Perl.
2280
2281       The README file for general stuff.
2282
2283       The Artistic and Copying files for copyright information.
2284
2285       <http://dev.perl.org/perl5/errata.html> for a list of issues found
2286       after this release, as well as a list of CPAN modules known to be
2287       incompatible with this release.
2288
2289
2290
2291perl v5.12.4                      2011-06-07                  PERL5120DELTA(1)
Impressum