.\" -*- mode: troff; coding: utf-8 -*- .\" Automatically generated by Pod::Man 5.01 (Pod::Simple 3.43) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" \*(C` and \*(C' are quotes in nroff, nothing in troff, for use with C<>. .ie n \{\ . ds C` "" . ds C' "" 'br\} .el\{\ . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{\ . if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" ======================================================================== .\" .IX Title "PERL5300DELTA 1" .TH PERL5300DELTA 1 2024-04-17 "perl v5.38.2" "Perl Programmers Reference Guide" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH NAME perl5300delta \- what is new for perl v5.30.0 .SH DESCRIPTION .IX Header "DESCRIPTION" This document describes differences between the 5.28.0 release and the 5.30.0 release. .PP If you are upgrading from an earlier release such as 5.26.0, first read perl5280delta, which describes differences between 5.26.0 and 5.28.0. .SH Notice .IX Header "Notice" sv_utf8_(downgrade|decode) are no longer marked as experimental. [GH #16822] . .SH "Core Enhancements" .IX Header "Core Enhancements" .SS "Limited variable length lookbehind in regular expression pattern matching is now experimentally supported" .IX Subsection "Limited variable length lookbehind in regular expression pattern matching is now experimentally supported" Using a lookbehind assertion (like \f(CW\*(C`(?<=foo?)\*(C'\fR or \f(CW\*(C`(? for 11.0; for 12.0; and for 12.1. (Unicode 12.1 differs from 12.0 only in the addition of a single character, that for the new Japanese era name.) .PP The Word_Break property, as in past Perl releases, remains tailored to behave more in line with expectations of Perl users. This means that sequential runs of horizontal white space characters are not broken apart, but kept as a single run. Unicode 11 changed from past versions to be more in line with Perl, but it left several white space characters as causing breaks: TAB, NO BREAK SPACE, and FIGURE SPACE (U+2007). We have decided to continue to use the previous Perl tailoring with regards to these. .SS "Wildcards in Unicode property value specifications are now partially supported" .IX Subsection "Wildcards in Unicode property value specifications are now partially supported" You can now do something like this in a regular expression pattern .PP .Vb 1 \& qr! \ep{nv= /(?x) \eA [0\-5] \ez / }! .Ve .PP which matches all Unicode code points whose numeric value is between 0 and 5 inclusive. So, it could match the Thai or Bengali digits whose numeric values are 0, 1, 2, 3, 4, or 5. .PP This marks another step in implementing the regular expression features the Unicode Consortium suggests. .PP Most properties are supported, with the remainder planned for 5.32. Details are in "Wildcards in Property Values" in perlunicode. .SS "qr'\eN{name}' is now supported" .IX Subsection "qr'N{name}' is now supported" Previously it was an error to evaluate a named character \f(CW\*(C`\eN{...}\*(C'\fR within a single quoted regular expression pattern (whose evaluation is deferred from the normal place). This restriction is now removed. .SS "Turkic UTF\-8 locales are now seamlessly supported" .IX Subsection "Turkic UTF-8 locales are now seamlessly supported" Turkic languages have different casing rules than other languages for the characters \f(CW"i"\fR and \f(CW"I"\fR. The uppercase of \f(CW"i"\fR is LATIN CAPITAL LETTER I WITH DOT ABOVE (U+0130); and the lowercase of \f(CW"I"\fR is LATIN SMALL LETTER DOTLESS I (U+0131). Unicode furnishes alternate casing rules for use with Turkic languages. Previously, Perl ignored these, but now, it uses them when it detects that it is operating under a Turkic UTF\-8 locale. .SS "It is now possible to compile perl to always use thread-safe locale operations." .IX Subsection "It is now possible to compile perl to always use thread-safe locale operations." Previously, these calls were only used when the perl was compiled to be multi-threaded. To always enable them, add .PP .Vb 1 \& \-Accflags=\*(Aq\-DUSE_THREAD_SAFE_LOCALE\*(Aq .Ve .PP to your \fIConfigure\fR flags. .SS "Eliminate opASSIGN macro usage from core" .IX Subsection "Eliminate opASSIGN macro usage from core" This macro is still defined but no longer used in core .ie n .SS """\-Drv"" now means something on ""\-DDEBUGGING"" builds" .el .SS "\f(CW\-Drv\fP now means something on \f(CW\-DDEBUGGING\fP builds" .IX Subsection "-Drv now means something on -DDEBUGGING builds" Now, adding the verbose flag (\f(CW\*(C`\-Dv\*(C'\fR) to the \f(CW\*(C`\-Dr\*(C'\fR flag turns on all possible regular expression debugging. .SH "Incompatible Changes" .IX Header "Incompatible Changes" .ie n .SS "Assigning non-zero to $[ is fatal" .el .SS "Assigning non-zero to \f(CW$[\fP is fatal" .IX Subsection "Assigning non-zero to $[ is fatal" Setting \f(CW$[\fR to a non-zero value has been deprecated since Perl 5.12 and now throws a fatal error. See "Assigning non-zero to \f(CW$[\fR is fatal" in perldeprecation. .SS "Delimiters must now be graphemes" .IX Subsection "Delimiters must now be graphemes" See "Use of unassigned code point or non-standalone grapheme for a delimiter." in perldeprecation .ie n .SS "Some formerly deprecated uses of an unescaped left brace ""{"" in regular expression patterns are now illegal" .el .SS "Some formerly deprecated uses of an unescaped left brace \f(CW""{""\fP in regular expression patterns are now illegal" .IX Subsection "Some formerly deprecated uses of an unescaped left brace ""{"" in regular expression patterns are now illegal" But to avoid breaking code unnecessarily, most instances that issued a deprecation warning, remain legal and now have a non-deprecation warning raised. See "Unescaped left braces in regular expressions" in perldeprecation. .SS "Previously deprecated \fBsysread()\fP/\fBsyswrite()\fP on :utf8 handles is now fatal" .IX Subsection "Previously deprecated sysread()/syswrite() on :utf8 handles is now fatal" Calling \fBsysread()\fR, \fBsyswrite()\fR, \fBsend()\fR or \fBrecv()\fR on a \f(CW\*(C`:utf8\*(C'\fR handle, whether applied explicitly or implicitly, is now fatal. This was deprecated in perl 5.24. .PP There were two problems with calling these functions on \f(CW\*(C`:utf8\*(C'\fR handles: .IP \(bu 4 All four functions only paid attention to the \f(CW\*(C`:utf8\*(C'\fR flag. Other layers were completely ignored, so a handle with \&\f(CW:encoding(UTF\-16LE)\fR layer would be treated as UTF\-8. Other layers, such as compression are completely ignored with or without the \&\f(CW\*(C`:utf8\*(C'\fR flag. .IP \(bu 4 \&\fBsysread()\fR and \fBrecv()\fR would read from the handle, skipping any validation by the layers, and do no validation of their own. This could lead to invalidly encoded perl scalars. .PP [GH #14839] . .SS "\fBmy()\fP in false conditional prohibited" .IX Subsection "my() in false conditional prohibited" Declarations such as \f(CW\*(C`my $x if 0\*(C'\fR are no longer permitted. .PP [GH #16702] . .SS "Fatalize $* and $#" .IX Subsection "Fatalize $* and $#" These special variables, long deprecated, now throw exceptions when used. .PP [GH #16718] . .SS "Fatalize unqualified use of \fBdump()\fP" .IX Subsection "Fatalize unqualified use of dump()" The \f(CWdump()\fR function, long discouraged, may no longer be used unless it is fully qualified, \fIi.e.\fR, \f(CWCORE::dump()\fR. .PP [GH #16719] . .SS "Remove \fBFile::Glob::glob()\fP" .IX Subsection "Remove File::Glob::glob()" The \f(CWFile::Glob::glob()\fR function, long deprecated, has been removed and now throws an exception which advises use of \f(CWFile::Glob::bsd_glob()\fR instead. .PP [GH #16721] . .ie n .SS "pack() no longer can return malformed UTF\-8" .el .SS "\f(CWpack()\fP no longer can return malformed UTF\-8" .IX Subsection "pack() no longer can return malformed UTF-8" It croaks if it would otherwise return a UTF\-8 string that contains malformed UTF\-8. This protects against potential security threats. This is considered a bug fix as well. [GH #16035] . .SS "Any set of digits in the Common script are legal in a script run of another script" .IX Subsection "Any set of digits in the Common script are legal in a script run of another script" There are several sets of digits in the Common script. \f(CW\*(C`[0\-9]\*(C'\fR is the most familiar. But there are also \f(CW\*(C`[\ex{FF10}\-\ex{FF19}]\*(C'\fR (FULLWIDTH DIGIT ZERO \- FULLWIDTH DIGIT NINE), and several sets for use in mathematical notation, such as the MATHEMATICAL DOUBLE-STRUCK DIGITs. Any of these sets should be able to appear in script runs of, say, Greek. But the design of 5.30 overlooked all but the ASCII digits \&\f(CW\*(C`[0\-9]\*(C'\fR, so the design was flawed. This has been fixed, so is both a bug fix and an incompatibility. [GH #16704] . .PP All digits in a run still have to come from the same set of ten digits. .SS "JSON::PP enables allow_nonref by default" .IX Subsection "JSON::PP enables allow_nonref by default" As JSON::XS 4.0 changed its policy and enabled allow_nonref by default, JSON::PP also enabled allow_nonref by default. .SH Deprecations .IX Header "Deprecations" .SS "In XS code, use of various macros dealing with UTF\-8." .IX Subsection "In XS code, use of various macros dealing with UTF-8." This deprecation was scheduled to become fatal in 5.30, but has been delayed to 5.32 due to problems that showed up with some CPAN modules. For details of what's affected, see perldeprecation. .SH "Performance Enhancements" .IX Header "Performance Enhancements" .IP \(bu 4 Translating from UTF\-8 into the code point it represents now is done via a deterministic finite automaton, speeding it up. As a typical example, \&\f(CWord("\ex7fff")\fR now requires 12% fewer instructions than before. The performance of checking that a sequence of bytes is valid UTF\-8 is similarly improved, again by using a DFA. .IP \(bu 4 Eliminate recursion from \fBfinalize_op()\fR. [GH #11866] . .IP \(bu 4 A handful of small optimizations related to character folding and character classes in regular expressions. .IP \(bu 4 Optimization of \f(CW\*(C`IV\*(C'\fR to \f(CW\*(C`UV\*(C'\fR conversions. [GH #16761] . .IP \(bu 4 Speed up of the integer stringification algorithm by processing two digits at a time instead of one. [GH #16769] . .IP \(bu 4 Improvements based on LGTM analysis and recommendation. (). [GH #16765] . [GH #16773] . .IP \(bu 4 Code optimizations in \fIregcomp.c\fR, \fIregcomp.h\fR, \fIregexec.c\fR. .IP \(bu 4 Regular expression pattern matching of things like \f(CW\*(C`qr/[^\fR\f(CIa\fR\f(CW]/\*(C'\fR is significantly sped up, where \fIa\fR is any ASCII character. Other classes can get this speed up, but which ones is complicated and depends on the underlying bit patterns of those characters, so differs between ASCII and EBCDIC platforms, but all case pairs, like \f(CW\*(C`qr/[Gg]/\*(C'\fR are included, as is \f(CW\*(C`[^01]\*(C'\fR. .SH "Modules and Pragmata" .IX Header "Modules and Pragmata" .SS "Updated Modules and Pragmata" .IX Subsection "Updated Modules and Pragmata" .IP \(bu 4 Archive::Tar has been upgraded from version 2.30 to 2.32. .IP \(bu 4 B has been upgraded from version 1.74 to 1.76. .IP \(bu 4 B::Concise has been upgraded from version 1.003 to 1.004. .IP \(bu 4 B::Deparse has been upgraded from version 1.48 to 1.49. .IP \(bu 4 bignum has been upgraded from version 0.49 to 0.51. .IP \(bu 4 bytes has been upgraded from version 1.06 to 1.07. .IP \(bu 4 Carp has been upgraded from version 1.38 to 1.50 .IP \(bu 4 Compress::Raw::Bzip2 has been upgraded from version 2.074 to 2.084. .IP \(bu 4 Compress::Raw::Zlib has been upgraded from version 2.076 to 2.084. .IP \(bu 4 Config::Extensions has been upgraded from version 0.02 to 0.03. .IP \(bu 4 Config::Perl::V. has been upgraded from version 0.29 to 0.32. This was due to a new configuration variable that has influence on binary compatibility: \&\f(CW\*(C`USE_THREAD_SAFE_LOCALE\*(C'\fR. .IP \(bu 4 CPAN has been upgraded from version 2.20 to 2.22. .IP \(bu 4 Data::Dumper has been upgraded from version 2.170 to 2.174 .Sp Data::Dumper now avoids leaking when \f(CW\*(C`croak\*(C'\fRing. .IP \(bu 4 DB_File has been upgraded from version 1.840 to 1.843. .IP \(bu 4 deprecate has been upgraded from version 0.03 to 0.04. .IP \(bu 4 Devel::Peek has been upgraded from version 1.27 to 1.28. .IP \(bu 4 Devel::PPPort has been upgraded from version 3.40 to 3.52. .IP \(bu 4 Digest::SHA has been upgraded from version 6.01 to 6.02. .IP \(bu 4 Encode has been upgraded from version 2.97 to 3.01. .IP \(bu 4 Errno has been upgraded from version 1.29 to 1.30. .IP \(bu 4 experimental has been upgraded from version 0.019 to 0.020. .IP \(bu 4 ExtUtils::CBuilder has been upgraded from version 0.280230 to 0.280231. .IP \(bu 4 ExtUtils::Manifest has been upgraded from version 1.70 to 1.72. .IP \(bu 4 ExtUtils::Miniperl has been upgraded from version 1.08 to 1.09. .IP \(bu 4 ExtUtils::ParseXS has been upgraded from version 3.39 to 3.40. \&\f(CW\*(C`OUTLIST\*(C'\fR parameters are no longer incorrectly included in the automatically generated function prototype. [GH #16746] . .IP \(bu 4 feature has been upgraded from version 1.52 to 1.54. .IP \(bu 4 File::Copy has been upgraded from version 2.33 to 2.34. .IP \(bu 4 File::Find has been upgraded from version 1.34 to 1.36. .Sp \&\f(CW$File::Find::dont_use_nlink\fR now defaults to 1 on all platforms. [GH #16759] . .Sp Variables \f(CW$Is_Win32\fR and \f(CW$Is_VMS\fR are being initialized. .IP \(bu 4 File::Glob has been upgraded from version 1.31 to 1.32. .IP \(bu 4 File::Path has been upgraded from version 2.15 to 2.16. .IP \(bu 4 File::Spec has been upgraded from version 3.74 to 3.78. .Sp Silence Cwd warning on Android builds if \f(CW\*(C`targetsh\*(C'\fR is not defined. .IP \(bu 4 File::Temp has been upgraded from version 0.2304 to 0.2309. .IP \(bu 4 Filter::Util::Call has been upgraded from version 1.58 to 1.59. .IP \(bu 4 GDBM_File has been upgraded from version 1.17 to 1.18. .IP \(bu 4 HTTP::Tiny has been upgraded from version 0.070 to 0.076. .IP \(bu 4 I18N::Langinfo has been upgraded from version 0.17 to 0.18. .IP \(bu 4 IO has been upgraded from version 1.39 to 1.40. .IP \(bu 4 IO-Compress has been upgraded from version 2.074 to 2.084. .Sp Adds support for \f(CW\*(C`IO::Uncompress::Zstd\*(C'\fR and \&\f(CW\*(C`IO::Uncompress::UnLzip\*(C'\fR. .Sp The \f(CW\*(C`BinModeIn\*(C'\fR and \f(CW\*(C`BinModeOut\*(C'\fR options are now no-ops. ALL files will be read/written in binmode. .IP \(bu 4 IPC::Cmd has been upgraded from version 1.00 to 1.02. .IP \(bu 4 JSON::PP has been upgraded from version 2.97001 to 4.02. .Sp JSON::PP as JSON::XS 4.0 enables \f(CW\*(C`allow_nonref\*(C'\fR by default. .IP \(bu 4 lib has been upgraded from version 0.64 to 0.65. .IP \(bu 4 Locale::Codes has been upgraded from version 3.56 to 3.57. .IP \(bu 4 Math::BigInt has been upgraded from version 1.999811 to 1.999816. .Sp \&\f(CWbnok()\fR now supports the full Kronenburg extension. [cpan #95628] . .IP \(bu 4 Math::BigInt::FastCalc has been upgraded from version 0.5006 to 0.5008. .IP \(bu 4 Math::BigRat has been upgraded from version 0.2613 to 0.2614. .IP \(bu 4 Module::CoreList has been upgraded from version 5.20180622 to 5.20190520. .Sp Changes to B::Op_private and Config .IP \(bu 4 Module::Load has been upgraded from version 0.32 to 0.34. .IP \(bu 4 Module::Metadata has been upgraded from version 1.000033 to 1.000036. .Sp Properly clean up temporary directories after testing. .IP \(bu 4 NDBM_File has been upgraded from version 1.14 to 1.15. .IP \(bu 4 Net::Ping has been upgraded from version 2.62 to 2.71. .IP \(bu 4 ODBM_File has been upgraded from version 1.15 to 1.16. .IP \(bu 4 PathTools has been upgraded from version 3.74 to 3.78. .IP \(bu 4 parent has been upgraded from version 0.236 to 0.237. .IP \(bu 4 perl5db.pl has been upgraded from version 1.54 to 1.55. .Sp Debugging threaded code no longer deadlocks in \f(CW\*(C`DB::sub\*(C'\fR nor \&\f(CW\*(C`DB::lsub\*(C'\fR. .IP \(bu 4 perlfaq has been upgraded from version 5.021011 to 5.20190126. .IP \(bu 4 PerlIO::encoding has been upgraded from version 0.26 to 0.27. .Sp Warnings enabled by setting the \f(CW\*(C`WARN_ON_ERR\*(C'\fR flag in \&\f(CW$PerlIO::encoding::fallback\fR are now only produced if warnings are enabled with \f(CW\*(C`use warnings "utf8";\*(C'\fR or setting \f(CW$^W\fR. .IP \(bu 4 PerlIO::scalar has been upgraded from version 0.29 to 0.30. .IP \(bu 4 podlators has been upgraded from version 4.10 to 4.11. .IP \(bu 4 POSIX has been upgraded from version 1.84 to 1.88. .IP \(bu 4 re has been upgraded from version 0.36 to 0.37. .IP \(bu 4 SDBM_File has been upgraded from version 1.14 to 1.15. .IP \(bu 4 sigtrap has been upgraded from version 1.08 to 1.09. .IP \(bu 4 Storable has been upgraded from version 3.08 to 3.15. .Sp Storable no longer probes for recursion limits at build time. [GH #16780] and others. .Sp Metasploit exploit code was included to test for CVE\-2015\-1592 detection, this caused anti-virus detections on at least one AV suite. The exploit code has been removed and replaced with a simple functional test. [GH #16778] .IP \(bu 4 Test::Simple has been upgraded from version 1.302133 to 1.302162. .IP \(bu 4 Thread::Queue has been upgraded from version 3.12 to 3.13. .IP \(bu 4 threads::shared has been upgraded from version 1.58 to 1.60. .Sp Added support for extra tracing of locking, this requires a \&\f(CW\*(C`\-DDEBUGGING\*(C'\fR and extra compilation flags. .IP \(bu 4 Time::HiRes has been upgraded from version 1.9759 to 1.9760. .IP \(bu 4 Time::Local has been upgraded from version 1.25 to 1.28. .IP \(bu 4 Time::Piece has been upgraded from version 1.3204 to 1.33. .IP \(bu 4 Unicode::Collate has been upgraded from version 1.25 to 1.27. .IP \(bu 4 Unicode::UCD has been upgraded from version 0.70 to 0.72. .IP \(bu 4 User::grent has been upgraded from version 1.02 to 1.03. .IP \(bu 4 utf8 has been upgraded from version 1.21 to 1.22. .IP \(bu 4 vars has been upgraded from version 1.04 to 1.05. .Sp \&\f(CW\*(C`vars.pm\*(C'\fR no longer disables non-vars strict when checking if strict vars is enabled. [GH #15851] . .IP \(bu 4 version has been upgraded from version 0.9923 to 0.9924. .IP \(bu 4 warnings has been upgraded from version 1.42 to 1.44. .IP \(bu 4 XS::APItest has been upgraded from version 0.98 to 1.00. .IP \(bu 4 XS::Typemap has been upgraded from version 0.16 to 0.17. .SS "Removed Modules and Pragmata" .IX Subsection "Removed Modules and Pragmata" The following modules will be removed from the core distribution in a future release, and will at that time need to be installed from CPAN. Distributions on CPAN which require these modules will need to list them as prerequisites. .PP The core versions of these modules will now issue \f(CW"deprecated"\fR\-category warnings to alert you to this fact. To silence these deprecation warnings, install the modules in question from CPAN. .PP Note that these are (with rare exceptions) fine modules that you are encouraged to continue to use. Their disinclusion from core primarily hinges on their necessity to bootstrapping a fully functional, CPAN-capable Perl installation, not usually on concerns over their design. .IP \(bu 4 B::Debug is no longer distributed with the core distribution. It continues to be available on CPAN as \&\f(CW\*(C`B::Debug \*(C'\fR. .IP \(bu 4 Locale::Codes has been removed at the request of its author. It continues to be available on CPAN as \&\f(CW\*(C`Locale::Codes \*(C'\fR [GH #16660] . .SH Documentation .IX Header "Documentation" .SS "Changes to Existing Documentation" .IX Subsection "Changes to Existing Documentation" We have attempted to update the documentation to reflect the changes listed in this document. If you find any we have missed, send email to perlbug@perl.org . .PP \fIperlapi\fR .IX Subsection "perlapi" .IP \(bu 4 \&\f(CWAvFILL()\fR was wrongly listed as deprecated. This has been corrected. [GH #16586] .PP \fIperlop\fR .IX Subsection "perlop" .IP \(bu 4 We no longer have null (empty line) here doc terminators, so perlop should not refer to them. .IP \(bu 4 The behaviour of \f(CW\*(C`tr\*(C'\fR when the delimiter is an apostrophe has been clarified. In particular, hyphens aren't special, and \f(CW\*(C`\ex{}\*(C'\fR isn't interpolated. [GH #15853] .PP \fIperlreapi, perlvar\fR .IX Subsection "perlreapi, perlvar" .IP \(bu 4 Improve docs for lastparen, lastcloseparen. .PP \fIperlfunc\fR .IX Subsection "perlfunc" .IP \(bu 4 The entry for "\-X" in perlfunc has been clarified to indicate that symbolic links are followed for most tests. .IP \(bu 4 Clarification of behaviour of \f(CW\*(C`reset EXPR\*(C'\fR. .IP \(bu 4 Try to clarify that \f(CWref(qr/xx/)\fR returns \f(CW\*(C`Regexp\*(C'\fR rather than \&\f(CW\*(C`REGEXP\*(C'\fR and why. [GH #16801] . .PP \fIperlreref\fR .IX Subsection "perlreref" .IP \(bu 4 Clarification of the syntax of /(?(cond)yes)/. .PP \fIperllocale\fR .IX Subsection "perllocale" .IP \(bu 4 There are actually two slightly different types of UTF\-8 locales: one for Turkic languages and one for everything else. Starting in Perl v5.30, Perl seamlessly handles both types. .PP \fIperlrecharclass\fR .IX Subsection "perlrecharclass" .IP \(bu 4 Added a note for the ::xdigit:: character class. .PP \fIperlvar\fR .IX Subsection "perlvar" .IP \(bu 4 More specific documentation of paragraph mode. [GH #16787] . .SH Diagnostics .IX Header "Diagnostics" The following additions or changes have been made to diagnostic output, including warnings and fatal error messages. For the complete list of diagnostic messages, see perldiag. .SS "Changes to Existing Diagnostics" .IX Subsection "Changes to Existing Diagnostics" .IP \(bu 4 As noted under "Incompatible Changes" above, the deprecation warning "Unescaped left brace in regex is deprecated here (and will be fatal in Perl 5.30), passed through in regex; marked by <\-\-\ HERE in m/%s/" has been changed to the non-deprecation warning "Unescaped left brace in regex is passed through in regex; marked by <\-\-\ HERE in m/%s/". .IP \(bu 4 Specifying \f(CW\*(C`\eo{}\*(C'\fR without anything between the braces now yields the fatal error message "Empty \eo{}". Previously it was "Number with no digits". This means the same wording is used for this kind of error as with similar constructs such as \f(CW\*(C`\ep{}\*(C'\fR. .IP \(bu 4 Within the scope of the experimental feature \f(CW\*(C`use re \*(Aqstrict\*(Aq\*(C'\fR, specifying \f(CW\*(C`\ex{}\*(C'\fR without anything between the braces now yields the fatal error message "Empty \ex{}". Previously it was "Number with no digits". This means the same wording is used for this kind of error as with similar constructs such as \f(CW\*(C`\ep{}\*(C'\fR. It is legal, though not wise to have an empty \f(CW\*(C`\ex\*(C'\fR outside of \f(CW\*(C`re \*(Aqstrict\*(Aq\*(C'\fR; it silently generates a NUL character. .IP \(bu 4 Type of arg \f(CW%d\fR to \f(CW%s\fR must be \f(CW%s\fR (not \f(CW%s\fR) .Sp Attempts to push, pop, etc on a hash or glob now produce this message rather than complaining that they no longer work on scalars. [GH #15774] . .IP \(bu 4 Prototype not terminated .Sp The file and line number is now reported for this error. [GH #16697] .IP \(bu 4 Under \f(CW\*(C`\-Dr\*(C'\fR (or \f(CW\*(C`use re \*(AqDebug\*(Aq\*(C'\fR) the compiled regex engine program is displayed. It used to use two different spellings for \fIinfinity\fR, \&\f(CW\*(C`INFINITY\*(C'\fR, and \f(CW\*(C`INFTY\*(C'\fR. It now uses the latter exclusively, as that spelling has been around the longest. .SH "Utility Changes" .IX Header "Utility Changes" .SS xsubpp .IX Subsection "xsubpp" .IP \(bu 4 The generated prototype (with \f(CW\*(C`PROTOTYPES: ENABLE\*(C'\fR) would include \&\f(CW\*(C`OUTLIST\*(C'\fR parameters, but these aren't arguments to the perl function. This has been rectified. [GH #16746] . .SH "Configuration and Compilation" .IX Header "Configuration and Compilation" .IP \(bu 4 Normally the thread-safe locale functions are used only on threaded builds. It is now possible to force their use on unthreaded builds on systems that have them available, by including the \&\f(CW\*(C`\-Accflags=\*(Aq\-DUSE_THREAD_SAFE_LOCALE\*(Aq\*(C'\fR option to \fIConfigure\fR. .IP \(bu 4 Improve detection of memrchr, strlcat, and strlcpy .IP \(bu 4 Improve Configure detection of \fBmemmem()\fR. [GH #16807] . .IP \(bu 4 Multiple improvements and fixes for \-DPERL_GLOBAL_STRUCT build option. .IP \(bu 4 Fix \-DPERL_GLOBAL_STRUCT_PRIVATE build option. .SH Testing .IX Header "Testing" .IP \(bu 4 \&\fIt/lib/croak/op\fR [GH #15774] . .Sp separate error for \f(CW\*(C`push\*(C'\fR, etc. on hash/glob. .IP \(bu 4 \&\fIt/op/svleak.t\fR [GH #16749] . .Sp Add test for \f(CW\*(C`goto &sub\*(C'\fR in overload leaking. .IP \(bu 4 Split \fIt/re/fold_grind.t\fR into multiple test files. .IP \(bu 4 Fix intermittent tests which failed due to race conditions which surface during parallel testing. [GH #16795] . .IP \(bu 4 Thoroughly test paragraph mode, using a new test file, \&\fIt/io/paragraph_mode.t\fR. [GH #16787] . .IP \(bu 4 Some tests in \fIt/io/eintr.t\fR caused the process to hang on pre\-16 Darwin. These tests are skipped for those version of Darwin. .SH "Platform Support" .IX Header "Platform Support" .SS "Platform-Specific Notes" .IX Subsection "Platform-Specific Notes" .IP "HP-UX 11.11" 4 .IX Item "HP-UX 11.11" An obscure problem in \f(CWpack()\fR when compiling with HP C\-ANSI-C has been fixed by disabling optimizations in \fIpp_pack.c\fR. .IP "Mac OS X" 4 .IX Item "Mac OS X" Perl's build and testing process on Mac OS X for \f(CW\*(C`\-Duseshrplib\*(C'\fR builds is now compatible with Mac OS X System Integrity Protection (SIP). .Sp SIP prevents binaries in \fI/bin\fR (and a few other places) being passed the \f(CW\*(C`DYLD_LIBRARY_PATH\*(C'\fR environment variable. For our purposes this prevents \f(CW\*(C`DYLD_LIBRARY_PATH\*(C'\fR from being passed to the shell, which prevents that variable being passed to the testing or build process, so running \f(CW\*(C`perl\*(C'\fR couldn't find \fIlibperl.dylib\fR. .Sp To work around that, the initial build of the \fIperl\fR executable expects to find \fIlibperl.dylib\fR in the build directory, and the library path is then adjusted during installation to point to the installed library. .Sp [GH #15057] . .IP Minix3 4 .IX Item "Minix3" Some support for Minix3 has been re-added. .IP Cygwin 4 .IX Item "Cygwin" Cygwin doesn't make \f(CW\*(C`cuserid\*(C'\fR visible. .IP "Win32 Mingw" 4 .IX Item "Win32 Mingw" C99 math functions are now available. .IP Windows 4 .IX Item "Windows" .RS 4 .PD 0 .IP \(bu 4 .PD The \f(CW\*(C`USE_CPLUSPLUS\*(C'\fR build option which has long been available in \&\fIwin32/Makefile\fR (for \fBnmake\fR) and \fIwin32/makefile.mk\fR (for \fBdmake\fR) is now also available in \fIwin32/GNUmakefile\fR (for \fBgmake\fR). .IP \(bu 4 The \fBnmake\fR makefile no longer defaults to Visual C++ 6.0 (a very old version which is unlikely to be widely used today). As a result, it is now a requirement to specify the \f(CW\*(C`CCTYPE\*(C'\fR since there is no obvious choice of which modern version to default to instead. Failure to specify \f(CW\*(C`CCTYPE\*(C'\fR will result in an error being output and the build will stop. .Sp (The \fBdmake\fR and \fBgmake\fR makefiles will automatically detect which compiler is being used, so do not require \f(CW\*(C`CCTYPE\*(C'\fR to be set. This feature has not yet been added to the \fBnmake\fR makefile.) .IP \(bu 4 \&\f(CWsleep()\fR with warnings enabled for a \f(CW\*(C`USE_IMP_SYS\*(C'\fR build no longer warns about the sleep timeout being too large. [GH #16631] . .IP \(bu 4 Support for compiling perl on Windows using Microsoft Visual Studio 2019 (containing Visual C++ 14.2) has been added. .IP \(bu 4 \&\fBsocket()\fR now sets \f(CW$!\fR if the protocol, address family and socket type combination is not found. [GH #16849] . .IP \(bu 4 The Windows Server 2003 SP1 Platform SDK build, with its early x64 compiler and tools, was accidentally broken in Perl 5.27.9. This has now been fixed. .RE .RS 4 .RE .SH "Internal Changes" .IX Header "Internal Changes" .IP \(bu 4 The sizing pass has been eliminated from the regular expression compiler. An extra pass may instead be needed in some cases to count the number of parenthetical capture groups. .IP \(bu 4 A new function "\f(CW\*(C`my_strtod\*(C'\fR" in perlapi or its synonym, \fBStrtod()\fR, is now available with the same signature as the libc \fBstrtod()\fR. It provides \&\fBstrotod()\fR equivalent behavior on all platforms, using the best available precision, depending on platform capabilities and \fIConfigure\fR options, while handling locale-related issues, such as if the radix character should be a dot or comma. .IP \(bu 4 Added \f(CWnewSVsv_nomg()\fR to copy a SV without processing get magic on the source. [GH #16461] . .IP \(bu 4 It is now forbidden to malloc more than \f(CW\*(C`PTRDIFF_T_MAX\*(C'\fR bytes. Much code (including C optimizers) assumes that all data structures will not be larger than this, so this catches such attempts before overflow happens. .IP \(bu 4 Two new regnodes have been introduced \f(CW\*(C`EXACT_ONLY8\*(C'\fR, and \&\f(CW\*(C`EXACTFU_ONLY8\*(C'\fR. They're equivalent to \f(CW\*(C`EXACT\*(C'\fR and \f(CW\*(C`EXACTFU\*(C'\fR, except that they contain a code point which requires UTF\-8 to represent/match. Hence, if the target string isn't UTF\-8, we know it can't possibly match, without needing to try. .IP \(bu 4 \&\f(CWprint_bytes_for_locale()\fR is now defined if \f(CW\*(C`DEBUGGING\*(C'\fR, Prior, it didn't get defined unless \f(CW\*(C`LC_COLLATE\*(C'\fR was defined on the platform. .SH "Selected Bug Fixes" .IX Header "Selected Bug Fixes" .IP \(bu 4 Compilation under \f(CW\*(C`\-DPERL_MEM_LOG\*(C'\fR and \f(CW\*(C`\-DNO_LOCALE\*(C'\fR have been fixed. .IP \(bu 4 Perl 5.28 introduced an \f(CWindex()\fR optimization when comparing to \-1 (or indirectly, e.g. >= 0). When this optimization was triggered inside a \f(CW\*(C`when\*(C'\fR clause it caused a warning ("Argument \f(CW%s\fR isn't numeric in smart match"). This has now been fixed. [GH #16626] .IP \(bu 4 The new in-place editing code no longer leaks directory handles. [GH #16602] . .IP \(bu 4 Warnings produced from constant folding operations on overloaded values no longer produce spurious "Use of uninitialized value" warnings. [GH #16349] . .IP \(bu 4 Fix for "mutator not seen in (lex = ...) .= ..." [GH #16655] . .IP \(bu 4 \&\f(CW\*(C`pack "u", "invalid uuencoding"\*(C'\fR now properly NUL terminates the zero-length SV produced. [GH #16343] . .IP \(bu 4 Improve the debugging output for \fBcalloc()\fR calls with \f(CW\*(C`\-Dm\*(C'\fR. [GH #16653] . .IP \(bu 4 Regexp script runs were failing to permit ASCII digits in some cases. [GH #16704] . .IP \(bu 4 On Unix-like systems supporting a platform-specific technique for determining \f(CW$^X\fR, Perl failed to fall back to the generic technique when the platform-specific one fails (for example, a Linux system with /proc not mounted). This was a regression in Perl 5.28.0. [GH #16715] . .IP \(bu 4 SDBM_File is now more robust with corrupt database files. The improvements do not make SDBM files suitable as an interchange format. [GH #16164] . .IP \(bu 4 \&\f(CW\*(C`binmode($fh);\*(C'\fR or \f(CW\*(C`binmode($fh, \*(Aq:raw\*(Aq);\*(C'\fR now properly removes the \&\f(CW\*(C`:utf8\*(C'\fR flag from the default \f(CW\*(C`:crlf\*(C'\fR I/O layer on Win32. [GH #16730] . .IP \(bu 4 The experimental reference aliasing feature was misinterpreting array and hash slice assignment as being localised, e.g. .Sp .Vb 1 \& \e(@a[3,5,7]) = \e(....); .Ve .Sp was being interpreted as: .Sp .Vb 1 \& local \e(@a[3,5,7]) = \e(....); .Ve .Sp [GH #16701] . .IP \(bu 4 \&\f(CW\*(C`sort SUBNAME\*(C'\fR within an \f(CW\*(C`eval EXPR\*(C'\fR when \f(CW\*(C`EXPR\*(C'\fR was UTF\-8 upgraded could panic if the \f(CW\*(C`SUBNAME\*(C'\fR was non-ASCII. [GH #16979] . .IP \(bu 4 Correctly handle \fBrealloc()\fR modifying \f(CW\*(C`errno\*(C'\fR on success so that the modification isn't visible to the perl user, since \fBrealloc()\fR is called implicitly by the interpreter. This modification is permitted by the C standard, but has only been observed on FreeBSD 13.0\-CURRENT. [GH #16907] . .IP \(bu 4 Perl now exposes POSIX \f(CW\*(C`getcwd\*(C'\fR as \f(CWInternals::getcwd()\fR if available. This is intended for use by \f(CW\*(C`Cwd.pm\*(C'\fR during bootstrapping and may be removed or changed without notice. This fixes some bootstrapping issues while building perl in a directory where some ancestor directory isn't readable. [GH #16903] . .IP \(bu 4 \&\f(CWpack()\fR no longer can return malformed UTF\-8. It croaks if it would otherwise return a UTF\-8 string that contains malformed UTF\-8. This protects against potential security threats. [GH #16035] . .IP \(bu 4 See "Any set of digits in the Common script are legal in a script run of another script". .IP \(bu 4 Regular expression matching no longer leaves stale UTF\-8 length magic when updating \f(CW$^R\fR. This could result in \f(CWlength($^R)\fR returning an incorrect value. .IP \(bu 4 Reduce recursion on ops [GH #11866] . .Sp This can prevent stack overflow when processing extremely deep op trees. .IP \(bu 4 Avoid leak in multiconcat with overloading. [GH #16823] . .IP \(bu 4 The handling of user-defined \f(CW\*(C`\ep{}\*(C'\fR properties (see "User-Defined Character Properties" in perlunicode) has been rewritten to be in C (instead of Perl). This speeds things up, but in the process several inconsistencies and bug fixes are made. .RS 4 .IP 1. 4 A few error messages have minor wording changes. This is essentially because the new way is integrated into the regex error handling mechanism that marks the position in the input at which the error occurred. That was not possible previously. The messages now also contain additional back-trace-like information in case the error occurs deep in nested calls. .IP 2. 4 A user-defined property is implemented as a perl subroutine with certain highly constrained naming conventions. It was documented previously that the sub would be in the current package if the package was unspecified. This turned out not to be true in all cases, but now it is. .IP 3. 4 All recursive calls are treated as infinite recursion. Previously they would cause the interpreter to panic. Now, they cause the regex pattern to fail to compile. .IP 4. 4 Similarly, any other error likely would lead to a panic; now to just the pattern failing to compile. .IP 5. 4 The old mechanism did not detect illegal ranges in the definition of the property. Now, the range max must not be smaller than the range min. Otherwise, the pattern fails to compile. .IP 6. 4 The intention was to have each sub called only once during the lifetime of the program, so that a property's definition is immutable. This was relaxed so that it could be called once for all /i compilations, and potentially a second time for non\-/i (the sub is passed a parameter indicating which). However, in practice there were instances when this was broken, and multiple calls were possible. Those have been fixed. Now (besides the /i,non\-/i cases) the only way a sub can be called multiple times is if some component of it has not been defined yet. For example, suppose we have sub \fBIsA()\fR whose definition is known at compile time, and it in turn calls \fBisB()\fR whose definition is not yet known. \&\fBisA()\fR will be called each time a pattern it appears in is compiled. If \&\fBisA()\fR also calls \fBisC()\fR and that definition is known, \fBisC()\fR will be called just once. .IP 7. 4 There were some races and very long hangs should one thread be compiling the same property as another simultaneously. These have now been fixed. .RE .RS 4 .RE .IP \(bu 4 Fixed a failure to match properly. .Sp An EXACTFish regnode has a finite length it can hold for the string being matched. If that length is exceeded, a second node is used for the next segment of the string, for as many regnodes as are needed. Care has to be taken where to break the string, in order to deal multi-character folds in Unicode correctly. If we want to break a string at a place which could potentially be in the middle of a multi-character fold, we back off one (or more) characters, leaving a shorter EXACTFish regnode. This backing off mechanism contained an off-by-one error. [GH #16806] . .IP \(bu 4 A bare \f(CW\*(C`eof\*(C'\fR call with no previous file handle now returns true. [GH #16786] .IP \(bu 4 Failing to compile a format now aborts compilation. Like other errors in sub-parses this could leave the parser in a strange state, possibly crashing perl if compilation continued. [GH #16169] .IP \(bu 4 If an in-place edit is still in progress during global destruction and the process exit code (as stored in \f(CW$?\fR) is zero, perl will now treat the in-place edit as successful, replacing the input file with any output produced. .Sp This allows code like: .Sp .Vb 1 \& perl \-i \-ne \*(Aqprint "Foo"; last\*(Aq .Ve .Sp to replace the input file, while code like: .Sp .Vb 1 \& perl \-i \-ne \*(Aqprint "Foo"; die\*(Aq .Ve .Sp will not. Partly resolves [GH #16748] . .IP \(bu 4 A regression in 5.28 caused the following code to fail .Sp .Vb 1 \& close(STDIN); open(CHILD, "|wc \-l")\*(Aq .Ve .Sp because the child's stdin would be closed on exec. This has now been fixed. .IP \(bu 4 Fixed an issue where compiling a regexp containing both compile-time and run-time code blocks could lead to trying to compile something which is invalid syntax. .IP \(bu 4 Fixed build failures with \f(CW\*(C`\-DNO_LOCALE_NUMERIC\*(C'\fR and \&\f(CW\*(C`\-DNO_LOCALE_COLLATE\*(C'\fR. [GH #16771] . .IP \(bu 4 Prevent the tests in \fIext/B/t/strict.t\fR from being skipped. [GH #16783] . .IP \(bu 4 \&\f(CW\*(C`/di\*(C'\fR nodes ending or beginning in \fIs\fR are now \f(CW\*(C`EXACTF\*(C'\fR. We do not want two \f(CW\*(C`EXACTFU\*(C'\fR to be joined together during optimization, and to form a \f(CW\*(C`ss\*(C'\fR, \f(CW\*(C`sS\*(C'\fR, \f(CW\*(C`Ss\*(C'\fR or \f(CW\*(C`SS\*(C'\fR sequence; they are the only multi-character sequences which may match differently under \f(CW\*(C`/ui\*(C'\fR and \f(CW\*(C`/di\*(C'\fR. .SH Acknowledgements .IX Header "Acknowledgements" Perl 5.30.0 represents approximately 11 months of development since Perl 5.28.0 and contains approximately 620,000 lines of changes across 1,300 files from 58 authors. .PP Excluding auto-generated files, documentation and release tools, there were approximately 510,000 lines of changes to 750 .pm, .t, .c and .h files. .PP Perl continues to flourish into its fourth decade thanks to a vibrant community of users and developers. The following people are known to have contributed the improvements that became Perl 5.30.0: .PP Aaron Crane, Abigail, Alberto Simões, Alexandr Savca, Andreas König, Andy Dougherty, Aristotle Pagaltzis, Brian Greenfield, Chad Granum, Chris \&'BinGOs' Williams, Craig A. Berry, Dagfinn Ilmari Mannsåker, Dan Book, Dan Dedrick, Daniel Dragan, Dan Kogai, David Cantrell, David Mitchell, Dominic Hargreaves, E. Choroba, Ed J, Eugen Konkov, François Perrad, Graham Knop, Hauke D, H.Merijn Brand, Hugo van der Sanden, Jakub Wilk, James Clarke, James E Keenan, Jerry D. Hedden, Jim Cromie, John SJ Anderson, Karen Etheridge, Karl Williamson, Leon Timmermans, Matthias Bethke, Nicholas Clark, Nicolas R., Niko Tyni, Pali, Petr Písař, Phil Pearl (Lobbes), Richard Leach, Ryan Voots, Sawyer X, Shlomi Fish, Sisyphus, Slaven Rezic, Steve Hay, Sullivan Beck, Tina Müller, Tomasz Konojacki, Tom Wyant, Tony Cook, Unicode Consortium, Yves Orton, Zak B. Elep. .PP The list above is almost certainly incomplete as it is automatically generated from version control history. In particular, it does not include the names of most of the (very much appreciated) contributors who reported issues to the Perl bug tracker. Noteworthy in this release were the large number of bug fixes made possible by Sergey Aleynikov's high quality perlbug reports for issues he discovered by fuzzing with AFL. .PP Many of the changes included in this version originated in the CPAN modules included in Perl's core. We're grateful to the entire CPAN community for helping Perl to flourish. .PP For a more complete list of all of Perl's historical contributors, please see the \fIAUTHORS\fR file in the Perl source distribution. .SH "Reporting Bugs" .IX Header "Reporting Bugs" If you find what you think is a bug, you might check the perl bug database at . There may also be information at , the Perl Home Page. .PP If you believe you have an unreported bug, please run the perlbug program included with your release. Be sure to trim your bug down to a tiny but sufficient test case. Your bug report, along with the output of \f(CW\*(C`perl \-V\*(C'\fR, will be sent off to perlbug@perl.org to be analysed by the Perl porting team. .PP If the bug you are reporting has security implications which make it inappropriate to send to a publicly archived mailing list, then see "SECURITY VULNERABILITY CONTACT INFORMATION" in perlsec for details of how to report the issue. .SH "Give Thanks" .IX Header "Give Thanks" If you wish to thank the Perl 5 Porters for the work we had done in Perl 5, you can do so by running the \f(CW\*(C`perlthanks\*(C'\fR program: .PP .Vb 1 \& perlthanks .Ve .PP This will send an email to the Perl 5 Porters list with your show of thanks. .SH "SEE ALSO" .IX Header "SEE ALSO" The \fIChanges\fR file for an explanation of how to view exhaustive details on what changed. .PP The \fIINSTALL\fR file for how to build Perl. .PP The \fIREADME\fR file for general stuff. .PP The \fIArtistic\fR and \fICopying\fR files for copyright information.