5 perl5231delta - what is new for perl v5.23.1
9 This document describes differences between the 5.23.0 release and the 5.23.1
12 If you are upgrading from an earlier release such as 5.22.0, first read
13 L<perl5230delta>, which describes differences between 5.22.0 and 5.23.0.
15 =head1 Core Enhancements
17 =head2 Integer shift (C<< << >> and C<< >> >>) now more explicitly defined
19 Negative shifts are reverse shifts: left shift becomes right shift,
20 and right shift becomes left shift.
22 Shifting by the number of bits in a native integer (or more) is zero,
23 except when the "overshift" is right shifting a negative value under
24 C<use integer>, in which case the result is -1 (arithmetic shift).
26 Until now negative shifting and overshifting have been undefined
27 because they have relied on whatever the C implementation happens
28 to do. For example, for the overshift a common C behavior is
31 1 >> 64 == 1 >> (64 % 64) == 1 >> 0 == 1 # Common C behavior.
33 # And the same for <<, while Perl now produces 0 for both.
35 Now these behaviors are well-defined under Perl, regardless of what
36 the underlying C implementation does. Note, however, that you cannot
37 escape the native integer width, you need to know how far left you
38 can go. You can use for example:
41 my $wordbits = $Config{uvsize} * 8; # Or $Config{uvsize} << 3.
43 If you need a more bits on the left shift, you can use for example
44 the C<bigint> pragma, or the C<Bit::Vector> module from CPAN.
46 =head2 Postfix dereferencing is no longer experimental
48 Using the C<postderef> and C<postderef_qq> features no longer emits a
49 warning. Existing code that disables the C<experimental::postderef> warning
50 category that they previously used will continue to work. The C<postderef>
51 feature has no effect; all Perl code can use postfix dereferencing,
52 regardless of what feature declarations are in scope. The C<5.24> feature
53 bundle now includes the C<postderef_qq> feature.
55 =head2 printf and sprintf now allow reordered precision arguments
57 That is, C<< sprintf '|%.*2$|', 2, 3 >> now returns C<|002|>. This extends
58 the existing reordering mechanism (which allows reordering for arguments
59 that are used as format fields, widths, and vector separators).
61 =head1 Incompatible Changes
63 =head2 ASCII characters in variable names must now be all visible
65 It was legal until now on ASCII platforms for variable names to contain
66 non-graphical ASCII control characters (ordinals 0 through 31, and 127,
67 which are the C0 controls and C<DELETE>). This usage has been
68 deprecated since v5.20, and as of now causes a syntax error. The
69 variables these names referred to are special, reserved by Perl for
70 whatever use it may choose, now, or in the future. Each such variable
71 has an alternative way of spelling it. Instead of the single
72 non-graphic control character, a two character sequence beginning with a
73 caret is used, like C<$^]> and C<${^GLOBAL_PHASE}>. Details are at
74 L<perlvar>. It remains legal, though unwise and deprecated (raising a
75 deprecation warning), to use certain non-graphic non-ASCII characters in
76 variables names when not under S<C<use utf8>>. No code should do this,
77 as all such variables are reserved by Perl, and Perl doesn't currently
78 define any of them (but could at any time, without notice).
80 =head2 The C<autoderef> feature has been removed
82 The experimental C<autoderef> feature (which allowed calling C<push>,
83 C<pop>, C<shift>, C<unshift>, C<splice>, C<keys>, C<values>, and C<each> on
84 a scalar argument) has been deemed unsuccessful. It has now been removed;
85 trying to use the feature (or to disable the C<experimental::autoderef>
86 warning it previously triggered) now yields an exception.
88 =head1 Modules and Pragmata
90 =head2 Updated Modules and Pragmata
96 The libnet distribution has been upgraded from version 3.06 to 3.07.
100 L<autodie> has been upgraded from version 2.27 to 2.29.
104 L<DynaLoader> has been upgraded from version 1.32 to 1.33.
108 L<Encode> has been upgraded from version 2.73 to 2.75.
112 L<encoding> has been upgraded from version 2.15 to 2.16.
116 L<feature> has been upgraded from version 1.41 to 1.42.
120 L<File::Path> has been upgraded from version 2.09 to 2.11.
124 L<Getopt::Long> has been upgraded from version 2.46 to 2.47.
128 L<I18N::Langinfo> has been upgraded from version 0.12 to 0.13.
132 L<IPC::Open3> has been upgraded from version 1.18 to 1.19.
134 If a Perl exception was thrown from inside this module, the exception
135 C<IPC::Open3> threw to the callers of C<open3> would have an irrelevant
136 message derived from C<$!> which was in an undefined state, instead of the
137 C<$@> message which triggers the failure path inside C<open3>.
141 L<Module::CoreList> has been upgraded from version 5.20150620 to 5.20150720.
145 L<Opcode> has been upgraded from version 1.32 to 1.33.
149 L<PerlIO::scalar> has been upgraded from version 0.22 to 0.23.
153 L<POSIX> has been upgraded from version 1.54 to 1.55.
157 L<Socket> has been upgraded from version 2.019 to 2.020.
161 L<Storable> has been upgraded from version 2.53 to 2.54.
165 L<Unicode::Collate> has been upgraded from version 1.12 to 1.14.
169 L<Unicode::Normalize> has been upgraded from version 1.18 to 1.19.
173 L<warnings> has been upgraded from version 1.32 to 1.33.
177 L<XS::Typemap> has been upgraded from version 0.13 to 0.14.
183 The following additions or changes have been made to diagnostic output,
184 including warnings and fatal error messages. For the complete list of
185 diagnostic messages, see L<perldiag>.
187 =head2 Changes to Existing Diagnostics
193 The C<printf> and C<sprintf> builtins are now more careful about the
194 warnings they emit: argument reordering now disables the "redundant
195 argument" warning in all cases; and invalid format strings are no longer
196 treated as absorbing arguments (so "redundant argument" warnings can
197 correctly be emitted by such code).
201 =head1 Platform Support
203 =head2 Platform-Specific Notes
213 The minimum supported version of VMS is now v7.3-2, released in 2003. As a
214 side effect of this change, VAX is no longer supported as the terminal
215 release of OpenVMS VAX was v7.3 in 2001.
221 =head1 Internal Changes
227 C<sv_catpvf> and related functions (including C<sv_vcatpvfn_flags> when
228 called with a C<va_list> rather than an array of SV pointers) have never
229 handled argument reordering. Attempts to reorder arguments now yield an
230 exception, rather than being silently ignored.
234 =head1 Selected Bug Fixes
240 A leak in the XS typemap caused one scalar to be leaked each time a C<FILE *>
241 or a C<PerlIO *> was C<OUTPUT:>ed or imported to Perl, since perl 5.000. These
242 particular typemap entries are thought to be extremely rarely used by XS
243 modules. [perl #124181]
247 C<alarm()> and C<sleep()> will now warn if the argument is a negative number
248 and return undef. Previously they would pass the negative value to the
249 underlying C function which may have set up a timer with a surprising value.
253 =head1 Acknowledgements
255 Perl 5.23.1 represents approximately 4 weeks of development since Perl 5.23.0
256 and contains approximately 8,400 lines of changes across 320 files from 22
259 Excluding auto-generated files, documentation and release tools, there were
260 approximately 5,000 lines of changes to 140 .pm, .t, .c and .h files.
262 Perl continues to flourish into its third decade thanks to a vibrant community
263 of users and developers. The following people are known to have contributed the
264 improvements that became Perl 5.23.1:
266 Aaron Crane, Aristotle Pagaltzis, Chas. Owens, Chris 'BinGOs' Williams, Craig
267 A. Berry, Daniel Dragan, David Mitchell, Father Chrysostomos, Herbert Breunung,
268 H.Merijn Brand, James E Keenan, Jarkko Hietaniemi, Karen Etheridge, Karl
269 Williamson, Leon Timmermans, Matthew Horsfall, Max Maischein, Rafael
270 Garcia-Suarez, Ricardo Signes, Stanislaw Pusep, Steve Hay, Tony Cook.
272 The list above is almost certainly incomplete as it is automatically generated
273 from version control history. In particular, it does not include the names of
274 the (very much appreciated) contributors who reported issues to the Perl bug
277 Many of the changes included in this version originated in the CPAN modules
278 included in Perl's core. We're grateful to the entire CPAN community for
279 helping Perl to flourish.
281 For a more complete list of all of Perl's historical contributors, please see
282 the F<AUTHORS> file in the Perl source distribution.
284 =head1 Reporting Bugs
286 If you find what you think is a bug, you might check the articles recently
287 posted to the comp.lang.perl.misc newsgroup and the perl bug database at
288 L<https://rt.perl.org/> . There may also be information at
289 L<http://www.perl.org/> , the Perl Home Page.
291 If you believe you have an unreported bug, please run the L<perlbug> program
292 included with your release. Be sure to trim your bug down to a tiny but
293 sufficient test case. Your bug report, along with the output of C<perl -V>,
294 will be sent off to perlbug@perl.org to be analysed by the Perl porting team.
296 If the bug you are reporting has security implications, which make it
297 inappropriate to send to a publicly archived mailing list, then please send it
298 to perl5-security-report@perl.org. This points to a closed subscription
299 unarchived mailing list, which includes all the core committers, who will be
300 able to help assess the impact of issues, figure out a resolution, and help
301 co-ordinate the release of patches to mitigate or fix the problem across all
302 platforms on which Perl is supported. Please only use this address for
303 security issues in the Perl core, not for modules independently distributed on
308 The F<Changes> file for an explanation of how to view exhaustive details on
311 The F<INSTALL> file for how to build Perl.
313 The F<README> file for general stuff.
315 The F<Artistic> and F<Copying> files for copyright information.