X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=pod%2Fperltodo.pod;h=bae2fa975a662bf3499afece5a604e7a618f2601;hb=6d71adcd08598698fcddf4d2e47f1893427c4e79;hp=0dbff75e5cfb2072b88ebd89caca7a4d0024b94a;hpb=ee8e686db478652dd044fc00ee778f3050cbc23e;p=p5sagit%2Fp5-mst-13.2.git diff --git a/pod/perltodo.pod b/pod/perltodo.pod index 0dbff75..bae2fa9 100644 --- a/pod/perltodo.pod +++ b/pod/perltodo.pod @@ -4,683 +4,422 @@ perltodo - Perl TO-DO List =head1 DESCRIPTION -This is a list of wishes for Perl. Send updates to -I. If you want to work on any of these -projects, be sure to check the perl5-porters archives for past ideas, -flames, and propaganda. This will save you time and also prevent you -from implementing something that Larry has already vetoed. One set -of archives may be found at: +This is a list of wishes for Perl. The tasks we think are smaller or easier +are listed first. Anyone is welcome to work on any of these, but it's a good +idea to first contact I to avoid duplication of +effort. By all means contact a pumpking privately first if you prefer. - http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/ - -=head1 To do during 5.6.x - -=head2 Support for I/O disciplines - -C provides this, but the interface could be a lot more -straightforward. - -=head2 Autoload bytes.pm - -When the lexer sees, for instance, C, it should -automatically load the C pragma. - -=head2 Make "\u{XXXX}" et al work - -Danger, Will Robinson! Discussing the semantics of C<"\x{F00}">, -C<"\xF00"> and C<"\U{F00}"> on P5P I lead to a long and boring -flamewar. - -=head2 Create a char *sv_pvprintify(sv, STRLEN *lenp, UV flags) - -For displaying PVs with control characters, embedded nulls, and Unicode. -This would be useful for printing warnings, or data and regex dumping, -not_a_number(), and so on. - -Requirements: should handle both byte and UTF8 strings. isPRINT() -characters printed as-is, character less than 256 as \xHH, Unicode -characters as \x{HHH}. Don't assume ASCII-like, either, get somebody -on EBCDIC to test the output. - -Possible options, controlled by the flags: -- whitespace (other than ' ' of isPRINT()) printed as-is -- use isPRINT_LC() instead of isPRINT() -- print control characters like this: "\cA" -- print control characters like this: "^A" -- non-PRINTables printed as '.' instead of \xHH -- use \OOO instead of \xHH -- use the C/Perl-metacharacters like \n, \t -- have a maximum length for the produced string (read it from *lenp) -- append a "..." to the produced string if the maximum length is exceeded -- really fancy: print unicode characters as \N{...} +Whilst patches to make the list shorter are most welcome, ideas to add to +the list are also encouraged. Check the perl5-porters archives for past +ideas, and any discussion about them. One set of archives may be found at: -NOTE: pv_display(), pv_uni_display(), sv_uni_display() are already -doing something like the above. - -=head2 Overloadable regex assertions + http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/ -This may or may not be possible with the current regular expression -engine. The idea is that, for instance, C<\b> needs to be -algorithmically computed if you're dealing with Thai text. Hence, the -B<\b> assertion wants to be overloaded by a function. +What can we offer you in return? Fame, fortune, and everlasting glory? Maybe +not, but if your patch is incorporated, then we'll add your name to the +F file, which ships in the official distribution. How many other +programming languages offer you 1 line of immortality? -=head2 Unicode +=head1 The roadmap to 5.10 -=over 4 +The roadmap to 5.10 envisages feature based releases, as various items in this +TODO are completed. -=item * +=head2 Needed for a 5.9.5 release -Allow for long form of the General Category Properties, e.g -C<\p{IsOpenPunctuation}>, not just the abbreviated form, e.g. -C<\p{IsPs}>. +=over =item * -Allow for the metaproperties: C, C, -C, C (require the DerivedCoreProperties and -DerviceNormalizationProperties files). - -There are also multiple value properties still unimplemented: -C, C. +Review smart match semantics in light of Perl 6 developments. =item * - Case Mappings? http://www.unicode.org/unicode/reports/tr21/ - -Mostly implemented (all of 1:1, 1:N, N:1), only the "final sigma" -and locale-specific rules of SpecCase are not implemented. +Review assertions. Review syntax to combine assertions. Assertions could take +advantage of the lexical pragmas work. L =item * -UTF-8 identifier names should probably be canonicalized: NFC? - -=item * - -UTF-8 in package names and sub names? The first is problematic -because of the mapping to pathnames, ditto for the second one if -one does autosplitting, for example. Some of this works already -in 5.8.0, but essentially it is unsupported. Constructs to consider, -at the very least: - - use utf8; - package UnicodePackage; - sub new { bless {}, shift }; - sub UnicodeMethod1 { ... $_[0]->UnicodeMethod2(...) ... } - sub UnicodeMethod2 { ... } # in here caller(0) should contain Unicode - ... - package main; - my $x = UnicodePackage->new; - print ref $x, "\n"; # should be Unicode - $x->UnicodeMethod1(...); - my $y = UnicodeMethod3 UnicodePackage ...; - -In the above all I contain (identifier-worthy) characters -beyond the code point 255, for example 256. Wherever package/class or -subroutine names can be returned needs to be checked for Unicodeness. +C should be turned into a lexical pragma (probably). =back -See L for what's -there and what's missing. Almost all of Levels 2 and 3 is missing, -and as of 5.8.0 not even all of Level 1 is there. -They have some tricks Perl doesn't yet implement, such as character -class subtraction. - - http://www.unicode.org/unicode/reports/tr18/ - -=head2 Work out exit/die semantics for threads - -There are some suggestions to use for example something like this: -default to "(thread exiting first will) wait for the other threads -until up to 60 seconds". Other possibilities: - - use threads wait => 0; - -Do not wait. - - use threads wait_for => 10; - -Wait up to 10 seconds. - - use threads wait_for => -1; - -Wait for ever. - -http://archive.develooper.com/perl5-porters@perl.org/msg79618.html - -=head2 Better support for nonpreemptive threading systems like GNU pth - -To better support nonpreemptive threading systems, perhaps some of the -blocking functions internally in Perl should do a yield() before a -blocking call. (Now certain threads tests ({basic,list,thread.t}) -simply do a yield() before they sleep() to give nonpreemptive thread -implementations a chance). - -In some cases, like the GNU pth, which has replacement functions that -are nonblocking (pth_select instead of select), maybe Perl should be -using them instead when built for threading. - -=head2 Typed lexicals for compiler - -=head2 Compiler workarounds for Win32 - -=head2 AUTOLOADing in the compiler - -=head2 Fixing comppadlist when compiling - -=head2 Cleaning up exported namespace - -=head2 Complete signal handling - -Add C to opcodes which loop; replace C with -C; check C for signal safety. - -=head2 Out-of-source builds - -This was done for 5.6.0, but needs reworking for 5.7.x - -=head2 POSIX realtime support - -POSIX 1003.1 1996 Edition support--realtime stuff: POSIX semaphores, -message queues, shared memory, realtime clocks, timers, signals (the -metaconfig units mostly already exist for these) - -=head2 UNIX98 support - -Reader-writer locks, realtime/asynchronous IO - -=head2 IPv6 Support - -There are non-core modules, such as C, but these will need -integrating when IPv6 actually starts to really happen. See RFC 2292 -and RFC 2553. - -=head2 Long double conversion - -Floating point formatting is still causing some weird test failures. - -=head2 Locales - -Locales and Unicode interact with each other in unpleasant ways. -One possible solution would be to adopt/support ICU: - - http://oss.software.ibm.com/developerworks/opensource/icu/project/ - -=head2 Arithmetic on non-Arabic numerals - -C<[1234567890]> aren't the only numerals any more. - -=head2 POSIX Unicode character classes - -(C<[=a=]> for equivalence classes, C<[.ch.]> for collation.) -These are dependent on Unicode normalization and collation. - -=head2 Factoring out common suffices/prefices in regexps (trie optimization) - -Currently, the user has to optimize C and C into -C and C<[fg]oo> by hand; this could be done automatically. - -=head2 Security audit shipped utilities - -All the code we ship with Perl needs to be sensible about temporary file -handling, locking, input validation, and so on. - -=head2 Sort out the uid-setting mess - -Currently there are several problems with the setting of uids ($<, $> -for the real and effective uids). Firstly, what exactly setuid() call -gets invoked in which platform is simply a big mess that needs to be -untangled. Secondly, the effects are apparently not standard across -platforms, (if you first set $< and then $>, or vice versa, being -uid == euid == zero, or just euid == zero, or as a normal user, what are -the results?). The test suite not (usually) being run as root means -that these things do not get much testing. Thirdly, there's quite -often a third uid called saved uid, and Perl has no knowledge of that -feature in any way. (If one has the saved uid of zero, one can get -back any real and effective uids.) As an example, to change also the -saved uid, one needs to set the real and effective uids B-- in -most systems, that is: in HP-UX that doesn't seem to work. - -=head2 Custom opcodes - -Have a way to introduce user-defined opcodes without the subroutine call -overhead of an XSUB; the user should be able to create PP code. Simon -Cozens has some ideas on this. - -=head2 DLL Versioning - -Windows needs a way to know what version of an XS or C DLL it's -loading. - -=head2 Introduce @( and @) - -C<$(> may return "foo bar baz". Unfortunately, since groups can -theoretically have spaces in their names, this could be one, two or -three groups. - -=head2 Floating point handling - -C and C support is particularly troublesome. -(fp_classify(), fp_class(), fp_class_d(), class(), isinf(), -isfinite(), finite(), isnormal(), unordered(), , - (there are metaconfig units for all these) (I think), -fp_setmask(), fp_getmask(), fp_setround(), fp_getround() -(no metaconfig units yet for these). Don't forget finitel(), fp_classl(), -fp_class_l(), (yes, both do, unfortunately, exist), and unorderedl().) - -As of Perl 5.6.1, there is a Perl macro, Perl_isnan(). - -=head2 IV/UV preservation - -Nicholas Clark has done a lot of work on this, but work is continuing. -C<+>, C<-> and C<*> work, but guards need to be in place for C<%>, C, -C<&>, C, C and C. - -=head2 Replace pod2html with something using Pod::Parser - -The CPAN module C may be a more suitable basis for a -C converter; the current one duplicates the functionality -abstracted in C, which makes updating the POD language -difficult. - -=head2 Automate module testing on CPAN - -When a new Perl is being beta tested, porters have to manually grab -their favourite CPAN modules and test them - this should be done -automatically. - -=head2 sendmsg and recvmsg - -We have all the other BSD socket functions but these. There are -metaconfig units for these functions which can be added. To avoid these -being new opcodes, a solution similar to the way C was added -would be preferable. (Autoload the C module.) - -=head2 Rewrite perlre documentation - -The new-style patterns need full documentation, and the whole document -needs to be a lot clearer. - -=head2 Convert example code to IO::Handle filehandles - -=head2 Document Win32 choices - -=head2 Check new modules - -=head2 Make roffitall find pods and libs itself - -Simon Cozens has done some work on this but it needs a rethink. - -=head1 To do at some point - -These are ideas that have been regularly tossed around, that most -people believe should be done maybe during 5.8.x - -=head2 Remove regular expression recursion +=head2 Needed for a 5.9.6 release -Because the regular expression engine is recursive, badly designed -expressions can lead to lots of recursion filling up the stack. Ilya -claims that it is easy to convert the engine to being iterative, but -this has still not yet been done. There may be a regular expression -engine hit squad meeting at TPC5. +Stabilisation. If all goes well, this will be the equivalent of a 5.10-beta. -=head2 Memory leaks after failed eval +=head1 Tasks that only need Perl knowledge -Perl will leak memory if you C. This is -partially because it attempts to build up an op tree for that code and -doesn't properly free it. The same goes for non-syntactically-correct -regular expressions. Hugo looked into this, but decided it needed a -mark-and-sweep GC implementation. +=head2 common test code for timed bail out -Alan notes that: The basic idea was to extend the parser token stack -(C) to include a type field so we knew what sort of thing each -element of the stack was. The F code would then have to be -postprocessed to record the type of each entry on the stack as it was -created, and the parser patched so that it could unroll the stack -properly on error. +Write portable self destruct code for tests to stop them burning CPU in +infinite loops. This needs to avoid using alarm, as some of the tests are +testing alarm/sleep or timers. -This is possible to do, but would be pretty messy to implement, as it -would rely on even more sed hackery in F. +=head2 POD -> HTML conversion in the core still sucks -=head2 bitfields in pack +Which is crazy given just how simple POD purports to be, and how simple HTML +can be. It's not actually I simple as it sounds, particularly with the +flexibility POD allows for C<=item>, but it would be good to improve the +visual appeal of the HTML generated, and to avoid it having any validation +errors. See also L, as the layout of installation tree +is needed to improve the cross-linking. -=head2 Cross compilation +The addition of C and its related modules may make this task +easier to complete. -Make Perl buildable with a cross-compiler. This will play havoc with -Configure, which needs to know how the target system will respond to -its tests; maybe C will be a good starting point here. -(Indeed, Bart Schuller reports that he compiled up C for -the Agenda PDA and it works fine.) A really big spanner in the works -is the bootstrapping build process of Perl: if the filesystem the -target systems sees is not the same what the build host sees, various -input, output, and (Perl) library files need to be copied back and forth. +=head2 Parallel testing -As of 5.8.0 Configure mostly works for cross-compilation -(used successfully for iPAQ Linux), miniperl gets built, -but then building DynaLoader (and other extensions) fails -since MakeMaker knows nothing of cross-compilation. -(See INSTALL/Cross-compilation for the state of things.) +(This probably impacts much more than the core: also the Test::Harness +and TAP::* modules on CPAN.) -=head2 Perl preprocessor / macros +The core regression test suite is getting ever more comprehensive, which has +the side effect that it takes longer to run. This isn't so good. Investigate +whether it would be feasible to give the harness script the B