This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
perldelta: Oust the XS-specific core enhancements
[perl5.git] / pod / perldelta.pod
CommitLineData
44691e6f
AB
1=encoding utf8
2
3=head1 NAME
4
5076a392 5perldelta - what is new for perl v5.14.0
c71a852f 6
5076a392
FC
7=head1 DESCRIPTION
8
9This document describes differences between the 5.12.0 release and
10the 5.14.0 release.
11
12Some of the bug fixes in this release have been backported to subsequent
13releases of 5.12.x. Those are indicated with the 5.12.x version in
14parentheses.
15
16XXX Go through the perl512*delta files and do that.
17
18=head1 Notice
19
20XXX Any important notices here
21
22=head1 Core Enhancements
23
5076a392
FC
24=head2 Assignment to C<$0> sets the legacy process name with C<prctl()> on Linux
25
26On Linux the legacy process name will be set with L<prctl(2)>, in
27addition to altering the POSIX name via C<argv[0]> as perl has done
28since version 4.000. Now system utilities that read the legacy process
29name such as ps, top and killall will recognize the name you set when
30assigning to C<$0>. The string you supply will be cut off at 16 bytes,
31this is a limitation imposed by Linux.
32
5076a392
FC
33=head2 Exception Handling Reliability
34
35Several changes have been made to the way C<die>, C<warn>, and C<$@>
36behave, in order to make them more reliable and consistent.
37
38When an exception is thrown inside an C<eval>, the exception is no
39longer at risk of being clobbered by code running during unwinding
40(e.g., destructors). Previously, the exception was written into C<$@>
41early in the throwing process, and would be overwritten if C<eval> was
42used internally in the destructor for an object that had to be freed
43while exiting from the outer C<eval>. Now the exception is written
44into C<$@> last thing before exiting the outer C<eval>, so the code
45running immediately thereafter can rely on the value in C<$@> correctly
959ad7d5
FC
46corresponding to that C<eval>. (C<$@> is still also set before exiting the
47C<eval>, for the sake of destructors that rely on this.)
5076a392
FC
48
49Likewise, a C<local $@> inside an C<eval> will no longer clobber any
50exception thrown in its scope. Previously, the restoration of C<$@> upon
51unwinding would overwrite any exception being thrown. Now the exception
959ad7d5 52gets to the C<eval> anyway. So C<local $@> is safe before a C<die>.
5076a392
FC
53
54Exceptions thrown from object destructors no longer modify the C<$@>
55of the surrounding context. (If the surrounding context was exception
56unwinding, this used to be another way to clobber the exception being
959ad7d5
FC
57thrown.) Previously such an exception was
58sometimes emitted as a warning, and then either was
5076a392
FC
59string-appended to the surrounding C<$@> or completely replaced the
60surrounding C<$@>, depending on whether that exception and the surrounding
61C<$@> were strings or objects. Now, an exception in this situation is
62always emitted as a warning, leaving the surrounding C<$@> untouched.
63In addition to object destructors, this also affects any function call
64performed by XS code using the C<G_KEEPERR> flag.
65
5076a392
FC
66Warnings for C<warn> can now be objects, in the same way as exceptions
67for C<die>. If an object-based warning gets the default handling,
959ad7d5
FC
68of writing to standard error, it is stringified as
69before, with the file and line number appended. But
70a C<$SIG{__WARN__}> handler will now receive an
5076a392
FC
71object-based warning as an object, where previously it was passed the
72result of stringifying the object.
73
74=head2 Non-destructive substitution
75
959ad7d5
FC
76The substitution (C<s///>) and transliteration
77(C<y///>) operators now support an C</r> option that
5076a392
FC
78copies the input variable, carries out the substitution on
79the copy and returns the result. The original remains unmodified.
80
81 my $old = 'cat';
82 my $new = $old =~ s/cat/dog/r;
83 # $old is 'cat' and $new is 'dog'
84
959ad7d5 85This is particularly useful with C<map>. See L<perlop> for more examples.
5076a392
FC
86
87=head2 package block syntax
88
89A package declaration can now contain a code block, in which case the
90declaration is in scope only inside that block. So C<package Foo { ... }>
91is precisely equivalent to C<{ package Foo; ... }>. It also works with
92a version number in the declaration, as in C<package Foo 1.2 { ... }>.
93See L<perlfunc> (434da3..36f77d, 702646).
94
5076a392
FC
95=head2 perl -h no longer recommends -w
96
97perl -h used to mark the -w option as recommended; since this option is
98far less useful than it used to be due to lexical 'use warnings' and since
99perl -h is primary a list and brief explanation of the command line switches,
100the recommendation has now been removed (60eaec).
101
102=head2 \o{...} for octals
103
104There is a new escape sequence, C<"\o">, in double-quote-like contexts.
105It must be followed by braces enclosing an octal number of at least one
106digit. It interpolates as the character with an ordinal value equal to
107the octal number. This construct allows large octal ordinals beyond the
108current max of 0777 to be represented. It also allows you to specify a
109character in octal which can safely be concatenated with other regex
110snippets and which won't be confused with being a backreference to
111a regex capture group. See L<perlre/Capture groups>.
112
113=head2 C<\N{I<name>}> and C<charnames> enhancements
114
115C<\N{}> and C<charnames::vianame> now know about the abbreviated
116character names listed by Unicode, such as NBSP, SHY, LRO, ZWJ, etc., as
117well as all the customary abbreviations for the C0 and C1 control
118characters (such as ACK, BEL, CAN, etc.), as well as a few new variants
119in common usage of some C1 full names.
120
959ad7d5
FC
121Unicode has a number of named character sequences, in which particular sequences
122of code points are given names. C<\N{...}> now recognizes these.
123
124C<\N{}>, C<charnames::vianame>, C<charnames::viacode> now know about every
125character in Unicode. Previously, they didn't know about the Hangul syllables
126nor a number of CJK (Chinese/Japanese/Korean) characters.
127
5076a392
FC
128In the past, it was ineffective to override one of Perl's abbreviations
129with your own custom alias. Now it works.
130
131You can also create a custom alias directly to the ordinal of a
132character, known by C<\N{...}>, C<charnames::vianame()>, and
133C<charnames::viacode()>. Previously, an alias had to be to an official
134Unicode character name. This made it impossible to create an alias for
135a code point that had no name, such as the ones reserved for private
136use. So this change allows you to make more effective use of private
137use characters. Only if there is no official name will
138C<charnames::viacode()> return your custom one.
139
959ad7d5
FC
140A new function, C<charnames::string_vianame()>, has been added.
141This function is a run-time version of C<\N{...}>, returning the string
142of characters whose Unicode name is its parameter. It can handle
143Unicode named character sequences, whereas the pre-existing
144C<charnames::vianame()> cannot, as the latter returns a single code
145point.
146
5076a392
FC
147See L<charnames> for details on all these changes.
148
149=head2 Uppercase X/B allowed in hexadecimal/binary literals
150
151Literals may now use either upper case C<0X...> or C<0B...> prefixes,
152in addition to the already supported C<0x...> and C<0b...>
153syntax. (RT#76296) (a674e8d, 333f87f)
154
155C, Ruby, Python and PHP already supported this syntax, and it makes
156Perl more internally consistent. A round-trip with C<eval sprintf
157"%#X", 0x10> now returns C<16> in addition to C<eval sprintf "%#x",
1580x10>, which worked before.
159
160=head2 C<srand()> now returns the seed
161
162This allows programs that need to have repeatable results to not have to come
163up with their own seed generating mechanism. Instead, they can use C<srand()>
164and somehow stash the return for future use. Typical is a test program which
165has too many combinations to test comprehensively in the time available to it
166each run. It can test a random subset each time, and should there be a failure,
167log the seed used for that run so that it can later be used to reproduce the
168exact results.
169
5076a392
FC
170=head2 C<(?^...)> regex construct added to signify default modifiers
171
172A caret (also called a "circumflex accent") C<"^"> immediately following
173a C<"(?"> in a regular expression now means that the subexpression is to
174not inherit the surrounding modifiers such as C</i>, but to revert to the
175Perl defaults. Any modifiers following the caret override the defaults.
176
177The stringification of regular expressions now uses this
178notation. E.g., before, C<qr/hlagh/i> would be stringified as
179C<(?i-xsm:hlagh)>, but now it's stringified as C<(?^i:hlagh)>.
180
181The main purpose of this is to allow tests that rely on the
182stringification to not have to change when new modifiers are added.
183See L<perlre/Extended Patterns>.
184
959ad7d5 185=head2 C</d>, C</l>, C</u>, C</a>, and C</aa> regular expression modifiers
5076a392 186
959ad7d5
FC
187Four new regular expression modifiers have been added. These are mutually
188exclusive; one only can be turned on at a time.
5076a392 189
959ad7d5 190The C</l> modifier says to compile the regular expression as if it were
5076a392
FC
191in the scope of C<use locale>, even if it is not.
192
959ad7d5 193The C</u> modifier says to compile the regular expression as if it were
5076a392
FC
194in the scope of a C<use feature "unicode_strings"> pragma.
195
959ad7d5 196The C</d> modifier is used to override any C<use locale> and
5076a392
FC
197C<use feature "unicode_strings"> pragmas that are in effect at the time
198of compiling the regular expression.
199
959ad7d5
FC
200The C</a> regular expression modifier restricts C<\s>, C<\d> and C<\w> and
201the Posix (C<[[:posix:]]>) character classes to the ASCII range. The
202complements and C<\b> and C<\B> are correspondingly
203affected. Otherwise, C</a> behaves like the C</u> modifier, in that
204case-insensitive matching uses Unicode semantics; for example, "k" will
205match the Unicode C<\N{KELVIN SIGN}> under C</i> matching, and code
206points in the Latin1 range, above ASCII will have Unicode semantics when
207it comes to case-insensitive matching.
5076a392 208
959ad7d5
FC
209The C</aa> modifier is like C</a>, except that, in case-insensitive matching, no ASCII character will match a
210non-ASCII character. For example,
5076a392 211
959ad7d5 212 'k' =~ /\N{KELVIN SIGN}/ai
5076a392 213
959ad7d5 214will match; it won't under C</aa>.
5076a392 215
959ad7d5 216See L<perlre/Modifiers> for more detail.
5076a392
FC
217
218=head2 Reentrant regular expression engine
219
220It is now safe to use regular expressions within C<(?{...})> and
221C<(??{...})> code blocks inside regular expressions.
222
223These block are still experimental, however, and still have problems with
224lexical (C<my>) variables, lexical pragmata and abnormal exiting.
225
5076a392
FC
226=head2 Return value of C<delete $+{...}>
227
228Custom regular expression engines can now determine the return value of
229C<delete> on an entry of C<%+> or C<%->.
230
5076a392
FC
231=head2 Single term prototype
232
233The C<+> prototype is a special alternative to C<$> that will act like
234C<\[@%]> when given a literal array or hash variable, but will otherwise
235force scalar context on the argument. This is useful for functions which
236should accept either a literal array or an array reference as the argument:
237
238 sub smartpush (+@) {
239 my $aref = shift;
240 die "Not an array or arrayref" unless ref $aref eq 'ARRAY';
241 push @$aref, @_;
242 }
243
244When using the C<+> prototype, your function must check that the argument
245is of an acceptable type.
246
247=head2 C<use re '/flags';>
248
249The C<re> pragma now has the ability to turn on regular expression flags
250till the end of the lexical scope:
251
252 use re '/x';
253 "foo" =~ / (.+) /; # /x implied
254
255See L<re/"'/flags' mode"> for details.
256
257=head2 Statement labels can appear in more places
258
259Statement labels can now occur before any type of statement or declaration,
260such as C<package>.
261
5076a392
FC
262=head2 Array and hash container functions accept references
263
264All built-in functions that operate directly on array or hash
265containers now also accept hard references to arrays or hashes:
266
267 |----------------------------+---------------------------|
268 | Traditional syntax | Terse syntax |
269 |----------------------------+---------------------------|
270 | push @$arrayref, @stuff | push $arrayref, @stuff |
271 | unshift @$arrayref, @stuff | unshift $arrayref, @stuff |
272 | pop @$arrayref | pop $arrayref |
273 | shift @$arrayref | shift $arrayref |
274 | splice @$arrayref, 0, 2 | splice $arrayref, 0, 2 |
275 | keys %$hashref | keys $hashref |
276 | keys @$arrayref | keys $arrayref |
277 | values %$hashref | values $hashref |
278 | values @$arrayref | values $arrayref |
279 | ($k,$v) = each %$hashref | ($k,$v) = each $hashref |
280 | ($k,$v) = each @$arrayref | ($k,$v) = each $arrayref |
281 |----------------------------+---------------------------|
282
283This allows these built-in functions to act on long dereferencing chains
284or on the return value of subroutines without needing to wrap them in
285C<@{}> or C<%{}>:
286
287 push @{$obj->tags}, $new_tag; # old way
288 push $obj->tags, $new_tag; # new way
289
290 for ( keys %{$hoh->{genres}{artists}} ) {...} # old way
291 for ( keys $hoh->{genres}{artists} ) {...} # new way
292
293For C<push>, C<unshift> and C<splice>, the reference will auto-vivify
294if it is not defined, just as if it were wrapped with C<@{}>.
295
296Calling C<keys> or C<values> directly on a reference gives a substantial
297performance improvement over explicit dereferencing.
298
299For C<keys>, C<values>, C<each>, when overloaded dereferencing is
300present, the overloaded dereference is used instead of dereferencing the
301underlying reftype. Warnings are issued about assumptions made in the
302following three ambiguous cases:
303
304 (a) If both %{} and @{} overloading exists, %{} is used
305 (b) If %{} overloading exists on a blessed arrayref, %{} is used
306 (c) If @{} overloading exists on a blessed hashref, @{} is used
307
5076a392
FC
308=head2 New global variable C<${^GLOBAL_PHASE}>
309
310A new global variable, C<${^GLOBAL_PHASE}>, has been added to allow
311introspection of the current phase of the perl interpreter. It's explained in
312detail in L<perlvar/"${^GLOBAL_PHASE}"> and
313L<perlmod/"BEGIN, UNITCHECK, CHECK, INIT and END">.
314
315=head2 Unicode Version 6.0 is now supported (mostly)
316
317Perl comes with the Unicode 6.0 data base updated with
318L<Corrigendum #8|http://www.unicode.org/versions/corrigendum8.html>,
319with one exception noted below.
320See L<http://unicode.org/versions/Unicode6.0.0> for details on the new
321release. Perl does not support any Unicode provisional properties,
322including the new ones for this release, but their database files are
323packaged with Perl.
324
325Unicode 6.0 has chosen to use the name C<BELL> for the character at U+1F514,
326which is a symbol that looks like a bell, and used in Japanese cell
327phones. This conflicts with the long-standing Perl usage of having
328C<BELL> mean the ASCII C<BEL> character, U+0007. In Perl 5.14,
329C<\N{BELL}> will continue to mean U+0007, but its use will generate a
330deprecated warning message, unless such warnings are turned off. The
331new name for U+0007 in Perl will be C<ALERT>, which corresponds nicely
332with the existing shorthand sequence for it, C<"\a">. C<\N{BEL}> will
333mean U+0007, with no warning given. The character at U+1F514 will not
334have a name in 5.14, but can be referred to by C<\N{U+1F514}>. The plan
335is that in Perl 5.16, C<\N{BELL}> will refer to U+1F514, and so all code
336that uses C<\N{BELL}> should convert by then to using C<\N{ALERT}>,
337C<\N{BEL}>, or C<"\a"> instead.
338
5076a392
FC
339=head2 C<-d:-foo> calls C<Devel::foo::unimport>
340
341The syntax C<-dI<B<:>foo>> was extended in 5.6.1 to make C<-dI<:fooB<=bar>>>
342equivalent to C<-MDevel::foo=bar>, which expands
343internally to C<use Devel::foo 'bar';>.
344F<perl> now allows prefixing the module name with C<->, with the same
345semantics as C<-M>, I<i.e.>
346
347=over 4
348
349=item C<-d:-foo>
350
351Equivalent to C<-M-Devel::foo>, expands to
352C<no Devel::foo;>, calls C<< Devel::foo->unimport() >>
353if the method exists.
354
355=item C<-d:-foo=bar>
356
357Equivalent to C<-M-Devel::foo=bar>, expands to C<no Devel::foo 'bar';>,
358calls C<< Devel::foo->unimport('bar') >> if the method exists.
359
360=back
361
362This is particularly useful to suppresses the default actions of a
363C<Devel::*> module's C<import> method whilst still loading it for debugging.
364
365=head2 Filehandle method calls load L<IO::File> on demand
366
367When a method call on a filehandle would die because the method cannot
368be resolved, and L<IO::File> has not been loaded, Perl now loads L<IO::File>
369via C<require> and attempts method resolution again:
370
371 open my $fh, ">", $file;
372 $fh->binmode(":raw"); # loads IO::File and succeeds
373
374This also works for globs like STDOUT, STDERR and STDIN:
375
376 STDOUT->autoflush(1);
377
378Because this on-demand load only happens if method resolution fails, the
379legacy approach of manually loading an L<IO::File> parent class for partial
380method support still works as expected:
381
382 use IO::Handle;
383 open my $fh, ">", $file;
384 $fh->autoflush(1); # IO::File not loaded
385
386=head2 Full functionality for C<use feature 'unicode_strings'>
387
388This release provides full functionality for C<use feature
389'unicode_strings'>. Under its scope, all string operations executed and
390regular expressions compiled (even if executed outside its scope) have
391Unicode semantics. See L<feature>.
392
393This feature avoids most forms of the "Unicode Bug" (See
394L<perlunicode/The "Unicode Bug"> for details.) If there is a
395possibility that your code will process Unicode strings, you are
396B<strongly> encouraged to use this subpragma to avoid nasty surprises.
397
5076a392
FC
398=head2 printf-like functions understand post-1980 size modifiers
399
400Perl's printf and sprintf operators, and Perl's internal printf replacement
401function, now understand the C90 size modifiers "hh" (C<char>), "z"
402(C<size_t>), and "t" (C<ptrdiff_t>). Also, when compiled with a C99
403compiler, Perl now understands the size modifier "j" (C<intmax_t>).
404
405So, for example, on any modern machine, C<sprintf('%hhd', 257)> returns '1'.
406
407=head2 DTrace probes now include package name
408
409The DTrace probes now include an additional argument (C<arg3>) which contains
410the package the subroutine being entered or left was compiled in.
411
412For example using the following DTrace script:
413
414 perl$target:::sub-entry
415 {
416 printf("%s::%s\n", copyinstr(arg0), copyinstr(arg3));
417 }
418
419and then running:
420
421 perl -e'sub test { }; test'
422
423DTrace will print:
424
425 main::test
426
427=head2 Stacked labels
428
429Multiple statement labels can now appear before a single statement.
430
5076a392
FC
431=head2 Any unsigned value can be encoded as a character
432
433With this release, Perl is adopting a model that any unsigned value can
434be treated as a code point and encoded internally (as utf8) without
435warnings -- not just the code points that are legal in Unicode.
436However, unless utf8 warnings have been
437explicitly lexically turned off, outputting or performing a
438Unicode-defined operation (such as upper-casing) on such a code point
439will generate a warning. Attempting to input these using strict rules
440(such as with the C<:encoding('UTF-8')> layer) will continue to fail.
441Prior to this release the handling was very inconsistent, and incorrect
442in places. Also, the Unicode non-characters, some of which previously were
443erroneously considered illegal in places by Perl, contrary to the Unicode
444standard, are now always legal internally. But inputting or outputting
445them will work the same as for the non-legal Unicode code points, as the
446Unicode standard says they are illegal for "open interchange".
447
448=head2 Regular expression debugging output improvement
449
450Regular expression debugging output (turned on by C<use re 'debug';>) now
451uses hexadecimal when escaping non-ASCII characters, instead of octal.
452
5076a392
FC
453=head2 Add C<\p{Titlecase}> as a synonym for C<\p{Title}>
454
455This synonym is added for symmetry with the Unicode property names
456C<\p{Uppercase}> and C<\p{Lowercase}>.
457
5076a392
FC
458=head2 New warnings categories for problematic (non-)Unicode code points.
459
460Three new warnings subcategories of <utf8> have been added. These
461allow you to turn off warnings for their covered events, while allowing
462the other UTF-8 warnings to remain on. The three categories are:
463C<surrogate> when UTF-16 surrogates are encountered;
464C<nonchar> when Unicode non-character code points are encountered;
465and C<non_unicode> when code points that are above the legal Unicode
466maximum of 0x10FFFF are encountered.
467
468=head1 Security
469
470=head2 Restrict \p{IsUserDefined} to In\w+ and Is\w+
471
472In L<perlunicode/"User-Defined Character Properties">, it says you can
473create custom properties by defining subroutines whose names begin with
474"In" or "Is". However, perl doesn't actually enforce that naming
475restriction, so \p{foo::bar} will call foo::Bar() if it exists.
476
477This commit finally enforces this convention. Note that this broke a
478number of existing tests for properties, since they didn't always use an
479Is/In prefix.
480
481=head2 User-defined regular expression properties
482
483Perl no longer allows a tainted regular expression to invoke a user-defined
484property via C<\p{...}> syntax. It simply dies instead [perl #82616].
485
486=head1 Incompatible Changes
487
488=head2 "C<\cI<X>>"
489
490The backslash-c construct was designed as a way of specifying
491non-printable characters, but there were no restrictions (on ASCII
492platforms) on what the character following the C<c> could be. Now, that
493character must be one of the ASCII characters.
494
495=head2 localised tied hashes, arrays and scalars are no longed tied
496
497In the following:
498
499 tie @a, ...;
500 {
501 local @a;
502 # here, @a is a now a new, untied array
503 }
504 # here, @a refers again to the old, tied array
505
506The new local array used to be made tied too, which was fairly pointless,
507and has now been fixed. This fix could however potentially cause a change
508in behaviour of some code.
509
510=head2 C<given> return values
511
512Starting from this release, C<given> blocks returns the last evaluated
513expression, or an empty list if the block was exited by C<break>. Thus you
514can now write:
515
516 my $type = do {
517 given ($num) {
518 break when undef;
519 'integer' when /^[+-]?[0-9]+$/;
520 'float' when /^[+-]?[0-9]+(?:\.[0-9]+)?$/;
521 'unknown';
522 }
523 };
524
525See L<perlsyn/Return value> for details.
526
527=head2 localised tied scalars are tied again.
528
529The change in behaviour in 5.13.1 of localising tied scalar values has
530been reverted to the existing 5.12.0 and earlier behaviour (the change for
531arrays and hashes remains).
532
533=head2 Naming fixes in Policy_sh.SH may invalidate Policy.sh
534
535Several long-standing typos and naming confusions in Policy_sh.SH have
536been fixed, standardizing on the variable names used in config.sh.
537
538This will change the behavior of Policy.sh if you happen to have been
539accidentally relying on the Policy.sh incorrect behavior. We'd appreciate
540feedback from anyone using Policy.sh to be sure nothing is broken by
541this change (c1bd23).
542
543=head2 Stashes are now always defined
544
545C<defined %Foo::> now always returns true, even when no symbols have yet been
546defined in that package.
547
548This is a side effect of removing a special case kludge in the tokeniser,
549added for 5.10.0, to hide side effects of changes to the internal storage of
550hashes that to drastically reduce their memory usage overhead.
551
552Calling defined on a stash has been deprecated since 5.6.0, warned on
553lexicals since 5.6.0, and has warned for stashes (and other package
554variables) since 5.12.0. C<defined %hash> has always exposed an
555implementation detail - emptying a hash by deleting all entries from it does
556not make C<defined %hash> false, hence C<defined %hash> is not valid code to
557determine whether an arbitrary hash is empty. Instead, use the behaviour
558that an empty C<%hash> always returns false in a scalar context.
559
560=head2 \400 - \777
561
562Use of C<\400> - C<\777> in regexes in certain circumstances has given
563different, anomalous behavior than their use in all other
564double-quote-like contexts. Since 5.10.1, a deprecated warning message
565has been raised when this happens. Now, all double-quote-like contexts
566have the same behavior, namely to be equivalent to C<\x{100}> -
567C<\x{1FF}>, with no deprecation warning. Use of these values in the
568command line option C<"-0"> retains the current meaning to slurp input
569files whole; previously, this was documented only for C<"-0777">. It is
570recommended, however, because of various ambiguities, to use the new
571C<\o{...}> construct to represent characters in octal.
572(fa1639c..f6993e9).
573
574=head2 Declare API incompatibility between blead releases
575
576Only stable releases (5.10.x, 5.12.x, 5.14.x, ...) guarantee binary
577compatibility with each other, while blead releases (5.13.x, 5.15.x, ...) often
578break this compatibility. However, prior to perl 5.13.4, all blead releases had
579the same C<PERL_API_REVISION>, C<PERL_API_VERSION>, and C<PERL_API_SUBVERSION>,
580effectively declaring them as binary compatible, which they weren't. From now
581on, blead releases will have a C<PERL_API_SUBVERSION> equal to their
582C<PERL_SUBVERSION>, explicitly marking them as incompatible with each other.
583
584Maintenance releases of stable perl versions will continue to make no
585intentionally incompatible API changes.
586
587=head2 Check API compatibility when loading XS modules
588
589When perl's API changes in incompatible ways (which usually happens between
590every major release), XS modules compiled for previous versions of perl will not
591work anymore. They will need to be recompiled against the new perl.
592
593In order to ensure that modules are recompiled, and to prevent users from
594accidentally loading modules compiled for old perls into newer ones, the
595C<XS_APIVERSION_BOOTCHECK> macro has been added. That macro, which is called
596when loading every newly compiled extension, compares the API version of the
597running perl with the version a module has been compiled for and raises an
598exception if they don't match.
599
600=head2 Binary Incompatible with all previous Perls
601
602Some bit fields have been reordered; therefore, this release will not be binary
603compatible with any previous Perl release.
604
605=head2 Change in the parsing of certain prototypes
606
607Functions declared with the following prototypes now behave correctly as unary
608functions:
609
610=over 4
611
612=item *
613
614C<*>
615
616=item *
617
618C<\sigil>
619
620=item *
621
622C<\[...]>
623
624=item *
625
626C<;$>
627
628=item *
629
630C<;*>
631
632=item *
633
634C<;\sigil>
635
636=item *
637
638C<;\[...]>
639
640=back
641
642Due to this bug fix, functions using the C<(*)>, C<(;$)> and C<(;*)> prototypes
643are parsed with higher precedence than before. So in the following example:
644
645 sub foo($);
646 foo $a < $b;
647
648the second line is now parsed correctly as C<< foo($a) < $b >>, rather than
649C<< foo($a < $b) >>. This happens when one of these operators is used in
650an unparenthesised argument:
651
652 < > <= >= lt gt le ge
653 == != <=> eq ne cmp ~~
654 &
655 | ^
656 &&
657 || //
658 .. ...
659 ?:
660 = += -= *= etc.
661
662=head2 Magic variables outside the main package
663
664In previous versions of Perl, magic variables like C<$!>, C<%SIG>, etc. would
665'leak' into other packages. So C<%foo::SIG> could be used to access signals,
666C<${"foo::!"}> (with strict mode off) to access C's C<errno>, etc.
667
668This was a bug, or an 'unintentional' feature, which caused various ill effects,
669such as signal handlers being wiped when modules were loaded, etc.
670
671This has been fixed (or the feature has been removed, depending on how you see
672it).
673
674=head2 Smart-matching against array slices
675
676Previously, the following code resulted in a successful match:
677
678 my @a = qw(a y0 z);
679 my @b = qw(a x0 z);
680 @a[0 .. $#b] ~~ @b;
681
682This odd behaviour has now been fixed [perl #77468].
683
684=head2 C API changes
685
686The first argument of the C API function C<Perl_fetch_cop_label> has changed
687from C<struct refcounted he *> to C<COP *>, to better insulate the user from
688implementation details.
689
690This API function was marked as "may change", and likely isn't in use outside
691the core. (Neither an unpacked CPAN, nor Google's codesearch, finds any other
692references to it.)
693
694=head2 Stringification of regexes has changed
695
696Default regular expression modifiers are now notated by using
697C<(?^...)>. Code relying on the old stringification will fail. The
698purpose of this is so that when new modifiers are added, such code will
699not have to change (after this one time), as the stringification will
700automatically incorporate the new modifiers.
701
702Code that needs to work properly with both old- and new-style regexes
703can avoid the whole issue by using (for Perls since 5.9.5):
704
705 use re qw(regexp_pattern);
706 my ($pat, $mods) = regexp_pattern($re_ref);
707
708where C<$re_ref> is a reference to a compiled regular expression. Upon
709return, C<$mods> will be a string containing all the non-default
710modifiers used when the regular expression was compiled, and C<$pattern>
711the actual pattern.
712
713If the actual stringification is important, or older Perls need to be
714supported, you can use something like the following:
715
716 # Accept both old and new-style stringification
717 my $modifiers = (qr/foobar/ =~ /\Q(?^/) ? '^' : '-xism';
718
719And then use C<$modifiers> instead of C<-xism>.
720
721=head2 Regular expressions retain their localeness when interpolated
722
723Regular expressions compiled under C<"use locale"> now retain this when
724interpolated into a new regular expression compiled outside a
725C<"use locale">, and vice-versa.
726
727Previously, a regular expression interpolated into another one inherited
728the localeness of the surrounding one, losing whatever state it
729originally had. This is considered a bug fix, but may trip up code that
730has come to rely on the incorrect behavior.
731
732=head2 Directory handles not copied to threads
733
734On systems that do not have a C<fchdir> function, newly-created threads no
735longer inherit directory handles from their parent threads. Such programs
736would probably have crashed anyway [perl #75154].
737
738=head2 Negation treats strings differently from before
739
740The unary negation operator C<-> now treats strings that look like numbers
741as numbers [perl #57706].
742
743=head2 Negative zero
744
745Negative zero (-0.0), when converted to a string, now becomes "0" on all
746platforms. It used to become "-0" on some, but "0" on others.
747
748If you still need to determine whether a zero is negative, use
749C<sprintf("%g", $zero) =~ /^-/> or the L<Data::Float> module on CPAN.
750
751=head2 Dereferencing typeglobs
752
753If you assign a typeglob to a scalar variable:
754
755 $glob = *foo;
756
757the glob that is copied to C<$glob> is marked with a special flag
758indicating that the glob is just a copy. This allows subsequent assignments
759to C<$glob> to overwrite the glob. The original glob, however, is
760immutable.
761
762Many Perl operators did not distinguish between these two types of globs.
763This would result in strange behaviour in edge cases: C<untie $scalar>
764would do nothing if the last thing assigned to the scalar was a glob
765(because it treated it as C<untie *$scalar>, which unties a handle).
766Assignment to a glob slot (e.g., C<(*$glob) = \@some_array>) would simply
767assign C<\@some_array> to C<$glob>.
768
769To fix this, the C<*{}> operator (including the C<*foo> and C<*$foo> forms)
770has been modified to make a new immutable glob if its operand is a glob
771copy. Various operators that make a distinction between globs and scalars
772have been modified to treat only immutable globs as globs.
773
774This causes an incompatible change in code that assigns a glob to the
775return value of C<*{}> when that operator was passed a glob copy. Take the
776following code, for instance:
777
778 $glob = *foo;
779 *$glob = *bar;
780
781The C<*$glob> on the second line returns a new immutable glob. That new
782glob is made an alias to C<*bar>. Then it is discarded. So the second
783assignment has no effect.
784
785It also means that C<tie $handle> will now tie C<$handle> as a scalar, even
786if it has had a glob assigned to it.
787
788The upside to this incompatible change is that bugs [perl #77496],
789[perl #77502], [perl #77508], [perl #77688], and [perl #77812],
790and maybe others, too, have been fixed.
791
792See L<http://rt.perl.org/rt3/Public/Bug/Display.html?id=77810> for even
793more detail.
794
795=head2 Clearing stashes
796
797Stash list assignment C<%foo:: = ()> used to make the stash anonymous
798temporarily while it was being emptied. Consequently, any of its
799subroutines referenced elsewhere would become anonymous (showing up as
800"(unknown)" in C<caller>). Now they retain their package names, such that
801C<caller> will return the original sub name if there is still a reference
802to its typeglob, or "foo::__ANON__" otherwise [perl #79208].
803
804=head2 C<:=> is now a syntax error
805
806Previously C<my $pi := 4;> was exactly equivalent to C<my $pi : = 4;>,
807with the C<:> being treated as the start of an attribute list, ending before
808the C<=>. The use of C<:=> to mean C<: => was deprecated in 5.12.0, and is now
809a syntax error. This will allow the future use of C<:=> as a new token.
810
811We find no Perl 5 code on CPAN using this construction, outside the core's
812tests for it, so we believe that this change will have very little impact on
813real-world codebases.
814
815If it is absolutely necessary to have empty attribute lists (for example,
816because of a code generator) then avoid the error by adding a space before
817the C<=>.
818
819=head2 Run-time code block in regular expressions
820
821Code blocks in regular expressions (C<(?{...})> and C<(??{...})>) used not
822to inherit any pragmata (strict, warnings, etc.) if the regular expression
823was compiled at run time as happens in cases like these two:
824
825 use re 'eval';
826 $foo =~ $bar; # when $bar contains (?{...})
827 $foo =~ /$bar(?{ $finished = 1 })/;
828
829This was a bug, which has now been fixed. But it has the potential to break
830any code that was relying on this bug.
831
832=head2 All objects are destroyed
833
834It used to be possible to prevent a destructor from being called during
835global destruction by artificially increasing the reference count of an
836object.
837
838Now such objects I<will> will be destroyed, as a result of a bug fix
839[perl #81230].
840
841This has the potential to break some XS modules. (In fact, it break some.
842See L</Known Problems>, below.)
843
844=head2 Most C<\p{}> properties are now immune from case-insensitive matching
845
846For most Unicode properties, it doesn't make sense to have them match
847differently under C</i> case-insensitive matching than not. And doing
848so leads to unexpected results and potential security holes. For
849example
850
851 m/\p{ASCII_Hex_Digit}+/i
852
853could previously match non-ASCII characters because of the Unicode
854matching rules. There were a number of bugs in this feature until an
855earlier release in the 5.13 series. Now this release reverts, and
856removes the feature completely except for the few properties where
857people have come to expect it, namely the ones where casing is an
858integral part of their functionality, such as C<m/\p{Uppercase}/i> and
859C<m/\p{Lowercase}/i>, both of which match the exact same code points,
860namely those matched by C<m/\p{Cased}/i>. Details are in
861L<perlrecharclass/Unicode Properties>.
862
863User-defined property handlers that need to match differently under
864C</i> must change to read the new boolean parameter passed it which is
865non-zero if case-insensitive matching is in effect; 0 if not. See
866L<perluniprops/User-Defined Character Properties>.
867
868=head2 regex: \p{} in pattern implies Unicode semantics
869
870Now, a Unicode property match specified in the pattern will indicate
871that the pattern is meant for matching according to Unicode rules
872(e40e74f)
873
874=head2 add GvCV_set() and GvGP_set() macros and change GvGP()
875
876This allows a future commit to eliminate some backref magic between GV
877and CVs, which will require complete control over assignment to the
878gp_cv slot.
879
880If you've been using GvGP() in lvalue context this change will break
881your code, you should use GvGP_set() instead. (c43ae56)
882
883=head2 _swash_inversion_hash is no longer exported as part of the API
884
885This function shouldn't be called from XS code. (4c2e113)
886
887=head2 Unreferenced objects in global destruction
888
889The fix for [perl #36347], which made sure that destructors were called on
890unreferenced objects, broke the tests for three CPAN modules, which
891apparently rely on the bug.
892
893To provide more time for fixing them (as this is such a minor bug), we
894have reverted the fix until after perl 5.14.0.
895
896This resolves [perl #82542] and other related tickets.
897
898=head2 C<close> on shared pipes
899
900The C<close> function no longer waits for the child process to exit if the
901underlying file descriptor is still in use by another thread, to avoid
902deadlocks. It returns true in such cases.
903
904=head2 Passing references to warn()
905
906An earlier Perl 5.13.x release changed C<warn($ref)> to leave the reference
907unchanged, allowing C<$SIG{__WARN__}> handlers to access the original
908reference. But this stopped warnings that were references from having the
909file and line number appended even when there was no C<$SIG{__WARN__}>
910handler in place.
911
912Now C<warn> checks for the presence of such a handler and, if there is
913none, proceeds to stringify the reference and append the file and line
914number. This allows simple uses of C<warn> for debugging to continue to
915work as they did before.
916
917=head1 Deprecations
918
919The following items are now deprecated.
920
921=over 4
922
923=item C<Perl_ptr_table_clear>
924
925C<Perl_ptr_table_clear> is no longer part of Perl's public API. Calling it now
926generates a deprecation warning, and it will be removed in a future
927release.
928
929=item *
930
931Omitting a space between a regex pattern or pattern modifiers and the following
932word is deprecated. For example, C<< m/foo/sand $bar >> will still be parsed
933as C<< m/foo/s and $bar >> but will issue a warning.
934
935=back
936
937=head2 Omitting a space between a regular expression and subsequent word
938
939Omitting a space between a regex pattern or pattern modifiers and the
940following word is deprecated. Deprecation for regular expression
941I<matches> was added in Perl 5.13.2. In this release, the deprecation
942is extended to regular expression I<substitutions>. For example,
943C<< s/foo/bar/sand $bar >> will still be parsed as
944C<< s/foo/bar/s and $bar >> but will issue a warning. (aa78b66)
945
946=head2 Deprecation warning added for deprecated-in-core .pl libs
947
948This is a mandatory warning, not obeying -X or lexical warning bits.
949The warning is modelled on that supplied by deprecate.pm for
950deprecated-in-core .pm libraries. It points to the specific CPAN
951distribution that contains the .pl libraries. The CPAN version, of
952course, does not generate the warning. (0111154)
953
954=head2 List assignment to C<$[>
955
956After assignment to C<$[> has been deprecated and started to give warnings in
957perl version 5.12.0, this version of perl also starts to emit a warning when
958assigning to C<$[> in list context. This fixes an oversight in 5.12.0.
959
960=head2 Use of qw(...) as parentheses
961
962Historically the parser fooled itself into thinking that C<qw(...)> literals
963were always enclosed in parentheses, and as a result you could sometimes omit
964parentheses around them:
965
966 for $x qw(a b c) { ... }
967
968The parser no longer lies to itself in this way. Wrap the list literal in
969parentheses, like:
970
971 for $x (qw(a b c)) { ... }
972
973=head2 C<\N{BELL}> is deprecated
974
975This is because Unicode is using that name for a different character.
976See L</Unicode Version 6.0 is now supported (mostly)> for more
977explanation.
978
979=head2 C<?PATTERN?> is deprecated
980
981C<?PATTERN?> (without the initial m) has been deprecated and now produces
982a warning. This is to allow future use of C<?> in new operators.
983The match-once functionality is still available in the form of C<m?PATTERN?>.
984
985=head2 C<sv_compile_2op()> is now deprecated
986
987The C<sv_compile_2op()> API function is now deprecated. Searches suggest
988that nothing on CPAN is using it, so this should have zero impact.
989
990It attempted to provide an API to compile code down to an optree, but failed
991to bind correctly to lexicals in the enclosing scope. It's not possible to
992fix this problem within the constraints of its parameters and return value.
993
994=head2 Tie functions on scalars holding typeglobs
995
996Calling a tie function (C<tie>, C<tied>, C<untie>) with a scalar argument
997acts on a file handle if the scalar happens to hold a typeglob.
998
999This is a long-standing bug that will be removed in Perl 5.16, as
1000there is currently no way to tie the scalar itself when it holds
1001a typeglob, and no way to untie a scalar that has had a typeglob
1002assigned to it.
1003
1004This bug was fixed in 5.13.7 but, because of the breakage it caused, the
1005fix has been reverted. Now there is a deprecation warning whenever a tie
1006function is used on a handle without an explicit C<*>.
1007
1008=over
1009
1010=item Deprecated Modules
1011
1012The following modules will be removed from the core distribution in a
1013future release, and should be installed from CPAN instead. Distributions
1014on CPAN which require these should add them to their prerequisites. The
1015core versions of these modules warnings will issue a deprecation warning.
1016
1017If you ship a packaged version of Perl, either alone or as part of a
1018larger system, then you should carefully consider the repercussions of
1019core module deprecations. You may want to consider shipping your default
1020build of Perl with packages for some or all deprecated modules which
1021install into C<vendor> or C<site> perl library directories. This will
1022inhibit the deprecation warnings.
1023
1024Alternatively, you may want to consider patching F<lib/deprecate.pm>
1025to provide deprecation warnings specific to your packaging system
1026or distribution of Perl, consistent with how your packaging system
1027or distribution manages a staged transition from a release where the
1028installation of a single package provides the given functionality, to
1029a later release where the system administrator needs to know to install
1030multiple packages to get that same functionality.
1031
1032You can silence these deprecation warnings by installing the modules
1033in question from CPAN. To install the latest version of all of them,
1034just install C<Task::Deprecations::5_14>.
1035
1036=over
1037
1038=item L<Devel::DProf>
1039
1040We strongly recommend that you install and used L<Devel::NYTProf> in
1041preference, as it offers significantly improved profiling and reporting.
1042
1043=back
1044
1045=back
1046
1047=head2 User-defined case-mapping
1048
1049This feature is being deprecated due to its many issues, as documented in
1050L<perlunicode/User-Defined Case Mappings (for serious hackers only)>.
1051It is planned to remove this feature in Perl 5.16. A CPAN module
1052providing improved functionality is being prepared for release by the
1053time 5.14 is.
1054
1055=head1 Performance Enhancements
1056
df91d470
FC
1057=head2 "safe signals" optimization
1058
1059Signal dispatch has been moved from the runloop into control ops. This
1060should give a few percent speed increase, and eliminates almost all of
1061the speed penalty caused by the introduction of "safe signals" in
10625.8.0. Signals should still be dispatched within the same statement as
1063they were previously - if this is not the case, or it is possible to
1064create uninterruptible loops, this is a bug, and reports are encouraged
1065of how to recreate such issues.
1066
1067=head2 Optimization of shift; and pop; calls without arguments
1068
1069Additional two OPs are not added anymore into op tree for shift and pop
1070calls without argument (when it works on C<@_>). Makes C<shift;> 5%
1071faster over C<shift @_;> on not threaded perl and 25% faster on threaded.
1072
1073=head2 Adjacent pairs of nextstate opcodes are now optimized away
1074
1075Previously, in code such as
1076
1077 use constant DEBUG => 0;
1078
1079 sub GAK {
1080 warn if DEBUG;
1081 print "stuff\n";
1082 }
1083
1084the ops for C<warn if DEBUG;> would be folded to a C<null> op (C<ex-const>), but
1085the C<nextstate> op would remain, resulting in a runtime op dispatch of
1086C<nextstate>, C<nextstate>, ...
1087
1088The execution of a sequence of C<nextstate> ops is indistinguishable from just
1089the last C<nextstate> op so the peephole optimizer now eliminates the first of
1090a pair of C<nextstate> ops, except where the first carries a label, since labels
1091must not be eliminated by the optimizer and label usage isn't conclusively known
1092at compile time.
1093
1094=head2 blah blah blah
1095
5076a392
FC
1096Only allocate entries for @_ on demand - this not only saves memory per
1097subroutine defined but should hopefully improve COW behaviour (77bac2).
1098
1099=head2 Multiple small improvements to threads
1100
1101The internal structures of threading now make fewer API calls and fewer
1102allocations, resulting in noticeably smaller object code. Additionally,
1103many thread context checks have been deferred so that they're only done
1104when required (although this is only possible for non-debugging builds).
1105
1106=head2 Size optimisations to SV and HV structures
1107
1108xhv_fill has been eliminated from struct xpvhv, saving 1 IV per hash and
1109on some systems will cause struct xpvhv to become cache aligned. To avoid
1110this memory saving causing a slowdown elsewhere, boolean use of HvFILL
1111now calls HvTOTALKEYS instead (which is equivalent) - so while the fill
1112data when actually required is now calculated on demand, the cases when
1113this needs to be done should be few and far between (f4431c .. fcd245).
1114
1115The order of structure elements in SV bodies has changed. Effectively,
1116the NV slot has swapped location with STASH and MAGIC. As all access to
1117SV members is via macros, this should be completely transparent. This
1118change allows the space saving for PVHVs documented above, and may reduce
1119the memory allocation needed for PVIVs on some architectures.
1120
1121=head2 Optimisation of regexp engine string comparison work
1122
1123The foldEQ_utf8 API function for case-insensitive comparison of strings (which
1124is used heavily by the regexp engine) was substantially refactored and
1125optimised - and its documentation much improved as a free bonus gift
1126(8b3587, e6226b).
1127
1128=head2 Memory consumption improvements to Exporter
1129
1130The @EXPORT_FAIL AV is no longer created unless required, hence neither is
1131the typeglob backing it - this saves about 200 bytes per Exporter using
1132package that doesn't use this functionality.
1133
1134=head2 blah blah blah
1135
1136There are several small optimizations to reduce CPU cache misses in various very
1137commonly used modules like C<warnings> and C<Carp> as well in accessing
1138file-handles for reading. (5.13.3)
1139
1140XXX These need to be changed to =head2 entries, or the entries above need
1141to change:
1142
1143=over 4
1144
1145=item *
1146
1147Make string appending 100 times faster
1148
1149When doing a lot of string appending, perl could end up allocating a lot more
1150memory than needed in a very inefficient way, if perl was configured to use the
1151system's C<malloc> implementation instead of its own.
1152
1153C<sv_grow>, which is what's being used to allocate more memory if necessary when
1154appending to a string, has now been taught how to round up the memory it
1155requests to a certain geometric progression, making it much faster on certain
1156platforms and configurations. On Win32, it's now about 100 times faster.
1157
1158=item *
1159
1160For weak references, the common case of just a single weak reference per
1161referent has been optimised to reduce the storage required. In this case it
1162saves the equivalent of one small perl array per referent.
1163
1164=item *
1165
1166C<XPV>, C<XPVIV>, and C<XPVNV> now only allocate the parts of the C<SV> body
1167they actually use, saving some space.
1168
1169=item *
1170
1171Scalars containing regular expressions now only allocate the part of the C<SV>
1172body they actually use, saving some space.
1173
1174=item *
1175
1176Compiling regular expressions has been made faster for the case where upgrading
1177the regex to utf8 is necessary but that isn't known when the compilation begins.
1178
1179=item *
1180
1181The bulk of the C<Tie::Hash::NamedCapture> module used to be in the perl
1182core. It has now been moved to an XS module, to reduce the overhead for
1183programs that do not use C<%+> or C<%->.
1184
1185=item *
1186
1187Eliminate C<PL_*> accessor functions under ithreads.
1188
1189When C<MULTIPLICITY> was first developed, and interpreter state moved into an
1190interpreter struct, thread and interpreter local C<PL_*> variables were defined
1191as macros that called accessor functions, returning the address of the value,
1192outside of the perl core. The intent was to allow members within the interpreter
1193struct to change size without breaking binary compatibility, so that bug fixes
1194could be merged to a maintenance branch that necessitated such a size change.
1195
1196However, some non-core code defines C<PERL_CORE>, sometimes intentionally to
1197bypass this mechanism for speed reasons, sometimes for other reasons but with
1198the inadvertent side effect of bypassing this mechanism. As some of this code is
1199widespread in production use, the result is that the core B<can't> change the
1200size of members of the interpreter struct, as it will break such modules
1201compiled against a previous release on that maintenance branch. The upshot is
1202that this mechanism is redundant, and well-behaved code is penalised by
1203it. Hence it can and should be removed.
1204
1205=item *
1206
1207When an object has many weak references to it, freeing that object
1208can under some some circumstances take O(N^2) time to free (where N is the
1209number of references). The number of circumstances has been reduced
1210[perl #75254]
1211
1212=item *
1213
1214An earlier optimisation to speed up C<my @array = ...> and
1215C<my %hash = ...> assignments caused a bug and was disabled in Perl 5.12.0.
1216
1217Now we have found another way to speed up these assignments [perl #82110].
1218
1219=back
1220
1221=head1 Modules and Pragmata
1222
1223=head2 New Modules and Pragmata
1224
1225=over 4
1226
1227=item *
1228
1229C<CPAN::Meta::YAML> 0.003 has been added as a dual-life module. It supports a
1230subset of YAML sufficient for reading and writing META.yml and MYMETA.yml files
1231included with CPAN distributions or generated by the module installation
1232toolchain. It should not be used for any other general YAML parsing or
1233generation task.
1234
1235=item *
1236
1237C<CPAN::Meta> version 2.110440 has been added as a dual-life module. It
1238provides a standard library to read, interpret and write CPAN distribution
1239metadata files (e.g. META.json and META.yml) which describes a
1240distribution, its contents, and the requirements for building it and
1241installing it. The latest CPAN distribution metadata specification is
1242included as C<CPAN::Meta::Spec> and notes on changes in the specification
1243over time are given in C<CPAN::Meta::History>.
1244
1245=item *
1246
1247C<HTTP::Tiny> 0.010 has been added as a dual-life module. It is a very
1248small, simple HTTP/1.1 client designed for simple GET requests and file
1249mirroring. It has has been added to enable CPAN.pm and CPANPLUS to
1250"bootstrap" HTTP access to CPAN using pure Perl without relying on external
1251binaries like F<curl> or F<wget>.
1252
1253=item *
1254
1255C<JSON::PP> 2.27105 has been added as a dual-life module, for the sake of
1256reading F<META.json> files in CPAN distributions.
1257
1258=item *
1259
1260C<Module::Metadata> 1.000003 has been added as a dual-life module. It gathers
1261package and POD information from Perl module files. It is a standalone module
1262based on Module::Build::ModuleInfo for use by other module installation
1263toolchain components. Module::Build::ModuleInfo has been deprecated in
1264favor of this module instead.
1265
1266=item *
1267
1268C<Perl::OSType> 1.002 has been added as a dual-life module. It maps Perl
1269operating system names (e.g. 'dragonfly' or 'MSWin32') to more generic types
1270with standardized names (e.g. "Unix" or "Windows"). It has been refactored
1271out of Module::Build and ExtUtils::CBuilder and consolidates such mappings into
1272a single location for easier maintenance.
1273
1274=item *
1275
1276The following modules were added by the C<Unicode::Collate>
1277upgrade. See below for details.
1278
1279C<Unicode::Collate::CJK::Big5>
1280
1281C<Unicode::Collate::CJK::GB2312>
1282
1283C<Unicode::Collate::CJK::JISX0208>
1284
1285C<Unicode::Collate::CJK::Korean>
1286
1287C<Unicode::Collate::CJK::Pinyin>
1288
1289C<Unicode::Collate::CJK::Stroke>
1290
1291=item *
1292
1293C<Version::Requirements> version 0.101020 has been added as a dual-life
1294module. It provides a standard library to model and manipulates module
1295prerequisites and version constraints as defined in the L<CPAN::Meta::Spec>.
1296
1297=back
1298
1299=head2 Updated Modules and Pragmata
1300
1301=over 4
1302
1303=item *
1304
1305XXX Where does this go in the list?
1306
1307Perl 4 C<.pl> libraries
1308
1309These historical libraries have been minimally modified to avoid using
1310C<$[>. This is to prepare them for the deprecation of C<$[>.
1311
1312=item *
1313
1314C<Archive::Extract> has been upgraded from version 0.38 to 0.48.
1315
1316Updates since 0.38 include: a safe print method that guards
1317Archive::Extract from changes to $\; a fix to the tests when run in core
1318perl; support for TZ files; and a modification for the lzma logic to favour
1319IO::Uncompress::Unlzma
1320
1321Resolves an issue with NetBSD-current and its new unzip
1322executable.
1323
1324=item *
1325
1326C<Archive::Tar> has been upgraded from version 1.54 to 1.76.
1327
1328Important changes since 1.54 include: compatibility with busybox
1329implementations of tar; a fix so that C<write()> and C<create_archive()>
1330close only handles they opened; and a bug was fixed regarding the exit code
1331of extract_archive. (afabe0e)
1332
1333Among other things, the new version adds a new option to C<ptar> to allow safe
1334creation of tarballs without world-writable files on Windows, allowing those
1335archives to be uploaded to CPAN.
1336
1337This adds the ptargrep utility for using regular expressions against
1338the contents of files in a tar archive.
1339
1340Skip extracting pax extended headers.
1341
1342=item *
1343
1344C<autodie> has been upgraded from version 2.06_01 to 2.1001.
1345
1346=item *
1347
1348C<B> has been upgraded from version 1.23 to 1.27.
1349
1350It no longer crashes when taking apart a C<y///> containing characters
1351outside the octet range or compiled in a C<use utf8> scope.
1352
1353The size of the shared object has been reduced by about 40%, with no
1354reduction in functionality.
1355
1356=item *
1357
1358C<B::Concise> has been upgraded from version 0.78 to 0.82.
1359
1360B::Concise marks rv2sv, rv2av and rv2hv ops with the new OPpDEREF flag
1361as "DREFed".
1362
1363It no longer produces mangled output with the C<-tree> option
1364[perl #80632].
1365
1366=item *
1367
1368C<B::Debug> has been upgraded from version 1.12 to 1.16.
1369
1370=item *
1371
1372C<B::Deparse> has been upgraded from version 0.96 to 1.02.
1373
1374A bug has been fixed when deparsing a nextstate op that has both a
1375change of package (relative to the previous nextstate), or a change of
1376C<%^H> or other state, and a label. Previously the label was emitted
1377first, leading to syntactically invalid output because a label is not
1378permitted immediately before a package declaration, B<BEGIN> block,
1379or some other things. Now the label is emitted last.
1380
1381The 'no 5.13.2' or similar form is now correctly handled by B::Deparse.
1382
1383B::Deparse now properly handles the code that applies a conditional
1384pattern match against implicit C<$_> as it was fixed in [perl #20444].
1385
1386It fixes deparsing of C<our> followed by a variable with funny characters
1387(as permitted under the C<utf8> pragma) [perl #33752].
1388
1389=item *
1390
1391C<B::Lint> has been upgraded from version 1.11_01 to 1.12.
1392
1393=item *
1394
1395C<base> has been upgraded from version 2.15 to 2.16.
1396
1397=item *
1398
1399C<bignum> has been upgraded from version 0.23 to 0.25.
1400
1401=item *
1402
1403C<blib> has been upgraded from version 1.04 to 1.06.
1404
1405=item *
1406
1407C<Carp> has been upgraded from version 1.18 to 1.19.
1408
1409L<Carp> now detects incomplete L<caller()|perlfunc/"caller EXPR"> overrides and
1410avoids using bogus C<@DB::args>. To provide backtraces, Carp relies on
1411particular behaviour of the caller built-in. Carp now detects if other code has
1412overridden this with an incomplete implementation, and modifies its backtrace
1413accordingly. Previously incomplete overrides would cause incorrect values in
1414backtraces (best case), or obscure fatal errors (worst case)
1415
1416This fixes certain cases of C<Bizarre copy of ARRAY> caused by modules
1417overriding C<caller()> incorrectly.
1418
1419It now avoids using regular expressions that cause perl to
1420load its Unicode tables, in order to avoid the 'BEGIN not safe after
1421errors' error that will ensue if there has been a syntax error
1422[perl #82854].
1423
1424=item *
1425
1426C<CGI> has been upgraded from version 3.48 to 3.51.
1427
1428This provides the following security fixes: the MIME boundary in
1429multipart_init is now random and improvements to the handling of
1430newlines embedded in header values.
1431
1432The documentation for param_fetch() has been corrected and clarified.
1433
1434=item *
1435
1436C<charnames> has been upgraded from version 1.07 to 1.10.
1437
1438C<viacode()> is now significantly faster.
1439
1440=item *
1441
1442C<Compress::Raw::Bzip2> has been upgraded from version 2.024 to 2.033.
1443
1444Updated to use bzip2 1.0.6
1445
1446=item *
1447
1448C<Compress::Raw::Zlib> has been upgraded from version 2.024 to 2.033.
1449
1450=item *
1451
1452C<Compress::Zlib> has been upgraded from version 2.024 to 2.027.
1453
1454=item *
1455
1456C<CPAN> has been upgraded from version 1.94_56 to 1.94_63.
1457
1458=over 4
1459
1460=item * release 1.94_57
1461
1462=item * bugfix: treat modules correctly that are deprecated in perl 5.12.
1463
1464=item * bugfix: RT #57482 and #57788 revealed that configure_requires
1465implicitly assumed build_requires instead of normal requires. (Reported
1466by Andrew Whatson and Father Chrysostomos respectively)
1467
1468=item * testfix: solaris should run the tests without expect because (some?)
1469solaris have a broken expect
1470
1471=item * testfix: run tests with cache_metadata off to prevent spill over
1472effects from previous test runs
1473
1474=back
1475
1476Includes support for META.json and MYMETA.json.
1477
1478=item *
1479
1480C<CPANPLUS> has been upgraded from version 0.90 to 0.9102.
1481
1482Fixed the shell test to skip if test is not being run under a terminal;
1483resolved the issue where a prereq on Config would not be recognised as a
1484core module.
1485
1486Includes support for META.json and MYMETA.json and a change to
1487using Digest::SHA for CPAN checksums.
1488
1489=item *
1490
1491C<CPANPLUS::Dist::Build> has been upgraded from version 0.46 to 0.54.
1492
1493=item *
1494
1495C<Cwd> has been upgraded from version 3.31 to 3.36.
1496
1497=item *
1498
1499C<Data::Dumper> has been upgraded from version 2.125 to 2.130_02.
1500
4ed2cea4
FC
1501The indentation used to be off when C<$Data::Dumper::Terse> was set. This
1502has been fixed [perl #73604].
1503
5076a392
FC
1504This fixes a crash when using custom sort functions that might cause the stack
1505to change.
1506
1507C<Dumpxs> no longer crashes with globs returned by C<*$io_ref>
1508[perl #72332].
1509
1510=item *
1511
1512C<DB_File> has been upgraded from version 1.820 to 1.821.
1513
1514=item *
1515
1516C<deprecate> has been upgraded from version 0.01 to 0.02.
1517
1518=item *
1519
1520C<Devel::DProf> has been upgraded from version 20080331.00 to 20110228.00.
1521
1522Merely loading C<Devel::DProf> now no longer triggers profiling to start.
1523C<use Devel::DProf> and C<perl -d:DProf ...> still behave as before and start
1524the profiler.
1525
1526NOTE: C<Devel::DProf> is deprecated and will be removed from a future
1527version of Perl. We strongly recommend that you install and use
1528L<Devel::NYTProf> instead, as it offers significantly improved
1529profiling and reporting.
1530
1531=item *
1532
1533C<Devel::Peek> has been upgraded from version 1.04 to 1.06.
1534
1535=item *
1536
1537C<Devel::SelfStubber> has been upgraded from version 1.03 to 1.05.
1538
1539=item *
1540
1541C<diagnostics> has been upgraded from version 1.19 to 1.22.
1542
1543It now renders pod links slightly better, and has been taught to find
1544descriptions for messages that share their descriptions with other
1545messages.
1546
1547=item *
1548
1549C<Digest::MD5> has been upgraded from version 2.39 to 2.51.
1550
1551It is now safe to use this module in combination with threads.
1552
1553=item *
1554
1555C<Digest::SHA> has been upgraded from version 5.47 to 5.61.
1556
1557C<shasum> now more closely mimics C<sha1sum>/C<md5sum>.
1558
1559C<Addfile> accepts all POSIX filenames.
1560
1561New SHA-512/224 and SHA-512/256 transforms ref. NIST Draft FIPS 180-4 (February 2011)
1562
1563=item *
1564
1565C<Dumpvalue> has been upgraded from version 1.13 to 1.15.
1566
1567=item *
1568
1569C<DynaLoader> has been upgraded from version 1.10 to 1.12.
1570
1571It fixes a buffer overflow when passed a very long file name.
1572
1573It no longer inherits from AutoLoader; hence it no longer
1574produces weird error messages for unsuccessful method calls on classes that
1575inherit from DynaLoader [perl #84358].
1576
1577=item *
1578
1579C<Encode> has been upgraded from version 2.39 to 2.42.
1580
1581Now, all 66 Unicode non-characters are treated the same way U+FFFF has
1582always been treated; if it was disallowed, all 66 are disallowed; if it
1583warned, all 66 warn.
1584
1585=item *
1586
1587C<Env> has been upgraded from version 1.01 to 1.02.
1588
1589=item *
1590
1591C<Errno> has been upgraded from version 1.11 to 1.13.
1592
1593The implementation of C<Errno> has been refactored to use about 55% less memory.
1594There should be no user-visible changes.
1595
1596On some platforms with unusual header files, like Win32/gcc using mingw64
1597headers, some constants which weren't actually error numbers have been exposed
1598by C<Errno>. This has been fixed [perl #77416].
1599
1600=item *
1601
1602C<Exporter> has been upgraded from version 5.64_01 to 5.64_03.
1603
1604Exporter no longer overrides C<$SIG{__WARN__}> [perl #74472]
1605
1606=item *
1607
1608C<ExtUtils::CBuilder> has been upgraded from 0.27 to 0.280201.
1609
1610Handle C and C++ compilers separately.
1611
1612Preserves exit status on VMS.
1613
1614=item *
1615
1616C<ExtUtils::Command> has been upgraded from version 1.16 to 1.17.
1617
1618=item *
1619
1620C<ExtUtils::Constant> has been upgraded from 0.22 to 0.23.
1621
1622The C<AUTOLOAD> helper code generated by C<ExtUtils::Constant::ProxySubs>
1623can now C<croak> for missing constants, or generate a complete C<AUTOLOAD>
1624subroutine in XS, allowing simplification of many modules that use it.
1625(C<Fcntl>, C<File::Glob>, C<GDBM_File>, C<I18N::Langinfo>, C<POSIX>, C<Socket>)
1626
1627C<ExtUtils::Constant::ProxySubs> can now optionally push the names of all
1628constants onto the package's C{@EXPORT_OK}. This has been used to replace
1629less space-efficient code in C<B>, helping considerably shrink the size of its
1630shared object.
1631
1632=item *
1633
1634C<ExtUtils::Constant::Utils> has been upgraded from 0.02 to 0.03.
1635
1636Refactoring and fixing of backcompat code, preparing for resynchronisation
1637with CPAN.
1638
1639=item *
1640
1641C<ExtUtils::Embed> has been upgraded from 1.28 to 1.30.
1642
1643=item *
1644
1645C<ExtUtils::MakeMaker> has been upgraded from version 6.56 to 6.57_05.
1646
1647=item *
1648
1649C<ExtUtils::Manifest> has been upgraded from version 1.57 to 1.58.
1650
1651=item *
1652
1653C<ExtUtils::ParseXS> has been upgraded from 2.21 to 2.2208.
1654
1655=item *
1656
1657C<Fcntl> has been upgraded from 1.06 to 1.11.
1658
1659=item *
1660
1661C<File::Copy> has been downgraded from version 2.17 to 2.21.
1662
1663An extra stanza was added explaining behaviours when the copy destination
1664already exists and is a directory.
1665
1666=item *
1667
1668C<File::DosGlob> has been upgraded from version 1.01 to 1.03.
1669
1670It allows patterns containing literal parentheses (they no longer need to
1671be escaped). On Windows, it no longer adds an extra F<./> to the file names
1672returned when the pattern is a relative glob with a drive specification,
1673like F<c:*.pl> [perl #71712].
1674
1675=item *
1676
1677C<File::Fetch> has been upgraded from version 0.24 to 0.32.
1678
1679C<HTTP::Lite> is now supported for 'http' scheme.
1680
1681The C<fetch> utility is supported on FreeBSD, NetBSD and
1682Dragonfly BSD for the C<http> and C<ftp> schemes.
1683
1684=item *
1685
1686C<File::Find> has been upgraded from version 1.15 to 1.18.
1687
1688It improves handling of backslashes on Windows, so that paths such as
1689F<c:\dir\/file> are no longer generated [perl #71710].
1690
1691=item *
1692
1693C<feature> has been upgraded from 1.16 to 1.19.
1694
1695Documentation and test updates for the C<unicode_strings> feature.
1696See L</Full functionality for C<use feature 'unicode_strings'>>.
1697
1698=item *
1699
1700C<File::CheckTree> has been upgraded from 4.4 to 4.41.
1701
1702=item *
1703
1704C<File::Glob> has been upgraded from 1.07 to 1.11.
1705
1706=item *
1707
1708C<File::stat> has been upgraded from 1.02 to 1.04.
1709
1710The C<-x> and C<-X> file test operators now work correctly under the root
1711user.
1712
1713=item *
1714
1715C<Filter::Simple> has been upgraded from version 0.84 to 0.85.
1716
1717=item *
1718
1719C<GDBM_File> has been upgraded from 1.10 to 1.13.
1720
1721This fixes a memory leak when DBM filters are used.
1722
1723=item *
1724
1725C<Hash::Util> has been upgraded from 0.07 to 0.10.
1726
1727Hash::Util now enables "no warnings 'uninitialized'" to suppress spurious
1728warnings from undefined hash values (RT #74280).
1729
1730=item *
1731
1732C<Hash::Util::FieldHash> has been upgraded from 1.04 to 1.07.
1733
1734=item *
1735
1736C<I18N::Collate> has been upgraded from 1.01 to 1.02.
1737
1738=item *
1739
1740C<I18N::Langinfo> has been upgraded from version 0.03 to 0.07.
1741
1742C<langinfo()> now defaults to using C<$_> if there is no argument given, just
1743like the documentation always claimed it did.
1744
1745=item *
1746
1747C<I18N::LangTags> has been upgraded from version 0.35 to 0.35_01.
1748
1749=item *
1750
1751C<if> has been upgraded from version 0.05 to 0.0601.
1752
1753=item *
1754
1755C<IO> has been upgraded from version 1.25_02 to 1.25_04.
1756
1757=item *
1758
1759The IO-Compress distribution has been upgraded from version 2.024 to 2.033.
1760
1761=item *
1762
1763C<IO::Select> has been upgraded from version 1.17 to 1.18.
1764
1765It now allows IO::Handle objects (and objects in derived classes) to be
1766removed from an IO::Select set even if the underlying file descriptor is
1767closed or invalid.
1768
1769=item *
1770
1771C<IO::Socket> has been upgraded from version 1.31 to 1.32.
1772
1773C<getsockopt> and C<setsockopt> are now documented.
1774
1775=item *
1776
1777C<IPC::Cmd> has been upgraded from version 0.54 to 0.68.
1778
1779Resolves an issue with splitting Win32 command lines.
1780
1781=item *
1782
1783C<IPC::Open3> has been upgraded from 1.05 to 1.08.
1784
4ed2cea4
FC
1785C<open3> now produces an error if the C<exec> call fails, allowing this
1786condition to be distinguished from a child process that exited with a
1787non-zero status [perl #72016].
1788
5076a392
FC
1789The internal C<xclose> routine now knows how to handle file descriptors, as
1790documented, so duplicating STDIN in a child process using its file
1791descriptor now works [perl #76474].
1792
1793=item *
1794
1795C<IPC::SysV> has been upgraded from version 2.01 to 2.03.
1796
1797=item *
1798
1799C<lib> has been upgraded from version 0.62 to 0.63.
1800
1801=item *
1802
1803The Locale-Codes distribution has been upgraded from version 2.07 to 3.16.
1804
1805Locale::Country, Locale::Language and Locale::Currency were updated from
18063.12 to 3.13 of the Locale-Codes distribution to include locale code changes.
1807
1808Adds some codes.
1809
1810=item *
1811
1812C<Locale::Maketext> has been upgraded from version 1.14 to 1.17.
1813
1814Locale::Maketext guts have been merged back into the main module
1815and adds external cache support
1816
1817It fixes an infinite loop in C<Locale::Maketext::Guts::_compile()> when
1818working with tainted values (CPAN RT #40727).
1819
1820C<< ->maketext >> calls will now backup and restore C<$@> so that error
1821messages are not suppressed (CPAN RT #34182).
1822
1823=item *
1824
1825C<Log::Message> has been upgraded from version 0.02 to 0.04.
1826
1827=item *
1828
1829C<Log::Message::Simple> has been upgraded from version 0.06 to 0.08.
1830
1831=item *
1832
1833C<Math::BigInt> has been upgraded from version 1.89_01 to 1.994.
1834
1835This fixes, among other things, incorrect results when computing binomial
1836coefficients [perl #77640].
1837
1838This prevents C<sqrt($int)> from crashing under C<use bigrat;>
1839[perl #73534].
1840
1841=item *
1842
1843C<Math::BigInt::FastCalc> has been upgraded from version 0.19 to 0.28.
1844
1845=item *
1846
1847C<Math::BigRat> has been upgraded from version 0.24 to 0.26_01.
1848
1849=item *
1850
1851C<Memoize> has been upgraded from version 1.01_03 to 1.02.
1852
1853=item *
1854
1855C<MIME::Base64> has been upgraded from 3.08 to 3.13.
1856
1857Includes new functions to calculate the length of encoded and decoded
1858base64 strings.
1859
1860Now provides C<encode_base64url> and C<decode_base64url> functions to process
1861the base64 scheme for "URL applications".
1862
1863=item *
1864
1865C<Module::Build> has been upgraded from version 0.3603 to 0.3800.
1866
1867A notable change is the deprecation of several modules.
1868Module::Build::Version has been deprecated and Module::Build now relies
1869directly upon L<version>. Module::Build::ModuleInfo has been deprecated in
1870favor of a standalone copy of it called L<Module::Metadata>.
1871Module::Build::YAML has been deprecated in favor of L<CPAN::Meta::YAML>.
1872
1873Module::Build now also generates META.json and MYMETA.json files
1874in accordance with version 2 of the CPAN distribution metadata specification,
1875L<CPAN::Meta::Spec>. The older format META.yml and MYMETA.yml files are
1876still generated, as well.
1877
1878=item *
1879
1880C<Module::CoreList> has been upgraded from version 2.29 to XXX.
1881
1882Besides listing the updated core modules of this release, it also stops listing
1883the C<Filespec> module. That module never existed in core. The scripts
1884generating C<Module::CoreList> confused it with C<VMS::Filespec>, which actually
1885is a core module, since the time of perl 5.8.7.
1886
1887=item *
1888
1889C<Module::Load> has been upgraded from version 0.16 to 0.18.
1890
1891=item *
1892
1893C<Module::Load::Conditional> has been upgraded from version 0.34 to 0.40.
1894
1895=item *
1896
1897C<Module::Metadata> has been upgraded from version 1.000003 to 1.000004.
1898
1899XXX This is not listed in corelist for 5.12.0. When was it added?
1900
1901=item *
1902
1903C<mro> has been upgraded from version 1.02 to 1.06.
1904
1905C<next::method> I<et al.> now take into account that every class inherits
1906from UNIVERSAL [perl #68654].
1907
1908=item *
1909
1910C<NDBM_File> has been upgraded from 1.08 to 1.11.
1911
1912This fixes a memory leak when DBM filters are used.
1913
1914=item *
1915
1916C<NEXT> has been upgraded from version 0.64 to 0.65.
1917
1918=item *
1919
1920C<ODBM_File> has been upgraded from 1.08 to 1.09.
1921
1922This fixes a memory leak when DBM filters are used.
1923
1924=item *
1925
1926C<Net::Ping> has been upgraded from 2.36 to 2.37.
1927
1928=item *
1929
1930C<ODBM_File> has been upgraded from 1.07 to 1.10.
1931
1932=item *
1933
1934C<Object::Accessor> has been upgraded from version 0.36 to 0.38.
1935
1936=item *
1937
1938C<open> has been upgraded from version 1.07 to 1.08.
1939
1940=item *
1941
1942C<Opcode> has been upgraded from 1.15 to 1.18.
1943
1944=item *
1945
1946C<overload> has been upgraded from 1.11 to 1.12.
1947
1948C<overload::Method> can now handle subroutines that are themselves blessed
1949into overloaded classes [perl #71998].
1950
1951Avoid a taint problem in use of sprintf.
1952
1953The documentation has greatly improved. See L</Documentation> below.
1954
1955=item *
1956
1957C<Params::Check> has been upgraded from version 0.26 to 0.28.
1958
1959=item *
1960
1961C<parent> has been upgraded from version 0.223 to 0.225.
1962
1963=item *
1964
1965C<Parse::CPAN::Meta> has been upgraded from version 1.40 to 1.4401.
1966
1967The latest Parse::CPAN::Meta can now read YAML or JSON files using
1968L<CPAN::Meta::YAML> and L<JSON::PP>, which are now part of the Perl core.
1969
1970=item *
1971
1972The PathTools distribution has been upgraded from version 3.31 to 3.34.
1973
1974Various issues in L<File::Spec::VMS> have been fixed. (5.13.4)
1975
1976=item *
1977
1978C<PerlIO::encoding> has been upgraded from 0.12 to 0.14.
1979
1980=item *
1981
1982C<PerlIO::scalar> has been upgraded from 0.07 to 0.11.
1983
1984A C<read> after a C<seek> beyond the end of the string no longer thinks it
1985has data to read [perl #78716].
1986
1987=item *
1988
1989C<PerlIO::via> has been upgraded from 0.09 to 0.11.
1990
1991=item *
1992
1993The podlators distribution has been upgraded from version 2.3.1 to 2.4.0.
1994
1995=item *
1996
1997C<Pod::LaTeX> has been upgraded from version 0.58 to 0.59.
1998
1999=item *
2000
2001C<Pod::Simple> has been upgraded from 3.14 to 3.15
2002
2003Includes various fixes to C<HTML> and C<XHTML> handling.
2004
2005=item *
2006
2007C<POSIX> has been upgraded from 1.19 to 1.23.
2008
2009It now includes constants for POSIX signal constants.
2010
2011=item *
2012
2013C<re> has been upgraded from version 0.11 to 0.15.
2014
2015New C<use re "/flags"> pragma
2016
2017Enforce that C</d>, C</u>, and C</l> are mutually exclusive.
2018
2019C<re> has been upgraded from version 0.16 to 0.17.
2020
2021It now supports the double-a flag: C<use re '/aa';>
2022
2023The C<regmust> function used to crash when called on a regular expression
2024belonging to a pluggable engine. Now it has been disabled for those.
2025
2026C<regmust> no longer leaks memory.
2027
2028=item *
2029
2030C<Safe> has been upgraded from version 2.25 to 2.29.
2031
2032This fixes a possible infinite loop when looking for coderefs.
2033
2034It adds C<&version::vxs::VCMP> to the default share.
2035
2036=item *
2037
2038C<SDBM_File> has been upgraded from 1.06 to 1.08.
2039
2040=item *
2041
2042C<SelfLoader> has been upgraded from 1.17 to 1.18.
2043
2044It now works in taint mode [perl #72062].
2045
2046=item *
2047
2048C<sigtrap> has been upgraded from version 1.04 to 1.05.
2049
2050It no longer tries to modify read-only arguments when generating a
2051backtrace [perl #72340].
2052
2053=item *
2054
2055C<Socket> has been upgraded from version 1.87 to XXX.
2056
2057It has several new functions for handling IPv6 addresses. (from 5.13.8)
2058
2059It provides new affordances for IPv6,
2060including implementations of the C<Socket::getaddrinfo()> and
2061C<Socket::getnameinfo()> functions, along with related constants.
2062
2063=item *
2064
2065C<Storable> has been upgraded from version 2.22 to 2.27.
2066
2067Includes performance improvement for overloaded classes.
2068
2069=item *
2070
2071C<Storable> has been upgraded from 2.24 to 2.25.
2072
2073This adds support for serialising code references that contain UTF-8 strings
2074correctly. The Storable minor version number changed as a result, meaning that
2075Storable users who set C<$Storable::accept_future_minor> to a C<FALSE> value
2076will see errors (see L<Storable/FORWARD COMPATIBILITY> for more details).
2077
2078Freezing no longer gets confused if the Perl stack gets reallocated
2079during freezing [perl #80074].
2080
2081=item *
2082
2083C<Sys::Hostname> has been upgraded from 1.11 to 1.14.
2084
2085=item *
2086
2087C<Term::ANSIColor> has been upgraded from version 2.02 to 3.00.
2088
2089=item *
2090
2091C<Term::UI> has been upgraded from version 0.20 to 0.26.
2092
2093=item *
2094
2095C<Test::Harness> has been upgraded from version 3.17 to 3.23.
2096
2097The core update from Test-Harness 3.17 to 3.21 fixed some things, but
2098also L<introduced a known problem|/"Known Problems"> with argument
2099passing to non-Perl tests. (5.13.3)
2100
2101=item *
2102
2103C<Test::Simple> has been upgraded from version 0.94 to 0.98.
2104
2105Among many other things, subtests without a C<plan> or C<no_plan> now have an
2106implicit C<done_testing()> added to them.
2107
2108=item *
2109
2110C<Thread::Queue> has been upgraded from version 2.11 to 2.12.
2111
2112=item *
2113
2114C<Thread::Semaphore> has been upgraded from version 2.09 to 2.12.
2115
2116Added new methods -E<gt>down_nb() and -E<gt>down_force() at the suggestion
2117of Rick Garlick.
2118
2119Refactored methods to skip argument validation when no argument is supplied.
2120
2121=item *
2122
2123C<threads> has been upgraded from version 1.75 to 1.82.
2124
2125=item *
2126
2127C<threads::shared> has been upgraded from version 1.32 to 1.36.
2128
2129=item *
2130
2131C<Tie::Hash> has been upgraded from version 1.03 to 1.04.
2132
2133Calling C<< Tie::Hash-E<gt>TIEHASH() >> used to loop forever. Now it C<croak>s.
2134
2135=item *
2136
2137C<Tie::Hash::NamedCapture> has been upgraded from version 0.06 to 0.08.
2138
2139Some of the Perl code has been converted to XS for efficency's sake.
2140
2141=item *
2142
2143C<Tie::RefHash> has been upgraded from version 1.38 to 1.39.
2144
2145=item *
2146
2147C<Time::HiRes> has been upgraded from version 1.9719 to 1.9721.
2148
2149=item *
2150
2151C<Time::Local> has been upgraded from version 1.1901_01 to 1.2000.
2152
2153=item *
2154
2155C<Time::Piece> has been upgraded from version 1.15_01 to 1.20_01.
2156
2157=item *
2158
2159C<Unicode::Collate> has been upgraded from version 0.52_01 to 0.73.
2160
2161Includes Unicode Collation Algorithm 18
2162
2163Among other things, it is now using UCA Revision 20 (based on Unicode 5.2.0) and
2164supports a couple of new locales.
2165
2166U::C::Locale newly supports locales: ar, be, bg, de__phonebook, hu, hy, kk, mk, nso, om,
2167tn, vi, hr, ig, ru, sq, se, sr, to and uk
2168
2169This release newly adds locales C<ja> C<ko> and C<zh> and its variants
2170( C<zh__big5han>, C<zh__gb2312han>, C<zh__pinyin>, C<zh__stroke> ).
2171
2172Supported UCA_Version 22 for Unicode 6.0.0.
2173
2174The following modules have been added:
2175
2176C<Unicode::Collate::CJK::Big5> for C<zh__big5han> which makes
2177tailoring of CJK Unified Ideographs in the order of CLDR's big5han ordering.
2178
2179C<Unicode::Collate::CJK::GB2312> for C<zh__gb2312han> which makes
2180tailoring of CJK Unified Ideographs in the order of CLDR's gb2312han ordering.
2181
2182C<Unicode::Collate::CJK::JISX0208> which makes tailoring of 6355 kanji
2183(CJK Unified Ideographs) in the JIS X 0208 order.
2184
2185C<Unicode::Collate::CJK::Korean> which makes tailoring of CJK Unified Ideographs
2186in the order of CLDR's Korean ordering.
2187
2188C<Unicode::Collate::CJK::Pinyin> for C<zh__pinyin> which makes
2189tailoring of CJK Unified Ideographs in the order of CLDR's pinyin ordering.
2190
2191C<Unicode::Collate::CJK::Stroke> for C<zh__stroke> which makes
2192tailoring of CJK Unified Ideographs in the order of CLDR's stroke ordering.
2193
2194DUCET has been updated for Unicode 6.0.0 as Collate/allkeys.txt and
2195the default UCA_Version is 22.
2196
2197This also sees the switch from using the pure-perl version of this
2198module to the XS version.
2199
2200=item *
2201
2202C<Unicode::Normalize> has been upgraded from version 1.03 to 1.10.
2203
2204=item *
2205
2206C<Unicode::UCD> has been upgraded from version 0.27 to 0.32.
2207
2208Add info about named sequence alternatives.
2209
2210Don't use C<CompositionExclusions.txt>.
2211
2212This includes a number of bug fixes:
2213
2214=over 4
2215
2216=item charinfo()
2217
2218=over 4
2219
2220=item *
2221
2222It is now updated to Unicode Version 6 with Corrigendum #8, except,
2223as with Perl 5.14, the code point at U+1F514 has no name.
2224
2225=item *
2226
2227The Hangul syllable code points have the correct names, and their
2228decompositions are always output without requiring L<Lingua::KO::Hangul::Util>
2229to be installed.
2230
2231=item *
2232
2233The CJK (Chinese-Japanese-Korean) code points U+2A700 - U+2B734
2234and U+2B740 - 2B81D are now properly handled.
2235
2236=item *
2237
2238The numeric values are now output for those CJK code points that have them.
2239
2240=item *
2241
2242The names that are output for code points with multiple aliases are now the
2243corrected ones.
2244
2245=back
2246
2247=item charscript()
2248
2249This now correctly returns "Unknown" instead of C<undef> for the script
2250of a code point that hasn't been assigned another one.
2251
2252=item charblock()
2253
2254This now correctly returns "No_Block" instead of C<undef> for the block
2255of a code point that hasn't been assigned to another one.
2256
2257=back
2258
2259Added new function C<Unicode::UCD::num()>. This function will return the
2260numeric value of the string passed it; C<undef> if the string in its
2261entirety has no safe numeric value.
2262
2263To be safe, a string must be a single character which has a numeric
2264value, or consist entirely of characters that match \d, coming from the
2265same Unicode block of digits. Thus, a mix of Bengali and Western
2266digits would be considered unsafe, as well as a mix of half- and
2267full-width digits, but strings consisting entirely of Devanagari digits
2268or of "Mathematical Bold" digits would would be safe.
2269
2270=item *
2271
2272C<version> has been upgraded from 0.82 to 0.88.
2273
2274Modify export logic for C<is_strict> and C<is_lax>.
2275
2276=item *
2277
2278C<warnings> and C<warnings::register> have been upgraded from version 1.09
2279to 1.11 and from version 1.01 to 1.02 respectively.
2280
2281Calling C<use warnings> without arguments is now significantly more efficient.
2282
2283It is now possible to register warning categories other than the names of
2284packages using C<warnings::register>. See L<perllexwarn> for more information.
2285
2286=item *
2287
2288C<VMS::DCLsym> has been upgraded from version 1.03 to 1.05.
2289
2290Two bugs have been fixed [perl #84086]:
2291
2292The symbol table name was lost when tying a hash, due to a thinko in
2293C<TIEHASH>. The result was that all tied hashes interacted with the
2294local symbol table.
2295
2296Unless a symbol table name had been explicitly specified in the call
2297to the constructor, querying the special key ':LOCAL' failed to
2298identify objects connected to the local symbol table.
2299
2300=item *
2301
2302C<Win32> has been upgraded from version 0.39 to 0.44.
2303
2304Add several functions. (5.13.8)
2305
2306Corrections to names returned by C<Win32::GetOSName> and
2307C<Win32::GetOSDisplayName>.
2308
2309=item *
2310
2311C<XSLoader> has been upgraded from version 0.10 to 0.11.
2312
2313=back
2314
2315=head2 Dual-life Modules and Pragmata
2316
2317These modules were formerly distributed only in the Perl core
2318distribution, and are now dual-lifed (meaning they are now also available
2319separately on CPAN):
2320
2321=over 4
2322
2323=item *
2324
2325C<autouse>
2326
2327=item *
2328
2329C<Devel::SelfStubber>
2330
2331=item *
2332
2333C<Dumpvalue>
2334
2335=item *
2336
2337C<Env>
2338
2339=item *
2340
2341C<File::CheckTree>
2342
2343=item *
2344
2345C<I18N::Collate>
2346
2347=back
2348
2349=head2 Removed Modules and Pragmata
2350
2351The following modules have been removed from the core distribution, and if
2352needed should be installed from CPAN instead.
2353
2354=over
2355
2356=item C<Class::ISA>
2357
2358=item C<Pod::Plainer>
2359
2360=item C<Switch>
2361
2362=back
2363
2364The removal of C<Shell> has been deferred until after 5.14, as the
2365implementation of C<Shell> shipped with 5.12.0 did not correctly issue the
2366warning that it was to be removed from core.
2367
2368=head1 Documentation
2369
2370XXX Changes to files in F<pod/> go here. Consider grouping entries by
2371file and be sure to link to the appropriate page, e.g. L<perlfunc>.
2372
2373=head2 New Documentation
2374
2375=head3 perlgpl
2376
2377L<perlgpl> has been updated to contain GPL version 1, as is included in the
2378F<README> distributed with perl.
2379
2380=head3 L<perl5121delta>
2381
2382The Perl 5.12.1 perldelta file was added from the Perl maintenance branch
2383
2384=head3 L<perlpodstyle>
2385
2386New style guide for POD documentation,
2387split mostly from the NOTES section of the pod2man man page.
2388
2389( This was added to C<v5.13.6> but was not documented with that release ).
2390
2391=head2 Changes to Existing Documentation
2392
4ed2cea4
FC
2393=head3 L<perlmodlib>
2394
2395The perlmodlib page that came with Perl 5.12.0 was missing a lot of
2396modules, due to a bug in the script that generates the list. This has been
2397fixed [perl #74332].
2398
5076a392
FC
2399=head3 Replace wrong tr/// table in perlebcdic.pod
2400
2401perlebcdic.pod contains a helpful table to use in tr/// to convert
2402between EBCDIC and Latin1/ASCII. Unfortunately, the table was the
2403inverse of the one it describes, though the code that used the table
2404worked correctly for the specific example given.
2405
2406The table has been changed to its inverse, and the sample code changed
2407to correspond, as this is easier for the person trying to follow the
2408instructions since deriving the old table is somewhat more complicated.
2409
2410The table has also been changed to hex from octal, as that is more the norm
2411these days, and the recipes in the pod altered to print out leading
2412zeros to make all the values the same length, as the table that they can
2413generate has them (5f26d5).
2414
2415=head3 Document tricks for user-defined casing
2416
2417perlunicode.pod now contains an explanation of how to override, mangle
2418and otherwise tweak the way perl handles upper, lower and other case
2419conversions on unicode data, and how to provide scoped changes to alter
2420one's own code's behaviour without stomping on anybody else (71648f).
2421
2422=head3 Document $# and $* as removed and clarify $#array usage
2423
2424$# and $* were both disabled as of perl5 version 10; this release adds
2425documentation to that effect, a description of the results of continuing
2426to try and use them, and a note explaining that $# can also function as a
2427sigil in the $#array form (7f315d2).
2428
2429=head3 INSTALL explicitly states the requirement for C89
2430
2431This was already true but it's now Officially Stated For The Record (51eec7).
2432
2433=head3 No longer advertise Math::TrulyRandom
2434
2435This module hasn't been updated since 1996 so we can't recommend it any more
2436(83918a).
2437
2438=head3 perlfaq synchronised to upstream
2439
2440The FAQ has been updated to commit
244137550b8f812e591bcd0dd869d61677dac5bda92c from the perlfaq repository
2442at git@github.com:briandfoy/perlfaq.git
2443
2444=head3 General changes
2445
2446=over
2447
2448=item *
2449
2450Octal character escapes in documentation now prefer a three-digit octal
2451escape or the new C<\o{...}> escape as they have more consistent behavior
2452in different contexts than other forms. (ce7b6f0) (d8b950d) (e1f120a)
2453
2454=item *
2455
2456Documentation now standardizes on the term 'capture group' over 'buffer'
2457in regular expression documentation (c27a5cf)
2458
2459=back
2460
2461=head3 L<perlfunc>
2462
2463=over
2464
2465=item *
2466
2467Added cautionary note about "no VERSION" (e0de7c2)
2468
2469=item *
2470
2471Added additional notes regarding srand when forking (d460397)
2472
2473=back
2474
2475=head3 L<perlop>
2476
2477=over 4
2478
2479=item *
2480
2481Improved documentation of unusual character escapes (4068718, 9644846)
2482
2483=item *
2484
2485Clarified how hexadecimal escapes are interpreted, with particular
2486attention to the treatment of invalid characters (9644846)
2487
2488=back
2489
2490=head3 L<perlrun>
2491
2492=over
2493
2494=item *
2495
2496Clarified the behavior of the C<-0NNN> switch for C<-0400> or higher (7ba31cb)
2497
2498=back
2499
2500=head3 L<perlpolicy>
2501
2502=over
2503
2504=item *
2505
2506Added the policy on compatibility and deprecation along with definitions of
2507terms like "deprecation" (70e4a83)
2508
2509=back
2510
2511=head3 L<perlre>
2512
2513=over
2514
2515=item *
2516
2517Added examples of the perils of not using \g{} when there are more
2518than nine back-references (9d86067)
2519
2520=back
2521
2522=head3 L<perltie>
2523
2524=over
2525
2526=item *
2527
2528Updated some examples for modern Perl style (67d00dd)
2529
2530=back
2531
2532=head3 L<perldiag>
2533
2534=over 4
2535
2536=item *
2537
2538The following existing diagnostics are now documented:
2539
2540=over 4
2541
2542=item *
2543
2544L<Ambiguous use of %c resolved as operator %c|perldiag/"Ambiguous use of %c resolved as operator %c">
2545
2546=item *
2547
2548L<Ambiguous use of %c{%s} resolved to %c%s|perldiag/"Ambiguous use of %c{%s} resolved to %c%s">
2549
2550=item *
2551
2552L<Ambiguous use of %c{%s%s} resolved to %c%s%s|perldiag/"Ambiguous use of %c{%s%s} resolved to %c%s%s">
2553
2554=item *
2555
2556L<Ambiguous use of -%s resolved as -&%s()|perldiag/"Ambiguous use of -%s resolved as -&%s()">
2557
2558=item *
2559
2560L<Invalid strict version format (%s)|perldiag/"Invalid strict version format (%s)">
2561
2562=item *
2563
2564L<Invalid version format (%s)|perldiag/"Invalid version format (%s)">
2565
2566=item *
2567
2568L<Invalid version object|perldiag/"Invalid version object">
2569
2570=back
2571
2572=back
2573
2574=head3 L<perlport>
2575
2576=over 4
2577
2578=item *
2579
2580Documented a L<limitation|perlport/alarm> of L<alarm()|perlfunc/"alarm SECONDS">
2581on Win32.
2582
2583=back
2584
2585=head3 L<perlre>
2586
2587=over 4
2588
2589=item *
2590
2591Minor fix to a multiple scalar match example.
2592
2593=back
2594
2595=head3 L<perlapi>
2596
2597=over 4
2598
2599=item *
2600
2601Many of the optree construction functions are now documented.
2602
2603=back
2604
2605=head3 L<perlbook>
2606
2607=over 4
2608
2609=item *
2610
2611Expanded to cover many more popular books.
2612
2613=back
2614
2615=head3 L<perlfaq>
2616
2617=over 4
2618
2619=item *
2620
2621L<perlfaq>, L<perlfaq2>, L<perlfaq4>, L<perlfaq5>, L<perlfaq6>, L<perlfaq8>, and
2622L<perlfaq9> have seen various updates and modernizations.
2623
2624=back
2625
2626=head3 L<perlapi>
2627
2628=over 4
2629
2630=item *
2631
2632The documentation for the C<SvTRUE> macro was simply wrong in stating that
2633get-magic is not processed. It has been corrected.
2634
2635=back
2636
2637=head3 L<perlvar>
2638
2639L<perlvar> reorders the variables and groups them by topic. Each variable
2640introduced after Perl 5.000 notes the first version in which it is
2641available. L<perlvar> also has a new section for deprecated variables to
2642note when they were removed.
2643
2644=head3 blah blah blah
2645
2646Array and hash slices in scalar context are now documented in L<perldata>.
2647
2648=head3 blah blah blah
2649
2650L<perlform> and L<perllocale> have been corrected to state that
2651C<use locale> affects formats.
2652
2653=head3 All documentation
2654
2655=over
2656
2657=item *
2658
2659Numerous POD warnings were fixed.
2660
2661=item *
2662
2663Many, many spelling errors and typographical mistakes were corrected throughout Perl's core.
2664
2665=back
2666
2667=head3 C<perlhack>
2668
2669=over 4
2670
2671=item *
2672
2673C<perlhack> was extensively reorganized.
2674
2675=back
2676
2677=head3 C<perlfunc>
2678
2679=over 4
2680
2681=item *
2682
2683It has now been documented that C<ord> returns 0 for an empty string.
2684
2685=back
2686
2687=head3 L<overload>
2688
2689=over 4
2690
2691=item *
2692
2693L<overload>'s documentation has practically undergone a rewrite. It
2694is now much more straightforward and clear.
2695
2696=back
2697
2698=head3 L<perlhack> and perlrepository
2699
2700=over 4
2701
2702=item *
2703
2704The L<perlhack> and perlrepository documents have been heavily edited and
2705split up into several new documents.
2706
2707The L<perlhack> document is now much shorter, and focuses on the Perl 5
2708development process and submitting patches to Perl. The technical content has
2709been moved to several new documents, L<perlsource>, L<perlinterp>,
2710L<perlhacktut>, and L<perlhacktips>. This technical content has only been
2711lightly edited.
2712
2713The perlrepository document has been renamed to L<perlgit>. This new document
2714is just a how-to on using git with the Perl source code. Any other content
2715that used to be in perlrepository has been moved to perlhack.
2716
2717=back
2718
2719=head3 L<perlfunc>
2720
2721=over 4
2722
2723=item *
2724
2725The documentation for the C<map> function now contains more examples,
2726see B<perldoc -f map> (f947627)
2727
2728=back
2729
2730=head3 L<perlfaq4>
2731
2732=over 4
2733
2734=item *
2735
2736Examples in L<perlfaq4> have been updated to show the use of
2737L<Time::Piece>. (9243591)
2738
2739=back
2740
2741=head3 Miscellaneous
2742
2743=over 4
2744
2745=item *
2746
2747Many POD related RT bugs and other issues which are too numerous to
2748enumerate have been solved by Michael Stevens.
2749
2750=back
2751
2752=head1 Diagnostics
2753
2754The following additions or changes have been made to diagnostic output,
2755including warnings and fatal error messages. For the complete list of
2756diagnostic messages, see L<perldiag>.
2757
2758=head2 New Diagnostics
2759
2760=over
2761
2762=item Parsing code internal error (%s)
2763
2764New fatal error produced when parsing code supplied by an extension violated the
2765parser's API in a detectable way.
2766
2767=item Use of qw(...) as parentheses is deprecated
2768
2769See L</"Use of qw(...) as parentheses"> for details.
2770
2771=item Using !~ with %s doesn't make sense
2772
2773This message was actually added in
27745.13.2, but was omitted from perldelta. It now applies also to the C<y///>
2775operator, and has been documented.
2776
2777=item Closure prototype called
2778
2779There is a new "Closure prototype called" error [perl #68560].
2780
2781=item Operation "%s" returns its argument for ...
2782
2783Performing an operation requiring Unicode semantics (such as case-folding)
2784on a Unicode surrogate or a non-Unicode character now triggers a warning:
2785'Operation "%s" returns its argument for ...'.
2786
2787=item "\b{" is deprecated; use "\b\{" instead
2788
2789=item "\B{" is deprecated; use "\B\{" instead
2790
2791Use of an unescaped "{" immediately following a C<\b> or C<\B> is now
2792deprecated so as to reserve its use for Perl itself in a future release.
2793
2794=item regcomp: Add warning if \p is used under locale. (fb2e24c)
2795
2796C<\p> implies Unicode matching rules, which are likely going to be
2797different than the locale's.
2798
2799=item panic: gp_free failed to free glob pointer - something is repeatedly re-creating entries
2800
2801This new error is triggered if a destructor called on an object in a
2802typeglob that is being freed creates a new typeglob entry containing an
2803object with a destructor that creates a new entry containing an object....
2804
2805=item refcnt: fd %d%s
2806
2807This new error only occurs if a internal consistency check fails when a
2808pipe is about to be closed.
2809
2810=item Regexp modifier "/%c" may not appear twice
2811
2812(F syntax) The regular expression pattern had one of the mutually exclusive
2813modifiers repeated. Remove all but one of the occurrences.
2814
2815=item Regexp modifiers "/%c" and "/%c" are mutually exclusive
2816
2817(F syntax) The regular expression pattern had more than one of the mutually
2818exclusive modifiers. Retain only the modifier that is supposed to be there.
2819
2820=item Insecure user-defined property %s
2821
2822(F) Perl detected tainted data when trying to compile a regular
2823expression that contains a call to a user-defined character property
2824function, i.e. C<\p{IsFoo}> or C<\p{InFoo}>.
2825See L<perlunicode/User-Defined Character Properties> and L<perlsec>.
2826
2827=back
2828
2829=head2 Changes to Existing Diagnostics
2830
2831=over 4
2832
2833=item *
2834
4ed2cea4
FC
2835The "Variable $foo is not imported" warning that precedes a
2836C<strict 'vars'> error has now been assigned the "misc" category, so that
2837C<no warnings> will suppress it [perl #73712].
2838
2839=item *
2840
5076a392
FC
2841C<warn> and C<die> now produce 'Wide character' warnings when fed a
2842character outside the byte range if STDERR is a byte-sized handle.
2843
2844=item *
2845
2846The 'Layer does not match this perl' error message has been replaced with
2847these more helpful messages:
2848
2849=over 4
2850
2851=item *
2852
2853PerlIO layer function table size (%d) does not match size expected by this
2854perl (%d)
2855
2856=item *
2857
2858PerlIO layer instance size (%d) does not match size expected by this perl
2859(%d)
2860
2861=back
2862
2863[perl #73754]
2864
2865=item *
2866
2867The "Found = in conditional" warning that is emitted when a constant is
2868assigned to a variable in a condition is now withheld if the constant is
2869actually a subroutine or one generated by C<use constant>, since the value
2870of the constant may not be known at the time the program is written
2871[perl #77762].
2872
2873=item *
2874
2875Previously, if none of the C<gethostbyaddr>, C<gethostbyname> and
2876C<gethostent> functions were implemented on a given platform, they would
2877all die with the message 'Unsupported socket function "gethostent" called',
2878with analogous messages for C<getnet*> and C<getserv*>. This has been
2879corrected.
2880
2881=item *
2882
2883The warning message about regex unrecognized escapes passed through is
2884changed to include any literal '{' following the 2-char escape. e.g.,
2885"\q{" will include the { in the message as part of the escape
2886(216bfc0).
2887
2888=item *
2889
2890C<binmode $fh, ':scalar'> no longer warns (8250589)
2891
2892Perl will now no longer produce this warning:
2893
2894 $ perl -we 'open my $f, ">", \my $x; binmode $f, "scalar"'
2895 Use of uninitialized value in binmode at -e line 1.
2896
2897=back
2898
2899=head1 Utility Changes
2900
2901=head3 L<perldb>
2902
2903=over
2904
2905=item *
2906
2907The remote terminal works after forking and spawns new sessions - one
2908for each forked process (11653f7)
2909
2910=item *
2911
2912Uses the less pager path from Config instead of searching for it (bf320d6)
2913
2914=back
2915
2916=head3 L<h2ph>
2917
2918=over 4
2919
2920=item *
2921
2922The use of a deprecated C<goto> construct has been removed [perl #74404].
2923
2924=back
2925
2926=head3 L<ptargrep>
2927
2928=over 4
2929
2930=item *
2931
2932L<ptargrep> is a utility to apply pattern matching to the contents of files
2933in a tar archive. It comes with C<Archive::Tar>.
2934
2935=back
2936
2937=head3 C<perlbug>
2938
2939=over 4
2940
2941=item *
2942
4ed2cea4
FC
2943C<perlbug> now looks in the EMAIL environment variable for a return address
2944if the REPLY-TO and REPLYTO variables are empty.
2945
2946=item *
2947
5076a392
FC
2948C<perlbug> did not previously generate a From: header, potentially
2949resulting in dropped mail. Now it does include that header.
2950
2951=back
2952
2953=head3 C<buildtoc>
2954
2955=over 4
2956
2957=item *
2958
2959F<pod/buildtoc> has been modernized and can now be used to test the
2960well-formedness of F<pod/perltoc.pod> automatically.
2961
2962=back
2963
2964=head3 L<perlbug>
2965
2966=over 4
2967
2968=item *
2969
2970[perl #82996] Use the user's from address as return-path in perlbug
2971
2972Many systems these days don't have a valid Internet domain name and
2973perlbug@perl.org does not accept email with a return-path that does
2974not resolve. Therefore pass the user's address to sendmail so it's
2975less likely to get stuck in a mail queue somewhere. (019cfd2)
2976
2977=back
2978
2979=head1 Configuration and Compilation
2980
2981=over 4
2982
2983=item *
2984
2985Fix CCINCDIR and CCLIBDIR for mingw64 cross compiler to correctly be under
2986$(CCHOME)\mingw\include and \lib rather than immediately below $(CCHOME).
2987
2988=item *
2989
2990This means the 'incpath', 'libpth', 'ldflags', 'lddlflags' and
2991'ldflags_nolargefiles' values in Config.pm and Config_heavy.pl are now
2992set correctly (23ae7f).
2993
2994=item *
2995
2996Adjusted 'make test.valgrind' to account for cpan/dist/ext separation
2997(e07ce2e)
2998
2999=item *
3000
3001Compatibility with C<C++> compilers has been improved.
3002
3003=item *
3004
3005On compilers that support it, C<-Wwrite-strings> is now added to cflags by
3006default.
3007
3008=item *
3009
3010The C<Encode> module can now (once again) be included in a static Perl
3011build. The special-case handling for this situation got broken in Perl
30125.11.0, and has now been repaired.
3013
3014=back
3015
3016=head1 Testing
3017
3018XXX Any significant changes to the testing of a freshly built perl should be
3019listed here. Changes which create B<new> files in F<t/> go here as do any
3020large changes to the testing harness (e.g. when parallel testing was added).
3021Changes to existing files in F<t/> aren't worth summarising, although the bugs
3022that they represent may be covered elsewhere.
3023
3024=over 4
3025
3026=item *
3027
3028F<t/harness> clears PERL5LIB, PERLLIB, PERL5OPT as t/TEST does (a2d3de1)
3029
3030=item *
3031
3032Many common testing routines were refactored into t/lib/common.pl
3033
3034=item *
3035
3036Several test files have been modernized to use Test::More
3037
3038=item *
3039
3040F<t/op/print.t> has been added to test implicit printing of C<$_>.
3041
3042=item *
3043
3044F<t/io/errnosig.t> has been added to test for restoration of of C<$!> when
3045leaving signal handlers.
3046
3047=item *
3048
3049F<t/op/tie_fetch_count.t> has been added to see if C<FETCH> is only called once
3050on tied variables.
3051
3052=item *
3053
3054F<lib/Tie/ExtraHash.t> has been added to make sure the, previously untested,
3055L<Tie::ExtraHash> keeps working.
3056
3057=item *
3058
3059F<t/re/overload.t> has been added to test against string corruption in pattern
3060matches on overloaded objects. This is a TODO test.
3061
3062=item *
3063
3064The new F<t/lib/universal.t> script tests the Internal::* functions and other
3065things in F<universal.c>.
3066
3067=item *
3068
3069A rare race condition in F<t/op/while_readdir.t> has been fixed, stopping it
3070from failing randomly when running tests in parallel.
3071
3072=item *
3073
3074The new F<t/op/leaky-magic.t> script tests that magic applied to variables in
3075the main packages does not affect other packages.
3076
3077=item *
3078
3079The script F<t/op/threads-dirh.t> has been added, which tests interaction
3080of threads and directory handles.
3081
3082=item *
3083
3084The new F<t/mro/isa_aliases.t> has been added, which tests that
3085C<*Foo::ISA = *Bar::ISA> works properly.
3086
3087=item *
3088
3089F<t/mro/isarev.t> has been added, which tests that C<PL_isarev> (accessible
3090at the Perl level via C<mro::get_isarev>) is updated properly.
3091
3092=item *
3093
3094F<t/run/switchd-78586.t> has been added, which tests that [perl #78586]
3095has been fixed (related to line numbers in the debugger).
3096
3097=item *
3098
3099C<lib/File/DosGlob.t> has been modernized and now uses C<Test::More>.
3100
3101=item *
3102
3103A new test script, C<t/porting/filenames.t>, makes sure that filenames and
3104paths are reasonably portable.
3105
3106=item *
3107
3108C<t/porting/diag.t> is now several orders of magnitude faster.
3109
3110=item *
3111
3112C<t/porting/buildtoc.t> now tests that the documentation TOC file is current and well-formed.
3113
3114=item *
3115
3116C<t/base/while.t> now tests the basics of a while loop with minimal dependencies.
3117
3118=item *
3119
3120C<t/cmd/while.t> now uses F<test.pl> for better maintainability.
3121
3122=item *
3123
3124C<t/op/split.t> now tests calls to C<split> without any pattern specified.
3125
3126=item *
3127
3128F<porting/FindExt.t> now skips all tests on a static (-Uusedl) build
3129of perl.
3130
3131=item *
3132
3133F<porting/FindExt.t> now passes on non-Win32 platforms when some
3134extensions are built statically.
3135
3136=item *
3137
3138The tests for C<split /\s/> and Unicode have been moved from
3139F<t/op/split.t> to the new F<t/op/split_unicode.t>.
3140
3141=item *
3142
3143F<t/re/re.t> has been moved to F<ext/re/t/re_funcs_u.t>.
3144
3145=item *
3146
3147The tests for [perl #72922] have been moved from F<t/re/qr.t> to the new
3148F<t/re/qr-72922.t>.
3149
3150=item *
3151
3152F<t/re/reg_unsafe.t> has been deleted and its only test moved to
3153F<t/re/pat_advanced.t>.
3154
3155=back
3156
3157=head1 Platform Support
3158
3159XXX Any changes to platform support should be listed in the sections below.
3160
3161[ Within the sections, list each platform as a =item entry with specific
3162changes as paragraphs below it. ]
3163
3164=head2 New Platforms
3165
3166XXX List any platforms that this version of perl compiles on, that previous
3167versions did not. These will either be enabled by new files in the F<hints/>
3168directories, or new subdirectories and F<README> files at the top level of the
3169source tree.
3170
3171=over 4
3172
3173=item AIX
3174
3175Perl now builds on AIX 4.2.
3176
3177=back
3178
3179=head2 Discontinued Platforms
3180
3181=over 4
3182
3183=item MacOS Classic
3184
3185Support for MacOS Classic within ExtUtils::MakeMaker was removed from Perl in
3186December 2004. Vestigial MacOS Classic specific code has now been removed
3187from other core modules as well (8f8c2a4..c457df0)
3188
3189=item Apollo DomainOS
3190
3191The last vestiges of support for this platform have been excised from the
3192Perl distribution. It was officially discontinued in version 5.12.0. It had
3193not worked for years before that.
3194
3195=item MacOS Classic
3196
3197The last vestiges of support for this platform have been excised from the
3198Perl distribution. It was officially discontinued in an earlier version.
3199
3200=back
3201
3202=head2 Platform-Specific Notes
3203
3204=head3 Recent OpenBSDs now use perl's malloc
3205
3206OpenBSD E<gt> 3.7 has a new malloc implementation which is mmap based
3207and as such can release memory back to the OS; however for perl using
3208this malloc causes a substantial slowdown so we now default to using
3209perl's malloc instead (RT #75742) (9b58b5).
3210
3211=head3 VMS
3212
3213=over 4
3214
3215=item *
3216
3217Make C<PerlIOUnix_open> honour default permissions on VMS.
3218
3219When C<perlio> became the default and C<unixio> became the default bottom layer,
3220the most common path for creating files from Perl became C<PerlIOUnix_open>,
3221which has always explicitly used C<0666> as the permission mask.
3222
3223To avoid this, C<0777> is now passed as the permissions to C<open()>. In the
3224VMS CRTL, C<0777> has a special meaning over and above intersecting with the
3225current umask; specifically, it allows Unix syscalls to preserve native default
3226permissions.
3227
3228=back
3229
3230=head3 Win32
3231
3232t/io/openpid.t now uses the alarm() watchdog strategy for more
3233robustness (5732108)
3234
3235=over 4
3236
3237=item *
3238
3239Fixed a possible hang in F<t/op/readline.t>.
3240
3241=item *
3242
3243Fixed build process for SDK2003SP1 compilers.
3244
3245=item *
3246
3247When using old 32-bit compilers, the define C<_USE_32BIT_TIME_T> will now be set
3248in C<$Config{ccflags}>. This improves portability when compiling XS extensions
3249using new compilers, but for a perl compiled with old 32-bit compilers.
3250
3251=back
3252
3253XXX A bunch of entries that need conversion to =head2 format (unless the
3254entries above change to =items):
3255
3256=over
3257
3258=item IRIX
3259
3260Conversion of strings to floating-point numbers is now more accurate on
3261IRIX systems [perl #32380].
3262
3263=item Mac OS X
3264
3265Early versions of Mac OS X (Darwin) had buggy implementations of the
3266C<setregid>, C<setreuid>, C<setrgid> and C<setruid> functions, so perl
3267would pretend they did not exist.
3268
3269These functions are now recognised on Mac OS 10.5 (Leopard; Darwin 9) and
3270higher, as they have been fixed [perl #72990].
3271
3272=item OpenVOS
3273
3274perl now builds again with OpenVOS (formerly known as Stratus VOS)
3275[perl #78132].
3276
3277=item VMS
3278
3279The shortening of symbols longer than 31 characters in the C sources is
3280now done by the compiler rather than by xsubpp (which could only do so
3281for generated symbols in XS code).
3282
3283=item Windows
3284
3285C<$Config{gccversion}> is now set correctly when perl is built using the
3286mingw64 compiler from L<http://mingw64.org> [perl #73754].
3287
3288The build process proceeds more smoothly with mingw and dmake when
3289F<C:\MSYS\bin> is in the PATH, due to a C<Cwd> fix.
3290
3291=item Windows
3292
3293Directory handles are now properly cloned when threads are created. In perl
32945.13.6, child threads simply stopped inheriting directory handles. In
3295previous versions, threads would share handles, resulting in crashes.
3296
3297Support for building with Visual C++ 2010 is now underway, but is not yet
3298complete. See F<README.win32> for more details.
3299
3300=item VMS
3301
3302Record-oriented files (record format variable or variable with fixed control)
3303opened for write by the perlio layer will now be line buffered to prevent the
3304introduction of spurious line breaks whenever the perlio buffer fills up.
3305
3306=item NetBSD
3307
3308The NetBSD hints file has been changed to make the system's malloc the
3309default.
3310
3311=item Windows
3312
3313The option to use an externally-supplied C<crypt()>, or to build with no
3314C<crypt()> at all, has been removed. Perl supplies its own C<crypt()>
3315implementation for Windows, and the political situation that required
3316this part of the distribution to sometimes be omitted is long gone.
3317
3318=item Cygwin
3319
3320=over
3321
3322=item *
3323
3324Updated MakeMaker to build man pages on cygwin.
3325
3326=item *
3327
3328Improved rebase behaviour
3329
3330If a dll is updated on cygwin reuse the old imagebase address.
3331This solves most rebase errors, esp when updating on core dll's.
3332See L<http://www.tishler.net/jason/software/rebase/rebase-2.4.2.README> for more information.
3333
3334=item *
3335
3336Support the standard cyg dll prefix, which is e.g. needed for FFI's.
3337
3338=item *
3339
3340Updated build hints file
3341
3342=back
3343
3344
3345=item Solaris
3346
3347DTrace is now supported on Solaris. There used to be build failures, but
3348these have been fixed [perl #73630].
3349
3350=item Windows
3351
3352=over 4
3353
3354=item *
3355
3356The C<test-prep> build target now depends on F<pod/perltoc.pod> to allow the
3357F<t/porting/buildtoc.t> test to run successfully.
3358
3359=back
3360
3361=item MirBSD
3362
3363=over 4
3364
3365=item *
3366
3367[perl #82988] Skip hanging taint.t test on MirBSD 10 (1fb83d0)
3368
3369Skip a hanging test under MirBSD that was already being skipped under
3370OpenBSD.
3371
3372=item *
3373
3374Previously if you build perl with a shared libperl.so on MirBSD (the
3375default config), it will work up to the installation; however, once
3376installed, it will be unable to find libperl. Treat path handling
3377like in the other BSD dialects.
3378
3379=back
3380
3381=back
3382
3383=head1 Internal Changes
3384
f8e88449
FC
3385=head2 New APIs
3386
3387=head2 CLONE_PARAMS structure added to ease correct thread creation
3388
3389Modules that create threads should now create C<CLONE_PARAMS> structures
3390by calling the new function C<Perl_clone_params_new()>, and free them with
3391C<Perl_clone_params_del()>. This will ensure compatibility with any future
3392changes to the internals of the C<CLONE_PARAMS> structure layout, and that
3393it is correctly allocated and initialised.
3394
3395=head2 API function to parse statements
3396
3397The C<parse_fullstmt> function has been added to allow parsing of a single
3398complete Perl statement. See L<perlapi> for details.
3399
3400=head2 API functions for accessing the runtime hinthash
3401
3402A new C API for introspecting the hinthash C<%^H> at runtime has been added.
3403See C<cop_hints_2hv>, C<cop_hints_fetchpvn>, C<cop_hints_fetchpvs>,
3404C<cop_hints_fetchsv>, and C<hv_copy_hints_hv> in L<perlapi> for details.
3405
3406=head2 C interface to C<caller()>
3407
3408The C<caller_cx> function has been added as an XSUB-writer's equivalent of
3409C<caller()>. See L<perlapi> for details.
3410
3411=head2 Custom per-subroutine check hooks
3412
3413XS code in an extension module can now annotate a subroutine (whether
3414implemented in XS or in Perl) so that nominated XS code will be called
3415at compile time (specifically as part of op checking) to change the op
3416tree of that subroutine. The compile-time check function (supplied by
3417the extension module) can implement argument processing that can't be
3418expressed as a prototype, generate customised compile-time warnings,
3419perform constant folding for a pure function, inline a subroutine
3420consisting of sufficiently simple ops, replace the whole call with a
3421custom op, and so on. This was previously all possible by hooking the
3422C<entersub> op checker, but the new mechanism makes it easy to tie the
3423hook to a specific subroutine. See L<perlapi/cv_set_call_checker>.
3424
3425To help in writing custom check hooks, several subtasks within standard
3426C<entersub> op checking have been separated out and exposed in the API.
3427
3428=head2 Improved support for custom OPs
3429
3430Custom ops can now be registered with the new C<custom_op_register> C
3431function and the C<XOP> structure. This will make it easier to add new
3432properties of custom ops in the future. Two new properties have been added
3433already, C<xop_class> and C<xop_peep>.
3434
3435C<xop_class> is one of the OA_*OP constants, and allows L<B> and other
3436introspection mechanisms to work with custom ops that aren't BASEOPs.
3437C<xop_peep> is a pointer to a function that will be called for ops of this
3438type from C<Perl_rpeep>.
3439
3440See L<perlguts/Custom Operators> and L<perlapi/Custom Operators> for more
3441detail.
3442
3443The old C<PL_custom_op_names>/C<PL_custom_op_descs> interface is still
3444supported but discouraged.
3445
3446=head2 Changes to existing APIs
3447
3448XXX This probably contains also internal changes unrelated to APIs. It
3449needs to be sorted out. Maybe we also need an ‘Other Changes’ or ‘Really
3450Internal Changes’ section.
3451
5076a392
FC
3452=over 4
3453
3454=item *
3455
3456The protocol for unwinding the C stack at the last stage of a C<die>
3457has changed how it identifies the target stack frame. This now uses
3458a separate variable C<PL_restartjmpenv>, where previously it relied on
3459the C<blk_eval.cur_top_env> pointer in the C<eval> context frame that
3460has nominally just been discarded. This change means that code running
3461during various stages of Perl-level unwinding no longer needs to take
3462care to avoid destroying the ghost frame.
3463
3464=item *
3465
3466The format of entries on the scope stack has been changed, resulting in a
3467reduction of memory usage of about 10%. In particular, the memory used by
3468the scope stack to record each active lexical variable has been halved.
3469
3470=item *
3471
3472Memory allocation for pointer tables has been changed. Previously
3473C<Perl_ptr_table_store> allocated memory from the same arena system as C<SV>
3474bodies and C<HE>s, with freed memory remaining bound to those arenas until
3475interpreter exit. Now it allocates memory from arenas private to the specific
3476pointer table, and that memory is returned to the system when
3477C<Perl_ptr_table_free> is called. Additionally, allocation and release are both
3478less CPU intensive.
3479
3480=item *
3481
3482A new function, Perl_magic_methcall has been added that wraps the setup needed
3483to call a magic method like FETCH (the existing S_magic_methcall function has
3484been renamed S_magic_methcall1).
3485
3486=item *
3487
3488The implementation of sv_dup_inc() has changed from a macro to a function.
3489
3490=item *
3491
3492The C<find_rundefsvoffset> function has been deprecated. It appeared that
3493its design was insufficient to reliably get the lexical C<$_> at run-time.
3494
3495Use the new C<find_rundefsv> function or the C<UNDERBAR> macro instead.
3496They directly return the right SV representing C<$_>, whether it's lexical
3497or dynamic (789bd8 .. 03d5bc).
3498
3499=item *
3500
3501The following new functions or macros have been added to the public API:
3502C<SvNV_nomg>, C<sv_2nv_flags>, C<find_rundefsv>.
3503
3504=item *
3505
3506The C<UNDERBAR> macro now calls C<find_rundefsv>. C<dUNDERBAR> is now a
3507noop but should still be used to ensure past and future compatibility.
3508
3509=item *
3510
3511The ibcmp_* functions have been renamed and are now called foldEQ,
3512foldEQ_locale and foldEQ_utf8 (e6226b).
3513
3514=item *
3515
3516Under some circumstances, the C<CvGV()> field of a CV is now reference
3517counted. To ensure consistent behaviour, direct assignment to it, for
3518example C<CvGV(cv) = gv> is now a compile-time error. A new macro,
3519C<CvGV_set(cv,gv)> has been introduced to perform this operation safely.
3520Note that modification of this field is not part of of the public API,
3521regardless of this new macro. This change caused some
3522L<issues|/"Known Problems"> in modules that used the private C<GvGV()>
3523field.
3524
3525=item *
3526
3527It is now possible for XS code to hook into Perl's lexical scope
3528mechanism at compile time, using the new C<Perl_blockhook_register>
3529function. See L<perlguts/"Compile-time scope hooks">.
3530
3531=item *
3532
3533Added C<Perl_croak_no_modify()> to implement
3534C<Perl_croak("%s", PL_no_modify)> (6ad8f25)
3535
3536=item *
3537
3538Added prototypes for C<tie()> and C<untie()> to allow overloading (RT#75902)
3539(1db4d19)
3540
3541=item *
3542
3543Adds C<my_[l]stat_flags()> to replace C<my_[l]stat()>. C<my_stat()> and
3544C<my_lstat()> call get magic on the stack arg, so create C<_flags()>
3545variants that allow us to control this. (0d7d409)
3546
3547=item *
3548
3549Removed C<PERL_POLLUTE>
3550
3551The option to define C<PERL_POLLUTE> to expose older 5.005 symbols for backwards
3552compatibility has been removed. It's use was always discouraged, and MakeMaker
3553contains a more specific escape hatch:
3554
3555 perl Makefile.PL POLLUTE=1
3556
3557This can be used for modules that have not been upgraded to 5.6 naming
3558conventions (and really should be completely obsolete by now).
3559
3560=item *
3561
3562Added C<PERL_STATIC_INLINE>
3563
3564The C<PERL_STATIC_INLINE> define has been added to provide the best-guess
3565incantation to use for static inline functions, if the C compiler supports
3566C99-style static inline. If it doesn't, it'll give a plain C<static>.
3567
3568C<HAS_STATIC_INLINE> can be used to check if the compiler actually supports
3569inline functions.
3570
3571=item *
3572
3573C<CALL_FPTR> and C<CPERLscope> have been deprecated.
3574
3575Those are left from an old implementation of C<MULTIPLICITY> using C++ objects,
3576which was removed in Perl 5.8. Nowadays these macros do exactly nothing, so
3577they shouldn't be used anymore.
3578
3579For compatibility, they are still defined for external C<XS> code. Only
3580extensions defining C<PERL_CORE> must be updated now.
3581
3582=item *
3583
3584C<lex_stuff_pvs()> has been added as a convenience macro wrapping
3585C<lex_stuff_pvn()> for literal strings.
3586
3587=item *
3588
3589The recursive part of the peephole optimizer is now hookable.
3590
3591In addition to C<PL_peepp>, for hooking into the toplevel peephole optimizer, a
3592C<PL_rpeepp> is now available to hook into the optimizer recursing into
3593side-chains of the optree.
3594
3595=item *
3596
3597See L</Regular expressions retain their localeness when interpolated>,
3598above.
3599
3600=item *
3601
3602The C<sv_cmp_flags>, C<sv_cmp_locale_flags>, C<sv_eq_flags> and
3603C<sv_collxfrm_flags> functions have been added. These are like their
3604non-_flags counterparts, but allow one to specify whether get-magic is
3605processed.
3606
3607The C<sv_cmp>, C<sv_cmp_locale>, C<sv_eq> and C<sv_collxfrm> functions have
3608been replaced with wrappers around the new functions.
3609
3610=item *
3611
3612A new C<sv_2bool_flags> function has been added.
3613
3614This is like C<sv_2bool>, but it lets the calling code decide whether
3615get-magic is handled. C<sv_2bool> is now a macro that calls the new
3616function.
3617
3618=item *
3619
3620A new macro, C<SvTRUE_nomg>, has been added.
3621
3622This is like C<SvTRUE>, except that it does not process magic. It uses the
3623new C<sv_2bool_flags> function.
3624
3625=item *
3626
3627C<sv_catsv_flags> no longer calls C<mg_get> on its second argument (the
3628source string) if the flags passed to it do not include SV_GMAGIC. So it
3629now matches the documentation.
3630
3631=item *
3632
3633A new interface has been added for custom check hooks on subroutines. See
3634L</Custom per-subroutine check hooks>, above.
3635
3636=item *
3637
3638List op building functions have been added to the
3639API. See L<op_append_elem|perlapi/op_append_elem>,
3640L<op_append_list|perlapi/op_append_list>, and
3641L<op_prepend_elem|perlapi/op_prepend_elem>.
3642
3643=item *
3644
3645The L<LINKLIST|perlapi/LINKLIST> macro, part of op building that
3646constructs the execution-order op chain, has been added to the API.
3647
3648=item *
3649
3650Many functions ending with pvn now have equivalent pv/pvs/sv versions.
3651
3652=item *
3653
3654The C<save_freeop>, C<save_op>, C<save_pushi32ptr> and C<save_pushptrptr>
3655functions have been added to the API.
3656
3657=item *
3658
3659The new API function C<parse_stmtseq()> parses a sequence of statements, up
3660to closing brace or EOF.
3661
3662=item *
3663
3664C<lex_start> has been added to the API, but is considered experimental.
3665
3666=item *
3667
3668A new C<parse_block> function has been added to the API [perl #78222].
3669
3670=item *
3671
3672A new, experimental API has been added for accessing the internal
3673structure that Perl uses for C<%^H>. See the functions beginning with
3674C<cophh_> in L<perlapi>.
3675
3676=item *
3677
3678A stash can now have a list of effective names in addition to its usual
3679name. The first effective name can be accessed via the C<HvENAME> macro,
3680which is now the recommended name to use in MRO linearisations (C<HvNAME>
3681being a fallback if there is no C<HvENAME>).
3682
3683These names are added and deleted via C<hv_ename_add> and
3684C<hv_ename_delete>. These two functions are I<not> part of the API.
3685
3686=item *
3687
3688The way the parser handles labels has been cleaned up and refactored. As a
3689result, the C<newFOROP()> constructor function no longer takes a parameter
3690stating what label is to go in the state op.
3691
3692=item *
3693
3694The C<newWHILEOP()> and C<newFOROP()> functions no longer accept a line
3695number as a parameter.
3696
3697=item *
3698
3699A new C<parse_barestmt()> function has been added, for parsing a statement
3700without a label.
3701
3702=item *
3703
3704A new C<parse_label()> function has been added, that parses a statement
3705label, separate from statements.
3706
3707=item *
3708
3709The C<CvSTASH()> macro can now only be used as an rvalue. C<CvSTASH_set()>
3710has been added to replace assignment to C<CvSTASH()>. This is to ensure
3711that backreferences are handled properly. These macros are not part of the
3712API.
3713
3714=item *
3715
3716The C<op_scope()> and C<op_lvalue()> functions have been added to the API,
3717but are considered experimental.
3718
3719=item *
3720
3721The L<C<mg_findext()>|perlapi/mg_findext> and
3722L<C<sv_unmagicext()>|perlapi/sv_unmagicext>
3723functions have been added to the API.
3724They allow extension authors to find and remove magic attached to
3725scalars based on both the magic type and the magic virtual table, similar to how
3726C<sv_magicext()> attaches magic of a certain type and with a given virtual table
3727to a scalar. This eliminates the need for extensions to walk the list of
3728C<MAGIC> pointers of an C<SV> to find the magic that belongs to them.
3729
3730=item *
3731
3732The
3733L<C<parse_fullexpr()>|perlapi/parse_fullexpr>,
3734L<C<parse_listexpr()>|perlapi/parse_listexpr>,
3735L<C<parse_termexpr()>|perlapi/parse_termexpr>, and
3736L<C<parse_arithexpr()>|perlapi/parse_arithexpr>
3737functions have been added to the API. They perform
3738recursive-descent parsing of expressions at various precedence levels.
3739They are expected to be used by syntax plugins.
3740
3741=item *
3742
3743The opcode bodies for C<chop> and C<chomp> and for C<schop> and C<schomp> have
3744been merged. The implementation functions C<Perl_do_chop()> and
3745C<Perl_do_chomp()>, never part of the public API, have been merged and moved to
3746a static function in F<pp.c>. This shrinks the perl binary slightly, and should
3747not affect any code outside the core (unless it is relying on the order of side
3748effects when C<chomp> is passed a I<list> of values).
3749
3750=item *
3751
3752Some of the flags parameters to the uvuni_to_utf8_flags() and
3753utf8n_to_uvuni() have changed. This is a result of Perl now allowing
3754internal storage and manipulation of code points that are problematic
3755in some situations. Hence, the default actions for these functions has
3756been complemented to allow these code points. The new flags are
3757documented in L<perlapi>. Code that requires the problematic code
3758points to be rejected needs to change to use these flags. Some flag
3759names are retained for backward source compatibility, though they do
3760nothing, as they are now the default. However the flags
3761C<UNICODE_ALLOW_FDD0>, C<UNICODE_ALLOW_FFFF>, C<UNICODE_ILLEGAL>, and
3762C<UNICODE_IS_ILLEGAL> have been removed, as they stem from a
3763fundamentally broken model of how the Unicode non-character code points
3764should be handled, which is now described in
3765L<perlunicode/Non-character code points>. See also L</Selected Bug Fixes>.
3766
3767=item *
3768
3769Certain shared flags in the C<pmop.op_pmflags> and C<regexp.extflags>
3770structures have been removed. These are: C<Rxf_Pmf_LOCALE>,
3771C<Rxf_Pmf_UNICODE>, and C<PMf_LOCALE>. Instead there are encodes and
3772three static in-line functions for accessing the information:
3773C<get_regex_charset()>, C<set_regex_charset()>, and C<get_regex_charset_name()>,
3774which are defined in the places where the original flags were.
3775
3776=item *
3777
3778A new option has been added to C<pv_escape> to dump all characters above
3779ASCII in hexadecimal. Before, one could get all characters as hexadecimal
3780or the Latin1 non-ASCII as octal
3781
3782
3783=item *
3784
3785Generate pp_* prototypes in pp_proto.h, and remove pp.sym
3786
3787Eliminate the #define pp_foo Perl_pp_foo(pTHX) macros, and update the 13
3788locations that relied on them.
3789
3790regen/opcode.pl now generates prototypes for the PP functions directly, into
3791pp_proto.h. It no longer writes pp.sym, and regen/embed.pl no longer reads
3792this, removing the only ordering dependency in the regen scripts. opcode.pl
3793is now responsible for prototypes for pp_* functions. (embed.pl remains
3794responsible for ck_* functions, reading from regen/opcodes)
3795
3796=item *
3797
3798Fix harmless invalid read in Perl_re_compile() (f6d9469)
3799
3800[perl #2460] described a case where electric fence reported an invalid
3801read. This could be reproduced under valgrind with blead and -e'/x/',
3802but only on a non-debugging build.
3803
3804This was because it was checking for certain pairs of nodes (e.g. BOL + END)
3805and wasn't allowing for EXACT nodes, which have the string at the next
3806node position when using a naive NEXTOPER(first). In the non-debugging
3807build, the nodes aren't initialised to zero, and a 1-char EXACT node isn't
3808long enough to spill into the type field of the "next node".
3809
3810Fix this by only using NEXTOPER(first) when we know the first node is
3811kosher.
3812
3813=item *
3814
3815Break out the generated function Perl_keywords() into F<keywords.c>, a new file. (26ea9e1)
3816
3817As it and Perl_yylex() both need FEATURE_IS_ENABLED, feature_is_enabled() is
3818no longer static, and the two macro definitions move from toke.c to perl.h
3819
3820Previously, one had to cut and paste the output of perl_keywords.pl into the
3821middle of toke.c, and it was not clear that it was generated code.
3822
3823=item *
3824
3825A lot of tests have been ported from Test to Test::More, e.g. in
38263842ad6.
3827
3828=item *
3829
3830Increase default PerlIO buffer size. (b83080d)
3831
3832The previous default size of a PerlIO buffer (4096 bytes) has been increased
3833to the larger of 8192 bytes and your local BUFSIZ. Benchmarks show that doubling
3834this decade-old default increases read and write performance in the neighborhood
3835of 25% to 50% when using the default layers of perlio on top of unix. To choose
3836a non-default size, such as to get back the old value or to obtain and even
3837larger value, configure with:
3838
3839 ./Configure -Accflags=-DPERLIOBUF_DEFAULT_BUFSIZ=N
3840
3841where N is the desired size in bytes; it should probably be a multiple of
3842your page size.
3843
3844=back
3845
3846=head1 Selected Bug Fixes
3847
3848=over 4
3849
3850=item *
3851
4ed2cea4
FC
3852C<when(scalar){...}> no longer crashes, but produces a syntax error
3853[perl #74114].
3854
3855=item *
3856
3857The C-level C<lex_stuff_pvn> function would sometimes cause a spurious
3858syntax error on the last line of the file if it lacked a final semicolon
3859[perl #74006].
3860
3861=item *
3862
3863The regular expression engine no longer loops when matching
3864C<"\N{LATIN SMALL LIGATURE FF}" =~ /f+/i> and similar expressions
3865[perl #72998].
3866
3867=item *
3868
3869A label right before a string eval (C<foo: eval $string>) no longer causes
3870the label to be associated also with the first statement inside the eval
3871[perl #74290] (5.12.1).
3872
3873=item *
3874
5076a392
FC
3875Naming a deprecated character in \N{...} will not leak memory.
3876
3877=item *
3878
3879FETCH is no longer called needlessly on some tied variables.
3880
3881=item *
3882
3883The trie runtime code should no longer allocate massive amounts of memory,
3884fixing #74484.
3885
3886=item *
3887
3888Timely cleanup of SVs that are cloned into a new thread but then
3889discovered to be orphaned (i.e. their owners are -not- cloned) (e42956)
3890
3891=item *
3892
3893Don't accidentally clone lexicals in scope within active stack frames in
3894the parent when creating a child thread (RT #73086) (05d04d).
3895
3896=item *
3897
3898Avoid loading feature.pm when 'no 5.13.2;' or similar is
3899encountered (faee19).
3900
3901=item *
3902
3903Trap invalid use of SvIVX on SVt_REGEXP when assertions are on
3904(e77da3)
3905
3906=item *
3907
3908Don't stamp on $DB::single, $DB::trace and $DB::signal if they
3909already have values when $^P is assigned to (RT #72422) (4c0f30).
3910
3911=item *
3912
3913chop now correctly handles perl's extended UTF-8 (RT #73246) (65ab92)
3914
3915=item *
3916
3917Defer signal handling when shared SV locks are held to avoid
3918deadlocks (RT #74868) (65c742).
3919
3920=item *
3921
3922glob() no longer crashes when %File::Glob:: is empty and
3923CORE::GLOBAL::glob isn't present (4984aa).
3924
3925=item *
3926
3927perlbug now always permits the sender address to be changed
3928before sending - if you were having trouble sending bug reports before
3929now, this should fix it, we hope (e6eb90).
3930
3931=item *
3932
3933Overloading now works properly in conjunction with tied
3934variables. What formerly happened was that most ops checked their
3935arguments for overloading I<before> checking for magic, so for example
3936an overloaded object returned by a tied array access would usually be
3937treated as not overloaded (RT #57012) (6f1401, ed3b9b, 6a5f8c .. 24328f).
3938
3939=item *
3940
3941Independently, a bug was fixed that prevented $tied-E<gt>() from
3942always calling FETCH correctly (RT #8438) (7c7501)
3943
3944=item *
3945
3946Some work has been done on the internal pointers that link between symbol
3947tables (stashes), typeglobs and subroutines. This has the effect that
3948various edge cases related to deleting stashes or stash entries (e.g.
3949<%FOO:: = ()>), and complex typeglob or code reference aliasing, will no
3950longer crash the interpreter.
3951
3952=item *
3953
3954Fixed readline() when interrupted by signals so it no longer returns
3955the "same thing" as before or random memory
3956
3957=item *
3958
3959Fixed a regression of kill() when a match variable is used for the
3960process ID to kill (RT#75812) (8af710e)
3961
3962=item *
3963
3964Fixed several subtle bugs in sort() when @_ is accessed within a subroutine
3965used for sorting (RT#72334) (8f443ca)
3966
3967=item *
3968
3969Catch yyparse() exceptions in C<< (?{...}) >> (RT#2353) (634d691)
3970
3971=item *
3972
3973Avoid UTF-8 cache panics with offsets beyond a string (RT #75898) (3e2d381)
3974
3975=item *
3976
3977Fixed POSIX::strftime memory leak (RT#73520) (c4bc4aa)
3978
3979=item *
3980
3981Doesn't set strict with C<no VERSION> if C<VERSION> is greater than 5.12
3982(da8fb5d)
3983
3984=item *
3985
3986Avoids multiple FETCH/stringify on filetest ops (40c852d)
3987
3988=item *
3989
3990Fixed issue with string C<eval> not detecting taint of overloaded/tied
3991arguments (RT #75716) (895b760)
3992
3993=item *
3994
3995Fix potential crashes of string C<eval> when evaluating a object with
3996overloaded stringification by creating a stringified copy when necessary
3997(3e5c018)
3998
3999=item *
4000
4001Fixed bug where overloaded stringification could remove tainting
4002(RT #75716) (a02ec77)
4003
4004=item *
4005
4006Plugs more memory leaks in vms.c. (9e2bec0)
4007
4008=item *
4009
4010Fix pthread include error for Time::Piece (e9f284c)
4011
4012=item *
4013
4014A possible memory leak when using L<caller()|perlfunc/"caller EXPR"> to set
4015C<@DB::args> has been fixed.
4016
4017=item *
4018
4019Several memory leaks when loading XS modules were fixed.
4020
4021=item *
4022
4023A panic in the regular expression optimizer has been fixed (RT#75762).
4024
4025=item *
4026
4027Assignments to lvalue subroutines now honor copy-on-write behavior again, which
4028has been broken since version 5.10.0 (RT#75656).
4029
4030=item *
4031
4032Assignments to glob copies now behave just like assignments to regular globs
4033(RT#1804).
4034
4035=item *
4036
4037Within signal handlers, C<$!> is now implicitly localized.
4038
4039=item *
4040
4041L<readline|perlfunc/"readline EXPR"> now honors C<< <> >> overloading on tied
4042arguments.
4043
4044=item *
4045
4046L<substr()|perlfunc/"substr EXPR,OFFSET,LENGTH,REPLACEMENT">,
4047L<pos()|perlfunc/"index STR,SUBSTR,POSITION">, L<keys()|perlfunc/"keys HASH">,
4048and L<vec()|perlfunc/"vec EXPR,OFFSET,BITS"> could, when used in combination
4049with lvalues, result in leaking the scalar value they operate on, and cause its
4050destruction to happen too late. This has now been fixed.
4051
4052=item *
4053
4054Building with C<PERL_GLOBAL_STRUCT>, which has been broken accidentally in
40555.13.3, now works again.
4056
4057=item *
4058
4059A regression introduced in Perl 5.12.0, making
4060C<< my $x = 3; $x = length(undef) >> result in C<$x> set to C<3> has been
4061fixed. C<$x> will now be C<undef>.
4062
4063=item *
4064
4065A fatal error in regular expressions when processing UTF-8 data has been fixed [perl #75680].
4066
4067=item *
4068
4069An erroneous regular expression engine optimization that caused regex verbs like
4070C<*COMMIT> to sometimes be ignored has been removed.
4071
4072=item *
4073
4074The Perl debugger now also works in taint mode [perl #76872].
4075
4076=item *
4077
4078Several memory leaks in cloning and freeing threaded Perl interpreters have been
4079fixed [perl #77352].
4080
4081=item *
4082
4083A possible string corruption when doing regular expression matches on overloaded
4084objects has been fixed [perl #77084].
4085
4086=item *
4087
4088Magic applied to variables in the main package no longer affects other packages.
4089See L</Magic variables outside the main package> above [perl #76138].
4090
4091=item *
4092
4093Opening a glob reference via C<< open $fh, "E<gt>", \*glob >> will no longer
4094cause the glob to be corrupted when the filehandle is printed to. This would
4095cause perl to crash whenever the glob's contents were accessed
4096[perl #77492].
4097
4098=item *
4099
4100The postincrement and postdecrement operators, C<++> and C<-->, used to cause
4101leaks when being used on references. This has now been fixed.
4102
4103=item *
4104
4105A bug when replacing the glob of a loop variable within the loop has been fixed
4106[perl #21469]. This
4107means the following code will no longer crash:
4108
4109 for $x (...) {
4110 *x = *y;
4111 }
4112
4113=item *
4114
4115Perl would segfault if the undocumented C<Internals> functions that used
4116reference prototypes were called with the C<&foo()> syntax, e.g.
4117C<&Internals::SvREADONLY(undef)> [perl #77776].
4118
4119These functions now call C<SvROK> on their arguments before dereferencing them
4120with C<SvRV>, and we test for this case in F<t/lib/universal.t>.
4121
4122=item *
4123
4124When assigning a list with duplicated keys to a hash, the assignment used to
4125return garbage and/or freed values:
4126
4127 @a = %h = (list with some duplicate keys);
4128
4129This has now been fixed [perl #31865].
4130
4131=item *
4132
4133An earlier release of the 5.13 series of Perl changed the semantics of opening a
4134reference to a copy of a glob:
4135
4136 my $var = *STDOUT;
4137 open my $fh, '>', \$var;
4138
4139This was a mistake, and the previous behaviour from Perl 5.10 and 5.12, which is
4140to treat \$var as a scalar reference, has now been restored.
4141
4142=item *
4143
4144The regular expression bracketed character class C<[\8\9]> was effectively the
4145same as C<[89\000]>, incorrectly matching a NULL character. It also gave
4146incorrect warnings that the C<8> and C<9> were ignored. Now C<[\8\9]> is the
4147same as C<[89]> and gives legitimate warnings that C<\8> and C<\9> are
4148unrecognized escape sequences, passed-through.
4149
4150=item *
4151
4152C<warn()> and C<die()> now respect utf8-encoded scalars [perl #45549].
4153
4154=item *
4155
4156A regular expression match in the right-hand side of a global substitution
4157(C<s///g>) that is in the same scope will no longer cause match variables
4158to have the wrong values on subsequent iterations. This can happen when an
4159array or hash subscript is interpolated in the right-hand side, as in
4160C<s|(.)|@a{ print($1), /./ }|g> [perl #19078].
4161
4162=item *
4163
4164Constant-folding used to cause
4165
4166 $text =~ ( 1 ? /phoo/ : /bear/)
4167
4168to turn into
4169
4170 $text =~ /phoo/
4171
4172at compile time. Now it correctly matches against C<$_> [perl #20444].
4173
4174=item *
4175
4176Parsing Perl code (either with string C<eval> or by loading modules) from
4177within a C<UNITCHECK> block no longer causes the interpreter to crash
4178[perl #70614].
4179
4180=item *
4181
4182When C<-d> is used on the shebang (C<#!>) line, the debugger now has access
4183to the lines of the main program. In the past, this sometimes worked and
4184sometimes did not, depending on what order things happened to be arranged
4185in memory [perl #71806].
4186
4187=item *
4188
4189The C<y///> or C<tr///> operator now calls get-magic (e.g., the C<FETCH>
4190method of a tie) on its left-hand side just once, not twice [perl #76814].
4191
4192=item *
4193
4194String comparison (C<eq>, C<ne>, C<lt>, C<gt>, C<le>, C<ge> and
4195C<cmp>) and logical not (C<not> and C<!>) operators no longer call magic
4196(e.g., tie methods) twice on their operands [perl #76814].
4197
4198This bug was introduced in an earlier 5.13 release, and does not affect
4199perl 5.12.
4200
4201=item *
4202
4203When a tied (or other magic) variable is used as, or in, a regular
4204expression, it no longer has its C<FETCH> method called twice
4205[perl #76814].
4206
4207This bug was introduced in an earlier 5.13 release, and does not affect
4208perl 5.12.
4209
4210=item *
4211
4212The C<-C> command line option can now be followed by other options
4213[perl #72434].
4214
4215=item *
4216
4217Assigning a glob to a PVLV used to convert it to a plain string. Now it
4218works correctly, and a PVLV can hold a glob. This would happen when a
4219nonexistent hash or array element was passed to a subroutine:
4220
4221 sub { $_[0] = *foo }->($hash{key});
4222 # $_[0] would have been the string "*main::foo"
4223
4224It also happened when a glob was assigned to, or returned from, an element
4225of a tied array or hash [perl #36051].
4226
4227=item *
44691e6f 4228
5076a392
FC
4229Creating a new thread when directory handles were open used to cause a
4230crash, because the handles were not cloned, but simply passed to the new
4231thread, resulting in a double free.
44691e6f 4232
5076a392
FC
4233Now directory handles are cloned properly, on systems that have a C<fchdir>
4234function. On other systems, new threads simply do not inherit directory
4235handles from their parent threads [perl #75154].
44691e6f 4236
5076a392 4237=item *
44691e6f 4238
5076a392
FC
4239The regular expression parser no longer hangs when parsing C<\18> and
4240C<\88>.
44691e6f 4241
5076a392
FC
4242This bug was introduced in version 5.13.5 and did not affect earlier
4243versions [perl #78058].
b7188eb5 4244
5076a392 4245=item *
b7188eb5 4246
5076a392 4247Subroutine redefinition works once more in the debugger [perl #48332].
44691e6f 4248
5076a392 4249=item *
658a9f31 4250
5076a392
FC
4251The C<&> C<|> C<^> bitwise operators no longer coerce read-only arguments
4252[perl #20661].
658a9f31 4253
5076a392 4254=item *
658a9f31 4255
5076a392
FC
4256Stringifying a scalar containing -0.0 no longer has the affect of turning
4257false into true [perl #45133].
b7188eb5 4258
5076a392 4259=item *
b7188eb5 4260
5076a392
FC
4261Aliasing packages by assigning to globs or deleting packages by deleting
4262their containing stash elements used to have erratic effects on method
4263resolution, because the internal 'isa' caches were not reset. This has been
4264fixed.
b7188eb5 4265
5076a392 4266=item *
3aa0ac5a 4267
5076a392
FC
4268C<sort> with a custom sort routine could crash if too many nested
4269subroutine calls occurred from within the sort routine [perl #77930].
3aa0ac5a 4270
5076a392
FC
4271This bug was introduced in an earlier 5.13 release, and did not affect
4272perl 5.12.
3aa0ac5a 4273
5076a392 4274=item *
3aa0ac5a 4275
5076a392
FC
4276The C<eval_sv> and C<eval_pv> C functions now set C<$@> correctly when
4277there is a syntax error and no C<G_KEEPERR> flag, and never set it if the
4278C<G_KEEPERR> flag is present [perl #3719].
270ca148 4279
5076a392 4280=item *
270ca148 4281
5076a392
FC
4282Nested C<map> and C<grep> blocks no longer leak memory when processing
4283large lists [perl #48004].
270ca148 4284
5076a392 4285=item *
44691e6f 4286
5076a392 4287Malformed C<version> objects no longer cause crashes [perl #78286].
44691e6f
AB
4288
4289=item *
4290
5076a392
FC
4291The interpreter no longer crashes when freeing deeply-nested arrays of
4292arrays. Hashes have not been fixed yet [perl #44225].
44691e6f 4293
5076a392 4294=item *
44691e6f 4295
5076a392
FC
4296The mechanism for freeing objects in globs used to leave dangling
4297pointers to freed SVs, meaning Perl users could see corrupted state
4298during destruction.
44691e6f 4299
5076a392
FC
4300Perl now only frees the affected slots of the GV, rather than freeing
4301the GV itself. This makes sure that there are no dangling refs or
4302corrupted state during destruction.
65484cb9 4303
5076a392 4304=item *
b7188eb5 4305
5076a392
FC
4306The typeglob C<*,>, which holds the scalar variable C<$,> (output field
4307separator), had the wrong reference count in child threads.
911a3729 4308
5076a392
FC
4309=item *
4310
4311C<splice> now calls set-magic. This means that, for instance, changes made
4312by C<splice @ISA> are respected by method calls [perl #78400].
452d0b70
DG
4313
4314=item *
4315
5076a392 4316C<use v5.8> no longer leaks memory [perl #78436].
911a3729 4317
5076a392 4318=item *
c8c13991 4319
5076a392
FC
4320The XS multicall API no longer causes subroutines to lose reference counts
4321if called via the multicall interface from within those very subroutines.
4322This affects modules like List::Util. Calling one of its functions with an
4323active subroutine as the first argument could cause a crash [perl #78070].
c8c13991 4324
5076a392
FC
4325=item *
4326
4327The C<parse_stmt> C function added in earlier in the 5.13.x series has been
4328fixed to work with statements ending with C<}> [perl #78222].
44691e6f 4329
f00d3350
BR
4330=item *
4331
5076a392
FC
4332The C<parse_fullstmt> C function added in 5.13.5 has been fixed to work
4333when called while an expression is being parsed.
fe3de278 4334
5076a392 4335=item *
35cdccfc 4336
5076a392
FC
4337Characters in the Latin-1 non-ASCII range (0x80 to 0xFF) used not to match
4338themselves if the string happened to be UTF8-encoded internally, the
4339regular expression was not, and the character in the regular expression was
4340inside a repeated group (e.g.,
4341C<Encode::decode_utf8("\303\200") =~ /(\xc0)+/>) [perl #78464].
35cdccfc 4342
5076a392
FC
4343=item *
4344
4345The C<(?d)> regular expression construct now overrides a previous C<(?u)>
4346or C<use feature "unicode_string"> [perl #78508].
f5c40488
CBW
4347
4348=item *
4349
5076a392
FC
4350A memory leak in C<do "file">, introduced in perl 5.13.6, has been fixed
4351[perl #78488].
b7188eb5 4352
5076a392 4353=item *
b7188eb5 4354
5076a392
FC
4355Various bugs related to typeglob dereferencing have been fixed. See
4356L</Dereferencing typeglobs>, above.
0bb35765 4357
5076a392 4358=item *
911a3729 4359
5076a392
FC
4360The C<SvPVbyte> function available to XS modules now calls magic before
4361downgrading the SV, to avoid warnings about wide characters [perl #72398].
911a3729 4362
5076a392 4363=item *
58f55cb3 4364
5076a392
FC
4365The C<=> operator used to ignore magic (e.g., tie methods) on its
4366right-hand side if the scalar happened to hold a typeglob. This could
4367happen if a typeglob was the last thing returned from or assigned to a tied
4368scalar [perl #77498].
58f55cb3 4369
5076a392 4370=item *
6b3df227 4371
5076a392
FC
4372C<sprintf> was ignoring locales when called with constant arguments
4373[perl #78632].
6b3df227 4374
5076a392 4375=item *
c9989a74 4376
5076a392
FC
4377A non-ASCII character in the Latin-1 range could match both a Posix
4378class, such as C<[[:alnum:]]>, and its inverse C<[[:^alnum:]]>. This is
4379now fixed for regular expressions compiled under the C<"u"> modifier.
4380See L</C<use feature "unicode_strings"> now applies to more regex matching>. [perl #18281].
c9989a74 4381
5076a392
FC
4382=item *
4383
4384Concatenating long strings under C<use encoding> no longer causes perl to
4385crash [perl #78674].
b7188eb5
FC
4386
4387=item *
4388
5076a392
FC
4389Typeglob assignments would crash if the glob's stash no longer existed, so
4390long as the glob assigned to was named 'ISA' or the glob on either side of
4391the assignment contained a subroutine.
911a3729 4392
5076a392 4393=item *
c8c13991 4394
5076a392
FC
4395Calling C<< ->import >> on a class lacking an import method could corrupt
4396the stack, resulting in strange behaviour. For instance,
c8c13991 4397
5076a392 4398 push @a, "foo", $b = bar->import;
f00d3350 4399
5076a392 4400would assign 'foo' to C<$b> [perl #63790].
c34a735e 4401
5076a392 4402=item *
b7188eb5 4403
5076a392
FC
4404Creating an alias to a package when that package had been detached from the
4405symbol table would result in corrupted isa caches [perl #77358].
b7188eb5 4406
5076a392 4407=item *
b7188eb5 4408
5076a392
FC
4409C<.=> followed by C<< <> >> or C<readline> would leak memory if C<$/>
4410contained characters beyond the octet range and the scalar assigned to
4411happened to be encoded as UTF8 internally [perl #72246].
c34a735e 4412
05dbc6f8
KW
4413=item *
4414
5076a392
FC
4415The C<recv> function could crash when called with the MSG_TRUNC flag
4416[perl #75082].