2012年5月22日

[installer 3225] perl-5.16.0

perl-5.16.0 出ています。

☆ perl-5.16.0
http://www.perl.com/CPAN/src/
http://www.cpan.org/src/5.0/perl-5.16.0.tar.gz

NAME
perldelta - what is new for perl v5.16.0


DESCRIPTION
This document describes differences between the 5.14.0 release and the
5.16.0 release.

If you are upgrading from an earlier release such as 5.12.0, first read
perl5140delta, which describes differences between 5.12.0 and 5.14.0.

Some bug fixes in this release have been backported to later releases of
5.14.x. Those are indicated with the 5.14.x version in parentheses.

Notice
With the release of Perl 5.16.0, the 5.12.x series of releases is now
out of its support period. There may be future 5.12.x releases, but only
in the event of a critical security issue. Users of Perl 5.12 or earlier
should consider upgrading to a more recent release of Perl.

This policy is described in greater detail in perlpolicy.

Core Enhancements
"use *VERSION*"
As of this release, version declarations like "use v5.16" now disable
all features before enabling the new feature bundle. This means that the
following holds true:

use 5.016;
# only 5.16 features enabled here
use 5.014;
# only 5.14 features enabled here (not 5.16)

"use v5.12" and higher continue to enable strict, but explicit "use
strict" and "no strict" now override the version declaration, even when
they come first:

no strict;
use 5.012;
# no strict here

There is a new ":default" feature bundle that represents the set of
features enabled before any version declaration or "use feature" has
been seen. Version declarations below 5.10 now enable the ":default"
feature set. This does not actually change the behavior of "use v5.8",
because features added to the ":default" set are those that were
traditionally enabled by default, before they could be turned off.

"no feature" now resets to the default feature set. To disable all
features (which is likely to be a pretty special-purpose request, since
it presumably won't match any named set of semantics) you can now write
"no feature ':all'".

$[ is now disabled under "use v5.16". It is part of the default feature
set and can be turned on or off explicitly with "use feature
'array_base'".

"__SUB__"
The new "__SUB__" token, available under the "current_sub" feature (see
feature) or "use v5.16", returns a reference to the current subroutine,
making it easier to write recursive closures.

New and Improved Built-ins
More consistent "eval"
The "eval" operator sometimes treats a string argument as a sequence of
characters and sometimes as a sequence of bytes, depending on the
internal encoding. The internal encoding is not supposed to make any
difference, but there is code that relies on this inconsistency.

The new "unicode_eval" and "evalbytes" features (enabled under "use
5.16.0") resolve this. The "unicode_eval" feature causes "eval $string"
to treat the string always as Unicode. The "evalbytes" features provides
a function, itself called "evalbytes", which evaluates its argument
always as a string of bytes.

These features also fix oddities with source filters leaking to outer
dynamic scopes.

See feature for more detail.

"substr" lvalue revamp
When "substr" is called in lvalue or potential lvalue context with two
or three arguments, a special lvalue scalar is returned that modifies
the original string (the first argument) when assigned to.

Previously, the offsets (the second and third arguments) passed to
"substr" would be converted immediately to match the string, negative
offsets being translated to positive and offsets beyond the end of the
string being truncated.

Now, the offsets are recorded without modification in the special lvalue
scalar that is returned, and the original string is not even looked at
by "substr" itself, but only when the returned lvalue is read or
modified.

These changes result in an incompatible change:

If the original string changes length after the call to "substr" but
before assignment to its return value, negative offsets will remember
their position from the end of the string, affecting code like this:

my $string = "string";
my $lvalue = \substr $string, -4, 2;
print $$lvalue, "\n"; # prints "ri"
$string = "bailing twine";
print $$lvalue, "\n"; # prints "wi"; used to print "il"

The same thing happens with an omitted third argument. The returned
lvalue will always extend to the end of the string, even if the string
becomes longer.

Since this change also allowed many bugs to be fixed (see "The "substr"
operator"), and since the behavior of negative offsets has never been
specified, the change was deemed acceptable.

Return value of "tied"
The value returned by "tied" on a tied variable is now the actual scalar
that holds the object to which the variable is tied. This lets ties be
weakened with "Scalar::Util::weaken(tied $tied_variable)".

Unicode Support
Supports (*almost*) Unicode 6.1
Besides the addition of whole new scripts, and new characters in
existing scripts, this new version of Unicode, as always, makes some
changes to existing characters. One change that may trip up some
applications is that the General Category of two characters in the
Latin-1 range, PILCROW SIGN and SECTION SIGN, has been changed from
Other_Symbol to Other_Punctuation. The same change has been made for a
character in each of Tibetan, Ethiopic, and Aegean. The code points
U+3248..U+324F (CIRCLED NUMBER TEN ON BLACK SQUARE through CIRCLED
NUMBER EIGHTY ON BLACK SQUARE) have had their General Category changed
from Other_Symbol to Other_Numeric. The Line Break property has changes
for Hebrew and Japanese; and because of other changes in 6.1, the Perl
regular expression construct "\X" now works differently for some
characters in Thai and Lao.

New aliases (synonyms) have been defined for many property values;
these, along with the previously existing ones, are all cross-indexed in
perluniprops.

The return value of "charnames::viacode()" is affected by other changes:

Code point Old Name New Name
U+000A LINE FEED (LF) LINE FEED
U+000C FORM FEED (FF) FORM FEED
U+000D CARRIAGE RETURN (CR) CARRIAGE RETURN
U+0085 NEXT LINE (NEL) NEXT LINE
U+008E SINGLE-SHIFT 2 SINGLE-SHIFT-2
U+008F SINGLE-SHIFT 3 SINGLE-SHIFT-3
U+0091 PRIVATE USE 1 PRIVATE USE-1
U+0092 PRIVATE USE 2 PRIVATE USE-2
U+2118 SCRIPT CAPITAL P WEIERSTRASS ELLIPTIC FUNCTION

Perl will accept any of these names as input, but "charnames::viacode()"
now returns the new name of each pair. The change for U+2118 is
considered by Unicode to be a correction, that is the original name was
a mistake (but again, it will remain forever valid to use it to refer to
U+2118). But most of these changes are the fallout of the mistake
Unicode 6.0 made in naming a character used in Japanese cell phones to
be "BELL", which conflicts with the longstanding industry use of (and
Unicode's recommendation to use) that name to mean the ASCII control
character at U+0007. Therefore, that name has been deprecated in Perl
since v5.14, and any use of it will raise a warning message (unless
turned off). The name "ALERT" is now the preferred name for this code
point, with "BEL" an acceptable short form. The name for the new cell
phone character, at code point U+1F514, remains undefined in this
version of Perl (hence we don't implement quite all of Unicode 6.1), but
starting in v5.18, BELL will mean this character, and not U+0007.

Unicode has taken steps to make sure that this sort of mistake does not
happen again. The Standard now includes all generally accepted names and
abbreviations for control characters, whereas previously it didn't
(though there were recommended names for most of them, which Perl used).
This means that most of those recommended names are now officially in
the Standard. Unicode did not recommend names for the four code points
listed above between U+008E and U+008F, and in standardizing them
Unicode subtly changed the names that Perl had previously given them, by
replacing the final blank in each name by a hyphen. Unicode also
officially accepts names that Perl had deprecated, such as FILE
SEPARATOR. Now the only deprecated name is BELL. Finally, Perl now uses
the new official names instead of the old (now considered obsolete)
names for the first four code points in the list above (the ones which
have the parentheses in them).

Now that the names have been placed in the Unicode standard, these kinds
of changes should not happen again, though corrections, such as to
U+2118, are still possible.

Unicode also added some name abbreviations, which Perl now accepts: SP
for SPACE; TAB for CHARACTER TABULATION; NEW LINE, END OF LINE, NL, and
EOL for LINE FEED; LOCKING-SHIFT ONE for SHIFT OUT; LOCKING-SHIFT ZERO
for SHIFT IN; and ZWNBSP for ZERO WIDTH NO-BREAK SPACE.

More details on this version of Unicode are provided in
< http://www.unicode.org/versions/Unicode6.1.0/>;.

"use charnames" is no longer needed for "\N{*name*}"
When "\N{*name*}" is encountered, the "charnames" module is now
automatically loaded when needed as if the ":full" and ":short" options
had been specified. See charnames for more information.

"\N{...}" can now have Unicode loose name matching
This is described in the "charnames" item in "Updated Modules and
Pragmata" below.

Unicode Symbol Names
Perl now has proper support for Unicode in symbol names. It used to be
that "*{$foo}" would ignore the internal UTF8 flag and use the bytes of
the underlying representation to look up the symbol. That meant that
"*{"\x{100}"}" and "*{"\xc4\x80"}" would return the same thing. All
these parts of Perl have been fixed to account for Unicode:

* Method names (including those passed to "use overload")

* Typeglob names (including names of variables, subroutines, and
filehandles)

* Package names

* "goto"

* Symbolic dereferencing

* Second argument to "bless()" and "tie()"

* Return value of "ref()"

* Subroutine prototypes

* Attributes

* Various warnings and error messages that mention variable names or
values, methods, etc.

In addition, a parsing bug has been fixed that prevented "*{テゥ}" from
implicitly quoting the name, but instead interpreted it as "*{+テゥ}",
which would cause a strict violation.

"*{"*a::b"}" automatically strips off the * if it is followed by an
ASCII letter. That has been extended to all Unicode identifier
characters.

One-character non-ASCII non-punctuation variables (like $テゥ) are now
subject to "Used only once" warnings. They used to be exempt, as they
were treated as punctuation variables.

Also, single-character Unicode punctuation variables (like $窶ー) are now
supported [perl #69032].

Improved ability to mix locales and Unicode, including UTF-8 locales
An optional parameter has been added to "use locale"

use locale ':not_characters';

which tells Perl to use all but the "LC_CTYPE" and "LC_COLLATE" portions
of the current locale. Instead, the character set is assumed to be
Unicode. This lets locales and Unicode be seamlessly mixed, including
the increasingly frequent UTF-8 locales. When using this hybrid form of
locales, the ":locale" layer to the open pragma can be used to interface
with the file system, and there are CPAN modules available for ARGV and
environment variable conversions.

Full details are in perllocale.

New function "fc" and corresponding escape sequence "\F" for Unicode foldcase
Unicode foldcase is an extension to lowercase that gives better results
when comparing two strings case-insensitively. It has long been used
internally in regular expression "/i" matching. Now it is available
explicitly through the new "fc" function call (enabled by "use feature
'fc'", or "use v5.16", or explicitly callable via "CORE::fc") or through
the new "\F" sequence in double-quotish strings.

Full details are in "fc" in perlfunc.

The Unicode "Script_Extensions" property is now supported.
New in Unicode 6.0, this is an improved "Script" property. Details are
in "Scripts" in perlunicode.

XS Changes
Improved typemaps for Some Builtin Types
Most XS authors will know there is a longstanding bug in the OUTPUT
typemap for T_AVREF ("AV*"), T_HVREF ("HV*"), T_CVREF ("CV*"), and
T_SVREF ("SVREF" or "\$foo") that requires manually decrementing the
reference count of the return value instead of the typemap taking care
of this. For backwards-compatibility, this cannot be changed in the
default typemaps. But we now provide additional typemaps
"T_AVREF_REFCOUNT_FIXED", etc. that do not exhibit this bug. Using them
in your extension is as simple as having one line in your "TYPEMAP"
section:

HV* T_HVREF_REFCOUNT_FIXED

"is_utf8_char()"
The XS-callable function "is_utf8_char()", when presented with malformed
UTF-8 input, can read up to 12 bytes beyond the end of the string. This
cannot be fixed without changing its API, and so its use is now
deprecated. Use "is_utf8_char_buf()" (described just below) instead.

Added "is_utf8_char_buf()"
This function is designed to replace the deprecated "is_utf8_char()"
function. It includes an extra parameter to make sure it doesn't read
past the end of the input buffer.

Other "is_utf8_foo()" functions, as well as "utf8_to_foo()", etc.
Most other XS-callable functions that take UTF-8 encoded input
implicitly assume that the UTF-8 is valid (not malformed) with respect
to buffer length. Do not do things such as change a character's case or
see if it is alphanumeric without first being sure that it is valid
UTF-8. This can be safely done for a whole string by using one of the
functions "is_utf8_string()", "is_utf8_string_loc()", and
"is_utf8_string_loclen()".

New Pad API
Many new functions have been added to the API for manipulating lexical
pads. See "Pad Data Structures" in perlapi for more information.

Changes to Special Variables
$$ can be assigned to
$$ was made read-only in Perl 5.8.0. But only sometimes: "local $$"
would make it writable again. Some CPAN modules were using "local $$" or
XS code to bypass the read-only check, so there is no reason to keep $$
read-only. (This change also allowed a bug to be fixed while maintaining
backward compatibility.)

$^X converted to an absolute path on FreeBSD, OS X and Solaris
$^X is now converted to an absolute path on OS X, FreeBSD (without
needing /proc mounted) and Solaris 10 and 11. This augments the previous
approach of using /proc on Linux, FreeBSD, and NetBSD (in all cases,
where mounted).

This makes relocatable perl installations more useful on these
platforms. (See "Relocatable @INC" in INSTALL)

Debugger Changes
Features inside the debugger
The current Perl's feature bundle is now enabled for commands entered in
the interactive debugger.

New option for the debugger's t command
The t command in the debugger, which toggles tracing mode, now accepts a
numeric argument that determines how many levels of subroutine calls to
trace.

"enable" and "disable"
The debugger now has "disable" and "enable" commands for disabling
existing breakpoints and re-enabling them. See perldebug.

Breakpoints with file names
The debugger's "b" command for setting breakpoints now lets a line
number be prefixed with a file name. See "b [file]:[line] [condition]"
in perldebug.

The "CORE" Namespace
The "CORE::" prefix
The "CORE::" prefix can now be used on keywords enabled by feature.pm,
even outside the scope of "use feature".

Subroutines in the "CORE" namespace
Many Perl keywords are now available as subroutines in the CORE
namespace. This lets them be aliased:

BEGIN { *entangle = \&CORE::tie }
entangle $variable, $package, @args;

And for prototypes to be bypassed:

sub mytie(\[%$*@]$@) {
my ($ref, $pack, @args) = @_;
... do something ...
goto &CORE::tie;
}

Some of these cannot be called through references or via &foo syntax,
but must be called as barewords.

See CORE for details.

Other Changes
Anonymous handles
Automatically generated file handles are now named __ANONIO__ when the
variable name cannot be determined, rather than $__ANONIO__.

Autoloaded sort Subroutines
Custom sort subroutines can now be autoloaded [perl #30661]:

sub AUTOLOAD { ... }
@sorted = sort foo @list; # uses AUTOLOAD

"continue" no longer requires the "switch" feature
The "continue" keyword has two meanings. It can introduce a "continue"
block after a loop, or it can exit the current "when" block. Up to now,
the latter meaning was valid only with the "switch" feature enabled, and
was a syntax error otherwise. Since the main purpose of feature.pm is to
avoid conflicts with user-defined subroutines, there is no reason for
"continue" to depend on it.

DTrace probes for interpreter phase change
The "phase-change" probes will fire when the interpreter's phase
changes, which tracks the "${^GLOBAL_PHASE}" variable. "arg0" is the new
phase name; "arg1" is the old one. This is useful for limiting your
instrumentation to one or more of: compile time, run time, or destruct
time.

"__FILE__()" Syntax
The "__FILE__", "__LINE__" and "__PACKAGE__" tokens can now be written
with an empty pair of parentheses after them. This makes them parse the
same way as "time", "fork" and other built-in functions.

The "\$" prototype accepts any scalar lvalue
The "\$" and "\[$]" subroutine prototypes now accept any scalar lvalue
argument. Previously they accepted only scalars beginning with "$" and
hash and array elements. This change makes them consistent with the way
the built-in "read" and "recv" functions (among others) parse their
arguments. This means that one can override the built-in functions with
custom subroutines that parse their arguments the same way.

"_" in subroutine prototypes
The "_" character in subroutine prototypes is now allowed before "@" or
"%".

Security
Use "is_utf8_char_buf()" and not "is_utf8_char()"
The latter function is now deprecated because its API is insufficient to
guarantee that it doesn't read (up to 12 bytes in the worst case) beyond
the end of its input string. See is_utf8_char_buf().

Malformed UTF-8 input could cause attempts to read beyond the end of the buffer
Two new XS-accessible functions, "utf8_to_uvchr_buf()" and
"utf8_to_uvuni_buf()" are now available to prevent this, and the Perl
core has been converted to use them. See "Internal Changes".

"File::Glob::bsd_glob()" memory error with GLOB_ALTDIRFUNC (CVE-2011-2728).
Calling "File::Glob::bsd_glob" with the unsupported flag GLOB_ALTDIRFUNC
would cause an access violation / segfault. A Perl program that accepts
a flags value from an external source could expose itself to denial of
service or arbitrary code execution attacks. There are no known exploits
in the wild. The problem has been corrected by explicitly disabling all
unsupported flags and setting unused function pointers to null. Bug
reported by Clテゥment Lecigne. (5.14.2)

Privileges are now set correctly when assigning to $(
A hypothetical bug (probably unexploitable in practice) because the
incorrect setting of the effective group ID while setting $( has been
fixed. The bug would have affected only systems that have "setresgid()"
but not "setregid()", but no such systems are known to exist.

Deprecations
Don't read the Unicode data base files in lib/unicore
It is now deprecated to directly read the Unicode data base files. These
are stored in the lib/unicore directory. Instead, you should use the new
functions in Unicode::UCD. These provide a stable API, and give complete
information.

Perl may at some point in the future change or remove these files. The
file which applications were most likely to have used is
lib/unicore/ToDigit.pl. "prop_invmap()" in Unicode::UCD can be used to
get at its data instead.

XS functions "is_utf8_char()", "utf8_to_uvchr()" and
"utf8_to_uvuni()"
This function is deprecated because it could read beyond the end of the
input string. Use the new is_utf8_char_buf(), "utf8_to_uvchr_buf()" and
"utf8_to_uvuni_buf()" instead.

Future Deprecations
This section serves as a notice of features that are *likely* to be
removed or deprecated in the next release of perl (5.18.0). If your code
depends on these features, you should contact the Perl 5 Porters via the
mailing list < http://lists.perl.org/list/perl5-porters.html>; or perlbug
to explain your use case and inform the deprecation process.

Core Modules
These modules may be marked as deprecated *from the core*. This only
means that they will no longer be installed by default with the core
distribution, but will remain available on the CPAN.

* CPANPLUS

* Filter::Simple

* PerlIO::mmap

* Pod::LaTeX

* Pod::Parser

* SelfLoader

* Text::Soundex

* Thread.pm

Platforms with no supporting programmers:
These platforms will probably have their special build support removed
during the 5.17.0 development series.

* BeOS

* djgpp

* dgux

* EPOC

* MPE/iX

* Rhapsody

* UTS

* VM/ESA

Other Future Deprecations
* Swapping of $< and $>

For more information about this future deprecation, see the relevant
RT ticket <https://rt.perl.org/rt3/Ticket/Display.html?id=96212>.

* sfio, stdio

Perl supports being built without PerlIO proper, using a stdio or
sfio wrapper instead. A perl build like this will not support IO
layers and thus Unicode IO, making it rather handicapped.

PerlIO supports a "stdio" layer if stdio use is desired, and
similarly a sfio layer could be produced.

* Unescaped literal "{" in regular expressions.

Starting with v5.20, it is planned to require a literal "{" to be
escaped, for example by preceding it with a backslash. In v5.18, a
deprecated warning message will be emitted for all such uses. This
affects only patterns that are to match a literal "{". Other uses of
this character, such as part of a quantifier or sequence as in those
below, are completely unaffected:

/foo{3,5}/
/\p{Alphabetic}/
/\N{DIGIT ZERO}

Removing this will permit extensions to Perl's pattern syntax and
better error checking for existing syntax. See "Quantifiers" in
perlre for an example.

* Revamping "\Q" semantics in double-quotish strings when combined
with other escapes.

There are several bugs and inconsistencies involving combinations of
"\Q" and escapes like "\x", "\L", etc., within a "\Q...\E" pair.
These need to be fixed, and doing so will necessarily change current
behavior. The changes have not yet been settled.

Incompatible Changes
Special blocks called in void context
Special blocks ("BEGIN", "CHECK", "INIT", "UNITCHECK", "END") are now
called in void context. This avoids wasteful copying of the result of
the last statement [perl #108794].

The "overloading" pragma and regexp objects
With "no overloading", regular expression objects returned by "qr//" are
now stringified as "Regexp=REGEXP(0xbe600d)" instead of the regular
expression itself [perl #108780].

Two XS typemap Entries removed
Two presumably unused XS typemap entries have been removed from the core
typemap: T_DATAUNIT and T_CALLBACK. If you are, against all odds, a user
of these, please see the instructions on how to restore them in
perlxstypemap.

Unicode 6.1 has incompatibilities with Unicode 6.0
These are detailed in "Supports (almost) Unicode 6.1" above. You can
compile this version of Perl to use Unicode 6.0. See "Hacking Perl to
work on earlier Unicode versions (for very serious hackers only)" in
perlunicode.

Borland compiler
All support for the Borland compiler has been dropped. The code had not
worked for a long time anyway.

Certain deprecated Unicode properties are no longer supported by default
Perl should never have exposed certain Unicode properties that are used
by Unicode internally and not meant to be publicly available. Use of
these has generated deprecated warning messages since Perl 5.12. The
removed properties are Other_Alphabetic,
Other_Default_Ignorable_Code_Point, Other_Grapheme_Extend,
Other_ID_Continue, Other_ID_Start, Other_Lowercase, Other_Math, and
Other_Uppercase.

Perl may be recompiled to include any or all of them; instructions are
given in "Unicode character properties that are NOT accepted by Perl" in
perluniprops.

Dereferencing IO thingies as typeglobs
The "*{...}" operator, when passed a reference to an IO thingy (as in
"*{*STDIN{IO}}"), creates a new typeglob containing just that IO object.
Previously, it would stringify as an empty string, but some operators
would treat it as undefined, producing an "uninitialized" warning. Now
it stringifies as __ANONIO__ [perl #96326].

User-defined case-changing operations
This feature was deprecated in Perl 5.14, and has now been removed. The
CPAN module Unicode::Casing provides better functionality without the
drawbacks that this feature had, as are detailed in the 5.14
documentation:
< http://perldoc.perl.org/5.14.0/perlunicode.html#User-Defined-Case-Mappi
ngs-%28for-serious-hackers-only%29>

XSUBs are now 'static'
XSUB C functions are now 'static', that is, they are not visible from
outside the compilation unit. Users can use the new "XS_EXTERNAL(name)"
and "XS_INTERNAL(name)" macros to pick the desired linking behavior. The
ordinary "XS(name)" declaration for XSUBs will continue to declare
non-'static' XSUBs for compatibility, but the XS compiler,
ExtUtils::ParseXS ("xsubpp") will emit 'static' XSUBs by default.
ExtUtils::ParseXS's behavior can be reconfigured from XS using the
"EXPORT_XSUB_SYMBOLS" keyword. See perlxs for details.

Weakening read-only references
Weakening read-only references is no longer permitted. It should never
have worked anyway, and could sometimes result in crashes.

Tying scalars that hold typeglobs
Attempting to tie a scalar after a typeglob was assigned to it would
instead tie the handle in the typeglob's IO slot. This meant that it was
impossible to tie the scalar itself. Similar problems affected "tied"
and "untie": "tied $scalar" would return false on a tied scalar if the
last thing returned was a typeglob, and "untie $scalar" on such a tied
scalar would do nothing.

We fixed this problem before Perl 5.14.0, but it caused problems with
some CPAN modules, so we put in a deprecation cycle instead.

Now the deprecation has been removed and this bug has been fixed. So
"tie $scalar" will always tie the scalar, not the handle it holds. To
tie the handle, use "tie *$scalar" (with an explicit asterisk). The same
applies to "tied *$scalar" and "untie *$scalar".

IPC::Open3 no longer provides "xfork()", "xclose_on_exec()"
and "xpipe_anon()"
All three functions were private, undocumented, and unexported. They do
not appear to be used by any code on CPAN. Two have been inlined and one
deleted entirely.

$$ no longer caches PID
Previously, if one called fork(3) from C, Perl's notion of $$ could go
out of sync with what getpid() returns. By always fetching the value of
$$ via getpid(), this potential bug is eliminated. Code that depends on
the caching behavior will break. As described in Core Enhancements, $$
is now writable, but it will be reset during a fork.

$$ and "getppid()" no longer emulate POSIX semantics under LinuxThreads
The POSIX emulation of $$ and "getppid()" under the obsolete
LinuxThreads implementation has been removed. This only impacts users of
Linux 2.4 and users of Debian GNU/kFreeBSD up to and including 6.0, not
the vast majority of Linux installations that use NPTL threads.

This means that "getppid()", like $$, is now always guaranteed to return
the OS's idea of the current state of the process, not perl's cached
version of it.

See the documentation for $$ for details.

$<, $>, $( and $) are no longer cached
Similarly to the changes to $$ and "getppid()", the internal caching of
$<, $>, $( and $) has been removed.

When we cached these values our idea of what they were would drift out
of sync with reality if someone (e.g., someone embedding perl) called
"sete?[ug]id()" without updating "PL_e?[ug]id". Having to deal with this
complexity wasn't worth it given how cheap the "gete?[ug]id()" system
call is.

This change will break a handful of CPAN modules that use the XS-level
"PL_uid", "PL_gid", "PL_euid" or "PL_egid" variables.

The fix for those breakages is to use "PerlProc_gete?[ug]id()" to
retrieve them (e.g., "PerlProc_getuid()"), and not to assign to
"PL_e?[ug]id" if you change the UID/GID/EUID/EGID. There is no longer
any need to do so since perl will always retrieve the up-to-date version
of those values from the OS.

Which Non-ASCII characters get quoted by "quotemeta" and "\Q" has changed
This is unlikely to result in a real problem, as Perl does not attach
special meaning to any non-ASCII character, so it is currently
irrelevant which are quoted or not. This change fixes bug [perl #77654]
and brings Perl's behavior more into line with Unicode's
recommendations. See "quotemeta" in perlfunc.

Performance Enhancements
* Improved performance for Unicode properties in regular expressions

Matching a code point against a Unicode property is now done via a
binary search instead of linear. This means for example that the
worst case for a 1000 item property is 10 probes instead of 1000.
This inefficiency has been compensated for in the past by
permanently storing in a hash the results of a given probe plus the
results for the adjacent 64 code points, under the theory that
near-by code points are likely to be searched for. A separate hash
was used for each mention of a Unicode property in each regular
expression. Thus, "qr/\p{foo}abc\p{foo}/" would generate two hashes.
Any probes in one instance would be unknown to the other, and the
hashes could expand separately to be quite large if the regular
expression were used on many different widely-separated code points.
Now, however, there is just one hash shared by all instances of a
given property. This means that if "\p{foo}" is matched against "A"
in one regular expression in a thread, the result will be known
immediately to all regular expressions, and the relentless march of
using up memory is slowed considerably.

* Version declarations with the "use" keyword (e.g., "use 5.012") are
now faster, as they enable features without loading feature.pm.

* "local $_" is faster now, as it no longer iterates through magic
that it is not going to copy anyway.

* Perl 5.12.0 sped up the destruction of objects whose classes define
empty "DESTROY" methods (to prevent autoloading), by simply not
calling such empty methods. This release takes this optimization a
step further, by not calling any "DESTROY" method that begins with a
"return" statement. This can be useful for destructors that are only
used for debugging:

use constant DEBUG => 1;
sub DESTROY { return unless DEBUG; ... }

Constant-folding will reduce the first statement to "return;" if
DEBUG is set to 0, triggering this optimization.

* Assigning to a variable that holds a typeglob or copy-on-write
scalar is now much faster. Previously the typeglob would be
stringified or the copy-on-write scalar would be copied before being
clobbered.

* Assignment to "substr" in void context is now more than twice its
previous speed. Instead of creating and returning a special lvalue
scalar that is then assigned to, "substr" modifies the original
string itself.

* "substr" no longer calculates a value to return when called in void
context.

* Due to changes in File::Glob, Perl's "glob" function and its "<...>"
equivalent are now much faster. The splitting of the pattern into
words has been rewritten in C, resulting in speed-ups of 20% for
some cases.

This does not affect "glob" on VMS, as it does not use File::Glob.

* The short-circuiting operators "&&", "||", and "//", when chained
(such as "$a || $b || $c"), are now considerably faster to
short-circuit, due to reduced optree traversal.

* The implementation of "s///r" makes one fewer copy of the scalar's
value.

* Recursive calls to lvalue subroutines in lvalue scalar context use
less memory.

Modules and Pragmata
Deprecated Modules
Version::Requirements
Version::Requirements is now DEPRECATED, use
CPAN::Meta::Requirements, which is a drop-in replacement. It will be
deleted from perl.git blead in v5.17.0.

New Modules and Pragmata
* arybase -- this new module implements the $[ variable.

* PerlIO::mmap 0.010 has been added to the Perl core.

The "mmap" PerlIO layer is no longer implemented by perl itself, but
has been moved out into the new PerlIO::mmap module.

Updated Modules and Pragmata
This is only an overview of selected module updates. For a complete list
of updates, run:

$ corelist --diff 5.14.0 5.16.0

You can substitute your favorite version in place of 5.14.0, too.

* Archive::Extract has been upgraded from version 0.48 to 0.58.

Includes a fix for FreeBSD to only use "unzip" if it is located in
"/usr/local/bin", as FreeBSD 9.0 will ship with a limited "unzip" in
"/usr/bin".

* Archive::Tar has been upgraded from version 1.76 to 1.82.

Adjustments to handle files >8gb (>0777777777777 octal) and a
feature to return the MD5SUM of files in the archive.

* base has been upgraded from version 2.16 to 2.18.

"base" no longer sets a module's $VERSION to "-1" when a module it
loads does not define a $VERSION. This change has been made because
"-1" is not a valid version number under the new "lax" criteria used
internally by "UNIVERSAL::VERSION". (See version for more on "lax"
version criteria.)

"base" no longer internally skips loading modules it has already
loaded and instead relies on "require" to inspect %INC. This fixes a
bug when "base" is used with code that clear %INC to force a module
to be reloaded.

* Carp has been upgraded from version 1.20 to 1.26.

It now includes last read filehandle info and puts a dot after the
file and line number, just like errors from "die" [perl #106538].

* charnames has been updated from version 1.18 to 1.30.

"charnames" can now be invoked with a new option, ":loose", which is
like the existing ":full" option, but enables Unicode loose name
matching. Details are in "LOOSE MATCHES" in charnames.

* B::Deparse has been upgraded from version 1.03 to 1.14. This fixes
numerous deparsing bugs.

* CGI has been upgraded from version 3.52 to 3.59.

It uses the public and documented FCGI.pm API in CGI::Fast.
CGI::Fast was using an FCGI API that was deprecated and removed from
documentation more than ten years ago. Usage of this deprecated API
with FCGI >= 0.70 or FCGI <= 0.73 introduces a security issue.
<https://rt.cpan.org/Public/Bug/Display.html?id=68380>
< http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2011-2766>;

Things that may break your code:

"url()" was fixed to return "PATH_INFO" when it is explicitly
requested with either the "path=>1" or "path_info=>1" flag.

If your code is running under mod_rewrite (or compatible) and you
are calling "self_url()" or you are calling "url()" and passing
"path_info=>1", these methods will actually be returning "PATH_INFO"
now, as you have explicitly requested or "self_url()" has requested
on your behalf.

The "PATH_INFO" has been omitted in such URLs since the issue was
introduced in the 3.12 release in December, 2005.

This bug is so old your application may have come to depend on it or
workaround it. Check for application before upgrading to this
release.

Examples of affected method calls:

$q->url(-absolute => 1, -query => 1, -path_info => 1);
$q->url(-path=>1);
$q->url(-full=>1,-path=>1);
$q->url(-rewrite=>1,-path=>1);
$q->self_url();

We no longer read from STDIN when the Content-Length is not set,
preventing requests with no Content-Length from sometimes freezing.
This is consistent with the CGI RFC 3875, and is also consistent
with CGI::Simple. However, the old behavior may have been expected
by some command-line uses of CGI.pm.

In addition, the DELETE HTTP verb is now supported.

* Compress::Zlib has been upgraded from version 2.035 to 2.048.

IO::Compress::Zip and IO::Uncompress::Unzip now have support for
LZMA (method 14). There is a fix for a CRC issue in
IO::Compress::Unzip and it supports Streamed Stored context now. And
fixed a Zip64 issue in IO::Compress::Zip when the content size was
exactly 0xFFFFFFFF.

* Digest::SHA has been upgraded from version 5.61 to 5.71.

Added BITS mode to the addfile method and shasum. This makes
partial-byte inputs possible via files/STDIN and lets shasum check
all 8074 NIST Msg vectors, where previously special programming was
required to do this.

* Encode has been upgraded from version 2.42 to 2.44.

Missing aliases added, a deep recursion error fixed and various
documentation updates.

Addressed 'decode_xs n-byte heap-overflow' security bug in
Unicode.xs (CVE-2011-2939). (5.14.2)

* ExtUtils::CBuilder updated from version 0.280203 to 0.280206.

The new version appends CFLAGS and LDFLAGS to their Config.pm
counterparts.

* ExtUtils::ParseXS has been upgraded from version 2.2210 to 3.16.

Much of ExtUtils::ParseXS, the module behind the XS compiler
"xsubpp", was rewritten and cleaned up. It has been made somewhat
more extensible and now finally uses strictures.

The typemap logic has been moved into a separate module,
ExtUtils::Typemaps. See "New Modules and Pragmata", above.

For a complete set of changes, please see the ExtUtils::ParseXS
changelog, available on the CPAN.

* File::Glob has been upgraded from version 1.12 to 1.17.

On Windows, tilde (~) expansion now checks the "USERPROFILE"
environment variable, after checking "HOME".

It has a new ":bsd_glob" export tag, intended to replace ":glob".
Like ":glob" it overrides "glob" with a function that does not split
the glob pattern into words, but, unlike ":glob", it iterates
properly in scalar context, instead of returning the last file.

There are other changes affecting Perl's own "glob" operator (which
uses File::Glob internally, except on VMS). See "Performance
Enhancements" and "Selected Bug Fixes".

* FindBin updated from version 1.50 to 1.51.

It no longer returns a wrong result if a script of the same name as
the current one exists in the path and is executable.

* HTTP::Tiny has been upgraded from version 0.012 to 0.017.

Added support for using $ENV{http_proxy} to set the default proxy
host.

Adds additional shorthand methods for all common HTTP verbs, a
"post_form()" method for POST-ing x-www-form-urlencoded data and a
"www_form_urlencode()" utility method.

* IO has been upgraded from version 1.25_04 to 1.25_06, and IO::Handle
from version 1.31 to 1.33.

Together, these upgrades fix a problem with IO::Handle's "getline"
and "getlines" methods. When these methods are called on the special
ARGV handle, the next file is automatically opened, as happens with
the built-in "<>" and "readline" functions. But, unlike the
built-ins, these methods were not respecting the caller's use of the
open pragma and applying the appropriate I/O layers to the
newly-opened file [rt.cpan.org #66474].

* IPC::Cmd has been upgraded from version 0.70 to 0.76.

Capturing of command output (both "STDOUT" and "STDERR") is now
supported using IPC::Open3 on MSWin32 without requiring IPC::Run.

* IPC::Open3 has been upgraded from version 1.09 to 1.12.

Fixes a bug which prevented use of "open3" on Windows when *STDIN,
*STDOUT or *STDERR had been localized.

Fixes a bug which prevented duplicating numeric file descriptors on
Windows.

"open3" with "-" for the program name works once more. This was
broken in version 1.06 (and hence in Perl 5.14.0) [perl #95748].

* Locale::Codes has been upgraded from version 3.16 to 3.21.

Added Language Extension codes (langext) and Language Variation
codes (langvar) as defined in the IANA language registry.

Added language codes from ISO 639-5

Added language/script codes from the IANA language subtag registry

Fixed an uninitialized value warning [rt.cpan.org #67438].

Fixed the return value for the all_XXX_codes and all_XXX_names
functions [rt.cpan.org #69100].

Reorganized modules to move Locale::MODULE to Locale::Codes::MODULE
to allow for cleaner future additions. The original four modules
(Locale::Language, Locale::Currency, Locale::Country,
Locale::Script) will continue to work, but all new sets of codes
will be added in the Locale::Codes namespace.

The code2XXX, XXX2code, all_XXX_codes, and all_XXX_names functions
now support retired codes. All codesets may be specified by a
constant or by their name now. Previously, they were specified only
by a constant.

The alias_code function exists for backward compatibility. It has
been replaced by rename_country_code. The alias_code function will
be removed some time after September, 2013.

All work is now done in the central module (Locale::Codes).
Previously, some was still done in the wrapper modules
(Locale::Codes::*). Added Language Family codes (langfam) as defined
in ISO 639-5.

* Math::BigFloat has been upgraded from version 1.993 to 1.997.

The "numify" method has been corrected to return a normalized Perl
number (the result of "0 + $thing"), instead of a string
[rt.cpan.org #66732].

* Math::BigInt has been upgraded from version 1.994 to 1.998.

It provides a new "bsgn" method that complements the "babs" method.

It fixes the internal "objectify" function's handling of "foreign
objects" so they are converted to the appropriate class
(Math::BigInt or Math::BigFloat).

* Math::BigRat has been upgraded from version 0.2602 to 0.2603.

"int()" on a Math::BigRat object containing -1/2 now creates a
Math::BigInt containing 0, rather than -0. Math::BigInt does not
even support negative zero, so the resulting object was actually
malformed [perl #95530].

* Math::Complex has been upgraded from version 1.56 to 1.59 and
Math::Trig from version 1.2 to 1.22.

Fixes include: correct copy constructor usage; fix polarwise
formatting with numeric format specifier; and more stable
"great_circle_direction" algorithm.

* Module::CoreList has been upgraded from version 2.51 to 2.66.

The "corelist" utility now understands the "-r" option for
displaying Perl release dates and the "--diff" option to print the
set of modlib changes between two perl distributions.

* Module::Metadata has been upgraded from version 1.000004 to
1.000009.

Adds "provides" method to generate a CPAN META provides data
structure correctly; use of "package_versions_from_directory" is
discouraged.

* ODBM_File has been upgraded from version 1.10 to 1.12.

The XS code is now compiled with "PERL_NO_GET_CONTEXT", which will
aid performance under ithreads.

* open has been upgraded from version 1.08 to 1.10.

It no longer turns off layers on standard handles when invoked
without the ":std" directive. Similarly, when invoked *with* the
":std" directive, it now clears layers on STDERR before applying the
new ones, and not just on STDIN and STDOUT [perl #92728].

* overload has been upgraded from version 1.13 to 1.18.

"overload::Overloaded" no longer calls "can" on the class, but uses
another means to determine whether the object has overloading. It
was never correct for it to call "can", as overloading does not
respect AUTOLOAD. So classes that autoload methods and implement
"can" no longer have to account for overloading [perl #40333].

A warning is now produced for invalid arguments. See "New
Diagnostics".

* PerlIO::scalar has been upgraded from version 0.11 to 0.14.

(This is the module that implements "open $fh, '>', \$scalar".)

It fixes a problem with "open my $fh, ">", \$scalar" not working if
$scalar is a copy-on-write scalar. (5.14.2)

It also fixes a hang that occurs with "readline" or "<$fh>" if a
typeglob has been assigned to $scalar [perl #92258].

It no longer assumes during "seek" that $scalar is a string
internally. If it didn't crash, it was close to doing so [perl
#92706]. Also, the internal print routine no longer assumes that the
position set by "seek" is valid, but extends the string to that
position, filling the intervening bytes (between the old length and
the seek position) with nulls [perl #78980].

Printing to an in-memory handle now works if the $scalar holds a
reference, stringifying the reference before modifying it.
References used to be treated as empty strings.

Printing to an in-memory handle no longer crashes if the $scalar
happens to hold a number internally, but no string buffer.

Printing to an in-memory handle no longer creates scalars that
confuse the regular expression engine [perl #108398].

* Pod::Functions has been upgraded from version 1.04 to 1.05.

Functions.pm is now generated at perl build time from annotations in
perlfunc.pod. This will ensure that Pod::Functions and perlfunc
remain in synchronisation.

* Pod::Html has been upgraded from version 1.11 to 1.1502.

This is an extensive rewrite of Pod::Html to use Pod::Simple under
the hood. The output has changed significantly.

* Pod::Perldoc has been upgraded from version 3.15_03 to 3.17.

It corrects the search paths on VMS [perl #90640]. (5.14.1)

The -v option now fetches the right section for $0.

This upgrade has numerous significant fixes. Consult its changelog
on the CPAN for more information.

* POSIX has been upgraded from version 1.24 to 1.30.

POSIX no longer uses AutoLoader. Any code which was relying on this
implementation detail was buggy, and may fail because of this
change. The module's Perl code has been considerably simplified,
roughly halving the number of lines, with no change in
functionality. The XS code has been refactored to reduce the size of
the shared object by about 12%, with no change in functionality.
More POSIX functions now have tests.

"sigsuspend" and "pause" now run signal handlers before returning,
as the whole point of these two functions is to wait until a signal
has arrived, and then return *after* it has been triggered. Delayed,
or "safe", signals were preventing that from happening, possibly
resulting in race conditions [perl #107216].

"POSIX::sleep" is now a direct call into the underlying OS "sleep"
function, instead of being a Perl wrapper on "CORE::sleep".
"POSIX::dup2" now returns the correct value on Win32 (*i.e.*, the
file descriptor). "POSIX::SigSet" "sigsuspend" and "sigpending" and
"POSIX::pause" now dispatch safe signals immediately before
returning to their caller.

"POSIX::Termios::setattr" now defaults the third argument to
"TCSANOW", instead of 0. On most platforms "TCSANOW" is defined to
be 0, but on some 0 is not a valid parameter, which caused a call
with defaults to fail.

* Socket has been upgraded from version 1.94 to 2.001.

It has new functions and constants for handling IPv6 sockets:

pack_ipv6_mreq
unpack_ipv6_mreq
IPV6_ADD_MEMBERSHIP
IPV6_DROP_MEMBERSHIP
IPV6_MTU
IPV6_MTU_DISCOVER
IPV6_MULTICAST_HOPS
IPV6_MULTICAST_IF
IPV6_MULTICAST_LOOP
IPV6_UNICAST_HOPS
IPV6_V6ONLY

* Storable has been upgraded from version 2.27 to 2.34.

It no longer turns copy-on-write scalars into read-only scalars when
freezing and thawing.

* Sys::Syslog has been upgraded from version 0.27 to 0.29.

This upgrade closes many outstanding bugs.

* Term::ANSIColor has been upgraded from version 3.00 to 3.01.

Only interpret an initial array reference as a list of colors, not
any initial reference, allowing the colored function to work
properly on objects with stringification defined.

* Term::ReadLine has been upgraded from version 1.07 to 1.09.

Term::ReadLine now supports any event loop, including unpublished
ones and simple IO::Select, loops without the need to rewrite
existing code for any particular framework [perl #108470].

* threads::shared has been upgraded from version 1.37 to 1.40.

Destructors on shared objects used to be ignored sometimes if the
objects were referenced only by shared data structures. This has
been mostly fixed, but destructors may still be ignored if the
objects still exist at global destruction time [perl #98204].

* Unicode::Collate has been upgraded from version 0.73 to 0.89.

Updated to CLDR 1.9.1

Locales updated to CLDR 2.0: mk, mt, nb, nn, ro, ru, sk, sr, sv, uk,
zh__pinyin, zh__stroke

Newly supported locales: bn, fa, ml, mr, or, pa, sa, si,
si__dictionary, sr_Latn, sv__reformed, ta, te, th, ur, wae.

Tailored compatibility ideographs as well as unified ideographs for
the locales: ja, ko, zh__big5han, zh__gb2312han, zh__pinyin,
zh__stroke.

Locale/*.pl files are now searched for in @INC.

* Unicode::Normalize has been upgraded from version 1.10 to 1.14.

Fixes for the removal of unicore/CompositionExclusions.txt from
core.

* Unicode::UCD has been upgraded from version 0.32 to 0.43.

This adds four new functions: "prop_aliases()" and
"prop_value_aliases()", which are used to find all Unicode-approved
synonyms for property names, or to convert from one name to another;
"prop_invlist" which returns all code points matching a given
Unicode binary property; and "prop_invmap" which returns the
complete specification of a given Unicode property.

* Win32API::File has been upgraded from version 0.1101 to 0.1200.

Added SetStdHandle and GetStdHandle functions

Removed Modules and Pragmata
As promised in Perl 5.14.0's release notes, the following modules have
been removed from the core distribution, and if needed should be
installed from CPAN instead.

* Devel::DProf has been removed from the Perl core. Prior version was
20110228.00.

* Shell has been removed from the Perl core. Prior version was
0.72_01.

* Several old perl4-style libraries which have been deprecated with
5.14 are now removed:

abbrev.pl assert.pl bigfloat.pl bigint.pl bigrat.pl cacheout.pl
complete.pl ctime.pl dotsh.pl exceptions.pl fastcwd.pl flush.pl
getcwd.pl getopt.pl getopts.pl hostname.pl importenv.pl
lib/find{,depth}.pl look.pl newgetopt.pl open2.pl open3.pl
pwd.pl shellwords.pl stat.pl tainted.pl termcap.pl timelocal.pl

They can be found on CPAN as Perl4::CoreLibs.

Documentation
New Documentation
perldtrace
perldtrace describes Perl's DTrace support, listing the provided probes
and gives examples of their use.

perlexperiment
This document is intended to provide a list of experimental features in
Perl. It is still a work in progress.

perlootut
This a new OO tutorial. It focuses on basic OO concepts, and then
recommends that readers choose an OO framework from CPAN.

perlxstypemap
The new manual describes the XS typemapping mechanism in unprecedented
detail and combines new documentation with information extracted from
perlxs and the previously unofficial list of all core typemaps.

Changes to Existing Documentation
perlapi
* The HV API has long accepted negative lengths to show that the key
is in UTF8. This is now documented.

* The "boolSV()" macro is now documented.

perlfunc
* "dbmopen" treats a 0 mode as a special case, that prevents a
nonexistent file from being created. This has been the case since
Perl 5.000, but was never documented anywhere. Now the perlfunc
entry mentions it [perl #90064].

* As an accident of history, "open $fh, '<:', ..." applies the default
layers for the platform (":raw" on Unix, ":crlf" on Windows),
ignoring whatever is declared by open.pm. This seems such a useful
feature it has been documented in perlfunc and open.

* The entry for "split" has been rewritten. It is now far clearer than
before.

perlguts
* A new section, Autoloading with XSUBs, has been added, which
explains the two APIs for accessing the name of the autoloaded sub.

* Some function descriptions in perlguts were confusing, as it was not
clear whether they referred to the function above or below the
description. This has been clarified [perl #91790].

perlobj
* This document has been rewritten from scratch, and its coverage of
various OO concepts has been expanded.

perlop
* Documentation of the smartmatch operator has been reworked and moved
from perlsyn to perlop where it belongs.

It has also been corrected for the case of "undef" on the left-hand
side. The list of different smart match behaviors had an item in the
wrong place.

* Documentation of the ellipsis statement ("...") has been reworked
and moved from perlop to perlsyn.

* The explanation of bitwise operators has been expanded to explain
how they work on Unicode strings (5.14.1).

* More examples for "m//g" have been added (5.14.1).

* The "<<\FOO" here-doc syntax has been documented (5.14.1).

perlpragma
* There is now a standard convention for naming keys in the "%^H",
documented under Key naming.

"Laundering and Detecting Tainted Data" in perlsec
* The example function for checking for taintedness contained a subtle
error. $@ needs to be localized to prevent its changing this
global's value outside the function. The preferred method to check
for this remains "tainted" in Scalar::Util.

perllol
* perllol has been expanded with examples using the new "push $scalar"
syntax introduced in Perl 5.14.0 (5.14.1).

perlmod
* perlmod now states explicitly that some types of explicit symbol
table manipulation are not supported. This codifies what was
effectively already the case [perl #78074].

perlpodstyle
* The tips on which formatting codes to use have been corrected and
greatly expanded.

* There are now a couple of example one-liners for previewing POD
files after they have been edited.

perlre
* The "(*COMMIT)" directive is now listed in the right section (Verbs
without an argument).

perlrun
* perlrun has undergone a significant clean-up. Most notably, the
-0x... form of the -0 flag has been clarified, and the final section
on environment variables has been corrected and expanded (5.14.1).

perlsub
* The ($;) prototype syntax, which has existed for rather a long time,
is now documented in perlsub. It lets a unary function have the same
precedence as a list operator.

perltie
* The required syntax for tying handles has been documented.

perlvar
* The documentation for $! has been corrected and clarified. It used
to state that $! could be "undef", which is not the case. It was
also unclear whether system calls set C's "errno" or Perl's $! [perl
#91614].

* Documentation for $$ has been amended with additional cautions
regarding changing the process ID.

Other Changes
* perlxs was extended with documentation on inline typemaps.

* perlref has a new Circular References section explaining how
circularities may not be freed and how to solve that with weak
references.

* Parts of perlapi were clarified, and Perl equivalents of some C
functions have been added as an additional mode of exposition.

* A few parts of perlre and perlrecharclass were clarified.

Removed Documentation
Old OO Documentation
The old OO tutorials, perltoot, perltooc, and perlboot, have been
removed. The perlbot (bag of object tricks) document has been removed as
well.

Development Deltas
The perldelta files for development releases are no longer packaged with
perl. These can still be found in the perl source code repository.

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.

New Diagnostics
New Errors
* Cannot set tied @DB::args

This error occurs when "caller" tries to set @DB::args but finds it
tied. Before this error was added, it used to crash instead.

* Cannot tie unreifiable array

This error is part of a safety check that the "tie" operator does
before tying a special array like @_. You should never see this
message.

* &CORE::%s cannot be called directly

This occurs when a subroutine in the "CORE::" namespace is called
with &foo syntax or through a reference. Some subroutines in this
package cannot yet be called that way, but must be called as
barewords. See "Subroutines in the "CORE" namespace", above.

* Source filters apply only to byte streams

This new error occurs when you try to activate a source filter
(usually by loading a source filter module) within a string passed
to "eval" under the "unicode_eval" feature.

New Warnings
* defined(@array) is deprecated

The long-deprecated "defined(@array)" now also warns for package
variables. Previously it issued a warning for lexical variables
only.

* length() used on %s

This new warning occurs when "length" is used on an array or hash,
instead of "scalar(@array)" or "scalar(keys %hash)".

* lvalue attribute %s already-defined subroutine

attributes.pm now emits this warning when the :lvalue attribute is
applied to a Perl subroutine that has already been defined, as doing
so can have unexpected side-effects.

* overload arg '%s' is invalid

This warning, in the "overload" category, is produced when the
overload pragma is given an argument it doesn't recognize,
presumably a mistyped operator.

* $[ used in %s (did you mean $] ?)

This new warning exists to catch the mistaken use of $[ in version
checks. $], not $[, contains the version number.

* Useless assignment to a temporary

Assigning to a temporary scalar returned from an lvalue subroutine
now produces this warning [perl #31946].

* Useless use of \E

"\E" does nothing unless preceded by "\Q", "\L" or "\U".

Removed Errors
* "sort is now a reserved word"

This error used to occur when "sort" was called without arguments,
followed by ";" or ")". (E.g., "sort;" would die, but "{sort}" was
OK.) This error message was added in Perl 3 to catch code like
"close(sort)" which would no longer work. More than two decades
later, this message is no longer appropriate. Now "sort" without
arguments is always allowed, and returns an empty list, as it did in
those cases where it was already allowed [perl #90030].

Changes to Existing Diagnostics
* The "Applying pattern match..." or similar warning produced when an
array or hash is on the left-hand side of the "=~" operator now
mentions the name of the variable.

* The "Attempt to free non-existent shared string" has had the
spelling of "non-existent" corrected to "nonexistent". It was
already listed with the correct spelling in perldiag.

* The error messages for using "default" and "when" outside a
topicalizer have been standardized to match the messages for
"continue" and loop controls. They now read 'Can't "default" outside
a topicalizer' and 'Can't "when" outside a topicalizer'. They both
used to be 'Can't use when() outside a topicalizer' [perl #91514].

* The message, "Code point 0x%X is not Unicode, no properties match
it; all inverse properties do" has been changed to "Code point 0x%X
is not Unicode, all \p{} matches fail; all \P{} matches succeed".

* Redefinition warnings for constant subroutines used to be mandatory,
even occurring under "no warnings". Now they respect the warnings
pragma.

* The "glob failed" warning message is now suppressible via "no
warnings" [perl #111656].

* The Invalid version format error message now says "negative version
number" within the parentheses, rather than "non-numeric data", for
negative numbers.

* The two warnings Possible attempt to put comments in qw() list and
Possible attempt to separate words with commas are no longer
mutually exclusive: the same "qw" construct may produce both.

* The uninitialized warning for "y///r" when $_ is implicit and
undefined now mentions the variable name, just like the non-/r
variation of the operator.

* The 'Use of "foo" without parentheses is ambiguous' warning has been
extended to apply also to user-defined subroutines with a (;$)
prototype, and not just to built-in functions.

* Warnings that ment

投稿者 xml-rpc : 2012年5月22日 13:29
役に立ちました?:
過去のフィードバック 平均:(0) 総合:(0) 投票回数:(0)
本記事へのTrackback: http://hoop.euqset.org/blog/mt-tb2006.cgi/110549
トラックバック
コメント
コメントする




画像の中に見える文字を入力してください。