5 perl5271delta - what is new for perl v5.27.1
9 This document describes differences between the 5.27.0 release and the 5.27.1
12 If you are upgrading from an earlier release such as 5.26.0, first read
13 L<perl5270delta>, which describes differences between 5.26.0 and 5.27.0.
15 =head1 Core Enhancements
17 =head2 L<C<delete>|perlfunc/delete EXPR> on key/value slices
19 L<C<delete>|perlfunc/delete EXPR> can now be used on key/value slices,
20 returning the keys along with the deleted values.
21 L<[perl #131328]|https://rt.perl.org/Ticket/Display.html?id=131328>
25 =head2 Default Hash Function Change
27 Perl 5.27.1 retires various older hash functions which are not viewed as
28 sufficiently secure for use in Perl. We now support four general purpose
29 hash functions, Siphash (2-4 and 1-3 variants), and Zaphod32, and StadtX
30 hash. In addition we support SBOX32 (a form of tabular hashing) for hashing
31 short strings, in conjunction with any of the other hash functions provided.
33 By default Perl is configured to support SBOX hashing of strings up to 24
34 characters, in conjunction with StadtX hashing on 64 bit builds, and
35 Zaphod32 hashing for 32 bit builds.
37 You may control these settings with the following options to Configure:
39 -DPERL_HASH_FUNC_SIPHASH
40 -DPERL_HASH_FUNC_SIPHASH13
41 -DPERL_HASH_FUNC_STADTX
42 -DPERL_HASH_FUNC_ZAPHOD32
44 To disable SBOX hashing you can use
46 -DPERL_HASH_USE_SBOX32_ALSO=0
48 And to set the maximum length to use SBOX32 hashing on with:
52 The maximum length allowed is 256. There probably isn't much point
53 in setting it higher than the default.
55 =head1 Incompatible Changes
57 =head2 Comma-less variable lists in formats are no longer allowed
59 Omitting the commas between variables passed to formats is no longer
60 allowed. This has been deprecated since Perl 5.000.
62 =head2 The C<:locked> and C<:unique> attributes have been removed
64 These have been no-ops and deprecated since Perl 5.12 and 5.10,
67 =head2 C<\N{}> with nothing between the braces is now illegal.
69 This has been deprecated since Perl 5.24.
71 =head2 Opening the same symbol as both a file and directory handle is no longer allowed
73 Using C<open()> and C<opendir()> to associate both a filehandle and a dirhandle
74 to the same symbol (glob or scalar) has been deprecated since Perl 5.10.
76 =head2 Use of bare C<< << >> to mean C<< <<"" >> is no longer allowed
78 Use of a bare terminator has been deprecated since Perl 5.000.
80 =head2 Setting $/ to a reference to a non-positive integer no longer allowed
82 This used to work like setting it to C<undef>, but has been deprecated
85 =head2 Unicode code points with values exceeding C<IV_MAX> are now fatal.
87 This was deprecated since Perl 5.24.
89 =head2 C<B::OP::terse> no longer exists.
91 Use C<B::Concise::b_terse> instead.
93 =head2 Use of inherited AUTOLOAD for non-methods is no longer allowed.
95 This was deprecated in Perl 5.004.
97 =head2 Use of strings with code points over 0xFF is not allowed for
98 bitwise string operators
100 Code points over C<0xFF> do not make sense for bitwise operators.
102 =head2 Setting C<${^ENCODING}> to a defined value is now illegal
104 This has been deprecated since Perl 5.22 and a no-op since Perl 5.26.
106 =head2 Backslash no longer escapes colon in PATH for the -S switch
108 Previously the C<-S> switch incorrectly treated backslash ("\") as an
109 escape for colon when traversing the C<PATH> environment variable.
112 =head2 the -DH (DEBUG_H) misfeature has been removed
114 On a perl built with debugging support, the C<H> flag to the C<-D>
115 debugging option has been removed. This was supposed to dump hash values,
116 but has been broken for many years.
120 =head2 Use of L<C<vec>|perlfunc/vec EXPR,OFFSET,BITS> on strings with code
121 points above 0xFF is deprecated.
123 Use of these is nonsensical, as C<vec> is a bit-oriented operation,
124 which operates on the underlying UTF-8 representation these strings must
125 be in, and will likely give unexpected results.
127 =head2 Some uses of unescaped C<"{"> are no longer fatal
129 Perl 5.26.0 fatalized some uses of an unescaped left brace, but an
130 exception was made at the last minute, specifically crafted to be a
131 minimal change to allow GNU Autoconf to work. This code is heavily
132 depended upon, and continues to use the deprecated usage. Its use of an
133 unescaped left brace is one where we have no intention of repurposing
134 C<"{"> to be something other than itself.
136 That exception is now generalized to include various other such cases
137 where the C<"{"> will not be repurposed. This is to get real experience
138 with this more complicated change now, in case we need to issue a dot
139 release if we find other things like Autoconf that are important to work
142 Note that these uses continue to raise a deprecation message.
144 =head1 Performance Enhancements
150 L<File::Glob> has been modified to remove unnecessary backtracking and
151 recursion, thanks to Russ Cox. See L<https://research.swtch.com/glob>
156 The C<ref()> builtin is now much faster in boolean context, since it no
157 longer bothers to construct a temporary string like C<Foo=ARRAY(0x134af48)>.
161 =head1 Modules and Pragmata
163 =head2 Updated Modules and Pragmata
169 L<Archive::Tar> has been upgraded from version 2.24 to 2.26.
173 L<B::Deparse> has been upgraded from version 1.40 to 1.41. It includes
174 many bug fixes, and in particular, it now deparses variable attributes
177 my $x :foo; # used to deparse as
178 # 'attributes'->import('main', \$x, 'foo'), my $x;
182 L<charnames> has been upgraded from version 1.44 to 1.45.
186 L<Devel::PPPort> has been upgraded from version 3.35 to 3.36.
190 L<DirHandle> has been upgraded from version 1.04 to 1.05.
194 L<ExtUtils::Install> has been upgraded from version 2.04 to 2.14.
198 L<ExtUtils::MakeMaker> has been upgraded from version 7.24 to 7.30.
202 L<File::Path> has been upgraded from version 2.12_01 to 2.14.
206 L<Filter::Util::Call> has been upgraded from version 1.55 to 1.57.
210 L<GDBM_File> has been upgraded from version 1.15 to 1.16.
214 L<Getopt::Long> has been upgraded from version 2.49 to 2.5.
218 L<if> has been upgraded from version 0.0606 to 0.0607.
222 L<IO::Socket::IP> has been upgraded from version 0.38 to 0.39.
226 L<IPC::Cmd> has been upgraded from version 0.96 to 0.98.
230 L<JSON::PP> has been upgraded from version 2.27400_02 to 2.94.
234 L<Locale::Codes> has been upgraded from version 3.42 to 3.52.
238 L<Module::CoreList> has been upgraded from version 5.20170620 to 5.20170621.
242 L<mro> has been upgraded from version 1.20 to 1.21.
246 L<PerlIO::scalar> has been upgraded from version 0.26 to 0.27.
250 L<PerlIO::via> has been upgraded from version 0.16 to 0.17.
254 L<Storable> has been upgraded from version 2.62 to 2.63.
258 L<Test::Harness> has been upgraded from version 3.38 to 3.39.
262 L<threads> has been upgraded from version 2.15 to 2.16.
266 L<threads::shared> has been upgraded from version 1.56 to 1.57.
270 L<version> has been upgraded from version 0.9917 to 0.9918.
276 Tests were added and changed to reflect the other additions and
277 changes in this release. Furthermore, these significant changes were
284 Testing of the XS-APItest directory is now done in parallel, where
289 Perl now includes a default F<.travis.yml> file for Travis CI testing
290 on github mirrors. [perl #123981]
294 =head1 Platform Support
296 =head2 Platform-Specific Notes
306 Support for compiling perl on Windows using Microsoft Visual Studio 2017
307 (containing Visual C++ 14.1) has been added.
313 =head1 Internal Changes
319 The C<PL_statbuf> interpreter variable has been removed.
323 The deprecated function C<to_utf8_case()>, accessible from XS code, has
329 L<C<is_utf8_invariant_string_loc()>|perlapi/is_utf8_invariant_string_loc>
330 has been added that is like
331 L<C<is_utf8_invariant_string()>|perlapi/is_utf8_invariant_string>
332 but takes an extra pointer parameter into which is stored the location
333 of the first variant character, if any are found.
337 =head1 Selected Bug Fixes
343 Fetching the name of a glob that was previously UTF-8 but wasn't any
344 longer would return that name flagged as UTF-8. [perl #131263]
348 The perl C<sprintf()> function (via the underlying C function
349 C<Perl_sv_vcatpvfn_flags()>) has been heavily reworked to fix many minor
350 bugs, including the integer wrapping of large width and precision
351 specifiers and potential buffer overruns. It has also been made faster in
356 Exiting from an C<eval>, whether normally or via an exception, now always
357 frees temporary values (possibly calling destructors) I<before> setting
360 sub DESTROY { eval { die "died in DESTROY"; } }
362 # $@ used to be equal to "died in DESTROY" here; it's now "".
366 =head1 Acknowledgements
368 Perl 5.27.1 represents approximately 3 weeks of development since Perl 5.27.0
369 and contains approximately 62,000 lines of changes across 510 files from 30
372 Excluding auto-generated files, documentation and release tools, there were
373 approximately 55,000 lines of changes to 380 .pm, .t, .c and .h files.
375 Perl continues to flourish into its third decade thanks to a vibrant community
376 of users and developers. The following people are known to have contributed the
377 improvements that became Perl 5.27.1:
379 Aaron Crane, Abigail, Andy Dougherty, Andy Lester, Aristotle Pagaltzis, Chris
380 'BinGOs' Williams, Craig A. Berry, Dagfinn Ilmari Mannsåker, Dan Collins,
381 David Mitchell, Eric Herman, Eugen Konkov, Father Chrysostomos, Graham Knop,
382 H.Merijn Brand, Jacques Germishuys, James E Keenan, Jerry D. Hedden, John
383 Peacock, Karl Williamson, Ken Cotterill, Lukas Mai, Matthew Horsfall, Sawyer X,
384 Steve Hay, Sullivan Beck, Thomas Sibley, Tony Cook, Yves Orton, Zefram.
386 The list above is almost certainly incomplete as it is automatically generated
387 from version control history. In particular, it does not include the names of
388 the (very much appreciated) contributors who reported issues to the Perl bug
391 Many of the changes included in this version originated in the CPAN modules
392 included in Perl's core. We're grateful to the entire CPAN community for
393 helping Perl to flourish.
395 For a more complete list of all of Perl's historical contributors, please see
396 the F<AUTHORS> file in the Perl source distribution.
398 =head1 Reporting Bugs
400 If you find what you think is a bug, you might check the perl bug database
401 at L<https://rt.perl.org/> . There may also be information at
402 L<http://www.perl.org/> , the Perl Home Page.
404 If you believe you have an unreported bug, please run the L<perlbug> program
405 included with your release. Be sure to trim your bug down to a tiny but
406 sufficient test case. Your bug report, along with the output of C<perl -V>,
407 will be sent off to perlbug@perl.org to be analysed by the Perl porting team.
409 If the bug you are reporting has security implications which make it
410 inappropriate to send to a publicly archived mailing list, then see
411 L<perlsec/SECURITY VULNERABILITY CONTACT INFORMATION>
412 for details of how to report the issue.
416 If you wish to thank the Perl 5 Porters for the work we had done in Perl 5,
417 you can do so by running the C<perlthanks> program:
421 This will send an email to the Perl 5 Porters list with your show of thanks.
425 The F<Changes> file for an explanation of how to view exhaustive details on
428 The F<INSTALL> file for how to build Perl.
430 The F<README> file for general stuff.
432 The F<Artistic> and F<Copying> files for copyright information.