This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
perldelta: Highlight some 5.21 areas; fix others
[perl5.git] / pod / perl52111delta.pod
1 =encoding utf8
2
3 =head1 NAME
4
5 perl52111delta - what is new for perl v5.21.11
6
7 =head1 DESCRIPTION
8
9 This document describes differences between the 5.21.10 release and the 5.21.11
10 release.
11
12 If you are upgrading from an earlier release such as 5.21.9, first read
13 L<perl52110delta>, which describes differences between 5.21.9 and 5.21.10.
14
15 =head1 Deprecations
16
17 =head2 Making all warnings fatal is discouraged
18
19 The documentation for L<fatal warnings|warnings/Fatal Warnings> notes that
20 C<< use warnings FATAL => 'all' >> is discouraged and provides stronger
21 language about the risks of fatal warnings in general.
22
23 =head1 Modules and Pragmata
24
25 =head2 Updated Modules and Pragmata
26
27 =over 4
28
29 =item *
30
31 L<attributes> has been upgraded from version 0.26 to 0.27.
32
33 =item *
34
35 L<B> has been upgraded from version 1.57 to 1.58.
36
37 =item *
38
39 L<B::Deparse> has been upgraded from version 1.34 to 1.35.
40
41 C<< <<>> >> is now correctly deparsed.
42
43 =item *
44
45 L<Config::Perl::V> has been upgraded from version 0.23 to 0.24.
46
47 =item *
48
49 L<CPAN> has been upgraded from version 2.10 to 2.11.
50
51 =item *
52
53 L<Cwd> has been upgraded from version 3.55 to 3.56.
54
55 =item *
56
57 L<ExtUtils::Miniperl> has been upgraded from version 1.04 to 1.05.
58
59 =item *
60
61 L<ExtUtils::ParseXS> has been upgraded from version 3.27 to 3.28.
62
63 =item *
64
65 L<ExtUtils::Typemaps> has been upgraded from version 3.25 to 3.28.
66
67 =item *
68
69 L<File::Spec> has been upgraded from version 3.55 to 3.56.
70
71 =item *
72
73 L<if> has been upgraded from version 0.0603 to 0.0604.
74
75 The documentation now notes that this module also works with C<no>.
76
77 =item *
78
79 L<IO::Socket::IP> has been upgraded from version 0.36 to 0.37.
80
81 =item *
82
83 L<Module::CoreList> has been upgraded from version 5.20150320 to 5.20150420.
84
85 Updated to cover the latest releases of Perl.  Also fixes a fencepost error in
86 is_core() and copes with versions that do not match x.yyyzzz.
87
88 =item *
89
90 L<perl5db.pl> has been upgraded from 1.48 to 1.49.
91
92 The debugger would cause an assertion failure.
93 L<[perl #124127]|https://rt.perl.org/Ticket/Display.html?id=124127>
94
95 =item *
96
97 L<PerlIO::mmap> has been upgraded from version 0.013 to 0.014.
98
99 =item *
100
101 L<utf8> has been upgraded from version 1.15 to 1.16.
102
103 Minor documentation update only.
104
105 =item *
106
107 L<warnings> has been upgraded from version 1.31 to 1.32.
108
109 =back
110
111 =head1 Documentation
112
113 =head2 Changes to Existing Documentation
114
115 =head3 L<perlebcdic>
116
117 =over 4
118
119 =item *
120
121 This document has been significantly updated in the light of recent
122 improvements to EBCDIC support.
123
124 =back
125
126 =head3 L<perlfunc>
127
128 =over 4
129
130 =item *
131
132 Mention that C<study()> is currently a no-op.
133
134 =back
135
136 =head3 L<perlguts>
137
138 =over 4
139
140 =item *
141
142 The OOK example has been updated to account for COW changes and a change in the
143 storage of the offset.
144
145 =back
146
147 =head3 L<perlhacktips>
148
149 =over 4
150
151 =item *
152
153 Documentation has been added illustrating the perils of assuming the contents
154 of static memory pointed to by the return values of Perl wrappers for C library
155 functions doesn't change.
156
157 =back
158
159 =head3 L<perlport>
160
161 =over 4
162
163 =item *
164
165 Out-of-date VMS-specific information has been fixed/simplified.
166
167 =back
168
169 =head3 L<perluniintro>
170
171 =over 4
172
173 =item *
174
175 Advice for how to make sure your strings and regular expression patterns are
176 interpreted as Unicode has been revised to account for the new Perl 5.22 EBCDIC
177 handling.
178
179 =back
180
181 =head3 L<perlvms>
182
183 =over 4
184
185 =item *
186
187 Out-of-date and/or incorrect material has been removed.
188
189 =back
190
191 =head1 Testing
192
193 =over 4
194
195 =item *
196
197 F<t/porting/re_context.t> has been added to test that L<utf8> and its
198 dependencies only use the subset of the C<$1..$n> capture vars that
199 Perl_save_re_context() is hard-coded to localize, because that function has no
200 efficient way of determining at runtime what vars to localize.
201
202 =back
203
204 =head1 Platform Support
205
206 =head2 Platform-Specific Notes
207
208 =over 4
209
210 =item Win32
211
212 F<miniperl.exe> is now built with C<-fno-strict-aliasing>, allowing 64-bit
213 builds to complete on GCC 4.8.
214 L<[perl #123976]|https://rt.perl.org/Ticket/Display.html?id=123976>
215
216 C<test-prep> again depends on C<test-prep-gcc> for GCC builds.
217 L<[perl #124221]|https://rt.perl.org/Ticket/Display.html?id=124221>
218
219 =back
220
221 =head1 Internal Changes
222
223 =over 4
224
225 =item *
226
227 Perl 5.21.2 introduced a new build option, C<-DPERL_OP_PARENT>, which causes
228 the last C<op_sibling> pointer to refer back to the parent rather than being
229 C<NULL>, and where instead a new flag indicates the end of the chain.  In this
230 release, the new implementation has been revised; in particular:
231
232 =over 4
233
234 =item *
235
236 On C<PERL_OP_PARENT> builds, the C<op_sibling> field has been renamed
237 C<op_sibparent> to reflect its new dual purpose.  Since the intention is that
238 this field should primarily be accessed via macros, this change should be
239 transparent for code written to work under C<PERL_OP_PARENT>.
240
241 =item *
242
243 The newly-introduced C<op_lastsib> flag bit has been renamed C<op_moresib> and
244 its logic inverted; i.e. it is initialised to zero in a new op, and is changed
245 to 1 when an op gains a sibling.
246
247 =item *
248
249 The function C<Perl_op_parent> is now only available on C<PERL_OP_PARENT>
250 builds.  Using it on a plain build will be a compile-timer error.
251
252 =item *
253
254 Three new macros, C<OpMORESIB_set>, C<OpLASTSIB_set>, C<OpMAYBESIB_set> have
255 been added, which are intended to be a low-level portable way to set
256 C<op_sibling> / C<op_sibparent> while also updating C<op_moresib>.  The first
257 sets the sibling pointer to a new sibling, the second makes the op the last
258 sibling, and the third conditionally does the first or second action.  The
259 C<op_sibling_splice()> function is retained as a higher-level interface that
260 can also maintain consistency in the parent at the same time (e.g. by updating
261 C<op_first> and C<op_last> where appropriate).
262
263 =item *
264
265 The macro C<OpSIBLING_set>, added in Perl 5.21.2, has been removed.  It didn't
266 manipulate C<op_moresib> and has been superseded by C<OpMORESIB_set> et al.
267
268 =item *
269
270 The C<op_sibling_splice> function now accepts a null C<parent> argument where
271 the splicing doesn't affect the first or last ops in the sibling chain, and
272 thus where the parent doesn't need to be updated accordingly.
273
274 =back
275
276 =back
277
278 =head1 Selected Bug Fixes
279
280 =over 4
281
282 =item *
283
284 C<pack("D", $x)> and C<pack("F", $x)> now zero the padding on x86 long double
285 builds.  GCC 4.8 and later, under some build options, would either overwrite
286 the zero-initialized padding, or bypass the initialized buffer entirely.  This
287 caused F<op/pack.t> to fail.
288 L<[perl #123971]|https://rt.perl.org/Ticket/Display.html?id=123971>
289
290 =item *
291
292 Extending an array cloned from a parent thread could result in "Modification of
293 a read-only value attempted" errors when attempting to modify the new elements.
294 L<[perl #124127]|https://rt.perl.org/Ticket/Display.html?id=124127>
295
296 =item *
297
298 An assertion failure and subsequent crash with C<< *x=<y> >> has been fixed.
299 L<[perl #123790]|https://rt.perl.org/Ticket/Display.html?id=123790>
300
301 =item *
302
303 An optimization for state variable initialization introduced in Perl 5.21.6 has
304 been reverted because it was found to exacerbate some other existing buggy
305 behaviour.
306 L<[perl #124160]|https://rt.perl.org/Ticket/Display.html?id=124160>
307
308 =item *
309
310 The extension of another optimization to cover more ops in Perl 5.21 has also
311 been reverted to its Perl 5.20 state as a temporary fix for regression issues
312 that it caused.
313 L<[perl #123790]|https://rt.perl.org/Ticket/Display.html?id=123790>
314
315 =item *
316
317 New bitwise ops added in Perl 5.21.9 accidentally caused C<$^H |= 0x1c020000>
318 to enable all features.  This has now been fixed.
319
320 =item *
321
322 A possible crashing/looping bug has been fixed.
323 L<[perl #124099]|https://rt.perl.org/Ticket/Display.html?id=124099>
324
325 =item *
326
327 UTF-8 variable names used in array indexes, unquoted UTF-8 HERE-document
328 terminators and UTF-8 function names all now work correctly.
329 L<[perl #124113]|https://rt.perl.org/Ticket/Display.html?id=124113>
330
331 =item *
332
333 Breakage in C<require(VERSION)> (with parentheses), introduced in Perl 5.21.6,
334 has been fixed.
335 L<[perl #124135]|https://rt.perl.org/Ticket/Display.html?id=124135>
336
337 =item *
338
339 Wide char warnings, wrongly raised in UTF-8 locales since Perl 5.21.8, are now
340 suppressed.
341 L<[perl #123527]|https://rt.perl.org/Ticket/Display.html?id=123527>
342
343 =item *
344
345 A subtle bug introduced in Perl 5.21.4 involving UTF-8 in regular expressions
346 and sometimes causing a crash has been fixed.  A new test script has been added
347 to test this fix; see under L</Testing>.
348 L<[perl #124109]|https://rt.perl.org/Ticket/Display.html?id=124109>
349
350 =item *
351
352 A change introduced in Perl 5.21.10 that broke the autovivification CPAN module
353 has been reverted.
354
355 =item *
356
357 A bug whereby C<< 'FOO'->f() >> lost the read-only status of C<FOO>, introduced
358 in Perl 5.21.7, has been fixed.
359 L<[perl #123619]|https://rt.perl.org/Ticket/Display.html?id=123619>
360
361 =item *
362
363 A regression in Perl 5.21 in the matching of C</[A-Z]/ai> has been fixed.
364
365 =back
366
367 =head1 Acknowledgements
368
369 Perl 5.21.11 represents approximately 4 weeks of development since Perl 5.21.10
370 and contains approximately 5,800 lines of changes across 240 files from 24
371 authors.
372
373 Excluding auto-generated files, documentation and release tools, there were
374 approximately 1,700 lines of changes to 160 .pm, .t, .c and .h files.
375
376 Perl continues to flourish into its third decade thanks to a vibrant community
377 of users and developers.  The following people are known to have contributed
378 the improvements that became Perl 5.21.11:
379
380 Alex Vandiver, Andreas König, Craig A. Berry, Dagfinn Ilmari Mannsåker, Daniel
381 Dragan, David Golden, David Mitchell, Father Chrysostomos, H.Merijn Brand,
382 Herbert Breunung, Hugo van der Sanden, James E Keenan, James McCoy, Karl
383 Williamson, Matthew Horsfall, Max Maischein, Nicholas Clark, Rafael
384 Garcia-Suarez, Randy Stauner, Ricardo Signes, Shirakata Kentaro, Steffen
385 Müller, Steve Hay, Tony Cook.
386
387 The list above is almost certainly incomplete as it is automatically generated
388 from version control history.  In particular, it does not include the names of
389 the (very much appreciated) contributors who reported issues to the Perl bug
390 tracker.
391
392 Many of the changes included in this version originated in the CPAN modules
393 included in Perl's core.  We're grateful to the entire CPAN community for
394 helping Perl to flourish.
395
396 For a more complete list of all of Perl's historical contributors, please see
397 the F<AUTHORS> file in the Perl source distribution.
398
399 =head1 Reporting Bugs
400
401 If you find what you think is a bug, you might check the articles recently
402 posted to the comp.lang.perl.misc newsgroup and the perl bug database at
403 https://rt.perl.org/ .  There may also be information at
404 http://www.perl.org/ , the Perl Home Page.
405
406 If you believe you have an unreported bug, please run the L<perlbug> program
407 included with your release.  Be sure to trim your bug down to a tiny but
408 sufficient test case.  Your bug report, along with the output of C<perl -V>,
409 will be sent off to perlbug@perl.org to be analysed by the Perl porting team.
410
411 If the bug you are reporting has security implications, which make it
412 inappropriate to send to a publicly archived mailing list, then please send it
413 to perl5-security-report@perl.org.  This points to a closed subscription
414 unarchived mailing list, which includes all the core committers, who will be
415 able to help assess the impact of issues, figure out a resolution, and help
416 co-ordinate the release of patches to mitigate or fix the problem across all
417 platforms on which Perl is supported.  Please only use this address for
418 security issues in the Perl core, not for modules independently distributed on
419 CPAN.
420
421 =head1 SEE ALSO
422
423 The F<Changes> file for an explanation of how to view exhaustive details on
424 what changed.
425
426 The F<INSTALL> file for how to build Perl.
427
428 The F<README> file for general stuff.
429
430 The F<Artistic> and F<Copying> files for copyright information.
431
432 =cut