From: Rafael Garcia-Suarez Date: Fri, 12 Mar 2004 21:35:49 +0000 (+0000) Subject: Update perl591delta. Include a small to-do list in it. X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=3c1c0f694fdfa5db91a2d11b9623a4bcfb0f52ab;p=p5sagit%2Fp5-mst-13.2.git Update perl591delta. Include a small to-do list in it. p4raw-id: //depot/perl@22492 --- diff --git a/pod/perl591delta.pod b/pod/perl591delta.pod index df76f58..a120c31 100644 --- a/pod/perl591delta.pod +++ b/pod/perl591delta.pod @@ -10,6 +10,19 @@ the 5.9.1 release. See L for the differences between =head1 Incompatible Changes +=head2 substr() lvalues are no longer fixed-length + +The lvalues returned by the three argument form of substr() used to be a +"fixed length window" on the original string. In some cases this could +cause surprising action at distance or other undefined behaviour. Now the +length of the window adjusts iself to the length of the string assigned to +it. + +=head2 The C<:unique> attribute is only meaningful for globals + +Now applying C<:unique> to lexical variables and to subroutines will +result in a compilation error. + =head1 Core Enhancements =head2 Lexical C<$_> @@ -53,11 +66,6 @@ correctly in picture lines. Using C<@#> and C<~~> together will now produce a compile-time error, as those format fields are incompatible. L has been improved, and miscellaneous bugs fixed. -=head2 The C<:unique> attribute is only meaningful for globals - -Now applying C<:unique> to lexical variables and to subroutines will -result in a compilation error. - =head2 Stacked filetest operators As a new form of syntactic sugar, it's now possible to stack up filetest @@ -119,29 +127,36 @@ The documentation has been revised in places to produce more standard manpages. The long-existing feature of C regexps setting C<$_> and pos() is now documented. +Sorting arrays in place (C<@a = sort @a>) is now optimized to avoid +making a temporary copy of the array. + =head1 Performance Enhancements The operations involving case mapping on UTF-8 strings (uc(), lc(), C, etc.) have been greatly speeded up. -=head1 Installation and Configuration Improvements +Access to elements of lexical arrays via a numeric constant between 0 and +255 is now faster. (This used to be only the case for global arrays.) =head1 Selected Bug Fixes -=head2 UTF8 bugs +=head2 UTF-8 bugs -Using substr() on a UTF8 string could cause subsequent accesses on that -string to return garbage. This was due to incorrect UTF8 offsets being +Using substr() on a UTF-8 string could cause subsequent accesses on that +string to return garbage. This was due to incorrect UTF-8 offsets being cached, and is now fixed. join() could return garbage when the same join() statement was used to -process 8 bit data having earlier processed UTF8 data, due to the flags +process 8 bit data having earlier processed UTF-8 data, due to the flags on that statement's temporary workspace not being reset correctly. This is now fixed. Using Unicode keys with tied hashes should now work correctly. -chop() and chomp() used to mangle UTF8 strings. This has been fixed. +chop() and chomp() used to mangle UTF-8 strings. This has been fixed. + +sprintf() used to misbehave when the format string was in UTF-8. This is +now fixed. =head2 Threading bugs @@ -150,7 +165,7 @@ threads. They are now. =head2 More bugs -C<$a .. $b> will now work as expected when either $a or $b is C +C<$a .. $b> will now work as expected when either $a or $b is C. Reading $^E now preserves $!. Previously, the C code implementing $^E did not preserve C, so reading $^E could cause C and therefore @@ -171,11 +186,11 @@ construct See L. -The fatal error "DESTROY created new reference to dead object" is now +The fatal error I is now documented in L. -A new error, "%ENV is aliased to %s", is produced when taint checks are -enabled and when *ENV has been aliased (and thus doesn't reflect the +A new error, I<%ENV is aliased to %s>, is produced when taint checks are +enabled and when C<*ENV> has been aliased (and thus doesn't reflect the program's environment anymore.) =head1 Changed Internals @@ -208,6 +223,11 @@ removed and replaced by two one-bit fields, C and C. C is now 9 bits long. (Consequently, the C class doesn't provide an C method anymore.) +=head2 New parser + +perl's parser is now generated by bison (it used to be generated by +byacc.) As a result, it seems to be a bit more robust. + =head1 Configuration and Building C now invokes callbacks regardless of the value of the variable @@ -215,11 +235,66 @@ they are called for. Previously callbacks were only invoked in the C branch. This change should only affect platform maintainers writing configuration hints files. -=head1 New Tests +The portability and clealiness of the Win32 makefiles has been improved. =head1 Known Problems -=head1 Platform Specific Problems +There are still a couple of problems in the implementation of the lexical +C<$_>: it doesn't work inside C blocks and with regard to the +reverse() built-in used without arguments. (See the TODO tests in +F.) + +=head2 Platform Specific Problems + +The test F may fail on OpenBSD. This hasn't been +diagnosed yet. + +On some configurations on AIX 5, one test in F fails. +When configured with long doubles, perl may fail tests 224-236 in +F on the same platform. + +=head1 To-do for perl 5.10.0 + +This is a non-exhaustive, non-ordered, non-contractual and non-definitive +list of things to do (or nice to have) for perl 5.10.0 : + +Clean up and finish support for assertions. See L. + +Reimplement the mechanism of lexical pragmas to be more extensible. Fix +current pragmas that don't work well with lexical scopes (C, for +example). MJD has ideas on this. + +Conversions from byte strings to UTF-8 currently map high bit characters +to Unicode without translation (or, depending on how you look at it, by +implicitly assuming the byte strings are in Latin-1). This is wrong, +because perl assumes the C locale by default. Thus upgrading a string to +UTF-8 (esp. in place) may change the meaning of its contents regarding +character classes, case mapping, etc. Try to find a way to fix it without +breaking all the legacy code out there (and without making the life of the +XS coders miserable.) + +Introduce a new special block, UNITCHECK, which is run at the end of a +compilation unit (module, file, eval(STRING) block). This will correspond to +the Perl 6 CHECK. Perl 5's CHECK cannot be changed or removed because the +O/B framework depends on it. + +Study the possibility of adding a new prototype character, C<_>, meaning +"this argument defaults to $_". + +Make the peephole optimizer optional. + +Allow lexical aliases (maybe via the syntax C. + +Fix the bugs revealed by running the test suite with the C<-t> switch (via +C). + +Make threads more robust. + +Make C and C work. + +A test suite for the B module would be nice. + +A ponie. =head1 Reporting Bugs