X-Git-Url: https://perl5.git.perl.org/perl5.git/blobdiff_plain/8883ce713db7d3379154eff221ad0cd87ad6ade6..f8d5a52263698f3448751c5ac18d2b5edac28b36:/pod/perldelta.pod diff --git a/pod/perldelta.pod b/pod/perldelta.pod index 0a93af2..1e4e7b2 100644 --- a/pod/perldelta.pod +++ b/pod/perldelta.pod @@ -5,15 +5,15 @@ [ this is a template for a new perldelta file. Any text flagged as XXX needs to be processed before release. ] -perldelta - what is new for perl v5.21.5 +perldelta - what is new for perl v5.21.6 =head1 DESCRIPTION -This document describes differences between the 5.21.4 release and the 5.21.5 +This document describes differences between the 5.21.5 release and the 5.21.6 release. -If you are upgrading from an earlier release such as 5.21.3, first read -L, which describes differences between 5.21.3 and 5.21.4. +If you are upgrading from an earlier release such as 5.21.4, first read +L, which describes differences between 5.21.4 and 5.21.5. =head1 Notice @@ -27,63 +27,21 @@ here, but most should go in the L section. [ List each enhancement as a =head2 entry ] -=head2 New double-diamond operator +=head2 List form of pipe open implemented for Win32 -C<<< <<>> >>> is like C<< <> >> but uses three-argument C to open -each file in @ARGV. So each element of @ARGV is an actual file name, and -"|foo" won't be treated as a pipe open. +The list form of pipe: -=head2 Aliasing via reference + open my $fh, "-|", "program", @arguments; -Variables and subroutines can now be aliased by assigning to a reference: - - \$c = \$d; - \&x = \&y; - -Or by using a backslash before a C iterator variable, which is -perhaps the most useful idiom this feature provides: - - foreach \%hash (@array_of_hash_refs) { ... } - -This feature is experimental and must be enabled via C. It will warn unless the C -warnings category is disabled. - -See L. - -=head2 Perl now supports POSIX 2008 locale currency additions. - -On platforms that are able to handle POSIX.1-2008, the -hash returned by -L|perllocale/The localeconv function> -includes the international currency fields added by that version of the -POSIX standard. These are -C, -C, -C, -C, -C, -and -C. - -=head2 Packing infinity or not-a-number into a character is now fatal. - -Before, when trying to pack infinity or not-a-number into a -(signed) character, Perl would warn, and assumed you tried to -pack C<< 0xFF >>; if you gave it as an argument to C<< chr >>, -C<< U+FFFD >> was returned. - -But now, all such actions (C<< pack >>, C<< chr >>, and C<< print '%c' >>) -result in a fatal error. +is now implemented on Win32. It has the same limitations as C on Win32, since the Win32 API doesn't accept program arguments +as a list. =head1 Security -=head2 Perl is now compiled with -fstack-protector-strong if available - -Perl has been compiled with the anti-stack-smashing option -C<-fstack-protector> since 5.10.1. Now Perl uses the newer variant -called C<-fstack-protector-strong>, if available. (This was added -already in 5.21.4.) +XXX Any security-related notices go here. In particular, any security +vulnerabilities closed should be noted here rather than in the +L section. [ List each security issue as a =head2 entry ] @@ -128,20 +86,18 @@ as an updated module in the L section. =back -=head2 Use of multiple /x regexp modifiers - -It is now deprecated to say something like any of the following: +[ List each other deprecation as a =head2 entry ] - qr/foo/xx; - /(?xax:foo)/; - use re qw(/amxx); +=head2 Use of non-graphic characters in single-character variable names -That is, now C should only occur once in any string of contiguous -regular expression pattern modifiers. We do not believe there are any -occurrences of this in all of CPAN. This is in preparation for a future -Perl release having C mean to allow white-space for readability in -bracketed character classes (those enclosed in square brackets: -C<[...]>). +The syntax for single-character variable names is more lenient than +for longer variable names, allowing the one-character name to be a +punctuation character or even invisible (a non-graphic). Perl v5.20 +deprecated the ASCII-range controls as such a name. Now, all +non-graphic characters that formerly were allowed are deprecated. +The practical effect of this occurs only when not under C>, and affects just the C1 controls (code points 0x80 through +0xFF), NO-BREAK SPACE, and SOFT HYPHEN. =head1 Performance Enhancements @@ -154,40 +110,7 @@ There may well be none in a stable release. =item * -C is up to 20% faster for non-magical/non-tied scalars containing a -string if it is a non-utf8 string or if C is in scope. - -=item * - -Non-magical/non-tied scalars that contain only a floating point value and are -on most Perl builds with 64 bit integers now use 8-32 less bytes of memory -depending on OS. - -=item * - -In C<@array = split>, the assigment can be optimised away with C -writing directly to the array. This optimisation was happening only for -package arrays other than @_ and only -sometimes. Now this optimisation happens -almost all the time. - -=item * - -C is now subject to constant folding. Moreover, C with a -scalar or constant for the separator and a single-item list to join is -simplified to a stringification. The separator doesn't even get evaluated. - -=item * - -C is implemented using two ops: a stringify op and a join op. -If the qq contains nothing but a single array, the stringification is -optimised away. - -=item * - -C and C in void context are no longer evaluated at -run time. Even a whole sequence of C statements will simply be -skipped over. +XXX =back @@ -217,83 +140,9 @@ XXX =item * -L has been upgraded from version 0.23 to 0.24. - -Avoid reading beyond the end of a buffer. [perl #122629] - -=item * - -L has been upgraded from version 0.993 to 0.994. - -Null ops that are part of the execution chain are now given sequence -numbers. - -Private flags for nulled ops are now dumped with mnemonics as they would be -for the non-nulled counterparts. - -L has been upgraded from version 1.28 to 1.29. - -Parenthesised arrays in lists passed to C<\> are now correctly deparsed -with parentheses (e.g., C<\(@a, (@b), @c)> now retains the parentheses -around @b), this preserving the flattening behaviour of referenced -parenthesised arrays. Formerly, it only worked for one array: C<\(@a)>. - -C is now deparsed correctly, with the C included. - -C was deparsed without the C (or C). -This has been fixed. - -Core keywords that conflict with lexical subroutines are now deparsed with -the C prefix. - -C now deparses correctly with C and -not C. - -C now deparses correctly with C in those -cases where the assignment is optimised away. - -=item * - -L has been upgraded from version 1.26 to 1.27. +L has been upgraded from version 1.37 to 1.38. -Remove dl_nonlazy global if unused in Dynaloader. [perl #122926] - -=item * - -L has been upgraded from version 1.12 to 1.13. - -Add support for the Linux pipe buffer size fcntl() commands. - -=item * - -L has been upgraded from version 1.28 to 1.29. - -Slightly faster module loading time. - -=item * - -L has been upgraded from version 5.20140920 to 5.20141020. - -Updated to cover the latest releases of Perl. - -=item * - -The PathTools module collection has been upgraded from version 3.50 to 3.51. - -Slightly faster module loading time. - -=item * - -L has been upgraded from version 1.44 to 1.45. - -POSIX::tmpnam() now produces a deprecation warning. [perl #122005] - -=item * - -L has been upgraded from version 0.17 to 0.18. - -Allow XSLoader to load modules from a different namespace. -[perl #122455] +Document the limitations of the isconnected() method. [perl #123096] =back @@ -326,18 +175,14 @@ XXX Changes which significantly change existing files in F go here. However, any changes to F should go in the L section. -=head3 L +=head3 L =over 4 =item * -Clarifications have been added to L -to the effect that Perl guarantees that C<[A-Z]>, C<[a-z]>, C<[0-9]> and -any subranges thereof in regular expression bracketed character classes -are guaranteed to match exactly what a naive English speaker would -expect them to match, even on platforms (such as EBCDIC) where special -handling is required to accomplish this. +The syntax of single-character variable names has been brought +up-to-date and more fully explained. =back @@ -361,29 +206,34 @@ and New Warnings =item * -L +XXX L -=item * +=back -L +=head3 New Warnings + +=over 4 =item * -L +L =item * -L +A new C warning category has been created, with the following warning +messages currently in it: -=back +=over 4 -=head3 New Warnings +=item * -=over 4 +L =item * -XXX L +L + +=back =back @@ -395,8 +245,7 @@ XXX Changes (i.e. rewording) of diagnostic messages go here =item * -'"my" variable &foo::bar can't be in a package' has been reworded to say -'subroutine' instead of 'variable'. +XXX Describe change here =back @@ -432,7 +281,7 @@ L section, instead. =item * -XXX +F with C<-Dmksymlinks> should now be faster. [perl #122002] =back @@ -450,10 +299,7 @@ that they represent may be covered elsewhere. =item * -Some regular expression tests are written in such a way that they will -run very slowly if certain optimizations break. These tests have been -moved into new files, F<< t/re/speed.t >> and F<< t/re/speed_thr.t >>, -and are run with a C<< watchdog() >>. +XXX =back @@ -500,76 +346,46 @@ L section. =over 4 -=item EBCDIC +=item XXX-some-platform -Special handling is required on EBCDIC platforms to get C to -match only C<"i"> and C<"j">, since there are 7 characters between the -code points for C<"i"> and C<"j">. This special handling had only been -invoked when both ends of the range are literals. Now it is also -invoked if any of the C<\N{...}> forms for specifying a character by -name or Unicode code point is used instead of a literal. See -L. +XXX =back -=head1 Internal Changes - -XXX Changes which affect the interface available to C code go here. Other -significant internal changes for future core maintainers should be noted as -well. - -[ List each change as a =item entry ] +=head3 Win32 =over 4 =item * -SVs of type SVt_NV are now bodyless when a build configure and platform allow -it, specifically C. The bodyless trick is the same one -as for IVs since 5.9.2, but for NVs, unlike IVs, is not guarenteed on all -platforms and build configurations. - -=item * - -The C<$DB::single>, C<$DB::signal> and C<$DB::trace> now have set and -get magic that stores their values as IVs and those IVs are used when -testing their values in C. This prevents perl from -recursing infinity if an overloaded object is assigned to any of those -variables. [perl #122445] +In the experimental C<:win32> layer, a crash in C was fixed. Also +opening C, which works the Win32 Perl's normal C<:unix> layer, was +implemented for C<:win32>. +L<[perl #122224]|https://rt.perl.org/Ticket/Display.html?id=122224> =item * -C which is marked as public API but undocumented has been -removed from public API. If you use C macro in your XS code to -preextend the mortal stack, you are unaffected by this change. +A new makefile option, C, has been added to the Windows +dmake makefile for gcc builds only. Set this to "define" if you want perl to +use long doubles to give more accuracy and range for floating point numbers. -=item * - -C, which was introduced in 5.21.4, has been changed incompatibly. -It now has a flags field that allows the caller to specify whether the name -should be fully qualified. See L. +=back -=item * +=head1 Internal Changes -Internally Perl no longer uses the C flag. C now -returns a true value for anything not marked PADTMP. C is now -defined as 0. +XXX Changes which affect the interface available to C code go here. Other +significant internal changes for future core maintainers should be noted as +well. -=item * +[ List each change as a =item entry ] -The macros SETsv and SETsvUN have been removed. They were no longer used -in the core since commit 6f1401dc2a, and have not been found present on -CPAN. +=over 4 =item * -The C<< SvFAKE >> bit (unused on HVs) got informally reserved by -David Mitchell for future work on vtables. - -=item * -The C function accepts C and C -flags, which specify whether the appended string is bytes or utf8, -respectively. +C has been removed. Although marked as public API, it is +undocumented and has no usage in modern perl versions on CPAN Grep. Calling it +has been fatal since 5.17.0. =back @@ -584,78 +400,30 @@ files in F and F are best summarized in L. =item * -Locking and unlocking values via L or C -no longer has any affect on values that are read-only to begin. Unlocking -such values could result in crashes, hangs or other erratic behaviour. - -=item * - -The internal C function (which L provides -access to) began erroneously to return true for "-e1" in 5.21.4, affecting -also C<-'-e1'>. This has been fixed. - -=item * - -The flip-flop operator (C<..> in scalar context) would return the same -scalar each time, unless the containing subroutine was called recursively. -Now it always returns a new scalar. [perl #122829] - -=item * - -Some unterminated C<(?(...)...)> constructs in regular expressions would -either crash or give erroneous error messages. C is one such -example. - -=item * - -C no longer calls FETCH twice. +fchmod() and futimes() now set C<$!> when they fail due to being +passed a closed file handle. [perl #122703] =item * -List assignments like C<($x, $z) = (1, $y)> now work correctly if $x and $y -have been aliased by C. +Perl now comes with a corrected Unicode 7.0 for the erratum issued on +October 21, 2014 (see L), +dealing with glyph shaping in Arabic. =item * -Some patterns including code blocks with syntax errors, such as -C, would hang or fail assertions on debugging builds. Now -they produce errors. +op_free() no longer crashes due to a stack overflow when freeing a +deeply recursive op tree. [perl #108276] =item * -An assertion failure when parsing C with debugging enabled has been -fixed. [perl #122771] +scalarvoid() would crash due to a stack overflow when processing a +deeply recursive op tree. [perl #108276] =item * -C<*a = *b; @a = split //, $b[1]> could do a bad read and produce junk -results. - -=item * - -In C<() = @array = split>, the C<() => at the beginning no longer confuses -the optimiser, making it assume a limit of 1. - -=item * - -Fatal warnings no longer prevent the output of syntax errors. -[perl #122966] - -=item * - -Fixed a NaN double to long double conversion error on VMS. For quiet NaNs -(and only on Itanium, not Alpha) negative infinity instead of NaN was -produced. - -=item * - -Fixed the issue that caused C<< make distclean >> to leave files behind -that shouldn't. [perl #122820] - -=item * - -AIX now sets the length in C<< getsockopt >> correctly. [perl #120835], -[rt #91183], [rt #85570]. +In Perl 5.20.0, C<$^N> accidentally had the internal UTF8 flag turned off +if accessed from a code block within a regular expression, effectively +UTF8-encoding the value. This has been fixed. [perl #123135] =back @@ -671,7 +439,10 @@ platform specific bugs also go here. =item * -XXX +Starting in 5.21.6, accessing L in an XSUB is forbidden. +CvPADLIST has be reused for a different internal purpose for XSUBs. Guard all +CvPADLIST expressions with C if your code doesn't already block +XSUB CV*s from going through optree CV* expecting code. =back @@ -695,7 +466,7 @@ here. XXX Generate this with: - perl Porting/acknowledgements.pl v5.21.4..HEAD + perl Porting/acknowledgements.pl v5.21.5..HEAD =head1 Reporting Bugs