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