1=head1 NAME 2 3perl589delta - what is new for perl v5.8.9 4 5=head1 DESCRIPTION 6 7This document describes differences between the 5.8.8 release and 8the 5.8.9 release. 9 10=head1 Notice 11 12The 5.8.9 release will be the last significant release of the 5.8.x 13series. Any future releases of 5.8.x will likely only be to deal with 14security issues, and platform build failures. Hence you should look to 15migrating to 5.10.x, if you have not started already. 16See L</"Known Problems"> for more information. 17 18=head1 Incompatible Changes 19 20A particular construction in the source code of extensions written in C++ 21may need changing. See L</"Changed Internals"> for more details. All 22extensions written in C, most written in C++, and all existing compiled 23extensions are unaffected. This was necessary to improve C++ support. 24 25Other than this, there are no changes intentionally incompatible with 5.8.8. 26If any exist, they are bugs and reports are welcome. 27 28=head1 Core Enhancements 29 30=head2 Unicode Character Database 5.1.0. 31 32The copy of the Unicode Character Database included in Perl 5.8 has 33been updated to 5.1.0 from 4.1.0. See 34L<http://www.unicode.org/versions/Unicode5.1.0/#NotableChanges> for the 35notable changes. 36 37=head2 stat and -X on directory handles 38 39It is now possible to call C<stat> and the C<-X> filestat operators on 40directory handles. As both directory and file handles are barewords, there 41can be ambiguities over which was intended. In these situations the file 42handle semantics are preferred. Both also treat C<*FILE{IO}> filehandles 43like C<*FILE> filehandles. 44 45=head2 Source filters in @INC 46 47It's possible to enhance the mechanism of subroutine hooks in @INC by 48adding a source filter on top of the filehandle opened and returned by the 49hook. This feature was planned a long time ago, but wasn't quite working 50until now. See L<perlfunc/require> for details. (Nicholas Clark) 51 52=head2 Exceptions in constant folding 53 54The constant folding routine is now wrapped in an exception handler, and 55if folding throws an exception (such as attempting to evaluate 0/0), perl 56now retains the current optree, rather than aborting the whole program. 57Without this change, programs would not compile if they had expressions that 58happened to generate exceptions, even though those expressions were in code 59that could never be reached at runtime. (Nicholas Clark, Dave Mitchell) 60 61=head2 C<no VERSION> 62 63You can now use C<no> followed by a version number to specify that you 64want to use a version of perl older than the specified one. 65 66=head2 Improved internal UTF-8 caching code 67 68The code that caches calculated UTF-8 byte offsets for character offsets for 69a string has been re-written. Several bugs have been located and eliminated, 70and the code now makes better use of the information it has, so should be 71faster. In particular, it doesn't scan to the end of a string before 72calculating an offset within the string, which should speed up some operations 73on long strings. It is now possible to disable the caching code at run time, 74to verify that it is not the cause of suspected problems. 75 76=head2 Runtime relocatable installations 77 78There is now F<Configure> support for creating a perl tree that is relocatable 79at run time. see L</Relocatable installations>. 80 81=head2 New internal variables 82 83=over 4 84 85=item C<${^CHILD_ERROR_NATIVE}> 86 87This variable gives the native status returned by the last pipe close, 88backtick command, successful call to C<wait> or C<waitpid>, or from the 89C<system> operator. See L<perlvar> for details. (Contributed by Gisle Aas.) 90 91=item C<${^UTF8CACHE}> 92 93This variable controls the state of the internal UTF-8 offset caching code. 941 for on (the default), 0 for off, -1 to debug the caching code by checking 95all its results against linear scans, and panicking on any discrepancy. 96 97=back 98 99=head2 C<readpipe> is now overridable 100 101The built-in function C<readpipe> is now overridable. Overriding it permits 102also to override its operator counterpart, C<qx//> (also known as C<``>). 103 104=head2 simple exception handling macros 105 106Perl 5.8.9 (and 5.10.0 onwards) now provides a couple of macros to do very 107basic exception handling in XS modules. You can use these macros if you call 108code that may C<croak>, but you need to do some cleanup before giving control 109back to Perl. See L<perlguts/Exception Handling> for more details. 110 111=head2 -D option enhancements 112 113=over 114 115=item * 116 117C<-Dq> suppresses the I<EXECUTING...> message when running under C<-D> 118 119=item * 120 121C<-Dl> logs runops loop entry and exit, and jump level popping. 122 123=item * 124 125C<-Dv> displays the process id as part of the trace output. 126 127=back 128 129=head2 XS-assisted SWASHGET 130 131Some pure-perl code that the regexp engine was using to retrieve Unicode 132properties and transliteration mappings has been reimplemented in XS 133for faster execution. 134(SADAHIRO Tomoyuki) 135 136=head2 Constant subroutines 137 138The interpreter internals now support a far more memory efficient form of 139inlineable constants. Storing a reference to a constant value in a symbol 140table is equivalent to a full typeglob referencing a constant subroutine, 141but using about 400 bytes less memory. This proxy constant subroutine is 142automatically upgraded to a real typeglob with subroutine if necessary. 143The approach taken is analogous to the existing space optimisation for 144subroutine stub declarations, which are stored as plain scalars in place 145of the full typeglob. 146 147However, to aid backwards compatibility of existing code, which (wrongly) 148does not expect anything other than typeglobs in symbol tables, nothing in 149core uses this feature, other than the regression tests. 150 151Stubs for prototyped subroutines have been stored in symbol tables as plain 152strings, and stubs for unprototyped subroutines as the number -1, since 5.005, 153so code which assumes that the core only places typeglobs in symbol tables 154has been making incorrect assumptions for over 10 years. 155 156=head1 New Platforms 157 158Compile support added for: 159 160=over 161 162=item * 163 164DragonFlyBSD 165 166=item * 167 168MidnightBSD 169 170=item * 171 172MirOS BSD 173 174=item * 175 176RISC OS 177 178=item * 179 180Cray XT4/Catamount 181 182=back 183 184=head1 Modules and Pragmata 185 186=head2 New Modules 187 188=over 189 190=item * 191 192C<Module::Pluggable> is a simple framework to create modules that accept 193pluggable sub-modules. The bundled version is 3.8 194 195=item * 196 197C<Module::CoreList> is a hash of hashes that is keyed on perl version as 198indicated in C<$]>. The bundled version is 2.17 199 200=item * 201 202C<Win32API::File> now available in core on Microsoft Windows. The bundled 203version is 0.1001_01 204 205=item * 206 207C<Devel::InnerPackage> finds all the packages defined by a single file. It is 208part of the C<Module::Pluggable> distribution. The bundled version is 0.3 209 210=back 211 212=head2 Updated Modules 213 214=over 215 216=item * 217 218C<attributes> upgraded to version 0.09 219 220=item * 221 222C<AutoLoader> upgraded to version 5.67 223 224=item * 225 226C<AutoSplit> upgraded to 1.06 227 228=item * 229 230C<autouse> upgraded to version 1.06 231 232=item * 233 234C<B> upgraded from 1.09_01 to 1.19 235 236=over 237 238=item * 239 240provides new pad related abstraction macros C<B::NV::COP_SEQ_RANGE_LOW>, 241C<B::NV::COP_SEQ_RANGE_HIGH>, C<B::NV::PARENT_PAD_INDEX>, 242C<B::NV::PARENT_FAKELEX_FLAGS>, which hides the difference in storage in 2435.10.0 and later. 244 245=item * 246 247provides C<B::sub_generation>, which exposes C<PL_sub_generation> 248 249=item * 250 251provides C<B::GV::isGV_with_GP>, which on pre-5.10 perls always returns true. 252 253=item * 254 255New type C<B::HE> added with methods C<VAL>, C<HASH> and C<SVKEY_force> 256 257=item * 258 259The C<B::GVf_IMPORTED_CV> flag is now set correctly when a proxy 260constant subroutine is imported. 261 262=item * 263 264bugs fixed in the handling of C<PMOP>s. 265 266=item * 267 268C<B::BM::PREVIOUS> returns now C<U32>, not C<U16>. 269C<B::CV::START> and C<B:CV::ROOT> return now C<NULL> on an XSUB, 270C<B::CV::XSUB> and C<B::CV::XSUBANY> return 0 on a non-XSUB. 271 272=back 273 274=item * 275 276C<B::C> upgraded to 1.05 277 278=item * 279 280C<B::Concise> upgraded to 0.76 281 282=over 283 284=item * 285 286new option C<-src> causes the rendering of each statement (starting with 287the nextstate OP) to be preceded by the first line of source code that 288generates it. 289 290=item * 291 292new option C<-stash="somepackage">, C<require>s "somepackage", and then renders 293each function defined in its namespace. 294 295=item * 296 297now has documentation of detailed hint symbols. 298 299=back 300 301=item * 302 303C<B::Debug> upgraded to version 1.05 304 305=item * 306 307C<B::Deparse> upgraded to version 0.87 308 309=over 4 310 311=item * 312 313properly deparse C<print readpipe $x, $y>. 314 315=item * 316 317now handles C<< ''->() >>, C<::()>, C<sub :: {}>, I<etc.> correctly [RT #43010]. 318All bugs in parsing these kinds of syntax are now fixed: 319 320 perl -MO=Deparse -e '"my %h = "->()' 321 perl -MO=Deparse -e '::->()' 322 perl -MO=Deparse -e 'sub :: {}' 323 perl -MO=Deparse -e 'package a; sub a::b::c {}' 324 perl -MO=Deparse -e 'sub the::main::road {}' 325 326=item * 327 328does B<not> deparse C<$^H{v_string}>, which is automatically set by the 329internals. 330 331=back 332 333=item * 334 335C<B::Lint> upgraded to version 1.11 336 337=item * 338 339C<B::Terse> upgraded to version 1.05 340 341=item * 342 343C<base> upgraded to version 2.13 344 345=over 4 346 347=item * 348 349loading a module via base.pm would mask a global C<$SIG{__DIE__}> in that 350module. 351 352=item * 353 354push all classes at once in C<@ISA> 355 356=back 357 358=item * 359 360C<Benchmark> upgraded to version 1.10 361 362=item * 363 364C<bigint> upgraded to 0.23 365 366=item * 367 368C<bignum> upgraded to 0.23 369 370=item * 371 372C<bigrat> upgraded to 0.23 373 374=item * 375 376C<blib> upgraded to 0.04 377 378=item * 379 380C<Carp> upgraded to version 1.10 381 382The argument backtrace code now shows C<undef> as C<undef>, 383instead of a string I<"undef">. 384 385=item * 386 387C<CGI> upgraded to version 3.42 388 389=item * 390 391C<charnames> upgraded to 1.06 392 393=item * 394 395C<constant> upgraded to version 1.17 396 397=item * 398 399C<CPAN> upgraded to version 1.9301 400 401=item * 402 403C<Cwd> upgraded to version 3.29 with some platform specific 404improvements (including for VMS). 405 406=item * 407 408C<Data::Dumper> upgraded to version 2.121_17 409 410=over 411 412=item * 413 414Fixes hash iterator current position with the pure Perl version [RT #40668] 415 416=item * 417 418Performance enhancements, which will be most evident on platforms where 419repeated calls to C's C<realloc()> are slow, such as Win32. 420 421=back 422 423=item * 424 425C<DB_File> upgraded to version 1.817 426 427=item * 428 429C<DB_Filter> upgraded to version 0.02 430 431=item * 432 433C<Devel::DProf> upgraded to version 20080331.00 434 435=item * 436 437C<Devel::Peek> upgraded to version 1.04 438 439=item * 440 441C<Devel::PPPort> upgraded to version 3.14 442 443=item * 444 445C<diagnostics> upgraded to version 1.16 446 447=item * 448 449C<Digest> upgraded to version 1.15 450 451=item * 452 453C<Digest::MD5> upgraded to version 2.37 454 455=item * 456 457C<DirHandle> upgraded to version 1.02 458 459=over 460 461=item * 462 463now localises C<$.>, C<$@>, C<$!>, C<$^E>, and C<$?> before closing the 464directory handle to suppress leaking any side effects of warnings about it 465already being closed. 466 467=back 468 469=item * 470 471C<DynaLoader> upgraded to version 1.09 472 473C<DynaLoader> can now dynamically load a loadable object from a file with a 474non-default file extension. 475 476=item * 477 478C<Encode> upgraded to version 2.26 479 480C<Encode::Alias> includes a fix for encoding "646" on Solaris (better known as 481ASCII). 482 483=item * 484 485C<English> upgraded to version 1.03 486 487=item * 488 489C<Errno> upgraded to version 1.10 490 491=item * 492 493C<Exporter> upgraded to version 5.63 494 495=item * 496 497C<ExtUtils::Command> upgraded to version 1.15 498 499=item * 500 501C<ExtUtils::Constant> upgraded to version 0.21 502 503=item * 504 505C<ExtUtils::Embed> upgraded to version 1.28 506 507=item * 508 509C<ExtUtils::Install> upgraded to version 1.50_01 510 511=item * 512 513C<ExtUtils::Installed> upgraded to version 1.43 514 515=item * 516 517C<ExtUtils::MakeMaker> upgraded to version 6.48 518 519=over 520 521=item * 522 523support for C<INSTALLSITESCRIPT> and C<INSTALLVENDORSCRIPT> 524configuration. 525 526=back 527 528=item * 529 530C<ExtUtils::Manifest> upgraded to version 1.55 531 532=item * 533 534C<ExtUtils::ParseXS> upgraded to version 2.19 535 536=item * 537 538C<Fatal> upgraded to version 1.06 539 540=over 541 542=item * 543 544allows built-ins in C<CORE::GLOBAL> to be made fatal. 545 546=back 547 548=item * 549 550C<Fcntl> upgraded to version 1.06 551 552=item * 553 554C<fields> upgraded to version 2.12 555 556=item * 557 558C<File::Basename> upgraded to version 2.77 559 560=item * 561 562C<FileCache> upgraded to version 1.07 563 564=item * 565 566C<File::Compare> upgraded to 1.1005 567 568=item * 569 570C<File::Copy> upgraded to 2.13 571 572=over 4 573 574=item * 575 576now uses 3-arg open. 577 578=back 579 580=item * 581 582C<File::DosGlob> upgraded to 1.01 583 584=item * 585 586C<File::Find> upgraded to version 1.13 587 588=item * 589 590C<File::Glob> upgraded to version 1.06 591 592=over 593 594=item * 595 596fixes spurious results with brackets inside braces. 597 598=back 599 600=item * 601 602C<File::Path> upgraded to version 2.07_02 603 604=item * 605 606C<File::Spec> upgraded to version 3.29 607 608=over 4 609 610=item * 611 612improved handling of bad arguments. 613 614=item * 615 616some platform specific improvements (including for VMS and Cygwin), with 617an optimisation on C<abs2rel> when handling both relative arguments. 618 619=back 620 621=item * 622 623C<File::stat> upgraded to version 1.01 624 625=item * 626 627C<File::Temp> upgraded to version 0.20 628 629=item * 630 631C<filetest> upgraded to version 1.02 632 633=item * 634 635C<Filter::Util::Call> upgraded to version 1.07 636 637=item * 638 639C<Filter::Simple> upgraded to version 0.83 640 641=item * 642 643C<FindBin> upgraded to version 1.49 644 645=item * 646 647C<GDBM_File> upgraded to version 1.09 648 649=item * 650 651C<Getopt::Long> upgraded to version 2.37 652 653=item * 654 655C<Getopt::Std> upgraded to version 1.06 656 657=item * 658 659C<Hash::Util> upgraded to version 0.06 660 661=item * 662 663C<if> upgraded to version 0.05 664 665=item * 666 667C<IO> upgraded to version 1.23 668 669Reduced number of calls to C<getpeername> in C<IO::Socket> 670 671=item * 672 673C<IPC::Open> upgraded to version 1.03 674 675=item * 676 677C<IPC::Open3> upgraded to version 1.03 678 679=item * 680 681C<IPC::SysV> upgraded to version 2.00 682 683=item * 684 685C<lib> upgraded to version 0.61 686 687=over 688 689=item * 690 691avoid warning about loading F<.par> files. 692 693=back 694 695=item * 696 697C<libnet> upgraded to version 1.22 698 699=item * 700 701C<List::Util> upgraded to 1.19 702 703=item * 704 705C<Locale::Maketext> upgraded to 1.13 706 707=item * 708 709C<Math::BigFloat> upgraded to version 1.60 710 711=item * 712 713C<Math::BigInt> upgraded to version 1.89 714 715=item * 716 717C<Math::BigRat> upgraded to version 0.22 718 719=over 4 720 721=item * 722 723implements new C<as_float> method. 724 725=back 726 727=item * 728 729C<Math::Complex> upgraded to version 1.54. 730 731=item * 732 733C<Math::Trig> upgraded to version 1.18. 734 735=item * 736 737C<NDBM_File> upgraded to version 1.07 738 739=over 740 741=item * 742 743improve F<g++> handling for systems using GDBM compatibility headers. 744 745=back 746 747=item * 748 749C<Net::Ping> upgraded to version 2.35 750 751=item * 752 753C<NEXT> upgraded to version 0.61 754 755=over 756 757=item * 758 759fix several bugs with C<NEXT> when working with C<AUTOLOAD>, C<eval> block, and 760within overloaded stringification. 761 762=back 763 764=item * 765 766C<ODBM_File> upgraded to 1.07 767 768=item * 769 770C<open> upgraded to 1.06 771 772=item * 773 774C<ops> upgraded to 1.02 775 776=item * 777 778C<PerlIO::encoding> upgraded to version 0.11 779 780=item * 781 782C<PerlIO::scalar> upgraded to version 0.06 783 784=over 4 785 786=item * 787 788[RT #40267] C<PerlIO::scalar> doesn't respect readonly-ness. 789 790=back 791 792=item * 793 794C<PerlIO::via> upgraded to version 0.05 795 796=item * 797 798C<Pod::Html> upgraded to version 1.09 799 800=item * 801 802C<Pod::Parser> upgraded to version 1.35 803 804=item * 805 806C<Pod::Usage> upgraded to version 1.35 807 808=item * 809 810C<POSIX> upgraded to version 1.15 811 812=over 813 814=item * 815 816C<POSIX> constants that duplicate those in C<Fcntl> are now imported from 817C<Fcntl> and re-exported, rather than being duplicated by C<POSIX> 818 819=item * 820 821C<POSIX::remove> can remove empty directories. 822 823=item * 824 825C<POSIX::setlocale> safer to call multiple times. 826 827=item * 828 829C<POSIX::SigRt> added, which provides access to POSIX realtime signal 830functionality on systems that support it. 831 832=back 833 834=item * 835 836C<re> upgraded to version 0.06_01 837 838=item * 839 840C<Safe> upgraded to version 2.16 841 842=item * 843 844C<Scalar::Util> upgraded to 1.19 845 846=item * 847 848C<SDBM_File> upgraded to version 1.06 849 850=item * 851 852C<SelfLoader> upgraded to version 1.17 853 854=item * 855 856C<Shell> upgraded to version 0.72 857 858=item * 859 860C<sigtrap> upgraded to version 1.04 861 862=item * 863 864C<Socket> upgraded to version 1.81 865 866=over 867 868=item * 869 870this fixes an optimistic use of C<gethostbyname> 871 872=back 873 874=item * 875 876C<Storable> upgraded to 2.19 877 878=item * 879 880C<Switch> upgraded to version 2.13 881 882=item * 883 884C<Sys::Syslog> upgraded to version 0.27 885 886=item * 887 888C<Term::ANSIColor> upgraded to version 1.12 889 890=item * 891 892C<Term::Cap> upgraded to version 1.12 893 894=item * 895 896C<Term::ReadLine> upgraded to version 1.03 897 898=item * 899 900C<Test::Builder> upgraded to version 0.80 901 902=item * 903 904C<Test::Harness> upgraded version to 2.64 905 906=over 907 908=item * 909 910this makes it able to handle newlines. 911 912=back 913 914=item * 915 916C<Test::More> upgraded to version 0.80 917 918=item * 919 920C<Test::Simple> upgraded to version 0.80 921 922=item * 923 924C<Text::Balanced> upgraded to version 1.98 925 926=item * 927 928C<Text::ParseWords> upgraded to version 3.27 929 930=item * 931 932C<Text::Soundex> upgraded to version 3.03 933 934=item * 935 936C<Text::Tabs> upgraded to version 2007.1117 937 938=item * 939 940C<Text::Wrap> upgraded to version 2006.1117 941 942=item * 943 944C<Thread> upgraded to version 2.01 945 946=item * 947 948C<Thread::Semaphore> upgraded to version 2.09 949 950=item * 951 952C<Thread::Queue> upgraded to version 2.11 953 954=over 955 956=item * 957 958added capability to add complex structures (e.g., hash of hashes) to queues. 959 960=item * 961 962added capability to dequeue multiple items at once. 963 964=item * 965 966added new methods to inspect and manipulate queues: C<peek>, C<insert> and 967C<extract> 968 969=back 970 971=item * 972 973C<Tie::Handle> upgraded to version 4.2 974 975=item * 976 977C<Tie::Hash> upgraded to version 1.03 978 979=item * 980 981C<Tie::Memoize> upgraded to version 1.1 982 983=over 984 985=item * 986 987C<Tie::Memoize::EXISTS> now correctly caches its results. 988 989=back 990 991=item * 992 993C<Tie::RefHash> upgraded to version 1.38 994 995=item * 996 997C<Tie::Scalar> upgraded to version 1.01 998 999=item * 1000 1001C<Tie::StdHandle> upgraded to version 4.2 1002 1003=item * 1004 1005C<Time::gmtime> upgraded to version 1.03 1006 1007=item * 1008 1009C<Time::Local> upgraded to version 1.1901 1010 1011=item * 1012 1013C<Time::HiRes> upgraded to version 1.9715 with various build improvements 1014(including VMS) and minor platform-specific bug fixes (including 1015for HP-UX 11 ia64). 1016 1017=item * 1018 1019C<threads> upgraded to 1.71 1020 1021=over 1022 1023=item * 1024 1025new thread state information methods: C<is_running>, C<is_detached> 1026and C<is_joinable>. C<list> method enhanced to return running or joinable 1027threads. 1028 1029=item * 1030 1031new thread signal method: C<kill> 1032 1033=item * 1034 1035added capability to specify thread stack size. 1036 1037=item * 1038 1039added capability to control thread exiting behavior. Added a new C<exit> 1040method. 1041 1042=back 1043 1044=item * 1045 1046C<threads::shared> upgraded to version 1.27 1047 1048=over 1049 1050=item * 1051 1052smaller and faster implementation that eliminates one internal structure and 1053the consequent level of indirection. 1054 1055=item * 1056 1057user locks are now stored in a safer manner. 1058 1059=item * 1060 1061new function C<shared_clone> creates a copy of an object leaving 1062shared elements as-is and deep-cloning non-shared elements. 1063 1064=item * 1065 1066added new C<is_shared> method. 1067 1068=back 1069 1070=item * 1071 1072C<Unicode::Normalize> upgraded to version 1.02 1073 1074=item * 1075 1076C<Unicode::UCD> upgraded to version 0.25 1077 1078=item * 1079 1080C<warnings> upgraded to version 1.05_01 1081 1082=item * 1083 1084C<Win32> upgraded to version 0.38 1085 1086=over 4 1087 1088=item * 1089 1090added new function C<GetCurrentProcessId> which returns the regular Windows 1091process identifier of the current process, even when called from within a fork. 1092 1093=back 1094 1095=item * 1096 1097C<XSLoader> upgraded to version 0.10 1098 1099=item * 1100 1101C<XS::APItest> and C<XS::Typemap> are for internal use only and hence 1102no longer installed. Many more tests have been added to C<XS::APItest>. 1103 1104=back 1105 1106=head1 Utility Changes 1107 1108=head2 debugger upgraded to version 1.31 1109 1110=over 4 1111 1112=item * 1113 1114Andreas KE<ouml>nig contributed two functions to save and load the debugger 1115history. 1116 1117=item * 1118 1119C<NEXT::AUTOLOAD> no longer emits warnings under the debugger. 1120 1121=item * 1122 1123The debugger should now correctly find tty the device on OS X 10.5 and VMS 1124when the program C<fork>s. 1125 1126=item * 1127 1128LVALUE subs now work inside the debugger. 1129 1130=back 1131 1132=head2 F<perlthanks> 1133 1134Perl 5.8.9 adds a new utility F<perlthanks>, which is a variant of F<perlbug>, 1135but for sending non-bug-reports to the authors and maintainers of Perl. 1136Getting nothing but bug reports can become a bit demoralising - we'll see if 1137this changes things. 1138 1139=head2 F<perlbug> 1140 1141F<perlbug> now checks if you're reporting about a non-core module and suggests 1142you report it to the CPAN author instead. 1143 1144=head2 F<h2xs> 1145 1146=over 1147 1148=item * 1149 1150won't define an empty string as a constant [RT #25366] 1151 1152=item * 1153 1154has examples for C<h2xs -X> 1155 1156=back 1157 1158=head2 F<h2ph> 1159 1160=over 4 1161 1162=item * 1163 1164now attempts to deal sensibly with the difference in path implications 1165between C<""> and C<< E<lt>E<gt> >> quoting in C<#include> statements. 1166 1167=item * 1168 1169now generates correct code for C<#if defined A || defined B> 1170[RT #39130] 1171 1172=back 1173 1174=head1 New Documentation 1175 1176As usual, the documentation received its share of corrections, clarifications 1177and other nitfixes. More C<< X<...> >> tags were added for indexing. 1178 1179L<perlunitut> is a tutorial written by Juerd Waalboer on Unicode-related 1180terminology and how to correctly handle Unicode in Perl scripts. 1181 1182L<perlunicode> is updated in section user defined properties. 1183 1184L<perluniintro> has been updated in the example of detecting data that is not 1185valid in particular encoding. 1186 1187L<perlcommunity> provides an overview of the Perl Community along with further 1188resources. 1189 1190L<CORE> documents the pseudo-namespace for Perl's core routines. 1191 1192=head1 Changes to Existing Documentation 1193 1194L<perlglossary> adds I<deprecated modules and features> and I<to be dropped modules>. 1195 1196L<perlhack> has been updated and added resources on smoke testing. 1197 1198The Perl FAQs (F<perlfaq1>..F<perlfaq9>) have been updated. 1199 1200L<perlcheat> is updated with better details on C<\w>, C<\d>, and C<\s>. 1201 1202L<perldebug> is updated with information on how to call the debugger. 1203 1204L<perldiag> documentation updated with I<subroutine with an ampersand> on the 1205argument to C<exists> and C<delete> and also several terminology updates on 1206warnings. 1207 1208L<perlfork> documents the limitation of C<exec> inside pseudo-processes. 1209 1210L<perlfunc>: 1211 1212=over 1213 1214=item * 1215 1216Documentation is fixed in section C<caller> and C<pop>. 1217 1218=item * 1219 1220Function C<alarm> now mentions C<Time::HiRes::ualarm> in preference 1221to C<select>. 1222 1223=item * 1224 1225Regarding precedence in C<-X>, filetest operators are the same as unary 1226operators, but not regarding parsing and parentheses (spotted by Eirik Berg 1227Hanssen). 1228 1229=item * 1230 1231C<reverse> function documentation received scalar context examples. 1232 1233=back 1234 1235L<perllocale> documentation is adjusted for number localization and 1236C<POSIX::setlocale> to fix Debian bug #379463. 1237 1238L<perlmodlib> is updated with C<CPAN::API::HOWTO> and 1239C<Sys::Syslog::win32::Win32> 1240 1241L<perlre> documentation updated to reflect the differences between 1242C<[[:xxxxx:]]> and C<\p{IsXxxxx}> matches. Also added section on C</g> and 1243C</c> modifiers. 1244 1245L<perlreguts> describe the internals of the regular expressions engine. It has 1246been contributed by Yves Orton. 1247 1248L<perlrebackslash> describes all perl regular expression backslash and escape 1249sequences. 1250 1251L<perlrecharclass> describes the syntax and use of character classes in 1252Perl Regular Expressions. 1253 1254L<perlrun> is updated to clarify on the hash seed I<PERL_HASH_SEED>. Also more 1255information in options C<-x> and C<-u>. 1256 1257L<perlsub> example is updated to use a lexical variable for C<opendir> syntax. 1258 1259L<perlvar> fixes confusion about real GID C<$(> and effective GID C<$)>. 1260 1261Perl thread tutorial example is fixed in section 1262L<perlthrtut/Queues: Passing Data Around> and L<perlthrtut>. 1263 1264L<perlhack> documentation extensively improved by Jarkko Hietaniemi and others. 1265 1266L<perltoot> provides information on modifying C<@UNIVERSAL::ISA>. 1267 1268L<perlport> documentation extended to include different C<kill(-9, ...)> 1269semantics on Windows. It also clearly states C<dump> is not supported on Win32 1270and cygwin. 1271 1272F<INSTALL> has been updated and modernised. 1273 1274=head1 Performance Enhancements 1275 1276=over 1277 1278=item * 1279 1280The default since perl 5.000 has been for perl to create an empty scalar 1281with every new typeglob. The increased use of lexical variables means that 1282most are now unused. Thanks to Nicholas Clark's efforts, Perl can now be 1283compiled with C<-DPERL_DONT_CREATE_GVSV> to avoid creating these empty scalars. 1284This will significantly decrease the number of scalars allocated for all 1285configurations, and the number of scalars that need to be copied for ithread 1286creation. Whilst this option is binary compatible with existing perl 1287installations, it does change a long-standing assumption about the 1288internals, hence it is not enabled by default, as some third party code may 1289rely on the old behaviour. 1290 1291We would recommend testing with this configuration on new deployments of 1292perl, particularly for multi-threaded servers, to see whether all third party 1293code is compatible with it, as this configuration may give useful performance 1294improvements. For existing installations we would not recommend changing to 1295this configuration unless thorough testing is performed before deployment. 1296 1297=item * 1298 1299C<diagnostics> no longer uses C<$&>, which results in large speedups 1300for regexp matching in all code using it. 1301 1302=item * 1303 1304Regular expressions classes of a single character are now treated the same as 1305if the character had been used as a literal, meaning that code that uses 1306char-classes as an escaping mechanism will see a speedup. (Yves Orton) 1307 1308=item * 1309 1310Creating anonymous array and hash references (ie. C<[]> and C<{}>) now incurs 1311no more overhead than creating an anonymous list or hash. Nicholas Clark 1312provided changes with a saving of two ops and one stack push, which was measured 1313as a slightly better than 5% improvement for these operations. 1314 1315=item * 1316 1317Many calls to C<strlen()> have been eliminated, either because the length was 1318already known, or by adopting or enhancing APIs that pass lengths. This has 1319been aided by the adoption of a C<my_sprintf()> wrapper, which returns the 1320correct C89 value - the length of the formatted string. Previously we could 1321not rely on the return value of C<sprintf()>, because on some ancient but 1322extant platforms it still returns C<char *>. 1323 1324=item * 1325 1326C<index> is now faster if the search string is stored in UTF-8 but only contains 1327characters in the Latin-1 range. 1328 1329=item * 1330 1331The Unicode swatch cache inside the regexp engine is now used. (the lookup had 1332a key mismatch, present since the initial implementation). [RT #42839] 1333 1334=back 1335 1336=head1 Installation and Configuration Improvements 1337 1338=head2 Relocatable installations 1339 1340There is now F<Configure> support for creating a relocatable perl tree. If 1341you F<Configure> with C<-Duserelocatableinc>, then the paths in C<@INC> (and 1342everything else in C<%Config>) can be optionally located via the path of the 1343F<perl> executable. 1344 1345At start time, if any paths in C<@INC> or C<Config> that F<Configure> marked 1346as relocatable (by starting them with C<".../">), then they are prefixed the 1347directory of C<$^X>. This allows the relocation can be configured on a 1348per-directory basis, although the default with C<-Duserelocatableinc> is that 1349everything is relocated. The initial install is done to the original configured 1350prefix. 1351 1352=head2 Configuration improvements 1353 1354F<Configure> is now better at removing temporary files. Tom Callaway 1355(from RedHat) also contributed patches that complete the set of flags 1356passed to the compiler and the linker, in particular that C<-fPIC> is now 1357enabled on Linux. It will also croak when your F</dev/null> isn't a device. 1358 1359A new configuration variable C<d_pseudofork> has been to F<Configure>, and is 1360available as C<$Config{d_pseudofork}> in the C<Config> module. This 1361distinguishes real C<fork> support from the pseudofork emulation used on 1362Windows platforms. 1363 1364F<Config.pod> and F<config.sh> are now placed correctly for cross-compilation. 1365 1366C<$Config{useshrplib}> is now 'true' rather than 'yes' when using a shared perl 1367library. 1368 1369=head2 Compilation improvements 1370 1371Parallel makes should work properly now, although there may still be problems 1372if C<make test> is instructed to run in parallel. 1373 1374Many compilation warnings have been cleaned up. A very stubborn compiler 1375warning in C<S_emulate_eaccess()> was killed after six attempts. 1376F<g++> support has been tuned, especially for FreeBSD. 1377 1378F<mkppport> has been integrated, and all F<ppport.h> files in the core will now 1379be autogenerated at build time (and removed during cleanup). 1380 1381=head2 Installation improvements. 1382 1383F<installman> now works with C<-Duserelocatableinc> and C<DESTDIR>. 1384 1385F<installperl> no longer installs: 1386 1387=over 4 1388 1389=item * 1390 1391static library files of statically linked extensions when a shared perl library 1392is being used. (They are not needed. See L</Windows> below). 1393 1394=item * 1395 1396F<SIGNATURE> and F<PAUSE*.pub> (CPAN files) 1397 1398=item * 1399 1400F<NOTES> and F<PATCHING> (ExtUtils files) 1401 1402=item * 1403 1404F<perlld> and F<ld2> (Cygwin files) 1405 1406=back 1407 1408=head2 Platform Specific Changes 1409 1410There are improved hints for AIX, Cygwin, DEC/OSF, FreeBSD, HP/UX, Irix 6 1411Linux, MachTen, NetBSD, OS/390, QNX, SCO, Solaris, SunOS, System V Release 5.x 1412(UnixWare 7, OpenUNIX 8), Ultrix, UMIPS, uts and VOS. 1413 1414=head3 FreeBSD 1415 1416=over 4 1417 1418=item * 1419 1420Drop C<-std=c89> and C<-ansi> if using C<long long> as the main integral type, 1421else in FreeBSD 6.2 (and perhaps other releases), system headers do not 1422declare some functions required by perl. 1423 1424=back 1425 1426=head3 Solaris 1427 1428=over 4 1429 1430=item * 1431 1432Starting with Solaris 10, we do not want versioned shared libraries, because 1433those often indicate a private use only library. These problems could often 1434be triggered when L<SUNWbdb> (Berkeley DB) was installed. Hence if Solaris 10 1435is detected set C<ignore_versioned_solibs=y>. 1436 1437=back 1438 1439=head3 VMS 1440 1441=over 4 1442 1443=item * 1444 1445Allow IEEE math to be deselected on OpenVMS I64 (but it remains the default). 1446 1447=item * 1448 1449Record IEEE usage in C<config.h> 1450 1451=item * 1452 1453Help older VMS compilers by using C<ccflags> when building C<munchconfig.exe>. 1454 1455=item * 1456 1457Don't try to build old C<Thread> extension on VMS when C<-Duseithreads> has 1458been chosen. 1459 1460=item * 1461 1462Passing a raw string of "NaN" to F<nawk> causes a core dump - so the string 1463has been changed to "*NaN*" 1464 1465=item * 1466 1467F<t/op/stat.t> tests will now test hard links on VMS if they are supported. 1468 1469=back 1470 1471=head3 Windows 1472 1473=over 4 1474 1475=item * 1476 1477When using a shared perl library F<installperl> no longer installs static 1478library files, import library files and export library files (of statically 1479linked extensions) and empty bootstrap files (of dynamically linked 1480extensions). This fixes a problem building PAR-Packer on Win32 with a debug 1481build of perl. 1482 1483=item * 1484 1485Various improvements to the win32 build process, including support for Visual 1486C++ 2005 Express Edition (aka Visual C++ 8.x). 1487 1488=item * 1489 1490F<perl.exe> will now have an icon if built with MinGW or Borland. 1491 1492=item * 1493 1494Improvements to the perl-static.exe build process. 1495 1496=item * 1497 1498Add Win32 makefile option to link all extensions statically. 1499 1500=item * 1501 1502The F<WinCE> directory has been merged into the F<Win32> directory. 1503 1504=item * 1505 1506C<setlocale> tests have been re-enabled for Windows XP onwards. 1507 1508=back 1509 1510=head1 Selected Bug Fixes 1511 1512=head2 Unicode 1513 1514Many many bugs related to the internal Unicode implementation (UTF-8) have 1515been fixed. In particular, long standing bugs related to returning Unicode 1516via C<tie>, overloading or C<$@> are now gone, some of which were never 1517reported. 1518 1519C<unpack> will internally convert the string back from UTF-8 on numeric types. 1520This is a compromise between the full consistency now in 5.10, and the current 1521behaviour, which is often used as a "feature" on string types. 1522 1523Using C<:crlf> and C<UTF-16> IO layers together will now work. 1524 1525Fixed problems with C<split>, Unicode C</\s+/> and C</ \0/>. 1526 1527Fixed bug RT #40641 - encoding of Unicode characters in regular expressions. 1528 1529Fixed a bug where using certain patterns in a regexp led to a panic. 1530[RT #45337] 1531 1532Perl no longer segfaults (due to infinite internal recursion) if the locale's 1533character is not UTF-8 [RT #41442]: 1534 1535 use open ':locale'; 1536 print STDERR "\x{201e}"; # „ 1537 1538=head2 PerlIO 1539 1540Inconsistencies have been fixed in the reference counting PerlIO uses to keep 1541track of Unix file descriptors, and the API used by XS code to manage getting 1542and releasing C<FILE *>s 1543 1544=head2 Magic 1545 1546Several bugs have been fixed in Magic, the internal system used to implement 1547features such as C<tie>, tainting and threads sharing. 1548 1549C<undef @array> on a tied array now correctly calls the C<CLEAR> method. 1550 1551Some of the bitwise ops were not checking whether their arguments were magical 1552before using them. [RT #24816] 1553 1554Magic is no longer invoked twice by the expression C<\&$x> 1555 1556A bug with assigning large numbers and tainting has been resolved. 1557[RT #40708] 1558 1559A new entry has been added to the MAGIC vtable - C<svt_local>. This is used 1560when copying magic to the new value during C<local>, allowing certain problems 1561with localising shared variables to be resolved. 1562 1563For the implementation details, see L<perlguts/Magic Virtual Tables>. 1564 1565=head2 Reblessing overloaded objects now works 1566 1567Internally, perl object-ness is on the referent, not the reference, even 1568though methods can only be called via a reference. However, the original 1569implementation of overloading stored flags related to overloading on the 1570reference, relying on the flags being copied when the reference was copied, 1571or set at the creation of a new reference. This manifests in a bug - if you 1572rebless an object from a class that has overloading, into one that does not, 1573then any other existing references think that they (still) point to an 1574overloaded object, choose these C code paths, and then throw errors. 1575Analogously, blessing into an overloaded class when other references exist will 1576result in them not using overloading. 1577 1578The implementation has been fixed for 5.10, but this fix changes the semantics 1579of flag bits, so is not binary compatible, so can't be applied to 5.8.9. 1580However, 5.8.9 has a work-around that implements the same bug fix. If the 1581referent has multiple references, then all the other references are located and 1582corrected. A full search is avoided whenever possible by scanning lexicals 1583outwards from the current subroutine, and the argument stack. 1584 1585A certain well known Linux vendor applied incomplete versions of this bug fix 1586to their F</usr/bin/perl> and then prematurely closed bug reports about 1587performance issues without consulting back upstream. This not being enough, 1588they then proceeded to ignore the necessary fixes to these unreleased changes 1589for 11 months, until massive pressure was applied by their long-suffering 1590paying customers, catalysed by the failings being featured on a prominent blog 1591and Slashdot. 1592 1593=head2 C<strict> now propagates correctly into string evals 1594 1595Under 5.8.8 and earlier: 1596 1597 $ perl5.8.8 -e 'use strict; eval "use foo bar" or die $@' 1598 Can't locate foo.pm in @INC (@INC contains: ... .) at (eval 1) line 2. 1599 BEGIN failed--compilation aborted at (eval 1) line 2. 1600 1601Under 5.8.9 and later: 1602 1603 $ perl5.8.9 -e 'use strict; eval "use foo bar" or die $@' 1604 Bareword "bar" not allowed while "strict subs" in use at (eval 1) line 1. 1605 1606This may cause problems with programs that parse the error message and rely 1607on the buggy behaviour. 1608 1609=head2 Other fixes 1610 1611=over 1612 1613=item * 1614 1615The tokenizer no longer treats C<=cute> (and other words beginning 1616with C<=cut>) as a synonym for C<=cut>. 1617 1618=item * 1619 1620Calling C<CORE::require> 1621 1622C<CORE::require> and C<CORE::do> were always parsed as C<require> and C<do> 1623when they were overridden. This is now fixed. 1624 1625=item * 1626 1627Stopped memory leak on long F</etc/groups> entries. 1628 1629=item * 1630 1631C<while (my $x ...) { ...; redo }> shouldn't C<undef $x>. 1632 1633In the presence of C<my> in the conditional of a C<while()>, C<until()>, 1634or C<for(;;)> loop, we now add an extra scope to the body so that C<redo> 1635doesn't C<undef> the lexical. 1636 1637=item * 1638 1639The C<encoding> pragma now correctly ignores anything following an C<@> 1640character in the C<LC_ALL> and C<LANG> environment variables. [RT # 49646] 1641 1642=item * 1643 1644A segfault observed with some F<gcc> 3.3 optimisations is resolved. 1645 1646=item * 1647 1648A possible segfault when C<unpack> used in scalar context with C<()> groups 1649is resolved. [RT #50256] 1650 1651=item * 1652 1653Resolved issue where C<$!> could be changed by a signal handler interrupting 1654a C<system> call. 1655 1656=item * 1657 1658Fixed bug RT #37886, symbolic dereferencing was allowed in the argument of 1659C<defined> even under the influence of C<use strict 'refs'>. 1660 1661=item * 1662 1663Fixed bug RT #43207, where C<lc>/C<uc> inside C<sort> affected the return 1664value. 1665 1666=item * 1667 1668Fixed bug RT #45607, where C<*{"BONK"} = \&{"BONK"}> didn't work correctly. 1669 1670=item * 1671 1672Fixed bug RT #35878, croaking from a XSUB called via C<goto &xsub> corrupts perl 1673internals. 1674 1675=item * 1676 1677Fixed bug RT #32539, F<DynaLoader.o> is moved into F<libperl.so> to avoid the 1678need to statically link DynaLoader into the stub perl executable. With this 1679F<libperl.so> provides everything needed to get a functional embedded perl 1680interpreter to run. 1681 1682=item * 1683 1684Fix bug RT #36267 so that assigning to a tied hash doesn't change the 1685underlying hash. 1686 1687=item * 1688 1689Fix bug RT #6006, regexp replaces using large replacement variables 1690fail some of the time, I<i.e.> when substitution contains something 1691like C<${10}> (note the bracket) instead of just C<$10>. 1692 1693=item * 1694 1695Fix bug RT #45053, C<Perl_newCONSTSUB()> is now thread safe. 1696 1697=back 1698 1699=head2 Platform Specific Fixes 1700 1701=head3 Darwin / MacOS X 1702 1703=over 4 1704 1705=item * 1706 1707Various improvements to 64 bit builds. 1708 1709=item * 1710 1711Mutex protection added in C<PerlIOStdio_close()> to avoid race conditions. 1712Hopefully this fixes failures in the threads tests F<free.t> and F<blocks.t>. 1713 1714=item * 1715 1716Added forked terminal support to the debugger, with the ability to update the 1717window title. 1718 1719=back 1720 1721=head3 OS/2 1722 1723=over 4 1724 1725=item * 1726 1727A build problem with specifying C<USE_MULTI> and C<USE_ITHREADS> but without 1728C<USE_IMP_SYS> has been fixed. 1729 1730=item * 1731 1732C<OS2::REXX> upgraded to version 1.04 1733 1734=back 1735 1736=head3 Tru64 1737 1738=over 4 1739 1740=item * 1741 1742Aligned floating point build policies for F<cc> and F<gcc>. 1743 1744=back 1745 1746=head3 RedHat Linux 1747 1748=over 4 1749 1750=item * 1751 1752Revisited a patch from 5.6.1 for RH7.2 for Intel's F<icc> [RT #7916], added an 1753additional check for C<$Config{gccversion}>. 1754 1755=back 1756 1757=head3 Solaris/i386 1758 1759=over 4 1760 1761=item * 1762 1763Use C<-DPTR_IS_LONG> when using 64 bit integers 1764 1765=back 1766 1767=head3 VMS 1768 1769=over 4 1770 1771=item * 1772 1773Fixed C<PerlIO::Scalar> in-memory file record-style reads. 1774 1775=item * 1776 1777pipe shutdown at process exit should now be more robust. 1778 1779=item * 1780 1781Bugs in VMS exit handling tickled by C<Test::Harness> 2.64 have been fixed. 1782 1783=item * 1784 1785Fix C<fcntl()> locking capability test in F<configure.com>. 1786 1787=item * 1788 1789Replaced C<shrplib='define'> with C<useshrplib='true'> on VMS. 1790 1791=back 1792 1793=head3 Windows 1794 1795=over 4 1796 1797=item * 1798 1799C<File::Find> used to fail when the target directory is a bare drive letter and 1800C<no_chdir> is 1 (the default is 0). [RT #41555] 1801 1802=item * 1803 1804A build problem with specifying C<USE_MULTI> and C<USE_ITHREADS> but without 1805C<USE_IMP_SYS> has been fixed. 1806 1807=item * 1808 1809The process id is no longer truncated to 16 bits on some Windows platforms 1810( http://bugs.activestate.com/show_bug.cgi?id=72443 ) 1811 1812=item * 1813 1814Fixed bug RT #54828 in F<perlio.c> where calling C<binmode> on Win32 and Cygwin 1815may cause a segmentation fault. 1816 1817=back 1818 1819=head2 Smaller fixes 1820 1821=over 4 1822 1823=item * 1824 1825It is now possible to overload C<eq> when using C<nomethod>. 1826 1827=item * 1828 1829Various problems using C<overload> with 64 bit integers corrected. 1830 1831=item * 1832 1833The reference count of C<PerlIO> file descriptors is now correctly handled. 1834 1835=item * 1836 1837On VMS, escaped dots will be preserved when converted to Unix syntax. 1838 1839=item * 1840 1841C<keys %+> no longer throws an C<'ambiguous'> warning. 1842 1843=item * 1844 1845Using C<#!perl -d> could trigger an assertion, which has been fixed. 1846 1847=item * 1848 1849Don't stringify tied code references in C<@INC> when calling C<require>. 1850 1851=item * 1852 1853Code references in C<@INC> report the correct file name when C<__FILE__> is 1854used. 1855 1856=item * 1857 1858Width and precision in sprintf didn't handle characters above 255 correctly. 1859[RT #40473] 1860 1861=item * 1862 1863List slices with indices out of range now work more consistently. 1864[RT #39882] 1865 1866=item * 1867 1868A change introduced with perl 5.8.1 broke the parsing of arguments of the form 1869C<-foo=bar> with the C<-s> on the <#!> line. This has been fixed. See 1870http://bugs.activestate.com/show_bug.cgi?id=43483 1871 1872=item * 1873 1874C<tr///> is now threadsafe. Previously it was storing a swash inside its OP, 1875rather than in a pad. 1876 1877=item * 1878 1879F<pod2html> labels anchors more consistently and handles nested definition 1880lists better. 1881 1882=item * 1883 1884C<threads> cleanup veto has been extended to include C<perl_free()> and 1885C<perl_destruct()> 1886 1887=item * 1888 1889On some systems, changes to C<$ENV{TZ}> would not always be 1890respected by the underlying calls to C<localtime_r()>. Perl now 1891forces the inspection of the environment on these systems. 1892 1893=item * 1894 1895The special variable C<$^R> is now more consistently set when executing 1896regexps using the C<(?{...})> construct. In particular, it will still 1897be set even if backreferences or optional sub-patterns C<(?:...)?> are 1898used. 1899 1900=back 1901 1902=head1 New or Changed Diagnostics 1903 1904=head2 panic: sv_chop %s 1905 1906This new fatal error occurs when the C routine C<Perl_sv_chop()> was passed a 1907position that is not within the scalar's string buffer. This is caused by 1908buggy XS code, and at this point recovery is not possible. 1909 1910=head2 Maximal count of pending signals (%s) exceeded 1911 1912This new fatal error occurs when the perl process has to abort due to 1913too many pending signals, which is bound to prevent perl from being 1914able to handle further incoming signals safely. 1915 1916=head2 panic: attempt to call %s in %s 1917 1918This new fatal error occurs when the ACL version file test operator is used 1919where it is not available on the current platform. Earlier checks mean that 1920it should never be possible to get this. 1921 1922=head2 FETCHSIZE returned a negative value 1923 1924New error indicating that a tied array has claimed to have a negative 1925number of elements. 1926 1927=head2 Can't upgrade %s (%d) to %d 1928 1929Previously the internal error from the SV upgrade code was the less informative 1930I<Can't upgrade that kind of scalar>. It now reports the current internal type, 1931and the new type requested. 1932 1933=head2 %s argument is not a HASH or ARRAY element or a subroutine 1934 1935This error, thrown if an invalid argument is provided to C<exists> now 1936correctly includes "or a subroutine". [RT #38955] 1937 1938=head2 Cannot make the non-overridable builtin %s fatal 1939 1940This error in C<Fatal> previously did not show the name of the builtin in 1941question (now represented by %s above). 1942 1943=head2 Unrecognized character '%s' in column %d 1944 1945This error previously did not state the column. 1946 1947=head2 Offset outside string 1948 1949This can now also be generated by a C<seek> on a file handle using 1950C<PerlIO::scalar>. 1951 1952=head2 Invalid escape in the specified encoding in regexp; marked by <-- HERE in m/%s/ 1953 1954New error, introduced as part of the fix to RT #40641 to handle encoding 1955of Unicode characters in regular expression comments. 1956 1957=head2 Your machine doesn't support dump/undump. 1958 1959A more informative fatal error issued when calling C<dump> on Win32 and 1960Cygwin. (Given that the purpose of C<dump> is to abort with a core dump, 1961and core dumps can't be produced on these platforms, this is more useful than 1962silently exiting.) 1963 1964=head1 Changed Internals 1965 1966The perl sources can now be compiled with a C++ compiler instead of a C 1967compiler. A necessary implementation details is that under C++, the macro 1968C<XS> used to define XSUBs now includes an C<extern "C"> definition. A side 1969effect of this is that B<C++> code that used the construction 1970 1971 typedef XS(SwigPerlWrapper); 1972 1973now needs to be written 1974 1975 typedef XSPROTO(SwigPerlWrapper); 1976 1977using the new C<XSPROTO> macro, in order to compile. C extensions are 1978unaffected, although C extensions are encouraged to use C<XSPROTO> too. 1979This change was present in the 5.10.0 release of perl, so any actively 1980maintained code that happened to use this construction should already have 1981been adapted. Code that needs changing will fail with a compilation error. 1982 1983C<set> magic on localizing/assigning to a magic variable will now only 1984trigger for I<container magics>, i.e. it will for C<%ENV> or C<%SIG> 1985but not for C<$#array>. 1986 1987The new API macro C<newSVpvs()> can be used in place of constructions such as 1988C<newSVpvn("ISA", 3)>. It takes a single string constant, and at C compile 1989time determines its length. 1990 1991The new API function C<Perl_newSV_type()> can be used as a more efficient 1992replacement of the common idiom 1993 1994 sv = newSV(0); 1995 sv_upgrade(sv, type); 1996 1997Similarly C<Perl_newSVpvn_flags()> can be used to combine 1998C<Perl_newSVpv()> with C<Perl_sv_2mortal()> or the equivalent 1999C<Perl_sv_newmortal()> with C<Perl_sv_setpvn()> 2000 2001Two new macros C<mPUSHs()> and C<mXPUSHs()> are added, to make it easier to 2002push mortal SVs onto the stack. They were then used to fix several bugs where 2003values on the stack had not been mortalised. 2004 2005A C<Perl_signbit()> function was added to test the sign of an C<NV>. It 2006maps to the system one when available. 2007 2008C<Perl_av_reify()>, C<Perl_lex_end()>, C<Perl_mod()>, C<Perl_op_clear()>, 2009C<Perl_pop_return()>, C<Perl_qerror()>, C<Perl_setdefout()>, 2010C<Perl_vivify_defelem()> and C<Perl_yylex()> are now visible to extensions. 2011This was required to allow C<Data::Alias> to work on Windows. 2012 2013C<Perl_find_runcv()> is now visible to perl core extensions. This was required 2014to allow C<Sub::Current> to work on Windows. 2015 2016C<ptr_table*> functions are now available in unthreaded perl. C<Storable> 2017takes advantage of this. 2018 2019There have been many small cleanups made to the internals. In particular, 2020C<Perl_sv_upgrade()> has been simplified considerably, with a straight-through 2021code path that uses C<memset()> and C<memcpy()> to initialise the new body, 2022rather than assignment via multiple temporary variables. It has also 2023benefited from simplification and de-duplication of the arena management 2024code. 2025 2026A lot of small improvements in the code base were made due to reports from 2027the Coverity static code analyzer. 2028 2029Corrected use and documentation of C<Perl_gv_stashpv()>, C<Perl_gv_stashpvn()>, 2030C<Perl_gv_stashsv()> functions (last parameter is a bitmask, not boolean). 2031 2032C<PERL_SYS_INIT>, C<PERL_SYS_INIT3> and C<PERL_SYS_TERM> macros have been 2033changed into functions. 2034 2035C<PERLSYS_TERM> no longer requires a context. C<PerlIO_teardown()> 2036is now called without a context, and debugging output in this function has 2037been disabled because that required that an interpreter was present, an invalid 2038assumption at termination time. 2039 2040All compile time options which affect binary compatibility have been grouped 2041together into a global variable (C<PL_bincompat_options>). 2042 2043The values of C<PERL_REVISION>, C<PERL_VERSION> and C<PERL_SUBVERSION> are 2044now baked into global variables (and hence into any shared perl library). 2045Additionally under C<MULTIPLICITY>, the perl executable now records the size of 2046the interpreter structure (total, and for this version). Coupled with 2047C<PL_bincompat_options> this will allow 5.8.10 (and later), when compiled with a 2048shared perl library, to perform sanity checks in C<main()> to verify that the 2049shared library is indeed binary compatible. 2050 2051Symbolic references can now have embedded NULs. The new public function 2052C<Perl_get_cvn_flags()> can be used in extensions if you have to handle them. 2053 2054=head2 Macro cleanups 2055 2056The core code, and XS code in F<ext> that is not dual-lived on CPAN, no longer 2057uses the macros C<PL_na>, C<NEWSV()>, C<Null()>, C<Nullav>, C<Nullcv>, 2058C<Nullhv>, C<Nullhv> I<etc>. Their use is discouraged in new code, 2059particularly C<PL_na>, which is a small performance hit. 2060 2061=head1 New Tests 2062 2063Many modules updated from CPAN incorporate new tests. Some core specific 2064tests have been added: 2065 2066=over 4 2067 2068=item ext/DynaLoader/t/DynaLoader.t 2069 2070Tests for the C<DynaLoader> module. 2071 2072=item t/comp/fold.t 2073 2074Tests for compile-time constant folding. 2075 2076=item t/io/pvbm.t 2077 2078Tests incorporated from 5.10.0 which check that there is no unexpected 2079interaction between the internal types C<PVBM> and C<PVGV>. 2080 2081=item t/lib/proxy_constant_subs.t 2082 2083Tests for the new form of constant subroutines. 2084 2085=item t/op/attrhand.t 2086 2087Tests for C<Attribute::Handlers>. 2088 2089=item t/op/dbm.t 2090 2091Tests for C<dbmopen>. 2092 2093=item t/op/inccode-tie.t 2094 2095Calls all tests in F<t/op/inccode.t> after first tying C<@INC>. 2096 2097=item t/op/incfilter.t 2098 2099Tests for source filters returned from code references in C<@INC>. 2100 2101=item t/op/kill0.t 2102 2103Tests for RT #30970. 2104 2105=item t/op/qrstack.t 2106 2107Tests for RT #41484. 2108 2109=item t/op/qr.t 2110 2111Tests for the C<qr//> construct. 2112 2113=item t/op/regexp_qr_embed.t 2114 2115Tests for the C<qr//> construct within another regexp. 2116 2117=item t/op/regexp_qr.t 2118 2119Tests for the C<qr//> construct. 2120 2121=item t/op/rxcode.t 2122 2123Tests for RT #32840. 2124 2125=item t/op/studytied.t 2126 2127Tests for C<study> on tied scalars. 2128 2129=item t/op/substT.t 2130 2131Tests for C<subst> run under C<-T> mode. 2132 2133=item t/op/symbolcache.t 2134 2135Tests for C<undef> and C<delete> on stash entries that are bound to 2136subroutines or methods. 2137 2138=item t/op/upgrade.t 2139 2140Tests for C<Perl_sv_upgrade()>. 2141 2142=item t/mro/package_aliases.t 2143 2144MRO tests for C<isa> and package aliases. 2145 2146=item t/pod/twice.t 2147 2148Tests for calling C<Pod::Parser> twice. 2149 2150=item t/run/cloexec.t 2151 2152Tests for inheriting file descriptors across C<exec> (close-on-exec). 2153 2154=item t/uni/cache.t 2155 2156Tests for the UTF-8 caching code. 2157 2158=item t/uni/chr.t 2159 2160Test that strange encodings do not upset C<Perl_pp_chr()>. 2161 2162=item t/uni/greek.t 2163 2164Tests for RT #40641. 2165 2166=item t/uni/latin2.t 2167 2168Tests for RT #40641. 2169 2170=item t/uni/overload.t 2171 2172Tests for returning Unicode from overloaded values. 2173 2174=item t/uni/tie.t 2175 2176Tests for returning Unicode from tied variables. 2177 2178=back 2179 2180=head1 Known Problems 2181 2182There are no known new bugs. 2183 2184However, programs that rely on bugs that have been fixed will have problems. 2185Also, many bug fixes present in 5.10.0 can't be back-ported to the 5.8.x 2186branch, because they require changes that are binary incompatible, or because 2187the code changes are too large and hence too risky to incorporate. 2188 2189We have only limited volunteer labour, and the maintenance burden is 2190getting increasingly complex. Hence this will be the last significant 2191release of the 5.8.x series. Any future releases of 5.8.x will likely 2192only be to deal with security issues, and platform build 2193failures. Hence you should look to migrating to 5.10.x, if you have 2194not started already. Alternatively, if business requirements constrain 2195you to continue to use 5.8.x, you may wish to consider commercial 2196support from firms such as ActiveState. 2197 2198=head1 Platform Specific Notes 2199 2200=head2 Win32 2201 2202C<readdir()>, C<cwd()>, C<$^X> and C<@INC> now use the alternate (short) 2203filename if the long name is outside the current codepage (Jan Dubois). 2204 2205=head3 Updated Modules 2206 2207=over 4 2208 2209=item * 2210 2211C<Win32> upgraded to version 0.38. Now has a documented 'WinVista' response 2212from C<GetOSName> and support for Vista's privilege elevation in C<IsAdminUser>. 2213Support for Unicode characters in path names. Improved cygwin and Win64 2214compatibility. 2215 2216=item * 2217 2218C<Win32API> updated to 0.1001_01 2219 2220=item * 2221 2222C<killpg()> support added to C<MSWin32> (Jan Dubois). 2223 2224=item * 2225 2226C<File::Spec::Win32> upgraded to version 3.2701 2227 2228=back 2229 2230=head2 OS/2 2231 2232=head3 Updated Modules 2233 2234=over 4 2235 2236=item * 2237 2238C<OS2::Process> upgraded to 1.03 2239 2240Ilya Zakharevich has added and documented several C<Window*> and C<Clipbrd*> 2241functions. 2242 2243=item * 2244 2245C<OS2::REXX::DLL>, C<OS2::REXX> updated to version 1.03 2246 2247=back 2248 2249=head2 VMS 2250 2251=head3 Updated Modules 2252 2253=over 4 2254 2255=item * 2256 2257C<DCLsym> upgraded to version 1.03 2258 2259=item * 2260 2261C<Stdio> upgraded to version 2.4 2262 2263=item * 2264 2265C<VMS::XSSymSet> upgraded to 1.1. 2266 2267=back 2268 2269=head1 Obituary 2270 2271Nick Ing-Simmons, long time Perl hacker, author of the C<Tk> and C<Encode> 2272modules, F<perlio.c> in the core, and 5.003_02 pumpking, died of a heart 2273attack on 25th September 2006. He will be missed. 2274 2275=head1 Acknowledgements 2276 2277Some of the work in this release was funded by a TPF grant. 2278 2279Steve Hay worked behind the scenes working out the causes of the differences 2280between core modules, their CPAN releases, and previous core releases, and 2281the best way to rectify them. He doesn't want to do it again. I know this 2282feeling, and I'm very glad he did it this time, instead of me. 2283 2284Paul Fenwick assembled a team of 18 volunteers, who broke the back of writing 2285this document. In particular, Bradley Dean, Eddy Tan, and Vincent Pit 2286provided half the team's contribution. 2287 2288Schwern verified the list of updated module versions, correcting quite a few 2289errors that I (and everyone else) had missed, both wrongly stated module 2290versions, and changed modules that had not been listed. 2291 2292The crack Berlin-based QA team of Andreas KE<ouml>nig and Slaven Rezic 2293tirelessly re-built snapshots, tested most everything CPAN against 2294them, and then identified the changes responsible for any module regressions, 2295ensuring that several show-stopper bugs were stomped before the first release 2296candidate was cut. 2297 2298The other core committers contributed most of the changes, and applied most 2299of the patches sent in by the hundreds of contributors listed in F<AUTHORS>. 2300 2301And obviously, Larry Wall, without whom we wouldn't have Perl. 2302 2303=head1 Reporting Bugs 2304 2305If you find what you think is a bug, you might check the articles 2306recently posted to the comp.lang.perl.misc newsgroup and the perl 2307bug database at http://bugs.perl.org. There may also be 2308information at http://www.perl.org, the Perl Home Page. 2309 2310If you believe you have an unreported bug, please run the B<perlbug> 2311program included with your release. Be sure to trim your bug down 2312to a tiny but sufficient test case. Your bug report, along with the 2313output of C<perl -V>, will be sent off to perlbug@perl.org to be 2314analysed by the Perl porting team. You can browse and search 2315the Perl 5 bugs at http://bugs.perl.org/ 2316 2317If the bug you are reporting has security implications, which make it 2318inappropriate to send to a publicly archived mailing list, then please send 2319it to perl5-security-report@perl.org. This points to a closed subscription 2320unarchived mailing list, which includes 2321all the core committers, who will be able 2322to help assess the impact of issues, figure out a resolution, and help 2323co-ordinate the release of patches to mitigate or fix the problem across all 2324platforms on which Perl is supported. Please only use this address for security 2325issues in the Perl core, not for modules independently distributed on CPAN. 2326 2327=head1 SEE ALSO 2328 2329The F<Changes> file for exhaustive details on what changed. 2330 2331The F<INSTALL> file for how to build Perl. 2332 2333The F<README> file for general stuff. 2334 2335The F<Artistic> and F<Copying> files for copyright information. 2336 2337=cut 2338