69a39109639681e64b33e8e240c11026ee5bc75e
[p5sagit/p5-mst-13.2.git] / pod / perl571delta.pod
1 =head1 NAME
2
3 perl571delta - what's new for perl v5.7.1
4
5 =head1 DESCRIPTION
6
7 This document describes differences between the 5.7.0 release and the
8 5.7.1 release.  
9
10 (To view the differences between the 5.6.0 release and the 5.7.0
11 release, see L<perl570delta>).
12
13 =head1 Security Vulnerability Closed
14
15 (This change was already made in 5.7.0 but bears repeating here.)
16
17 A potential security vulnerability in the optional suidperl component
18 of Perl was identified in August 2000.  suidperl is neither built nor
19 installed by default.  As of April 2001 the only known vulnerable
20 platform is Linux, most likely all Linux distributions.  CERT and
21 various vendors and distributors have been alerted about the vulnerability.
22 See http://www.cpan.org/src/5.0/sperl-2000-08-05/sperl-2000-08-05.txt
23 for more information.
24
25 The problem was caused by Perl trying to report a suspected security
26 exploit attempt using an external program, /bin/mail.  On Linux
27 platforms the /bin/mail program had an undocumented feature which
28 when combined with suidperl gave access to a root shell, resulting in
29 a serious compromise instead of reporting the exploit attempt.  If you
30 don't have /bin/mail, or if you have 'safe setuid scripts', or if
31 suidperl is not installed, you are safe.
32
33 The exploit attempt reporting feature has been completely removed from
34 all the Perl 5.7 releases (and will be gone also from the maintenance
35 release 5.6.1), so that particular vulnerability isn't there anymore.
36 However, further security vulnerabilities are, unfortunately, always
37 possible.  The suidperl code is being reviewed and if deemed too risky
38 to continue to be supported, it may be completely removed from future
39 releases.  In any case, suidperl should only be used by security
40 experts who know exactly what they are doing and why they are using
41 suidperl instead of some other solution such as sudo (see
42 http://www.courtesan.com/sudo/).
43
44 =head1 Incompatible Changes
45
46 =over 4
47
48 =item *
49
50 Although "you shouldn't do that", it was possible to write code that
51 depends on Perl's hashed key order (Data::Dumper does this).  The new
52 algorithm "One-at-a-Time" produces a different hashed key order.
53 More details are in L</"Performance Enhancements">.
54
55 =item *
56
57 The list of filenames from glob() (or <...>) is now by default sorted
58 alphabetically to be csh-compliant.  (bsd_glob() does still sort platform
59 natively, ASCII or EBCDIC, unless GLOB_ALPHASORT is specified.)
60
61 =back
62
63 =head1 Core Enhancements
64
65 =over 4
66
67 =item *
68
69 AUTOLOAD is now lvaluable, meaning that you can add the :lvalue attribute
70 to AUTOLOAD subroutines and you can assign to the AUTOLOAD return value.
71
72 =item *
73
74 IO is now by default done via PerlIO rather than system's "stdio".
75 PerlIO allows "layers" to be "pushed" onto a file handle to alter the
76 handle's behaviour.  Layers can be specified at open time via 3-arg
77 form of open:
78
79    open($fh,'>:crlf :utf8', $path) || ...
80
81 or on already opened handles via extended C<binmode>:
82
83    binmode($fh,':encoding(iso-8859-7)');
84
85 The built-in layers are: unix (low level read/write), stdio (as in
86 previous Perls), perlio (re-implementation of stdio buffering in a
87 portable manner), crlf (does CRLF <=> "\n" translation as on Win32,
88 but available on any platform).  A mmap layer may be available if
89 platform supports it (mostly UNIXes).
90
91 Layers to be applied by default may be specified via the 'open' pragma.
92
93 See L</"Installation and Configuration Improvements"> for the effects
94 of PerlIO on your architecture name.
95
96 =item *
97
98 File handles can be marked as accepting Perl's internal encoding of Unicode
99 (UTF-8 or UTF-EBCDIC depending on platform) by a pseudo layer ":utf8" :
100
101    open($fh,">:utf8","Uni.txt");
102
103 Note for EBCDIC users: the pseudo layer ":utf8" is badly named for you
104 since it's not UTF-8 what you will be getting but instead UTF-EBCDIC.
105 See http://www.unicode.org/unicode/reports/tr16/ for more information.
106 In future release this naming issue may or may not change.
107
108 =item *
109
110 File handles can translate character encodings from/to Perl's internal
111 Unicode form on read/write via the ":encoding()" layer.
112
113 =item *
114
115 File handles can be opened to "in memory" files held in Perl scalars via:
116
117    open($fh,'>', \$variable) || ...
118
119 =item *
120
121 Anonymous temporary files are available without need to
122 'use FileHandle' or other module via
123
124    open($fh,"+>", undef) || ...
125
126 That is a literal undef, not an undefined value.
127
128 =item *
129
130 The list form of C<open> is now implemented for pipes (at least on UNIX):
131
132    open($fh,"-|", 'cat', '/etc/motd')
133
134 creates a pipe, and runs the equivalent of exec('cat', '/etc/motd') in
135 the child process.
136
137 =item *
138
139 The following builtin functions are now overridable: chop(), chomp(),
140 each(), keys(), pop(), push(), shift(), splice(), unshift().
141
142 =item *
143
144 Formats now support zero-padded decimal fields.
145
146 =item *
147
148 Perl now tries internally to use integer values in numeric conversions
149 and basic arithmetics (+ - * /) if the arguments are integers, and
150 tries also to keep the results stored internally as integers.
151 This change leads into often slightly faster and always less lossy
152 arithmetics (previously Perl always preferred floating point numbers
153 in its math)
154
155 =item *
156
157 The printf() and sprintf() now support parameter reordering using the
158 C<%\d+\$> and C<*\d+\$> syntaxes.  For example
159
160     print "%2\$s %1\$s\n", "foo", "bar";
161
162 will print "bar foo\n"; This feature helps in writing
163 internationalised software.
164
165 =item *
166
167 Unicode in general should be now much more usable.  Unicode can be
168 used in hash keys, Unicode in regular expressions should work now,
169 Unicode in tr/// should work now (though tr/// seems to be a
170 particularly tricky to get right, so you have been warned)
171
172 =item *
173
174 The Unicode Character Database coming with Perl has been upgraded
175 to Unicode 3.1.  For more information, see http://www.unicode.org/,
176 and http://www.unicode.org/unicode/reports/tr27/
177
178 For developers interested in enhancing Perl's Unicode capabilities:
179 almost all the UCD files are included with the Perl distribution in
180 the lib/unicode subdirectory.  The most notable omission, for space
181 considerations, is the Unihan database.
182
183 =item *
184
185 The Unicode character classes \p{Blank} and \p{SpacePerl} have been
186 added.  "Blank" is like C isblank(), that is, it contains only
187 "horizontal whitespace" (the space character is, the newline isn't),
188 and the "SpacePerl" is the Unicode equivalent of C<\s> (\p{Space}
189 isn't, since that includes the vertical tabulator character, whereas
190 C<\s> doesn't.)
191
192 =back
193
194 =head1 Modules and Pragmata
195
196 =head2 New Modules
197
198 =over 4
199
200 =item *
201
202 B::Concise, from Stephen McCamant, is a new compiler backend for
203 walking the Perl syntax tree, printing concise info about ops.
204 The output is highly customisable.
205
206 See L<B::Concise> for more information.
207
208 =item *
209
210 Class::ISA for reporting the search path for a class's ISA tree,
211 from Sean Burke, has been added.
212
213 See L<Class::ISA> for more information.
214
215 =item *
216
217 Cwd has now a split personality: if possible, an extension is used,
218 (this will hopefully be both faster and more secure and robust) but
219 if not possible, the familiar Perl library implementation is used.
220
221 =item *
222
223 Digest, a frontend module for calculating digests (checksums),
224 from Gisle Aas, has been added.
225
226 See L<Digest> for more information.
227
228 =item *
229
230 Digest::MD5 for calculating MD5 digests (checksums), from Gisle Aas,
231 has been added.
232
233     use Digest::MD5 'md5_hex';
234
235     $digest = md5_hex("Thirsty Camel");
236
237     print $digest, "\n"; # 01d19d9d2045e005c3f1b80e8b164de1
238
239 NOTE: the MD5 backward compatibility module is purposefully not
240 included since its use is discouraged.
241
242 See L<Digest::MD5> for more information.
243
244 =item *
245
246 Encode, from Nick Ing-Simmons, provides a mechanism to translate
247 between different character encodings.  Support for Unicode,
248 ISO-8859-*, ASCII, CP*, KOI8-R, and three variants of EBCDIC are
249 compiled in to the module.  Several other encodings (like Japanese,
250 Chinese, and MacIntosh encodings) are included and will be loaded at
251 runtime.
252
253 Any encoding supported by Encode module is also available to the
254 ":encoding()" layer if PerlIO is used.
255
256 See L<Encode> for more information.
257
258 =item *
259
260 Filter::Simple is an easy-to-use frontend to Filter::Util::Call,
261 from Damian Conway.
262
263     # in MyFilter.pm:
264
265     package MyFilter;
266
267     use Filter::Simple sub {
268         while (my ($from, $to) = splice @_, 0, 2) {
269                 s/$from/$to/g;
270         }
271     };
272
273     1;
274
275     # in user's code:
276
277     use MyFilter qr/red/ => 'green';
278
279     print "red\n";   # this code is filtered, will print "green\n"
280     print "bored\n"; # this code is filtered, will print "bogreen\n"
281
282     no MyFilter;
283
284     print "red\n";   # this code is not filtered, will print "red\n"
285
286 See L<Filter::Simple> for more information.
287
288 =item *
289
290 Filter::Util::Call, from Paul Marquess, provides you with the
291 framework to write I<Source Filters> in Perl.  For most uses
292 the frontend Filter::Simple is to be preferred.
293 See L<Filter::Util::Call> for more information.
294
295 =item *
296
297 Locale::Constants, Locale::Country, Locale::Currency, and Locale::Language,
298 from Neil Bowers, have been added.  They provide the codes for various
299 locale standards, such as "fr" for France, "usd" for US Dollar, and
300 "jp" for Japanese.
301
302     use Locale::Country;
303
304     $country = code2country('jp');               # $country gets 'Japan'
305     $code    = country2code('Norway');           # $code gets 'no'
306
307 See L<Locale::Constants>, L<Locale::Country>, L<Locale::Currency>,
308 and L<Locale::Language> for more information.
309
310 =item *
311
312 MIME::Base64, from Gisle Aas, allows you to encode data in base64.
313
314     use MIME::Base64;
315
316     $encoded = encode_base64('Aladdin:open sesame');
317     $decoded = decode_base64($encoded);
318
319     print $encoded, "\n"; # "QWxhZGRpbjpvcGVuIHNlc2FtZQ=="
320
321 See L<MIME::Base64> for more information.
322
323 =item *
324
325 MIME::QuotedPrint, from Gisle Aas, allows you to encode data in
326 quoted-printable encoding.
327
328     use MIME::QuotedPrint;
329
330     $encoded = encode_qp("Smiley in Unicode: \x{263a}");
331     $decoded = decode_qp($encoded);
332
333     print $encoded, "\n"; # "Smiley in Unicode: =263A"
334
335 MIME::QuotedPrint has been enhanced to provide the basic methods
336 necessary to use it with PerlIO::Via as in :
337
338     use MIME::QuotedPrint;
339     open($fh,">Via(MIME::QuotedPrint)",$path)
340
341 See L<MIME::QuotedPrint> for more information.
342
343 =item *
344
345 PerlIO::Scalar, from Nick Ing-Simmons, provides the implementation of
346 IO to "in memory" Perl scalars as discussed above.  It also serves as
347 an example of a loadable layer.  Other future possibilities include
348 PerlIO::Array and PerlIO::Code.  See L<PerlIO::Scalar> for more
349 information.
350
351 =item *
352
353 PerlIO::Via, from Nick Ing-Simmons, acts as a PerlIO layer and wraps
354 PerlIO layer functionality provided by a class (typically implemented
355 in perl code).
356
357     use MIME::QuotedPrint;
358     open($fh,">Via(MIME::QuotedPrint)",$path)
359
360 This will automatically convert everything output to C<$fh>
361 to Quoted-Printable.  See L<PerlIO::Via> for more information.
362
363 =item *
364
365 Pod::Text::Overstrike, from Joe Smith, has been added.
366 It converts POD data to formatted overstrike text.
367 See L<Pod::Text::Overstrike> for more information.
368
369 =item *
370
371 Switch from Damian Conway has been added.  Just by saying
372
373     use Switch;
374
375 you have C<switch> and C<case> available in Perl.
376
377     use Switch;
378
379     switch ($val) {
380
381                 case 1          { print "number 1" }
382                 case "a"        { print "string a" }
383                 case [1..10,42] { print "number in list" }
384                 case (@array)   { print "number in list" }
385                 case /\w+/      { print "pattern" }
386                 case qr/\w+/    { print "pattern" }
387                 case (%hash)    { print "entry in hash" }
388                 case (\%hash)   { print "entry in hash" }
389                 case (\&sub)    { print "arg to subroutine" }
390                 else            { print "previous case not true" }
391     }
392
393 See L<Switch> for more information.
394
395 =item *
396
397 Text::Balanced from Damian Conway has been added, for
398 extracting delimited text sequences from strings.
399
400     use Text::Balanced 'extract_delimited';
401
402     ($a, $b) = extract_delimited("'never say never', he never said", "'", '');
403
404 C<$a> will be "'never say never'", C<$b> will be ', he never said'.
405
406 In addition to extract_delimited() there are also extract_bracketed(),
407 extract_quotelike(), extract_codeblock(), extract_variable(),
408 extract_tagged(), extract_multiple(), gen_delimited_pat(), and
409 gen_extract_tagged().  See L<Text::Balanced> for more information.
410
411 =item *
412
413 Tie::RefHash::Nestable, from Edward Avis, allows storing hash references
414 (unlike the standard Tie::Refhash)  The module is contained within
415 Tie::RefHash.
416
417 =item *
418
419 XS::Typemap is a test extension that exercises XS typemaps.
420 Nothing gets installed but for extension writers the code is
421 worth studying.
422
423 =back
424
425 =head2 Updated And Improved Modules and Pragmata
426
427 =over 4
428
429 =item *
430
431 B::Deparse should be now more robust.  It still far from providing a full
432 round trip for any random piece of Perl code, though, and is under active
433 development: expect more robustness in 5.7.2.
434
435 =item *
436
437 Class::Struct can now define the classes in compile time.
438
439 =item *
440
441 Math::BigFloat has undergone much fixing, and in addition the fmod()
442 function now supports modulus operations.
443
444 (The fixed Math::BigFloat module is also available in CPAN for those
445 who can't upgrade their Perl: http://www.cpan.org/authors/id/J/JP/JPEACOCK/)
446
447 =item *
448
449 Devel::Peek now has an interface for the Perl memory statistics
450 (this works only if you are using perl's malloc, and if you have
451 compiled with debugging).
452
453 =item *
454
455 IO::Socket has now atmark() method, which returns true if the socket
456 is positioned at the out-of-band mark.  The method is also exportable
457 as a sockatmark() function.
458
459 =item *
460
461 IO::Socket::INET has support for ReusePort option (if your platform
462 supports it).  The Reuse option now has an alias, ReuseAddr.  For clarity
463 you may want to prefer ReuseAddr.
464
465 =item *
466
467 Net::Ping has been enhanced.  There is now "external" protocol which
468 uses Net::Ping::External module which runs external ping(1) and parses
469 the output.  An alpha version of Net::Ping::External is available in
470 CPAN and in 5.7.2 the Net::Ping::External may be integrated to Perl.
471
472 =item *
473
474 The C<open> pragma allows layers other than ":raw" and ":crlf" when
475 using PerlIO.
476
477 =item *
478
479 POSIX::sigaction() is now much more flexible and robust.
480 You can now install coderef handlers, 'DEFAULT', and 'IGNORE'
481 handlers, installing new handlers was not atomic.
482
483 =item *
484
485 The Test module has been significantly enhanced.  Its use is
486 greatly recommended for module writers.
487
488 =item *
489
490 The utf8:: name space (as in the pragma) provides various
491 Perl-callable functions to provide low level access to Perl's
492 internal Unicode representation.  At the moment only length()
493 has been implemented.
494
495 =back
496
497 The following modules have been upgraded from the versions at CPAN:
498 CPAN, CGI, DB::File, File::Temp, Getopt::Long, Pod::Man, Pod::Text,
499 Storable, Text-Tabs+Wrap.
500
501 =head1 Performance Enhancements
502
503 =over 4
504
505 =item *
506
507 Hashes now use Bob Jenkins "One-at-a-Time" hashing key algorithm
508 (http://burtleburtle.net/bob/hash/doobs.html).
509 This algorithm is reasonably fast while producing a much better spread
510 of values.  Hash values output from the algorithm on a hash of all
511 3-char printable ASCII keys comes much closer to passing the DIEHARD
512 random number generation tests.  According to perlbench, this change
513 has not affected the overall speed of Perl.
514
515 =item *
516
517 unshift() should now be noticeably faster.
518
519 =back
520
521 =head1 Utility Changes
522
523 =over 4
524
525 =item *
526
527 h2xs now produces template README.
528
529 =item *
530
531 s2p has been completely rewritten in Perl.  (It is in fact a full
532 implementation of sed in Perl.)
533
534 =item *
535
536 xsubpp now supports OUT keyword.
537
538 =back
539
540 =head1 New Documentation
541
542 =head2 perlclib
543
544 Internal replacements for standard C library functions.
545 (Interesting only for extension writers and Perl core hackers.)
546
547 =head2 perliol
548
549 Internals of PerlIO with layers.
550
551 =head2 README.aix
552
553 Documentation on compiling Perl on AIX has been added.  AIX has
554 several different C compilers and getting the right patch level
555 is essential.  On install README.aix will be installed as L<perlaix>.
556
557 =head2 README.bs2000
558
559 Documentation on compiling Perl on the POSIX-BC platform (an EBCDIC
560 mainframe environment) has been added.
561
562 This was formerly known as README.posix-bc but the name was considered
563 to be too confusing (it has nothing to do with the POSIX module or the
564 POSIX standard).  On install README.bs2000 will be installed as L<perlbs2000>.
565
566 =head2 README.macos
567
568 In perl 5.7.1 (and in the 5.6.1) the MacPerl sources have been
569 synchronised with the standard Perl sources.  To compile MacPerl
570 some additional steps are required, and this file documents those
571 steps.  On install README.macos will be installed as L<perlmacos>.
572
573 =head2 README.mpeix
574
575 The README.mpeix has been podified, which means that this information
576 about compiling and using Perl on the MPE/iX miniframe platform will
577 be installed as L<perlmpeix>.
578
579 =head2 README.solaris
580
581 README.solaris has been created and Solaris wisdom from elsewhere
582 in the Perl documentation has been collected there.  On install
583 README.solaris will be installed as L<perlsolaris>.
584
585 =head2 README.vos
586
587 The README.vos has been podified, which means that this information
588 about compiling and using Perl on the Stratus VOS miniframe platform
589 will be installed as L<perlvos>.
590
591 =head2 Porting/repository.pod
592
593 Documentation on how to use the Perl source repository has been added.
594
595 =head1 Installation and Configuration Improvements
596
597 =over 4
598
599 =item *
600
601 Because PerlIO is now the default on most platforms, "-perlio" doesn't
602 get appended to the $Config{archname} (also known as $^O) anymore.
603 Instead, if you explicitly choose not to use perlio (Configure command
604 line option -Uuseperlio), you will get "-stdio" appended.
605
606 =item *
607
608 Another change related to the architecture name is that "-64all"
609 (-Duse64bitall, or "maximally 64-bit") is appended only if your
610 pointers are 64 bits wide.  (To be exact, the use64bitall is ignored.)
611
612 =item *
613
614 APPLLIB_EXP, a less-know configuration-time definition, has been
615 documented.  It can be used to prepend site-specific directories
616 to Perl's default search path (@INC), see INSTALL for information.
617
618 =item *
619
620 Building Berkeley DB3 for compatibility modes for DB, NDBM, and ODBM
621 has been documented in INSTALL.
622
623 =item *
624
625 If you are on IRIX or Tru64 platforms, new profiling/debugging options
626 have been added, see L<perlhack> for more information about pixie and
627 Third Degree.
628
629 =back
630
631 =head2 New Or Improved Platforms
632
633 For the list of platforms known to support Perl,
634 see L<perlport/"Supported Platforms">.
635
636 =over 4
637
638 =item *
639
640 AIX dynamic loading should be now better supported.
641
642 =item *
643
644 After a long pause, AmigaOS has been verified to be happy with Perl.
645
646 =item *
647
648 EBCDIC platforms (z/OS, also known as OS/390, POSIX-BC, and VM/ESA)
649 have been regained.  Many test suite tests still fail and the
650 co-existence of Unicode and EBCDIC isn't quite settled, but the
651 situation is much better than with Perl 5.6.  See L<perlos390>,
652 L<perlbs2000> (for POSIX-BC), and L<perlvmesa> for more information.
653
654 =item *
655
656 In HP-UX 10.20 Perl threading is now working with the various threading
657 packages available for HP-UX.  See L<perlhpux> (or in the source
658 distribution, README.hpux) for more information.
659
660 =item *
661
662 MacOS Classic (MacPerl has of course been available since
663 perl 5.004 but now the source code bases of standard Perl
664 and MacPerl have been synchronised)
665
666 =item *
667
668 NCR MP-RAS is now supported.
669
670 =item *
671
672 NonStop-UX is now supported.
673
674 =item *
675
676 Amdahl UTS is now supported.
677
678 =item *
679
680 z/OS (formerly known as OS/390, formerly known as MVS OE) has now
681 support for dynamic loading.  This is not selected by default,
682 however, you must specify -Dusedl in the arguments of Configure.
683
684 =back
685
686 =head2 Generic Improvements
687
688 =over 4
689
690 =item *
691
692 Configure no longer includes the DBM libraries (dbm, gdbm, db, ndbm)
693 when building the Perl binary.  The only exception to this is SunOS 4.x,
694 which needs them.
695
696 =item *
697
698 Some new Configure symbols, useful for extension writers:
699
700 =over 8
701
702 =item d_cmsghdr
703
704 For struct cmsghdr.
705
706 =item d_fcntl_can_lock
707
708 Whether fcntl() can be used for file locking.
709
710 =item d_fsync
711
712 =item d_getitimer
713
714 =item d_getpagsz
715
716 For getpagesize(), though you should prefer POSIX::sysconf(_SC_PAGE_SIZE))
717
718 =item d_msghdr_s
719
720 For struct msghdr.
721
722 =item need_va_copy
723
724 Whether one needs to use Perl_va_copy() to copy varargs.
725
726 =item d_readv
727
728 =item d_recvmsg
729
730 =item d_sendmsg
731
732 =item sig_size
733
734 The number of elements in an array needed to hold all the available signals.
735
736 =item d_sockatmark
737
738 =item d_strtoq
739
740 =item d_u32align
741
742 Whether one needs to access character data aligned by U32 sized pointers.
743
744 =item d_ualarm
745
746 =item d_usleep
747
748 =back
749
750 =item *
751
752 Removed Configure symbols: the PDP-11 memory model settings: huge,
753 large, medium, models.
754
755 =item *
756
757 SOCKS support is now much more robust.
758
759 =item *
760
761 If your file system supports symbolic links you can build Perl outside
762 of the source directory by
763
764         mkdir /tmp/perl/build/directory
765         cd /tmp/perl/build/directory
766         sh /path/to/perl/source/Configure -Dmksymlinks ...
767
768 This will create in /tmp/perl/build/directory a tree of symbolic links
769 pointing to files in /path/to/perl/source.  The original files are left
770 unaffected.  After Configure has finished you can just say
771
772         make all test
773
774 and Perl will be built and tested, all in /tmp/perl/build/directory.
775
776 =back
777
778 =head1 Selected Bug Fixes
779
780 Numerous memory leaks and uninitialized memory leaks have been hunted down.
781 Most importantly anonymous subs used to leak quite a bit.
782
783 =over 4
784
785 =item *
786
787 chop(@list) in list context returned the characters chopped in reverse
788 order.  This has been reversed to be in the right order.
789
790 =item *
791
792 The order of DESTROYS has been made more predictable.
793
794 =item *
795
796 mkdir() now ignores trailing slashes in the directory name,
797 as mandated by POSIX.
798
799 =item *
800
801 Attributes (like :shared) didn't work with our().
802
803 =item *
804
805 The PERL5OPT environment variable (for passing command line arguments
806 to Perl) didn't work for more than a single group of options.
807
808 =item *
809
810 The tainting behaviour of sprintf() has been rationalized.  It does
811 not taint the result of floating point formats anymore, making the
812 behaviour consistent with that of string interpolation.
813
814 =item *
815
816 All but the first argument of the IO syswrite() method are now optional.
817
818 =item *
819
820 Tie::ARRAY SPLICE method was broken.
821
822 =item *
823
824 vec() now tries to work with characters <= 255 when possible, but it leaves
825 higher character values in place.  In that case, if vec() was used to modify
826 the string, it is no longer considered to be utf8-encoded.
827
828 =back
829
830 =head2 Platform Specific Changes and Fixes
831
832 =over 4
833
834 =item *
835
836 Linux previously had problems related to sockaddrlen when using
837 accept(), revcfrom() (in Perl: recv()), getpeername(), and getsockname().
838
839 =item *
840
841 Previously DYNIX/ptx had problems in its Configure probe for non-blocking I/O.
842
843 =item *
844
845 Windows
846
847 =over 8
848
849 =item *
850
851 Borland C++ v5.5 is now a supported compiler that can build Perl.
852 However, the generated binaries continue to be incompatible with those
853 generated by the other supported compilers (GCC and Visual C++).
854
855 =item *
856
857 Win32::GetCwd() correctly returns C:\ instead of C: when at the drive root.
858 Other bugs in chdir() and Cwd::cwd() have also been fixed.
859
860 =item *
861
862 Duping socket handles with open(F, ">&MYSOCK") now works under Windows 9x.
863
864 =item *
865
866 The makefiles now provide a single switch to bulk-enable all the features
867 enabled in ActiveState ActivePerl (a popular binary distribution).
868
869 =back
870
871 =back
872
873 =head1 New or Changed Diagnostics
874
875 Two new debugging options have been added: if you have compiled your
876 Perl with debugging, you can use the -DT and -DR options to trace
877 tokenising and to add reference counts to displaying variables,
878 respectively.
879
880 =over 4
881
882 =item *
883
884 If an attempt to use a (non-blessed) reference as an array element
885 is made, a warning is given.
886
887 =item *
888
889 C<push @a;> and C<unshift @a;> (with no values to push or unshift)
890 now give a warning.  This may be a problem for generated and evaled
891 code.
892
893 =back
894
895 =head1 Changed Internals
896
897 =over 4
898
899 =item *
900
901 Some new APIs: ptr_table_clear(), ptr_table_free(), sv_setref_uv().
902 For the full list of the available APIs see L<perlapi>.
903
904 =item *
905
906 dTHR and djSP have been obsoleted; the former removed (because it's
907 a no-op) and the latter replaced with dSP.
908
909 =item *
910
911 Perl now uses system malloc instead of Perl malloc in all 64-bit
912 platforms, and even in some not-always-64-bit platforms like AIX,
913 IRIX, and Solaris.  This change breaks backward compatibility but
914 Perl's malloc has problems with large address spaces and also the
915 speed of vendors' malloc is generally better in large address space
916 machines (Perl's malloc is mostly tuned for space).
917
918 =back
919
920 =head1 Known Problems
921
922 Notice that this list doesn't contain problems that were present in
923 5.7.0 and still are there, see L<perl570delta> for those.
924
925 =head2 lib/b test 19
926
927 The test fails in various platforms (PA64 and IA64 are known), but the
928 exact cause is still being investigated.
929
930 =head2 Localising a Tied Variable Leaks Memory
931
932     use Tie::Hash;
933     tie my %tie_hash => 'Tie::StdHash';
934
935     ...
936
937     local($tie_hash{Foo}) = 1; # leaks
938
939 Code like the above is known to leak memory every time the local()
940 is executed.
941
942 =head2 sigaction test 13 in VMS
943
944 The test is known to fail, whether it's because of VMS of because
945 of faulty test, is not known.
946
947 =head2 sprintf tests 129 and 130
948
949 The op/sprintf tests 129 and 130 are known to fail in some platforms.
950 Examples include any platform using sfio, and Tandem's NonStop-UX.
951 The failing platforms do not comply with the ANSI C Standard, line
952 19ff on page 134 of ANSI X3.159 1989 to be exact.  (They produce
953 something else than "1" and "-1" when formatting 0.6 and -0.6 using
954 the printf format "%.0f", most often they produce "0" and "-0".)
955
956 =head2 Self-tying of Arrays and Hashes Is Forbidden
957
958 Self-tying of arrays and hashes is broken in rather deep and
959 hard-to-fix ways.  As a stop-gap measure to avoid people from getting
960 frustrated at the mysterious results (core dumps, most often) it is
961 for now forbidden (you will get a fatal error even from an attempt).
962
963 =head1 Reporting Bugs
964
965 If you find what you think is a bug, you might check the articles
966 recently posted to the comp.lang.perl.misc newsgroup and the perl
967 bug database at http://bugs.perl.org.  There may also be
968 information at http://www.perl.com/perl/, the Perl Home Page.
969
970 If you believe you have an unreported bug, please run the B<perlbug>
971 program included with your release.  Be sure to trim your bug down
972 to a tiny but sufficient test case.  Your bug report, along with the
973 output of C<perl -V>, will be sent off to perlbug@perl.org to be
974 analysed by the Perl porting team.
975
976 =head1 SEE ALSO
977
978 The F<Changes> file for exhaustive details on what changed.
979
980 The F<INSTALL> file for how to build Perl.
981
982 The F<README> file for general stuff.
983
984 The F<Artistic> and F<Copying> files for copyright information.
985
986 =head1 HISTORY
987
988 Written by Jarkko Hietaniemi <F<jhi@iki.fi>>, with many contributions
989 from The Perl Porters and Perl Users submitting feedback and patches.
990
991 Send omissions or corrections to <F<perlbug@perl.org>>.
992
993 =cut