{
    "mode": "man",
    "parameter": "perl581delta",
    "section": "1",
    "url": "https://www.chedong.com/phpMan.php/man/perl581delta/1/json",
    "generated": "2026-10-06T10:51:56Z",
    "sections": {
        "NAME": {
            "content": "perl581delta - what is new for perl v5.8.1\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "This document describes differences between the 5.8.0 release and the 5.8.1 release.\n\nIf you are upgrading from an earlier release such as 5.6.1, first read the perl58delta, which\ndescribes differences between 5.6.0 and 5.8.0.\n\nIn case you are wondering about 5.6.1, it was bug-fix-wise rather identical to the\ndevelopment release 5.7.1.  Confused?  This timeline hopefully helps a bit: it lists the new\nmajor releases, their maintenance releases, and the development releases.\n\nNew     Maintenance  Development\n\n5.6.0                             2000-Mar-22\n5.7.0        2000-Sep-02\n5.6.1                     2001-Apr-08\n5.7.1        2001-Apr-09\n5.7.2        2001-Jul-13\n5.7.3        2002-Mar-05\n5.8.0                             2002-Jul-18\n5.8.1                     2003-Sep-25\n",
            "subsections": []
        },
        "Incompatible Changes": {
            "content": "",
            "subsections": [
                {
                    "name": "Hash Randomisation",
                    "content": "Mainly due to security reasons, the \"random ordering\" of hashes has been made even more\nrandom.  Previously while the order of hash elements from keys(), values(), and each() was\nessentially random, it was still repeatable.  Now, however, the order varies between\ndifferent runs of Perl.\n\nPerl has never guaranteed any ordering of the hash keys, and the ordering has already changed\nseveral times during the lifetime of Perl 5.  Also, the ordering of hash keys has always\nbeen, and continues to be, affected by the insertion order.\n\nThe added randomness may affect applications.\n\nOne possible scenario is when output of an application has included hash data.  For example,\nif you have used the Data::Dumper module to dump data into different files, and then compared\nthe files to see whether the data has changed, now you will have false positives since the\norder in which hashes are dumped will vary.  In general the cure is to sort the keys (or the\nvalues); in particular for Data::Dumper to use the \"Sortkeys\" option.  If some particular\norder is really important, use tied hashes: for example the Tie::IxHash module which by\ndefault preserves the order in which the hash elements were added.\n\nMore subtle problem is reliance on the order of \"global destruction\".  That is what happens\nat the end of execution: Perl destroys all data structures, including user data.  If your\ndestructors (the DESTROY subroutines) have assumed any particular ordering to the global\ndestruction, there might be problems ahead.  For example, in a destructor of one object you\ncannot assume that objects of any other class are still available, unless you hold a\nreference to them.  If the environment variable PERLDESTRUCTLEVEL is set to a non-zero\nvalue, or if Perl is exiting a spawned thread, it will also destruct the ordinary references\nand the symbol tables that are no longer in use.  You can't call a class method or an\nordinary function on a class that has been collected that way.\n\nThe hash randomisation is certain to reveal hidden assumptions about some particular ordering\nof hash elements, and outright bugs: it revealed a few bugs in the Perl core and core\nmodules.\n\nTo disable the hash randomisation in runtime, set the environment variable PERLHASHSEED to\n0 (zero) before running Perl (for more information see \"PERLHASHSEED\" in perlrun), or to\ndisable the feature completely in compile time, compile with \"-DNOHASHSEED\" (see INSTALL).\n\nSee \"Algorithmic Complexity Attacks\" in perlsec for the original rationale behind this\nchange.\n"
                },
                {
                    "name": "UTF-8 On Filehandles No Longer Activated By Locale",
                    "content": "In Perl 5.8.0 all filehandles, including the standard filehandles, were implicitly set to be\nin Unicode UTF-8 if the locale settings indicated the use of UTF-8.  This feature caused too\nmany problems, so the feature was turned off and redesigned: see \"Core Enhancements\".\n"
                },
                {
                    "name": "Single-number v-strings are no longer v-strings before \"=>\"",
                    "content": "The version strings or v-strings (see \"Version Strings\" in perldata) feature introduced in\nPerl 5.6.0 has been a source of some confusion-- especially when the user did not want to use\nit, but Perl thought it knew better.  Especially troublesome has been the feature that before\na \"=>\" a version string (a \"v\" followed by digits) has been interpreted as a v-string instead\nof a string literal.  In other words:\n\n%h = ( v65 => 42 );\n\nhas meant since Perl 5.6.0\n\n%h = ( 'A' => 42 );\n\n(at least in platforms of ASCII progeny)  Perl 5.8.1 restores the more natural interpretation\n\n%h = ( 'v65' => 42 );\n\nThe multi-number v-strings like v65.66 and 65.66.67 still continue to be v-strings in Perl\n5.8.\n"
                },
                {
                    "name": "(Win32) The -C Switch Has Been Repurposed",
                    "content": "The -C switch has changed in an incompatible way.  The old semantics of this switch only made\nsense in Win32 and only in the \"use utf8\" universe in 5.6.x releases, and do not make sense\nfor the Unicode implementation in 5.8.0.  Since this switch could not have been used by\nanyone, it has been repurposed.  The behavior that this switch enabled in 5.6.x releases may\nbe supported in a transparent, data-dependent fashion in a future release.\n\nFor the new life of this switch, see \"UTF-8 no longer default under UTF-8 locales\", and \"-C\"\nin perlrun.\n"
                },
                {
                    "name": "(Win32) The /d Switch Of cmd.exe",
                    "content": "Perl 5.8.1 uses the /d switch when running the cmd.exe shell internally for system(),\nbackticks, and when opening pipes to external programs.  The extra switch disables the\nexecution of AutoRun commands from the registry, which is generally considered undesirable\nwhen running external programs.  If you wish to retain compatibility with the older behavior,\nset PERL5SHELL in your environment to \"cmd /x/c\".\n"
                }
            ]
        },
        "Core Enhancements": {
            "content": "",
            "subsections": [
                {
                    "name": "UTF-8 no longer default under UTF-8 locales",
                    "content": "In Perl 5.8.0 many Unicode features were introduced.   One of them was found to be of more\nnuisance than benefit: the automagic (and silent) \"UTF-8-ification\" of filehandles, including\nthe standard filehandles, if the user's locale settings indicated use of UTF-8.\n\nFor example, if you had \"enUS.UTF-8\" as your locale, your STDIN and STDOUT were\nautomatically \"UTF-8\", in other words an implicit binmode(..., \":utf8\") was made.  This meant\nthat trying to print, say, chr(0xff), ended up printing the bytes 0xc3 0xbf.  Hardly what you\nhad in mind unless you were aware of this feature of Perl 5.8.0.  The problem is that the\nvast majority of people weren't: for example in RedHat releases 8 and 9 the default locale\nsetting is UTF-8, so all RedHat users got UTF-8 filehandles, whether they wanted it or not.\nThe pain was intensified by the Unicode implementation of Perl 5.8.0 (still) having nasty\nbugs, especially related to the use of s/// and tr///.  (Bugs that have been fixed in 5.8.1)\n\nTherefore a decision was made to backtrack the feature and change it from implicit silent\ndefault to explicit conscious option.  The new Perl command line option \"-C\" and its\ncounterpart environment variable PERLUNICODE can now be used to control how Perl and Unicode\ninteract at interfaces like I/O and for example the command line arguments.  See \"-C\" in\nperlrun and \"PERLUNICODE\" in perlrun for more information.\n"
                },
                {
                    "name": "Unsafe signals again available",
                    "content": "In Perl 5.8.0 the so-called \"safe signals\" were introduced.  This means that Perl no longer\nhandles signals immediately but instead \"between opcodes\", when it is safe to do so.  The\nearlier immediate handling easily could corrupt the internal state of Perl, resulting in\nmysterious crashes.\n\nHowever, the new safer model has its problems too.  Because now an opcode, a basic unit of\nPerl execution, is never interrupted but instead let to run to completion, certain operations\nthat can take a long time now really do take a long time.  For example, certain network\noperations have their own blocking and timeout mechanisms, and being able to interrupt them\nimmediately would be nice.\n\nTherefore perl 5.8.1 introduces a \"backdoor\" to restore the pre-5.8.0 (pre-5.7.3, really)\nsignal behaviour.  Just set the environment variable PERLSIGNALS to \"unsafe\", and the old\nimmediate (and unsafe) signal handling behaviour returns.  See \"PERLSIGNALS\" in perlrun and\n\"Deferred Signals (Safe Signals)\" in perlipc.\n\nIn completely unrelated news, you can now use safe signals with POSIX::SigAction.  See\n\"POSIX::SigAction\" in POSIX.\n"
                },
                {
                    "name": "Tied Arrays with Negative Array Indices",
                    "content": "Formerly, the indices passed to \"FETCH\", \"STORE\", \"EXISTS\", and \"DELETE\" methods in tied\narray class were always non-negative.  If the actual argument was negative, Perl would call\nFETCHSIZE implicitly and add the result to the index before passing the result to the tied\narray method.  This behaviour is now optional.  If the tied array class contains a package\nvariable named $NEGATIVEINDICES which is set to a true value, negative values will be passed\nto \"FETCH\", \"STORE\", \"EXISTS\", and \"DELETE\" unchanged.\n"
                },
                {
                    "name": "local ${$x}",
                    "content": "The syntaxes\n\nlocal ${$x}\nlocal @{$x}\nlocal %{$x}\n\nnow do localise variables, given that the $x is a valid variable name.\n"
                },
                {
                    "name": "Unicode Character Database 4.0.0",
                    "content": "The copy of the Unicode Character Database included in Perl 5.8 has been updated to 4.0.0\nfrom 3.2.0.  This means for example that the Unicode character properties are as in Unicode\n4.0.0.\n"
                },
                {
                    "name": "Deprecation Warnings",
                    "content": "There is one new feature deprecation.  Perl 5.8.0 forgot to add some deprecation warnings,\nthese warnings have now been added.  Finally, a reminder of an impending feature removal.\n\n(Reminder) Pseudo-hashes are deprecated (really)\n\nPseudo-hashes were deprecated in Perl 5.8.0 and will be removed in Perl 5.10.0, see\nperl58delta for details.  Each attempt to access pseudo-hashes will trigger the warning\n\"Pseudo-hashes are deprecated\".  If you really want to continue using pseudo-hashes but not\nto see the deprecation warnings, use:\n\nno warnings 'deprecated';\n\nOr you can continue to use the fields pragma, but please don't expect the data structures to\nbe pseudohashes any more.\n\n(Reminder) 5.005-style threads are deprecated (really)\n\n5.005-style threads (activated by \"use Thread;\") were deprecated in Perl 5.8.0 and will be\nremoved after Perl 5.8, see perl58delta for details.  Each 5.005-style thread creation will\ntrigger the warning \"5.005 threads are deprecated\".  If you really want to continue using the\n5.005 threads but not to see the deprecation warnings, use:\n\nno warnings 'deprecated';\n\n(Reminder) The $* variable is deprecated (really)\n\nThe $* variable controlling multi-line matching has been deprecated and will be removed after\n5.8.  The variable has been deprecated for a long time, and a deprecation warning \"Use of $*\nis deprecated\" is given, now the variable will just finally be removed.  The functionality\nhas been supplanted by the \"/s\" and \"/m\" modifiers on pattern matching.  If you really want\nto continue using the $*-variable but not to see the deprecation warnings, use:\n\nno warnings 'deprecated';\n"
                },
                {
                    "name": "Miscellaneous Enhancements",
                    "content": "\"map\" in void context is no longer expensive. \"map\" is now context aware, and will not\nconstruct a list if called in void context.\n\nIf a socket gets closed by the server while printing to it, the client now gets a SIGPIPE.\nWhile this new feature was not planned, it fell naturally out of PerlIO changes, and is to be\nconsidered an accidental feature.\n\nPerlIO::getlayers(FH) returns the names of the PerlIO layers active on a filehandle.\n\nPerlIO::via layers can now have an optional UTF8 method to indicate whether the layer wants\nto \"auto-:utf8\" the stream.\n\nutf8::isutf8() has been added as a quick way to test whether a scalar is encoded internally\nin UTF-8 (Unicode).\n"
                }
            ]
        },
        "Modules and Pragmata": {
            "content": "",
            "subsections": [
                {
                    "name": "Updated Modules And Pragmata",
                    "content": "The following modules and pragmata have been updated since Perl 5.8.0:\n\nbase\nB::Bytecode\nIn much better shape than it used to be.  Still far from perfect, but maybe worth a try.\n\nB::Concise\nB::Deparse\nBenchmark\nAn  optional  feature, \":hireswallclock\", now allows for high resolution wall clock times\n(uses Time::HiRes).\n\nByteLoader\nSee B::Bytecode.\n\nbytes\nNow has bytes::substr.\n\nCGI\ncharnames\nOne can now have custom character name aliases.\n\nCPAN\nThere is now a simple command line frontend to the CPAN.pm module called cpan.\n\nData::Dumper\nA new option, Pair, allows choosing the separator between hash keys and values.\n\nDBFile\nDevel::PPPort\nDigest::MD5\nEncode\nSignificant updates on the encoding pragma functionality (tr/// and the DATA  filehandle,\nformats).\n\nIf  a  filehandle  has  been  marked  as  to  have an encoding, unmappable characters are\ndetected already during input, not later (when the corrupted data is being used).\n\nThe ISO 8859-6 conversion table has been corrected (the 0x30..0x39 erroneously mapped  to\nU+0660..U+0669,  instead  of  U+0030..U+0039).   The  GSM 03.38 conversion did not handle\nescape sequences correctly.  The UTF-7 encoding has been added  (making  Encode  feature-\ncomplete with Unicode::String).\n\nfields\nlibnet\nMath::BigInt\nA  lot  of  bugs  have  been  fixed  since  v1.60,  the  version included in Perl v5.8.0.\nEspecially noteworthy are the bug in Calc that caused div and mod to fail for some  large\nvalues, and the fixes to the handling of bad inputs.\n\nSome  new  features  were  added, e.g. the broot() method, you can now pass parameters to\nconfig() to change some settings at runtime, and it is now possible to trap the  creation\nof NaN and infinity.\n\nAs  usual,  some optimizations took place and made the math overall a tad faster. In some\ncases,  quite  a  lot   faster,   actually.   Especially   alternative   libraries   like\nMath::BigInt::GMP benefit from this. In addition, a lot of the quite clunky routines like\nfsqrt() and flog() are now much much faster.\n\nMIME::Base64\nNEXT\nDiamond inheritance now works.\n\nNet::Ping\nPerlIO::scalar\nReading from non-string scalars (like the special variables, see perlvar) now works.\n\npodlators\nPod::LaTeX\nPodParsers\nPod::Perldoc\nComplete rewrite.  As a side-effect, no longer refuses to startup when run by root.\n\nScalar::Util\nNew utilities: refaddr, isvstring, lookslikenumber, setprototype.\n\nStorable\nCan now store code references (via B::Deparse, so not foolproof).\n\nstrict\nEarlier  versions  of the strict pragma did not check the parameters implicitly passed to\nits \"import\" (use) and \"unimport\" (no) routine.  This caused the false idiom such as:\n\nuse strict qw(@ISA);\n@ISA = qw(Foo);\n\nThis however (probably) raised the false expectation that the strict refs, vars and  subs\nwere  being  enforced (and that @ISA was somehow \"declared\").  But the strict refs, vars,\nand subs are not enforced when using this false idiom.\n\nStarting from Perl 5.8.1, the above will cause an error to be  raised.   This  may  cause\nprograms  which  used  to execute seemingly correctly without warnings and errors to fail\nwhen run under 5.8.1.  This happens because\n\nuse strict qw(@ISA);\n\nwill now fail with the error:\n\nUnknown 'strict' tag(s) '@ISA'\n\nThe remedy to this problem is to replace this code with the correct idiom:\n\nuse strict;\nuse vars qw(@ISA);\n@ISA = qw(Foo);\n\nTerm::ANSIcolor\nTest::Harness\nNow much more picky about extra or missing output from test scripts.\n\nTest::More\nTest::Simple\nText::Balanced\nTime::HiRes\nUse of nanosleep(), if available, allows mixing subsecond sleeps with alarms.\n\nthreads\nSeveral fixes, for example for join() problems and memory leaks.  In some platforms (like\nLinux) that use glibc the minimum memory footprint of one ithread  has  been  reduced  by\nseveral hundred kilobytes.\n\nthreads::shared\nMany memory leaks have been fixed.\n\nUnicode::Collate\nUnicode::Normalize\nWin32::GetFolderPath\nWin32::GetOSVersion\nNow returns extra information.\n"
                }
            ]
        },
        "Utility Changes": {
            "content": "The  \"h2xs\"  utility  now  produces  a  more modern layout: Foo-Bar/lib/Foo/Bar.pm instead of\nFoo/Bar/Bar.pm.  Also, the boilerplate test is now called t/Foo-Bar.t instead of t/1.t.\n\nThe Perl debugger (lib/perl5db.pl) has now been extensively documented and bugs  found  while\ndocumenting have been fixed.\n\n\"perldoc\" has been rewritten from scratch to be more robust and feature rich.\n\n\"perlcc  -B\"  works  now  at  least somewhat better, while \"perlcc -c\" is rather more broken.\n(The Perl compiler suite as a whole continues to be experimental.)\n",
            "subsections": []
        },
        "New Documentation": {
            "content": "perl573delta has been added  to  list  the  differences  between  the  (now  quite  obsolete)\ndevelopment releases 5.7.2 and 5.7.3.\n\nperl58delta  has  been added: it is the perldelta of 5.8.0, detailing the differences between\n5.6.0 and 5.8.0.\n\nperlartistic has been added: it is the Artistic License in pod format, making it  easier  for\nmodules to refer to it.\n\nperlcheat has been added: it is a Perl cheat sheet.\n\nperlgpl  has been added: it is the GNU General Public License in pod format, making it easier\nfor modules to refer to it.\n\nperlmacosx has been added to tell about the installation and use of Perl in Mac OS X.\n\nperlos400 has been added to tell about the installation and use of Perl in OS/400 PASE.\n\nperlreref has been added: it is a regular expressions quick reference.\n",
            "subsections": []
        },
        "Installation and Configuration Improvements": {
            "content": "The Unix standard Perl location, /usr/bin/perl, is no longer overwritten  by  default  if  it\nexists.   This  change  was  very  prudent  because  so  many  Unix vendors already provide a\n/usr/bin/perl, but simultaneously many system utilities may depend on that exact  version  of\nPerl, so better not to overwrite it.\n\nOne can now specify installation directories for site and vendor man and HTML pages, and site\nand vendor scripts.  See INSTALL.\n\nOne  can  now specify a destination directory for Perl installation by specifying the DESTDIR\nvariable for  \"make  install\".   (This  feature  is  slightly  different  from  the  previous\n\"Configure -Dinstallprefix=...\".)  See INSTALL.\n\ngcc versions 3.x introduced a new warning that caused a lot of noise during Perl compilation:\n\"gcc  -Ialreadyknowndirectory  (warning:  changing search order)\".  This warning has now been\navoided by Configure weeding out such directories before the compilation.\n\nOne  can  now  build  subsets  of  Perl  core  modules   by   using   the   Configure   flags\n\"-Dnoextensions=...\" and \"-Donlyextensions=...\", see INSTALL.\n",
            "subsections": [
                {
                    "name": "Platform-specific enhancements",
                    "content": "In  Cygwin  Perl  can now be built with threads (\"Configure -Duseithreads\").  This works with\nboth Cygwin 1.3.22 and Cygwin 1.5.3.\n\nIn newer FreeBSD releases Perl 5.8.0 compilation failed because of trying  to  use  malloc.h,\nwhich in FreeBSD is just a dummy file, and a fatal error to even try to use.  Now malloc.h is\nnot used.\n\nPerl is now known to build also in Hitachi HI-UXMPP.\n\nPerl is now known to build again in LynxOS.\n\nMac  OS  X now installs with Perl version number embedded in installation directory names for\neasier upgrading of user-compiled Perl, and the installation directories in general are  more\nstandard.  In other words, the default installation no longer breaks the Apple-provided Perl.\nOn  the  other  hand,  with  \"Configure  -Dprefix=/usr\" you can now really replace the Apple-\nsupplied Perl (please be careful).\n\nMac OS X now builds Perl statically by default.  This  change  was  done  mainly  for  faster\nstartup  times.   The Apple-provided Perl is still dynamically linked and shared, and you can\nenable the sharedness for your own Perl builds by \"Configure -Duseshrplib\".\n\nPerl has been ported to IBM's OS/400 PASE environment.  The best way to build a Perl for PASE\nis to use an AIX host as a cross-compilation environment.  See README.os400.\n\nYet another cross-compilation option has been added: now Perl builds on OpenZaurus,  a  Linux\ndistribution  based  on  Mandrake  +  Embedix for the Sharp Zaurus PDA.  See the Cross/README\nfile.\n\nTru64 when using gcc 3 drops the optimisation for toke.c to \"-O2\" because of gigantic  memory\nuse with the default \"-O3\".\n\nTru64 can now build Perl with the newer Berkeley DBs.\n\nBuilding Perl on WinCE has been much enhanced, see README.ce and README.perlce.\n"
                }
            ]
        },
        "Selected Bug Fixes": {
            "content": "",
            "subsections": [
                {
                    "name": "Closures, eval and lexicals",
                    "content": "There  have  been  many fixes in the area of anonymous subs, lexicals and closures.  Although\nthis means that Perl is now more \"correct\", it is possible that some existing code will break\nthat happens to rely on the faulty behaviour.  In practice this is unlikely unless your  code\ncontains a very complex nesting of anonymous subs, evals and lexicals.\n"
                },
                {
                    "name": "Generic fixes",
                    "content": "If  an  input  filehandle  is marked \":utf8\" and Perl sees illegal UTF-8 coming in when doing\n\"<FH>\", if warnings are enabled a warning is immediately given  -  instead  of  being  silent\nabout it and Perl being unhappy about the broken data later.  (The :encoding(utf8) layer also\nworks the same way.)\n\nbinmode(SOCKET, \":utf8\") only worked on the input side, not on the output side of the socket.\nNow it works both ways.\n\nFor  threaded Perls certain system database functions like getpwent() and getgrent() now grow\ntheir result buffer dynamically, instead of failing.  This means that at sites with  lots  of\nusers and groups the functions no longer fail by returning only partial results.\n\nPerl   5.8.0   had  accidentally  broken  the  capability  for  users  to  define  their  own\nuppercase<->lowercase Unicode mappings (as advertised by the Camel).  This feature  has  been\nfixed and is also documented better.\n\nIn 5.8.0 this\n\n$someunicode .= <FH>;\n\ndidn't work correctly but instead corrupted the data.  This has now been fixed.\n\nTied  methods  like  FETCH  etc.  may  now  safely  access  tied values, i.e.  resulting in a\nrecursive call to FETCH etc.  Remember to break the recursion, though.\n\nAt startup Perl blocks the SIGFPE signal away since there isn't much Perl can  do  about  it.\nPreviously this blocking was in effect also for programs executed from within Perl.  Now Perl\nrestores  the  original  SIGFPE  handling  routine,  whatever it was, before running external\nprograms.\n\nLinenumbers in Perl scripts may now be greater than 65536,  or  216.   (Perl  scripts  have\nalways  been  able  to be larger than that, it's just that the linenumber for reported errors\nand warnings have \"wrapped around\".)  While scripts that large usually  indicate  a  need  to\nrethink  your  code  a bit, such Perl scripts do exist, for example as results from generated\ncode.  Now linenumbers can go all the way to 4294967296, or 232.\n"
                },
                {
                    "name": "Platform-specific fixes",
                    "content": "Linux\n\n•   Setting $0 works again (with certain limitations that Perl cannot do much about: see \"$0\"\nin perlvar)\n\nHP-UX\n\n•   Setting $0 now works.\n\nVMS\n\n•   Configuration now tests for the presence of poll(), and IO::Poll  now  uses  the  vendor-\nsupplied function if detected.\n\n•   A rare access violation at Perl start-up could occur if the Perl image was installed with\nprivileges  or  if  there  was  an  identifier  with  the  subsystem attribute set in the\nprocess's rightslist.   Either  of  these  circumstances  triggered  tainting  code  that\ncontained a pointer bug.  The faulty pointer arithmetic has been fixed.\n\n•   The  length limit on values (not keys) in the %ENV hash has been raised from 255 bytes to\n32640 bytes (except when the PERLENVTABLES setting overrides the default use of logical\nnames for %ENV).  If it is necessary to access these long values from  outside  Perl,  be\naware  that  they are implemented using search list logical names that store the value in\npieces, each 255-byte piece (up to 128 of them) being an element in the search list. When\ndoing a lookup in %ENV from within Perl, the elements are combined into a  single  value.\nThe  existing VMS-specific ability to access individual elements of a search list logical\nname via the $ENV{'foo;N'} syntax (where N is the search list index) is unimpaired.\n\n•   The piping implementation now uses local rather than global DCL symbols for inter-process\ncommunication.\n\n•   File::Find could become confused when navigating  to  a  relative  directory  whose  name\ncollided with a logical name.  This problem has been corrected by adding directory syntax\nto relative path names, thus preventing logical name translation.\n\nWin32\n\n•   A memory leak in the fork() emulation has been fixed.\n\n•   The return value of the ioctl() built-in function was accidentally broken in 5.8.0.  This\nhas been corrected.\n\n•   The  internal  message  loop  executed  by  perl  during  blocking  operations  sometimes\ninterfered with messages that were external to Perl.  This  often  resulted  in  blocking\noperations  terminating  prematurely  or  returning  incorrect  results,  when  Perl  was\nexecuting under environments  that  could  generate  Windows  messages.   This  has  been\ncorrected.\n\n•   Pipes and sockets are now automatically in binary mode.\n\n•   The  four-argument  form of select() did not preserve $! (errno) properly when there were\nerrors in the underlying call.  This is now fixed.\n\n•   The \"CR CR LF\" problem of has been fixed, binmode(FH, \":crlf\") is now effectively  a  no-\nop.\n"
                }
            ]
        },
        "New or Changed Diagnostics": {
            "content": "All the warnings related to pack() and unpack() were made more informative and consistent.\n",
            "subsections": [
                {
                    "name": "Changed \"A thread exited while %d threads were running\"",
                    "content": "The old version\n\nA thread exited while %d other threads were still running\n\nwas misleading because the \"other\" included also the thread giving the warning.\n"
                },
                {
                    "name": "Removed \"Attempt to clear a restricted hash\"",
                    "content": "It is not illegal to clear a restricted hash, so the warning was removed.\n"
                },
                {
                    "name": "New \"Illegal declaration of anonymous subroutine\"",
                    "content": "You must specify the block of code for \"sub\".\n"
                },
                {
                    "name": "Changed \"Invalid range \"%s\" in transliteration operator\"",
                    "content": "The old version\n\nInvalid [] range \"%s\" in transliteration operator\n\nwas simply wrong because there are no \"[] ranges\" in tr///.\n"
                },
                {
                    "name": "New \"Missing control char name in \\c\"",
                    "content": "Self-explanatory.\n"
                },
                {
                    "name": "New \"Newline in left-justified string for %s\"",
                    "content": "The  padding  spaces  would  appear  after the newline, which is probably not what you had in\nmind.\n"
                },
                {
                    "name": "New \"Possible precedence problem on bitwise %c operator\"",
                    "content": "If you think this\n\n$x & $y == 0\n\ntests whether the bitwise AND of $x and $y is zero, you will like this warning.\n"
                },
                {
                    "name": "New \"Pseudo-hashes are deprecated\"",
                    "content": "This warning should have been already in 5.8.0, since they are.\n"
                },
                {
                    "name": "New \"read() on %s filehandle %s\"",
                    "content": "You cannot read() (or sysread()) from a closed or unopened filehandle.\n"
                },
                {
                    "name": "New \"5.005 threads are deprecated\"",
                    "content": "This warning should have been already in 5.8.0, since they are.\n"
                },
                {
                    "name": "New \"Tied variable freed while still in use\"",
                    "content": "Something pulled the plug on a live tied variable, Perl plays safe by bailing out.\n"
                },
                {
                    "name": "New \"To%s: illegal mapping '%s'\"",
                    "content": "An illegal user-defined Unicode casemapping was specified.\n"
                },
                {
                    "name": "New \"Use of freed value in iteration\"",
                    "content": "Something modified the values being iterated over.  This is not good.\n"
                }
            ]
        },
        "Changed Internals": {
            "content": "These news matter to you only if you either write XS code or like to know about or hack  Perl\ninternals  (using  Devel::Peek  or any of the \"B::\" modules counts), or like to run Perl with\nthe \"-D\" option.\n\nThe embedding examples of perlembed have been reviewed to be up to date and  consistent:  for\nexample, the correct use of PERLSYSINIT3() and PERLSYSTERM().\n\nExtensive  reworking  of  the  pad code (the code responsible for lexical variables) has been\nconducted by Dave Mitchell.\n\nExtensive work on the v-strings by John Peacock.\n\nUTF-8 length and position cache: to speed up the handling of Unicode (UTF-8) scalars, a cache\nwas introduced.  Potential problems exist if an extension  bypasses  the  official  APIs  and\ndirectly modifies the PV of an SV: the UTF-8 cache does not get cleared as it should.\n\nAPIs  obsoleted  in  Perl  5.8.0,  like  sv2pv,  svcatpvn,  svcatsv,  svsetsv,  are again\navailable.\n\nCertain Perl core C APIs like cxinc and regatom are  no  longer  available  at  all  to  code\noutside  the  Perl core of the Perl core extensions.  This is intentional.  They never should\nhave been available with the shorter names, and if  you  application  depends  on  them,  you\nshould (be ashamed and) contact perl5-porters to discuss what are the proper APIs.\n\nCertain  Perl  core  C  APIs  like  \"Perllist\" are no longer available without their \"Perl\"\nprefix.  If your XS module stops working because some functions  cannot  be  found,  in  many\ncases  a  simple  fix  is  to  add  the \"Perl\" prefix to the function and the thread context\n\"aTHX\" as the first argument of the function call.  This is also how it should  always  have\nbeen  done:  letting the Perl-less forms to leak from the core was an accident.  For cleaner\nembedding you can also force this for all APIs by defining at compile  time  the  cpp  define\nPERLNOSHORTNAMES.\n\nPerlsavebool() has been added.\n\nRegexp  objects  (those  created with \"qr\") now have S-magic rather than R-magic.  This fixed\nregexps of the form /...(??{...;$x})/ to no longer ignore changes made to  $x.   The  S-magic\navoids  dropping the caching optimization and making (??{...}) constructs obscenely slow (and\nconsequently useless).  See also \"Magic Variables\" in perlguts.  Regexp::Copy was affected by\nthis change.\n\nThe Perl internal debugging macros DEBUG() and DEB() have been renamed  to  PERLDEBUG()  and\nPERLDEB() to avoid namespace conflicts.\n\n\"-DL\"  removed  (the  leaktest  had  been  broken  and unsupported for years, use alternative\ndebugging mallocs or tools like valgrind and Purify).\n\nVerbose modifier \"v\" added for \"-DXv\" and \"-Dsv\", see perlrun.\n\nNew Tests\nIn Perl 5.8.0 there were about 69000 separate tests in about 700 test files,  in  Perl  5.8.1\nthere  are  about  77000 separate tests in about 780 test files.  The exact numbers depend on\nthe Perl configuration and on the operating system platform.\n",
            "subsections": []
        },
        "Known Problems": {
            "content": "The hash randomisation mentioned in \"Incompatible Changes\" is definitely problematic: it will\nwake dormant bugs and shake out bad assumptions.\n\nIf you want to use modperl 2.x with Perl 5.8.1, you will need  modperl-1.9910  or  higher.\nEarlier versions of modperl 2.x do not work with the randomised hashes.  (modperl 1.x works\nfine.)  You will also need Apache::Test 1.04 or higher.\n\nMany  of the rarer platforms that worked 100% or pretty close to it with perl 5.8.0 have been\nleft a little bit untended since their maintainers  have  been  otherwise  busy  lately,  and\ntherefore  there  will  be  more  failures on those platforms.  Such platforms include Mac OS\nClassic, IBM z/OS (and other EBCDIC platforms), and NetWare.  The most common Perl  platforms\n(Unix  and  Unix-like,  Microsoft  platforms,  and  VMS) have large enough testing and expert\npopulation that they are doing well.\n",
            "subsections": [
                {
                    "name": "Tied hashes in scalar context",
                    "content": "Tied hashes do not currently return anything useful in scalar context, for example when  used\nas boolean tests:\n\nif (%tiedhash) { ... }\n\nThe  current  nonsensical behaviour is always to return false, regardless of whether the hash\nis empty or has elements.\n\nThe root cause is that there is no interface for the implementors of tied hashes to implement\nthe behaviour of a hash in scalar context.\n"
                },
                {
                    "name": "Net::Ping 450_service and 510_ping_udp failures",
                    "content": "The  subtests  9  and  18   of   lib/Net/Ping/t/450service.t,   and   the   subtest   2   of\nlib/Net/Ping/t/510pingudp.t  might  fail  if  you  have  an  unusual networking setup.  For\nexample in the latter case the test is trying to send a UDP ping to the IP address 127.0.0.1.\n"
                },
                {
                    "name": "B::C",
                    "content": "The C-generating compiler backend B::C (the frontend being \"perlcc -c\") is even  more  broken\nthan it used to be because of the extensive lexical variable changes.  (The good news is that\nB::Bytecode and ByteLoader are better than they used to be.)\n"
                }
            ]
        },
        "Platform Specific Problems": {
            "content": "",
            "subsections": [
                {
                    "name": "EBCDIC Platforms",
                    "content": "IBM  z/OS  and  other  EBCDIC platforms continue to be problematic regarding Unicode support.\nMany Unicode tests are skipped when they really should be fixed.\n"
                },
                {
                    "name": "Cygwin 1.5 problems",
                    "content": "In Cygwin 1.5 the io/tell and op/sysio tests have failures for some yet unknown  reason.   In\n1.5.5  the  threads  tests  stresscv,  stressre,  and  stressstring are failing unless the\nenvironment variable PERLIO is set to \"perlio\" (which  makes  also  the  io/tell  failure  go\naway).\n\nPerl  5.8.1  does  build  and  work  well with Cygwin 1.3: with (uname -a) \"CYGWINNT-5.0 ...\n1.3.22(0.78/3/2) 2003-03-18 09:20 i686 ...\"  a 100% \"make test\"  was achieved with \"Configure\n-des -Duseithreads\".\n"
                },
                {
                    "name": "HP-UX: HP cc warnings about sendfile and sendpath",
                    "content": "With certain HP C compiler releases (e.g. B.11.11.02) you will get many  warnings  like  this\n(lines wrapped for easier reading):\n\ncc: \"/usr/include/sys/socket.h\", line 504: warning 562:\nRedeclaration of \"sendfile\" with a different storage class specifier:\n\"sendfile\" will have internal linkage.\ncc: \"/usr/include/sys/socket.h\", line 505: warning 562:\nRedeclaration of \"sendpath\" with a different storage class specifier:\n\"sendpath\" will have internal linkage.\n\nThe warnings show up both during the build of Perl and during certain lib/ExtUtils tests that\ninvoke the C compiler.  The warning, however, is not serious and can be ignored.\n"
                },
                {
                    "name": "IRIX: t/uni/tr_7jis.t falsely failing",
                    "content": "The  test  t/uni/tr7jis.t  is  known to report failure under 'make test' or the test harness\nwith certain releases of IRIX (at least IRIX 6.5 and MIPSpro Compilers Version 7.3.1.1m), but\nif run manually the test fully passes.\n"
                },
                {
                    "name": "Mac OS X: no usemymalloc",
                    "content": "The Perl malloc (\"-Dusemymalloc\") does not work at all  in  Mac  OS  X.   This  is  not  that\nserious, though, since the native malloc works just fine.\n"
                },
                {
                    "name": "Tru64: No threaded builds with GNU cc (gcc)",
                    "content": "In  the  latest Tru64 releases (e.g. v5.1B or later) gcc cannot be used to compile a threaded\nPerl (-Duseithreads) because the system \"<pthread.h>\" file doesn't know about gcc.\n"
                },
                {
                    "name": "Win32: sysopen, sysread, syswrite",
                    "content": "As of the 5.8.0 release, sysopen()/sysread()/syswrite() do not behave like they  used  to  in\n5.6.1  and  earlier  with  respect  to  \"text\"  mode.   These built-ins now always operate in\n\"binary\" mode (even if sysopen() was passed the OTEXT flag, or if binmode() was used on  the\nfile  handle).  Note that this issue should only make a difference for disk files, as sockets\nand pipes have always been in \"binary\" mode  in  the  Windows  port.   As  this  behavior  is\ncurrently  considered  a  bug,  compatible behavior may be re-introduced in a future release.\nUntil then, the use of sysopen(), sysread() and syswrite() is not supported for  \"text\"  mode\noperations.\n"
                }
            ]
        },
        "Future Directions": {
            "content": "The  following  things  might happen in future.  The first publicly available releases having\nthese characteristics will be the developer releases Perl  5.9.x,  culminating  in  the  Perl\n5.10.0 release.  These are our best guesses at the moment: we reserve the right to rethink.\n\n•   PerlIO  will  become  The  Default.  Currently (in Perl 5.8.x) the stdio library is still\nused if Perl thinks it can use certain tricks to make stdio go really fast.   For  future\nreleases our goal is to make PerlIO go even faster.\n\n•   A  new  feature  called  assertions will be available.  This means that one can have code\ncalled assertions sprinkled in the code: usually they are optimised away, but they can be\nenabled with the \"-A\" option.\n\n•   A new operator \"//\" (defined-or) will be available.  This means that one will be able  to\nsay\n\n$a // $b\n\ninstead of\n\ndefined $a ? $a : $b\n\nand\n\n$c //= $d;\n\ninstead of\n\n$c = $d unless defined $c;\n\nThe  operator  will  have  the  same precedence and associativity as \"||\".  A source code\npatch   against   the   Perl   5.8.1   sources   will   be   available   in    CPAN    as\nauthors/id/H/HM/HMBRAND/dor-5.8.1.diff.\n\n•   unpack() will default to unpacking the $.\n\n•   Various Copy-On-Write techniques will be investigated in hopes of speeding up Perl.\n\n•   CPANPLUS, Inline, and Module::Build will become core modules.\n\n•   The ability to write true lexically scoped pragmas will be introduced.\n\n•   Work will continue on the bytecompiler and byteloader.\n\n•   v-strings  as  they  currently  exist  are  scheduled  to be deprecated.  The v-less form\n(1.2.3) will become a \"version object\" when used with  \"use\",  \"require\",  and  $VERSION.\n$^V  will also be a \"version object\" so the printf(\"%vd\",...) construct will no longer be\nneeded.  The v-ful version (v1.2.3) will become obsolete.  The equivalence of strings and\nv-strings (e.g.  that currently 5.8.0 is equal to \"\\5\\8\\0\") will go away.  There  may  be\nno  deprecation  warning for v-strings, though: it is quite hard to detect when v-strings\nare being used safely, and when they are not.\n\n•   5.005 Threads Will Be Removed\n\n•   The $* Variable Will Be Removed (it was deprecated a long time ago)\n\n•   Pseudohashes Will Be Removed\n",
            "subsections": []
        },
        "Reporting Bugs": {
            "content": "If you find what you think is a bug, you might check the  articles  recently  posted  to  the\ncomp.lang.perl.misc newsgroup and the perl bug database at http://bugs.perl.org/ .  There may\nalso be information at http://www.perl.com/ , the Perl Home Page.\n\nIf  you believe you have an unreported bug, please run the perlbug program included with your\nrelease.  Be sure to trim your bug down to a tiny but sufficient test case.  Your bug report,\nalong with the output of \"perl -V\", will be sent off to perlbug@perl.org to  be  analysed  by\nthe Perl porting team.  You can browse and search the Perl 5 bugs at http://bugs.perl.org/\n",
            "subsections": []
        },
        "SEE ALSO": {
            "content": "The Changes file for exhaustive details on what changed.\n\nThe INSTALL file for how to build Perl.\n\nThe README file for general stuff.\n\nThe Artistic and Copying files for copyright information.\n\nperl v5.38.2                                 2026-08-18                              PERL581DELTA(1)",
            "subsections": []
        }
    },
    "summary": "perl581delta - what is new for perl v5.8.1",
    "flags": [],
    "examples": [],
    "see_also": []
}