⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 perl5100delta.1

📁 视频监控网络部分的协议ddns,的模块的实现代码,请大家大胆指正.
💻 1
📖 第 1 页 / 共 5 页
字号:
octal..PPThe \fB\-C\fR option can no longer be used on the \f(CW\*(C`#!\*(C'\fR line. It wasn'tworking there anyway, since the standard streams are already set upat this point in the execution of the perl interpreter. You can use\&\fIbinmode()\fR instead to get the desired behaviour..Sh "\s-1UCD\s0 5.0.0".IX Subsection "UCD 5.0.0"The copy of the Unicode Character Database included in Perl 5 hasbeen updated to version 5.0.0..Sh "\s-1MAD\s0".IX Subsection "MAD"\&\s-1MAD\s0, which stands for \fIMiscellaneous Attribute Decoration\fR, is astill-in-development work leading to a Perl 5 to Perl 6 converter. Toenable it, it's necessary to pass the argument \f(CW\*(C`\-Dmad\*(C'\fR to Configure. Theobtained perl isn't binary compatible with a regular perl 5.10, and hasspace and speed penalties; moreover not all regression tests still passwith it. (Larry Wall, Nicholas Clark).Sh "\fIkill()\fP on Windows".IX Subsection "kill() on Windows"On Windows platforms, \f(CW\*(C`kill(\-9, $pid)\*(C'\fR now kills a process tree.(On \s-1UNIX\s0, this delivers the signal to all processes in the same processgroup.).SH "Incompatible Changes".IX Header "Incompatible Changes".Sh "Packing and \s-1UTF\-8\s0 strings".IX Subsection "Packing and UTF-8 strings"The semantics of \fIpack()\fR and \fIunpack()\fR regarding UTF\-8\-encoded data has beenchanged. Processing is now by default character per character instead ofbyte per byte on the underlying encoding. Notably, code that used thingslike \f(CW\*(C`pack("a*", $string)\*(C'\fR to see through the encoding of string will nowsimply get back the original \f(CW$string\fR. Packed strings can also get upgradedduring processing when you store upgraded characters. You can get the oldbehaviour by using \f(CW\*(C`use bytes\*(C'\fR..PPTo be consistent with \fIpack()\fR, the \f(CW\*(C`C0\*(C'\fR in \fIunpack()\fR templates indicatesthat the data is to be processed in character mode, i.e. character bycharacter; on the contrary, \f(CW\*(C`U0\*(C'\fR in \fIunpack()\fR indicates \s-1UTF\-8\s0 mode, wherethe packed string is processed in its UTF\-8\-encoded Unicode form on a byteby byte basis. This is reversed with regard to perl 5.8.X, but now consistentbetween \fIpack()\fR and \fIunpack()\fR..PPMoreover, \f(CW\*(C`C0\*(C'\fR and \f(CW\*(C`U0\*(C'\fR can also be used in \fIpack()\fR templates to specifyrespectively character and byte modes..PP\&\f(CW\*(C`C0\*(C'\fR and \f(CW\*(C`U0\*(C'\fR in the middle of a pack or unpack format now switch to thespecified encoding mode, honoring parens grouping. Previously, parens wereignored..PPAlso, there is a new \fIpack()\fR character format, \f(CW\*(C`W\*(C'\fR, which is intended toreplace the old \f(CW\*(C`C\*(C'\fR. \f(CW\*(C`C\*(C'\fR is kept for unsigned chars coded as bytes inthe strings internal representation. \f(CW\*(C`W\*(C'\fR represents unsigned (logical)character values, which can be greater than 255. It is therefore morerobust when dealing with potentially UTF\-8\-encoded data (as \f(CW\*(C`C\*(C'\fR will wrapvalues outside the range 0..255, and not respect the string encoding)..PPIn practice, that means that pack formats are now encoding-neutral, except\&\f(CW\*(C`C\*(C'\fR..PPFor consistency, \f(CW\*(C`A\*(C'\fR in \fIunpack()\fR format now trims all Unicode whitespacefrom the end of the string. Before perl 5.9.2, it used to strip only theclassical \s-1ASCII\s0 space characters..Sh "Byte/character count feature in \fIunpack()\fP".IX Subsection "Byte/character count feature in unpack()"A new \fIunpack()\fR template character, \f(CW"."\fR, returns the number of bytes orcharacters (depending on the selected encoding mode, see above) read so far..ie n .Sh "The $*\fP and \f(CW$# variables have been removed".el .Sh "The \f(CW$*\fP and \f(CW$#\fP variables have been removed".IX Subsection "The $* and $# variables have been removed"\&\f(CW$*\fR, which was deprecated in favor of the \f(CW\*(C`/s\*(C'\fR and \f(CW\*(C`/m\*(C'\fR regexpmodifiers, has been removed..PPThe deprecated \f(CW$#\fR variable (output format for numbers) has beenremoved..PPTwo new severe warnings, \f(CW\*(C`$#/$* is no longer supported\*(C'\fR, have been added..Sh "\fIsubstr()\fP lvalues are no longer fixed-length".IX Subsection "substr() lvalues are no longer fixed-length"The lvalues returned by the three argument form of \fIsubstr()\fR used to be a\&\*(L"fixed length window\*(R" on the original string. In some cases this couldcause surprising action at distance or other undefined behaviour. Now thelength of the window adjusts itself to the length of the string assigned toit..ie n .Sh "Parsing of ""\-f _""".el .Sh "Parsing of \f(CW\-f _\fP".IX Subsection "Parsing of -f _"The identifier \f(CW\*(C`_\*(C'\fR is now forced to be a bareword after a filetestoperator. This solves a number of misparsing issues when a global \f(CW\*(C`_\*(C'\fRsubroutine is defined..ie n .Sh """:unique""".el .Sh "\f(CW:unique\fP".IX Subsection ":unique"The \f(CW\*(C`:unique\*(C'\fR attribute has been made a no-op, since its currentimplementation was fundamentally flawed and not threadsafe..Sh "Effect of pragmas in eval".IX Subsection "Effect of pragmas in eval"The compile-time value of the \f(CW\*(C`%^H\*(C'\fR hint variable can now propagate intoeval("")uated code. This makes it more useful to implement lexicalpragmas..PPAs a side-effect of this, the overloaded-ness of constants now propagatesinto eval("")..Sh "chdir \s-1FOO\s0".IX Subsection "chdir FOO"A bareword argument to \fIchdir()\fR is now recognized as a file handle.Earlier releases interpreted the bareword as a directory name.(Gisle Aas).Sh "Handling of .pmc files".IX Subsection "Handling of .pmc files"An old feature of perl was that before \f(CW\*(C`require\*(C'\fR or \f(CW\*(C`use\*(C'\fR look for afile with a \fI.pm\fR extension, they will first look for a similar filenamewith a \fI.pmc\fR extension. If this file is found, it will be loaded inplace of any potentially existing file ending in a \fI.pm\fR extension..PPPreviously, \fI.pmc\fR files were loaded only if more recent than thematching \fI.pm\fR file. Starting with 5.9.4, they'll be always loaded ifthey exist..ie n .Sh "$^V is now a ""version"" object instead of a v\-string".el .Sh "$^V is now a \f(CWversion\fP object instead of a v\-string".IX Subsection "$^V is now a version object instead of a v-string"$^V can still be used with the \f(CW%vd\fR format in printf, but anycharacter-level operations will now access the string representationof the \f(CW\*(C`version\*(C'\fR object and not the ordinals of a v\-string.Expressions like \f(CW\*(C`substr($^V, 0, 2)\*(C'\fR or \f(CW\*(C`split //, $^V\*(C'\fRno longer work and must be rewritten..Sh "@\- and @+ in patterns".IX Subsection "@- and @+ in patterns"The special arrays \f(CW\*(C`@\-\*(C'\fR and \f(CW\*(C`@+\*(C'\fR are no longer interpolated in regularexpressions. (Sadahiro Tomoyuki).ie n .Sh "$AUTOLOAD can now be tainted".el .Sh "\f(CW$AUTOLOAD\fP can now be tainted".IX Subsection "$AUTOLOAD can now be tainted"If you call a subroutine by a tainted name, and if it defers to an\&\s-1AUTOLOAD\s0 function, then \f(CW$AUTOLOAD\fR will be (correctly) tainted.(Rick Delaney).Sh "Tainting and printf".IX Subsection "Tainting and printf"When perl is run under taint mode, \f(CW\*(C`printf()\*(C'\fR and \f(CW\*(C`sprintf()\*(C'\fR will nowreject any tainted format argument. (Rafael Garcia-Suarez).Sh "undef and signal handlers".IX Subsection "undef and signal handlers"Undefining or deleting a signal handler via \f(CW\*(C`undef $SIG{FOO}\*(C'\fR is nowequivalent to setting it to \f(CW\*(AqDEFAULT\*(Aq\fR. (Rafael Garcia-Suarez).Sh "strictures and dereferencing in \fIdefined()\fP".IX Subsection "strictures and dereferencing in defined()"\&\f(CW\*(C`use strict \*(Aqrefs\*(Aq\*(C'\fR was ignoring taking a hard reference in an argumentto \fIdefined()\fR, as in :.PP.Vb 3\&    use strict \*(Aqrefs\*(Aq;\&    my $x = \*(Aqfoo\*(Aq;\&    if (defined $$x) {...}.Ve.PPThis now correctly produces the run-time error \f(CW\*(C`Can\*(Aqt use string as aSCALAR ref while "strict refs" in use\*(C'\fR..PP\&\f(CW\*(C`defined @$foo\*(C'\fR and \f(CW\*(C`defined %$bar\*(C'\fR are now also subject to \f(CW\*(C`strict\&\*(Aqrefs\*(Aq\*(C'\fR (that is, \f(CW$foo\fR and \f(CW$bar\fR shall be proper references there.)(\f(CW\*(C`defined(@foo)\*(C'\fR and \f(CW\*(C`defined(%bar)\*(C'\fR are discouraged constructs anyway.)(Nicholas Clark).ie n .Sh """(?p{})"" has been removed".el .Sh "\f(CW(?p{})\fP has been removed".IX Subsection "(?p{}) has been removed"The regular expression construct \f(CW\*(C`(?p{})\*(C'\fR, which was deprecated in perl5.8, has been removed. Use \f(CW\*(C`(??{})\*(C'\fR instead. (Rafael Garcia-Suarez).Sh "Pseudo-hashes have been removed".IX Subsection "Pseudo-hashes have been removed"Support for pseudo-hashes has been removed from Perl 5.9. (The \f(CW\*(C`fields\*(C'\fRpragma remains here, but uses an alternate implementation.).Sh "Removal of the bytecode compiler and of perlcc".IX Subsection "Removal of the bytecode compiler and of perlcc"\&\f(CW\*(C`perlcc\*(C'\fR, the byteloader and the supporting modules (B::C, B::CC,B::Bytecode, etc.) are no longer distributed with the perl sources. Thoseexperimental tools have never worked reliably, and, due to the lack ofvolunteers to keep them in line with the perl interpreter developments, itwas decided to remove them instead of shipping a broken version of those.The last version of those modules can be found with perl 5.9.4..PPHowever the B compiler framework stays supported in the perl core, as withthe more useful modules it has permitted (among others, B::Deparse andB::Concise)..Sh "Removal of the \s-1JPL\s0".IX Subsection "Removal of the JPL"The \s-1JPL\s0 (Java-Perl Lingo) has been removed from the perl sources tarball..Sh "Recursive inheritance detected earlier".IX Subsection "Recursive inheritance detected earlier"Perl will now immediately throw an exception if you modify any package's\&\f(CW@ISA\fR in such a way that it would cause recursive inheritance..PPPreviously, the exception would not occur until Perl attempted to makeuse of the recursive inheritance while resolving a method or doing a\&\f(CW\*(C`$foo\->isa($bar)\*(C'\fR lookup..SH "Modules and Pragmata".IX Header "Modules and Pragmata".Sh "Upgrading individual core modules".IX Subsection "Upgrading individual core modules"Even more core modules are now also available separately through the\&\s-1CPAN\s0.  If you wish to update one of these modules, you don't need towait for a new perl release.  From within the cpan shell, running the\&'r' command will report on modules with upgrades available.  See\&\f(CW\*(C`perldoc CPAN\*(C'\fR for more information..Sh "Pragmata Changes".IX Subsection "Pragmata Changes".ie n .IP """feature""" 4.el .IP "\f(CWfeature\fR" 4.IX Item "feature"The new pragma \f(CW\*(C`feature\*(C'\fR is used to enable new features that might breakold code. See "The \f(CW\*(C`feature\*(C'\fR pragma" above..ie n .IP """mro""" 4.el .IP "\f(CWmro\fR" 4.IX Item "mro"This new pragma enables to change the algorithm used to resolve inheritedmethods. See "New Pragma, \f(CW\*(C`mro\*(C'\fR" above..ie n .IP "Scoping of the ""sort"" pragma" 4.el .IP "Scoping of the \f(CWsort\fR pragma" 4.IX Item "Scoping of the sort pragma"The \f(CW\*(C`sort\*(C'\fR pragma is now lexically scoped. Its effect used to be global..ie n .IP "Scoping of ""bignum""\fR, \f(CW""bigint""\fR, \f(CW""bigrat""" 4.el .IP "Scoping of \f(CWbignum\fR, \f(CWbigint\fR, \f(CWbigrat\fR" 4.IX Item "Scoping of bignum, bigint, bigrat"The three numeric pragmas \f(CW\*(C`bignum\*(C'\fR, \f(CW\*(C`bigint\*(C'\fR and \f(CW\*(C`bigrat\*(C'\fR are nowlexically scoped. (Tels).ie n .IP """base""" 4.el .IP "\f(CWbase\fR" 4.IX Item "base"The \f(CW\*(C`base\*(C'\fR pragma now warns if a class tries to inherit from itself.(Curtis \*(L"Ovid\*(R" Poe).ie n .IP """strict""\fR and \f(CW""warnings""" 4.el .IP "\f(CWstrict\fR and \f(CWwarnings\fR" 4.IX Item "strict and warnings"\&\f(CW\*(C`strict\*(C'\fR and \f(CW\*(C`warnings\*(C'\fR will now complain loudly if they are loaded viaincorrect casing (as in \f(CW\*(C`use Strict;\*(C'\fR). (Johan Vromans).ie n .IP """version""" 4.el .IP "\f(CWversion\fR" 4.IX Item "version"The \f(CW\*(C`version\*(C'\fR module provides support for version objects..ie n .IP """warnings""" 4.el .IP "\f(CWwarnings\fR" 4.IX Item "warnings"The \f(CW\*(C`warnings\*(C'\fR pragma doesn't load \f(CW\*(C`Carp\*(C'\fR anymore. That means that codethat used \f(CW\*(C`Carp\*(C'\fR routines without having loaded it at compile time mightneed to be adjusted; typically, the following (faulty) code won't workanymore, and will require parentheses to be added after the function name:.Sp.Vb 3\&    use warnings;\&    require Carp;\&    Carp::confess \*(Aqargh\*(Aq;.Ve.ie n .IP """less""" 4.el .IP "\f(CWless\fR" 4.IX Item "less"\&\f(CW\*(C`less\*(C'\fR now does something useful (or at least it tries to). In fact, ithas been turned into a lexical pragma. So, in your modules, you can nowtest whether your users have requested to use less \s-1CPU\s0, or less memory,less magic, or maybe even less fat. See less for more. (Joshua benJore).Sh "New modules".IX Subsection "New modules".IP "\(bu" 4\&\f(CW\*(C`encoding::warnings\*(C'\fR, by Audrey Tang, is a module to emit warningswhenever an \s-1ASCII\s0 character string containing high-bit bytes is implicitlyconverted into \s-1UTF\-8\s0. It's a lexical pragma since Perl 5.9.4; on olderperls, its effect is global..IP "\(bu" 4\&\f(CW\*(C`Module::CoreList\*(C'\fR, by Richard Clamp, is a small handy module that tellsyou what versions of core modules ship with any versions of Perl 5. Itcomes with a command-line frontend, \f(CW\*(C`corelist\*(C'\fR..IP "\(bu" 4\&\f(CW\*(C`Math::BigInt::FastCalc\*(C'\fR is an XS-enabled, and thus faster, version of\&\f(CW\*(C`Math::BigInt::Calc\*(C'\fR..IP "\(bu" 4\&\f(CW\*(C`Compress::Zlib\*(C'\fR is an interface to the zlib compression library. Itcomes with a bundled version of zlib, so having a working zlib is not a

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -