This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Document the "perl -d" bug fixes commit.
[perl5.git] / pod / perldelta.pod
CommitLineData
44691e6f
AB
1=encoding utf8
2
541cb22c 3=for comment
7f28d7ed 4This has been completed up to 5dca8ed9d28, except for
d6b99bf4 5b0f2e9e nwclark Fix two bugs related to pod files outside of pod/ (important enough?)
d6b99bf4 69b9f19d craigb Another vms bug
7f28d7ed 7cc5de3b craigb " " "
7f28d7ed
DR
843d9ecf jpeacock Set all version object math ops to noop
9f300909 smueller EU::ParseXS: Silence warning (probably unnecessary)
541cb22c 10
44691e6f
AB
11=head1 NAME
12
0aaeb177
SH
13[ this is a template for a new perldelta file. Any text flagged as
14XXX needs to be processed before release. ]
760696b8 15
0aaeb177 16perldelta - what is new for perl v5.15.6
062678b2 17
0aaeb177 18=head1 DESCRIPTION
ad32999b 19
0aaeb177
SH
20This document describes differences between the 5.15.5 release and
21the 5.15.6 release.
ad32999b 22
0aaeb177
SH
23If you are upgrading from an earlier release such as 5.15.4, first read
24L<perl5155delta>, which describes differences between 5.15.4 and
255.15.5.
ad32999b 26
0aaeb177 27=head1 Notice
ad32999b 28
0aaeb177 29XXX Any important notices here
ad32999b 30
0aaeb177 31=head1 Core Enhancements
a3f52e2e 32
0aaeb177
SH
33XXX New core language features go here. Summarise user-visible core language
34enhancements. Particularly prominent performance optimisations could go
35here, but most should go in the L</Performance Enhancements> section.
a3f52e2e 36
0aaeb177 37[ List each enhancement as a =head2 entry ]
6d110ad0 38
61f966e7
FC
39=head2 C<__SUB__>
40
41The new C<__SUB__> token, available under the "current_sub" feature (see
42L<feature>) or C<use v5.15>, returns a reference to the current subroutine,
43making it easier to write recursive closures.
44
d1fb015b
FC
45=head2 New option for the debugger's B<t> command
46
47The B<t> command in the debugger, which toggles tracing mode, now accepts a
48numerical argument that determines how many levels of subroutine calls to
49trace.
50
7e7629fa
FC
51=head2 Return value of C<tied>
52
53The value returned by C<tied> on a tied variable is now the actual scalar
54that holds the object to which the variable is tied. This allows ties to
55be weakened with C<Scalar::Util::weaken(tied $tied_variable)>.
56
7f28d7ed
DR
57=head2 Lvalue C<scalar>
58
59C<scalar> can now be used as an lvalue. You might consider this a new
60feature (which is why it is listed in this section), but the author of
61the change considered it a bug fix, since C<scalar> is only supposed to be
62setting scalar context, not changing lvalueness [perl #24346].
63
e3c71926 64=head1 Security
6d110ad0 65
0aaeb177
SH
66XXX Any security-related notices go here. In particular, any security
67vulnerabilities closed should be noted here rather than in the
68L</Selected Bug Fixes> section.
6d110ad0 69
6d91e957
KW
70=head2 C<is_utf8_char()>
71
72The XS-callable function C<is_utf8_char()> when presented with malformed
73UTF-8 input can read up to 12 bytes beyond the end of the string. This
74cannot be fixed without changing its API. It is not called from CPAN.
75The documentation for it now describes how to use it safely.
76
77=head2 Other C<is_utf8_foo()> functions, as well as C<utf8_to_foo()>, etc.
78
79Most of the other XS-callable functions that take UTF-8 encoded input
80implicitly assume that the UTF-8 is valid (not malformed) in regards to
81buffer length. Do not do things such as change a character's case or
82see if it is alphanumeric without first being sure that it is valid
83UTF-8. This can be safely done for a whole string by using one of the
84functions C<is_utf8_string()>, C<is_utf8_string_loc()>, and
85C<is_utf8_string_loclen()>.
6d110ad0 86
e3c71926 87=head1 Incompatible Changes
6d110ad0 88
0aaeb177 89XXX For a release on a stable branch, this section aspires to be:
ad32999b 90
0aaeb177
SH
91 There are no changes intentionally incompatible with 5.XXX.XXX
92 If any exist, they are bugs and reports are welcome.
ad32999b 93
0aaeb177 94[ List each incompatible change as a =head2 entry ]
ad32999b 95
7f28d7ed
DR
96=head2 C<use I<VERSION>>
97
98As of this release, version declarations like C<use v5.16> now disable all
99features before enabling the new feature bundle. This means that the
100following holds true:
101
102 use 5.016;
103 # 5.16 features enabled here
104 use 5.014;
105 # 5.16 features disabled here
106
107C<use v5.12> and higher continue to enable strict, but explicit
108C<use strict> and C<no strict> now override the version declaration, even
109when they come first:
110
111 no strict;
112 use 5.012;
113 # no strict here
114
115There is a new ":default" feature bundle, that represents the set of
116features enabled before any version declaration or C<use feature> has been
117seen. Version declarations below 5.10 now enable the ":default" feature
118set. This does not actually change the behaviour of C<use v5.8>, because
119features added to the ":default" set are those that were traditionally
120enabled by default, before they could be turned off.
121
122C<$[> is now disabled under C<use v5.16>. It is part of the default
123feature set and can be turned on or off explicitly
124with C<use feature 'array_base'>.
125
126=head2 C<UNIVERSAL::VERSION>
127
128The change to C<UNIVERSAL::VERSION> in 5.15.2 has been reverted. It now
129returns a stringified version object once more.
130
66008486
FC
131=head2 C<substr> lvalue revamp
132
133When C<substr> is called in lvalue or potential lvalue context with two or
134three arguments, a special lvalue scalar is returned that modifies the
135original string (the first argument) when assigned to.
136
137Previously, the offsets (the second and third arguments) passed to
138C<substr> would be converted immediately to match the string, negative
139offsets being translated to positive and offsets beyond the end of the
140string being truncated.
141
142Now, the offsets are recorded without modification in the special lvalue
143scalar that is returned, and the original string is not even looked at by
144C<substr> itself, but only when the returned lvalue is read or modified.
145
146These changes result in several incompatible changes and bug fixes:
147
148=over
149
150=item *
151
152If the original string changes length after the call to C<substr> but
153before assignment to its return value, negative offsets will remember
154their position from the end of the string, affecting code like this:
155
156 my $string = "string";
157 my $lvalue = \substr $string, -4, 2;
158 print $lvalue, "\n"; # prints "ri"
159 $string = "bailing twine";
160 print $lvalue, "\n"; # prints "wi"; used to print "il"
161
162The same thing happens with an omitted third argument. The returned lvalue
163will always extend to the end of the string, even if the string becomes
164longer.
165
166=item *
167
168Tied (and otherwise magical) variables are no longer exempt from the
169"Attempt ot use reference as lvalue in substr" warning.
170
171=item *
172
173That warning now occurs when the returned lvalue is assigned to, not when
174C<substr> itself is called. This only makes a difference if the return
175value of C<substr> is referenced and assigned to later.
176
177=item *
178
179The order in which "uninitialized" warnings occur for arguments to
180C<substr> has changed.
181
182=item *
183
184Passing a substring of a read-only value or a typeglob to a function (potential lvalue context) no longer causes an immediate "Can't coerce" or "Modification of a read-only value" error. That error only occurs if and
185when the value passed is assigned to.
186
7e7629fa
FC
187The same thing happens with the "substr outside of string" error. If the
188lvalue is only read, not written to, it is now just a warning, as with
189rvalue C<substr>.
66008486
FC
190
191=item *
192
193C<substr> assignments no longer call FETCH twice if the first argument is a
194tied variable, but just once.
195
196=back
197
198It was impossible to fix all the bugs without an incompatible change, and
199the behaviour of negative offsets was never specified, so the change was
200deemed acceptable.
201
d6b99bf4
FC
202=head2 Return value of C<eval>
203
204C<eval> returns C<undef> in scalar context or an empty list in list context
205when there is a run-time error. For syntax errors (when C<eval> is passed
206a string), in list context it used to return a list containing a single
207undefined element. Now it returns an empty list in list context for all
208errors [perl #80630].
209
7f28d7ed
DR
210=head2 Anonymous handles
211
212Automatically generated file handles are now named __ANONIO__ when the
213variable name cannot be determined, rather than $__ANONIO__.
214
541cb22c
FC
215=head2 XS API tweak
216
217The C<newCONSTSUB_flags> C-level function, added in 5.15.4, now has a
218C<len> parameter.
219
e3c71926 220=head1 Deprecations
6d110ad0 221
0aaeb177
SH
222XXX Any deprecated features, syntax, modules etc. should be listed here.
223In particular, deprecated modules should be listed here even if they are
224listed as an updated module in the L</Modules and Pragmata> section.
ae92a9ae 225
0aaeb177 226[ List each deprecation as a =head2 entry ]
ae92a9ae 227
e3c71926 228=head1 Performance Enhancements
6d110ad0 229
0aaeb177
SH
230XXX Changes which enhance performance without changing behaviour go here. There
231may well be none in a stable release.
232
233[ List each enhancement as a =item entry ]
234
e3c71926 235=over 4
6d110ad0
FC
236
237=item *
238
679b54e7
FC
239Perl 5.12.0 sped up the destruction of objects whose classes define empty
240C<DESTROY> methods (to prevent autoloading), simply by not calling such
241empty methods. This release takes this optimisation a step further, by not
242calling any C<DESTROY> method that begins with an C<return> statement.
243This can be useful for destructors that are only used for debugging:
244
245 use constant DEBUG => 1;
246 sub DESTROY { return unless DEBUG; ... }
247
248Constant-folding will reduce the first statement to C<return;> if DEBUG is
249set to 0, triggering this optimisation.
6d110ad0 250
d1fb015b
FC
251=item *
252
253Assign to a variable that holds a typeglob or copy-on-write scalar is now
254much faster. Previously the typeglob would be stringified or the
255copy-on-write scalar would be copied before being clobbered.
256
7e7629fa
FC
257=item *
258
259Assignment to a substring in void context is now more than twice its
260previous speed. Instead of creating and returning a special lvalue scalar
261that is then assigned to, C<substr> modifies the original string itself.
262
e3c71926 263=back
6d110ad0 264
e3c71926 265=head1 Modules and Pragmata
6d110ad0 266
0aaeb177
SH
267XXX All changes to installed files in F<cpan/>, F<dist/>, F<ext/> and F<lib/>
268go here. If Module::CoreList is updated, generate an initial draft of the
269following sections using F<Porting/corelist-perldelta.pl>, which prints stub
270entries to STDOUT. Results can be pasted in place of the '=head2' entries
271below. A paragraph summary for important changes should then be added by hand.
272In an ideal world, dual-life modules would have a F<Changes> file that could be
273cribbed.
274
275[ Within each section, list entries as a =item entry ]
276
e3c71926 277=head2 New Modules and Pragmata
6d110ad0 278
e3c71926 279=over 4
6d110ad0
FC
280
281=item *
282
0aaeb177 283XXX
6d110ad0
FC
284
285=back
286
e3c71926 287=head2 Updated Modules and Pragmata
6d110ad0 288
e3c71926 289=over 4
6d110ad0
FC
290
291=item *
292
f8c9502f
CBW
293L<Archive::Tar> has been upgraded from version 1.80 to version 1.82.
294
295Adjustments to handle files >8gb (>0777777777777 octal) and a feature to
296return the MD5SUM of files in the archive.
a3f52e2e 297
87b9431e
CBW
298=item *
299
74c26f06
CBW
300L<AutoLoader> has been upgraded from version 5.71 to version 5.72.
301
302=item *
303
8cea0f87
CBW
304L<B::Debug> has been upgraded from version 1.16 to version 1.17.
305
306=item *
307
be4a9ab3 308L<B::Deparse> has been upgraded from version 1.09 to version 1.10.
679b54e7 309
7f28d7ed
DR
310Various constructs that used to be deparsed incorrectly have been fixed:
311
312=over
313
314=item C<sort(foo(bar))>
315
316C<sort foo(bar)>, how it used to deparse, makes foo the sort routine,
317rather than a regular function call.
318
319=item Keys and values in C<%^H>
320
321Undefined values in the hint hash were being deparsed as empty strings.
322Whenever the hint hash changed, all undefined values, even those
323unmodified, were being printed.
324
325Special characters, such as quotation marks, were not being escaped
326properly.
327
328Some values used to be omitted if, for instance, a key was the same as a
329previous value and vice versa.
330
331=item "method BLOCK" syntax
332
333C<method { $expr }> used to be deparsed as something like
334C<< do{ $expr }->method >>, but the latter puts the $expr in scalar
335context, whereas the former puts in list context.
336
337=item C<do +{}> and C<do({})>
338
339These are both variants of do-file syntax, but were being deparsed as
340do-blocks.
341
342=item Keywords that do not follow the llafr
343
344Keywords like C<return> and C<last> that do not follow the
345looks-like-a-function rule are now deparsed correctly with parentheses in
346the right place.
347
348Similarly, C<not>, which I<does> follow the llafr, was being deparsed as
349though it does not.
350
351=item C<=~>
352
353In various cases, B::Deparse started adding a spurious C<$_ =~> before the
354right-hand side in Perl 5.14; e.g., C<< "" =~ <$a> >> would become
355C<< "" =~ ($_ =~ <$a>) >>.
356
357=item C<open local *FH>
358
359C<open>, C<pipe> and other functions that autovivify handles used to omit
360C<local *> from C<local *FH>.
361
362=item Negated single-letter subroutine calls
363
364Negated subroutine calls like C<- f()> and C<-(f())> were being deparsed
365as file test operators.
366
367=item C<&{&}>
368
369C<&{&}> and C<& &>, which are calls to the subroutine named "&", believe it
370or not, were being deparsed as C<&&>.
371
372=back
679b54e7
FC
373
374=item *
375
9505dd85 376L<Compress::Raw::Zlib> has been upgraded from version 2.042 to version 2.045.
87b9431e 377
7e700369
CBW
378=item *
379
6475ddc2 380L<Compress::Raw::Bzip2> has been upgraded from version 2.042 to version 2.045.
7e700369 381
dc7edc5c
CBW
382=item *
383
1d8dd5fc
CBW
384L<CPAN::Meta::YAML> has been upgraded from version 0.004 to version 0.005.
385
386=item *
387
9e87a279
CBW
388L<CPANPLUS> has been upgraded from version 0.9112 to version 0.9113.
389
390=item *
391
be4a9ab3 392L<Data::Dumper> has been upgraded from version 2.134 to version 2.135.
61f966e7
FC
393
394The XS implementation has been updated to account for the Unicode symbol
395changes in Perl 5.15.4. It also knows how to output typeglobs with nulls
396in their names.
397
398=item *
399
e39652ea
CBW
400L<Digest::SHA> has been upgraded from version 5.63 to version 5.70.
401
402Added BITS mode to addfile method and shasum which makes partial-byte inputs
403now possible via files/STDIN and allows shasum to check all 8074 NIST Msg vectors,
404where previously special programming was required to do this.
405
406=item *
407
7f28d7ed
DR
408L<Exporter> has been upgraded from version 5.65 to version 5.66.
409
410It no longer tries to localise C<$_> unnecessarily.
411
412=item *
413
ac616993
CBW
414L<ExtUtils::ParseXS> has been upgraded from version 3.05 to version 3.07.
415
416=item *
417
090349ce 418L<IO::Compress::Base> has been upgraded from version 2.042 to version 2.045.
08ad9465
CBW
419
420Added zipdetails utility.
dc7edc5c 421
7788a270
CBW
422=item *
423
4345d05b
CBW
424L<Locale::Codes> has been upgraded from version 3.18 to version 3.20.
425
426The code2XXX, XXX2code, all_XXX_codes, and all_XXX_names functions now support retired codes.
427All codesets may be specified by a constant or by their name now. Previously,
428they were specified only by a constant.
429The alias_code function exists for backward compatibility. It has been replaced by rename_country_code.
430The alias_code function will be removed sometime after September, 2013.
431All work is now done in the central module (Locale::Codes). Previously, some was still done in the
432wrapper modules (Locale::Codes::*) but that is gone now.
433Added Language Family codes (langfam) as defined in ISO 639-5.
434
435=item *
436
b42ff875
CBW
437L<Module::Loaded> has been uprgaded from version 0.06 to version 0.08.
438
439=item *
440
a71d67b1
CBW
441L<Pod::LaTeX> has been upgraded from version 0.59 to version 0.60.
442
443Added another LaTeX escape: --- => -{}-{}-
444
445Pod::LaTeX doesn't handle -- in PODs specially, passing it directly to
446LaTeX, which then proceeds to replace it with a single -. This patch
447replaces ----- with -{}-{}-{}-{}-
448
449=item *
450
be4a9ab3 451L<POSIX> has been upgraded from version 1.26 to version 1.27.
7e7629fa
FC
452
453It no longer produces a "Constant subroutine TCSANOW redefined" warning on
454Windows.
455
456XXX When did it start producing that warning? Was it post-5.15.5? Even if
457it was not, adding a note will help whoever compiles perl5160delta.
458
459=item *
460
c2654555
CBW
461L<Socket> has been upgraded from version 1.94_02 to version 1.96.
462
463=item *
464
85ca3be7
CBW
465L<threads> has been upgraded from version 1.85 to version 1.86.
466
467=item *
468
65ae8d99 469L<Unicode::Collate> has been upgraded from version 0.85 to version 0.87.
7788a270
CBW
470
471Tailored compatibility ideographs as well as unified ideographs for
472the locales: ja, ko, zh__big5han, zh__gb2312han, zh__pinyin, zh__stroke.
473
65ae8d99
CBW
474Now Locale/*.pl files are searched in @INC.
475
a3e88ad7
JP
476=item *
477
be4a9ab3 478L<UNIVERSAL> has been upgraded from version 1.10 to version 1.11.
a3e88ad7
JP
479
480Documentation change clarifies return values from UNIVERSAL::VERSION.
481
0aaeb177 482=back
6138a722 483
0aaeb177 484=head2 Removed Modules and Pragmata
6138a722 485
0aaeb177 486=over 4
be539103 487
a47fb3fe
CBW
488=item *
489
7f28d7ed
DR
490Changing the case of a UTF-8 encoded string under C<use locale> now
491gives better, but still imperfect, results. Previously, such a string
492would entirely lose locale semantics and silently be treated as Unicode.
493Now, the code points that are less than 256 are treated with locale
494rules, while those above 255 are, of course, treated as Unicode. See
495L<perlfunc/lc> for more details, including the deficiencies of this
496scheme.
a3f52e2e 497
0aaeb177 498=back
a3f52e2e 499
0aaeb177 500=head1 Documentation
a3f52e2e 501
0aaeb177
SH
502XXX Changes to files in F<pod/> go here. Consider grouping entries by
503file and be sure to link to the appropriate page, e.g. L<perlfunc>.
a3f52e2e 504
0aaeb177 505=head2 New Documentation
ad32999b 506
0aaeb177 507XXX Changes which create B<new> files in F<pod/> go here.
ad32999b 508
0aaeb177 509=head3 L<XXX>
ad32999b 510
0aaeb177 511XXX Description of the purpose of the new file here
6138a722 512
0aaeb177 513=head2 Changes to Existing Documentation
6138a722 514
0aaeb177
SH
515XXX Changes which significantly change existing files in F<pod/> go here.
516However, any changes to F<pod/perldiag.pod> should go in the L</Diagnostics>
517section.
a47fb3fe 518
7687d286 519=head3 L<perlsec/Laundering and Detecting Tainted Data>
a47fb3fe 520
0aaeb177 521=over 4
7ef25837 522
6d110ad0
FC
523=item *
524
7687d286
KW
525The example function for checking for taintedness contained a subtle
526error. C<$@> needs to be localized to prevent its changing this
527global's value outside the function. The preferred method to check for
528this, though, remains to use L<Scalar::Util/tainted>.
6d110ad0
FC
529
530=back
531
e3c71926
FR
532=head1 Diagnostics
533
534The following additions or changes have been made to diagnostic output,
535including warnings and fatal error messages. For the complete list of
536diagnostic messages, see L<perldiag>.
6d110ad0 537
0aaeb177
SH
538XXX New or changed warnings emitted by the core's C<C> code go here. Also
539include any changes in L<perldiag> that reconcile it to the C<C> code.
6138a722 540
0aaeb177
SH
541[ Within each section, list entries as a =item entry that links to perldiag,
542 e.g.
6138a722 543
0aaeb177 544 =item *
6138a722 545
0aaeb177
SH
546 L<Invalid version object|perldiag/"Invalid version object">
547]
6138a722 548
0aaeb177 549=head2 New Diagnostics
828d6195 550
0aaeb177 551XXX Newly added diagnostic messages go here
83307084 552
0aaeb177 553=head3 New Errors
d39de893 554
3432e5a1 555=over 4
39afdc5a
CBW
556
557=item *
558
0aaeb177 559XXX L<message|perldiag/"message">
6138a722 560
e3c71926 561=back
7b8e5ef0 562
0aaeb177 563=head3 New Warnings
91710846 564
e3c71926 565=over 4
91710846
DG
566
567=item *
568
0aaeb177 569XXX L<message|perldiag/"message">
f81e39ef 570
e3c71926 571=back
a2fa999d 572
0aaeb177
SH
573=head2 Changes to Existing Diagnostics
574
575XXX Changes (i.e. rewording) of diagnostic messages go here
bd65daab 576
e3c71926 577=over 4
bd65daab 578
3f2cb5bf
SM
579=item *
580
18fbfe8d
FC
581Redefinition warnings for constant subroutines used to be mandatory, even
582occurring under C<no warnings>. Now they respect the L<warnings> pragma.
b420b12a 583
61f966e7
FC
584=item *
585
586The "Attempt to free non-existent shared string" has had the spelling of
587"non-existent" corrected to "nonexistent". It was already listed with the
588correct spelling in L<perldiag>.
589
66008486
FC
590=item *
591
592The 'Use of "foo" without parentheses is ambiguous' warning has been
593extended to apply also to user-defined subroutines with a (;$) prototype,
594and not just to built-in functions.
595
3432e5a1 596=back
b420b12a 597
0aaeb177 598=head1 Utility Changes
9cfd094e 599
0aaeb177
SH
600XXX Changes to installed programs such as F<perlbug> and F<xsubpp> go
601here. Most of these are built within the directories F<utils> and F<x2p>.
95f7e41f 602
0aaeb177
SH
603[ List utility changes as a =head3 entry for each utility and =item
604entries for each change
605Use L<XXX> with program names to get proper documentation linking. ]
95f7e41f 606
08ad9465 607=head3 L<zipdetails>
d6cf2367 608
e3c71926 609=over 4
b53e16ae
FC
610
611=item *
612
08ad9465
CBW
613L<zipdetails> displays information about the internal record structure of the zip file.
614It is not concerned with displaying any details of the compressed data stored in the zip file.
b53e16ae 615
3432e5a1 616=back
60092ce4 617
0aaeb177
SH
618=head1 Configuration and Compilation
619
620XXX Changes to F<Configure>, F<installperl>, F<installman>, and analogous tools
621go here. Any other changes to the Perl build process should be listed here.
622However, any platform-specific changes should be listed in the
623L</Platform Support> section, instead.
624
625[ List changes as a =item entry ].
309aab3a 626
e3c71926 627=over 4
b53e16ae
FC
628
629=item *
630
60f0ee9d
NC
631F<pod/roffitall> is now build by F<pod/buildtoc>, instead of being shipped
632with the distribution. Its list of manpages is now generated (and therefore
633current). See also RT #103202 for an unresolved related issue.
a3f52e2e 634
61f966e7
FC
635=item *
636
637Perl 5.15.5 had a bug in its installation script, which did not install
638F<unicore/Name.pm>. This has been corrected [perl #104226].
639
640XXX Is that Perl version correct? Is the file path correct?
641
f4912a50
DR
642=item *
643
644The -Dusesitecustomize and -Duserelocatableinc options now work together
645properly.
646
0aaeb177 647=back
a3f52e2e 648
0aaeb177 649=head1 Testing
a3f52e2e 650
0aaeb177
SH
651XXX Any significant changes to the testing of a freshly built perl should be
652listed here. Changes which create B<new> files in F<t/> go here as do any
653large changes to the testing harness (e.g. when parallel testing was added).
654Changes to existing files in F<t/> aren't worth summarising, although the bugs
655that they represent may be covered elsewhere.
a3f52e2e 656
0aaeb177 657[ List each test improvement as a =item entry ]
a3f52e2e 658
0aaeb177 659=over 4
a3f52e2e
FC
660
661=item *
662
d1fb015b
FC
663The F<substr.t> and F<substr_thr.t> scripts for testing C<substr> have been
664moved under F<t/op/>, where they were originally. They had been moved
665under F<t/re/> along with the substitution tests when that directory was
666created.
a3f52e2e 667
0aaeb177 668=back
a3f52e2e 669
0aaeb177 670=head1 Platform Support
a3f52e2e 671
0aaeb177 672XXX Any changes to platform support should be listed in the sections below.
a3f52e2e 673
0aaeb177
SH
674[ Within the sections, list each platform as a =item entry with specific
675changes as paragraphs below it. ]
a3f52e2e 676
0aaeb177 677=head2 New Platforms
a3f52e2e 678
0aaeb177
SH
679XXX List any platforms that this version of perl compiles on, that previous
680versions did not. These will either be enabled by new files in the F<hints/>
681directories, or new subdirectories and F<README> files at the top level of the
682source tree.
a3f52e2e 683
0aaeb177 684=over 4
a3f52e2e 685
0aaeb177 686=item XXX-some-platform
a3f52e2e 687
0aaeb177 688XXX
a3f52e2e 689
0aaeb177 690=back
a3f52e2e 691
0aaeb177 692=head2 Discontinued Platforms
ca955add 693
0aaeb177 694XXX List any platforms that this version of perl no longer compiles on.
bbdd8bad 695
0aaeb177 696=over 4
bbdd8bad 697
0aaeb177 698=item XXX-some-platform
ad32999b 699
0aaeb177 700XXX
ad32999b 701
0aaeb177 702=back
ad32999b 703
0aaeb177 704=head2 Platform-Specific Notes
ad32999b 705
0aaeb177
SH
706XXX List any changes for specific platforms. This could include configuration
707and compilation changes or changes in portability/compatibility. However,
708changes within modules for platforms should generally be listed in the
709L</Modules and Pragmata> section.
ad32999b 710
f4912a50
DR
711=head3 VMS
712
0aaeb177 713=over 4
ad32999b 714
f4912a50 715=item *
ad32999b 716
f4912a50
DR
717Fixed a bug that caused a link error on older versions of VMS.
718
719=item *
720
721Perl no longer supports pre-7.0 VMS or pre-6.0 DEC C.
c15f899f 722
7f28d7ed 723=back
ad32999b 724
0aaeb177 725=head1 Internal Changes
ad32999b 726
0aaeb177
SH
727XXX Changes which affect the interface available to C<XS> code go here.
728Other significant internal changes for future core maintainers should
729be noted as well.
ad32999b 730
0aaeb177 731[ List each change as a =item entry ]
ad32999b 732
0aaeb177 733=over 4
ad32999b 734
3973654e
FC
735=item *
736
0aaeb177 737XXX
3973654e 738
0aaeb177 739=back
cca38fda 740
0aaeb177 741=head1 Selected Bug Fixes
9c7c1651 742
0aaeb177
SH
743XXX Important bug fixes in the core language are summarised here.
744Bug fixes in files in F<ext/> and F<lib/> are best summarised in
745L</Modules and Pragmata>.
9c7c1651 746
0aaeb177 747[ List each fix as a =item entry ]
fce59cd4 748
0aaeb177 749=over 4
fce59cd4 750
b9e83cd1
FC
751=item *
752
7402016d
AB
753RT #78266: The regex engine has been leaking memory when accessing
754named captures that weren't matched as part of a regex ever since 5.10
755when they were introduced, e.g. this would consume over a hundred MB
756of memory:
757
e46b6a32
FC
758 for (1..10_000_000) {
759 if ("foo" =~ /(foo|(?<capture>bar))?/) {
760 my $capture = $+{capture}
761 }
762 }
763 system "ps -o rss $$"'
7402016d
AB
764
765=item *
766
541cb22c
FC
767A constant subroutine assigned to a glob whose name contains a null will no
768longer cause extra globs to pop into existence when the constant is
769referenced under its new name.
b9e83cd1 770
679b54e7
FC
771=item *
772
773C<sort> was not treating C<sub {}> and C<sub {()}> as equivalent when such
774a sub was provided as the comparison routine. It used to croak on
775C<sub {()}>.
776
777=item *
778
779Subroutines from the C<autouse> namespace are once more exempt from
780redefinition warnings. This used to work in 5.005, but was broken in 5.6
781for most subroutines. For subs created via XS that redefine subroutines
782from the C<autouse> package, this stopped working in 5.10.
783
784=item *
785
786New XSUBs now produce redefinition warnings if they overwrite existing
787subs, as they did in 5.8.x. (The C<autouse> logic was reversed in 5.10-14.
788Only subroutines from the C<autouse> namespace would warn when clobbered.)
789
790=item *
791
792Redefinition warnings triggered by the creation of XSUBs now respect
793Unicode glob names, instead of using the internal representation. This was
794missed in 5.15.4, partly because this warning was so hard to trigger. (See
795the previous item.)
796
797=item *
798
799C<newCONSTSUB> used to use compile-time warning hints, instead of run-time
800hints. The following code should never produce a redefinition warning, but
801it used to, if C<newCONSTSUB> redefine and existing subroutine:
802
803 use warnings;
804 BEGIN {
805 no warnings;
806 some_XS_function_that_calls_new_CONSTSUB();
807 }
808
61f966e7
FC
809=item *
810
811Redefinition warnings for constant subroutines are on by default (what are
812known as severe warnings in L<perldiag>). This was only the case when it
813was a glob assignment or declaration of a Perl subroutine that caused the
814warning. If the creation of XSUBs triggered the warning, it was not a
815default warning. This has been corrected.
816
817=item *
818
819The internal check to see whether a redefinition warning should occur used
820to emit "uninitialized" warnings in cases like this:
821
822 use warnings "uninitialized";
823 use constant {u=>undef,v=>undef};
824 sub foo(){u} sub foo(){v}
825
826=item *
827
828A bug fix in Perl 5.14 introduced a new bug, causing "uninitialized"
829warnings to report the wrong variable if the operator in question has
830two operands and one is C<%{...}> or C<@{...}>. This has been fixed
831[perl #103766].
832
833=item *
834
835C<< version->new("version") >> and C<printf "%vd", "version"> no longer
836crash [perl #102586].
837
d1fb015b
FC
838=item *
839
840C<$tied =~ y/a/b/>, C<chop $tied> and C<chomp $tied> now call FETCH just
841once when $tied holds a reference.
842
843=item *
844
845Four-argument C<select> now always calls FETCH on tied arguments. It used
846to skip the call if the tied argument happened to hold C<undef> or a
847typeglob.
848
849=item *
850
851Four-argument C<select> no longer produces its "Non-string passed as
852bitmask" warning on tied or tainted variables that are strings.
853
854=item *
855
856C<sysread> now always calls FETCH on the buffer passed to it if it is tied.
857It used to skip the call if the tied variable happened to hold a typeglob.
858
859=item *
860
861C<< $tied .= <> >> now calls FETCH once on C<$tied>. It used to call it
862multiple times if the last value assigned to or returned from the tied
863variable was anything other than a string or typeglob.
864
66008486
FC
865=item *
866
867The C<evalbytes> keyword added in 5.15.5 was respecting C<use utf8>
868declarations from the outer scope, when it should have been ignoring them.
869
7e7629fa
FC
870=item *
871
872C<goto &func> no longers crashes, but produces an error message, when the
873unwinding of the current subroutine's scope fires a destructor that
874undefines the subroutine being "goneto" [perl #99850].
875
73512201
DG
876=item *
877
878Arithmetic assignment (C<$left += $right>) involving overloaded objects that
879rely on the 'nomethod' override no longer segfault when the left operand is not
880overloaded.
881
a1f0e6ed
FC
882=item *
883
884Assigning C<__PACKAGE__> or any other shared hash key scalar to a stash
885element no longer causes a double free. Regardless of this change, the
886results of such assignments are still undefined.
887
888=item *
889
890Creating a C<UNIVERSAL::AUTOLOAD> sub no longer stops C<%+>, C<%-> and
891C<%!> from working some of the time [perl #105024].
892
ad790500
FC
893=item *
894
895Assigning C<__PACKAGE__> or another shared hash key string to a variable no
896longer stops that variable from being tied if it happens to be a PVMG or
897PVLV internally.
898
6d91e957
KW
899=item *
900
901When presented with malformed UTF-8 input, the XS-callable functions
902C<is_utf8_string()>, C<is_utf8_string_loc()>, and
903C<is_utf8_string_loclen()> could read beyond the end of the input
904string by up to 12 bytes. This no longer happens. [perl #32080].
905However, currently, C<is_utf8_char()> still has this defect,
906see L</is_utf8_char()> above.
907
d6b99bf4
FC
908=item *
909
910Doing a substitution on a tied variable returning a copy-on-write scalar
911used to cause an assertion failure or an "Attempt to free nonexistent
912shared string" warning.
913
914=item *
915
916A change in perl 5.15.4 caused C<caller()> to produce malloc errors and a
917crash with Perl's own malloc, and possibly with other malloc
918implementations, too [perl #104034].
919
920=item *
921
922A bug fix in 5.15.5 could sometimes result in assertion failures under
923debugging builds of perl for certain syntax errors in C<eval>, such as
924C<eval(q|""!=!~//|);>
925
8aade7da
DR
926=item *
927
928The "c [line num]" debugger command was broken by other debugger changes
929release in 5.15.3. This is now fixed.
930
c7b728ca
SF
931=item *
932
933Breakpoints were not properly restored after a debugger restart using the
934"R" command in 5.15.3. This is now fixed.
935
936=item *
937
938The debugger prompt did not display the current line in 5.15.3. This is now
939fixed.
940
0aaeb177 941=back
bf19b80e 942
0aaeb177 943=head1 Known Problems
bf19b80e 944
0aaeb177
SH
945XXX Descriptions of platform agnostic bugs we know we can't fix go here. Any
946tests that had to be C<TODO>ed for the release would be noted here, unless
947they were specific to a particular platform (see below).
65b66aa9 948
0aaeb177
SH
949This is a list of some significant unfixed bugs, which are regressions
950from either 5.XXX.XXX or 5.XXX.XXX.
65b66aa9 951
0aaeb177 952[ List each fix as a =item entry ]
b53e16ae 953
0aaeb177 954=over 4
b53e16ae 955
7c864bb3
VP
956=item *
957
0aaeb177 958XXX
7c864bb3 959
63ac71b9 960=back
bbc28bfc 961
0aaeb177 962=head1 Obituary
8fe05716 963
0aaeb177
SH
964XXX If any significant core contributor has died, we've added a short obituary
965here.
8fe05716 966
0aaeb177 967=head1 Acknowledgements
8fe05716 968
0aaeb177 969XXX Generate this with:
8fe05716 970
0aaeb177 971 perl Porting/acknowledgements.pl v5.15.5..HEAD
29cf780c 972
44691e6f
AB
973=head1 Reporting Bugs
974
975If you find what you think is a bug, you might check the articles
34dc2ec0 976recently posted to the comp.lang.perl.misc newsgroup and the perl
44691e6f
AB
977bug database at http://rt.perl.org/perlbug/ . There may also be
978information at http://www.perl.org/ , the Perl Home Page.
979
980If you believe you have an unreported bug, please run the L<perlbug>
981program included with your release. Be sure to trim your bug down
982to a tiny but sufficient test case. Your bug report, along with the
983output of C<perl -V>, will be sent off to perlbug@perl.org to be
984analysed by the Perl porting team.
985
986If the bug you are reporting has security implications, which make it
987inappropriate to send to a publicly archived mailing list, then please send
34dc2ec0 988it to perl5-security-report@perl.org. This points to a closed subscription
b4707b2a
FC
989unarchived mailing list, which includes
990all the core committers, who will be able
44691e6f
AB
991to help assess the impact of issues, figure out a resolution, and help
992co-ordinate the release of patches to mitigate or fix the problem across all
34dc2ec0
DM
993platforms on which Perl is supported. Please only use this address for
994security issues in the Perl core, not for modules independently
44691e6f
AB
995distributed on CPAN.
996
997=head1 SEE ALSO
998
999The F<Changes> file for an explanation of how to view exhaustive details
1000on what changed.
1001
1002The F<INSTALL> file for how to build Perl.
1003
1004The F<README> file for general stuff.
1005
1006The F<Artistic> and F<Copying> files for copyright information.
1007
1008=cut