This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
support USE_THREADS+MULTIPLICITY; source compat tweaks for
[perl5.git] / Todo
CommitLineData
54aff467
GS
1Always check out the latest perl5-porters discussions on these subjects
2before embarking on an implementation tour.
ed3f4a32 3
8990e307
LW
4Tie Modules
5 VecArray Implement array using vec()
6 SubstrArray Implement array using substr()
7 VirtualArray Implement array using a file
8 ShiftSplice Defines shift et al in terms of splice method
93a17b20 9
8990e307 10Would be nice to have
ed3f4a32 11 pack "(stuff)*", "(stuff)4", ...
54aff467 12 contiguous bitfields in pack/unpack
463ee0b2 13 lexperl
54aff467
GS
14 bundled perl preprocessor
15 use posix calls internally where possible
9cc29783 16 gettimeofday (possibly best left for a module?)
8990e307 17 format BOTTOM
2304df62 18 -i rename file only when successfully changed
54aff467 19 all ARGV input should act like <>
2304df62 20 report HANDLE [formats].
a0d0e21e 21 support in perlmain to rerun debugger
aa00cc68 22 regression tests using __DIE__ hook
aa00cc68
TB
23 lexically scoped functions: my sub foo { ... }
24 lvalue functions
54aff467
GS
25 wantlvalue? more generalized want()/caller()?
26 named prototypes: sub foo ($foo, @bar) { ... } ?
7b8d334a 27 regression/sanity tests for suidperl
ed3f4a32
JH
28 iterators/lazy evaluation/continuations/first/
29 first_defined/short-circuiting grep/??
30 This is a very thorny and hotly debated subject,
54aff467
GS
31 tread carefully and do your homework first
32 full 64 bit support (i.e. "long long"). Things to consider:
2607c2e4
JH
33 how to store/retrieve 32+ integers into/from Perl scalars?
34 32+ constants in Perl code? (non-portable!)
35 32+ arguments/return values to/from system calls? (seek et al)
36 32+ bit ops (&|^~, currently explicitly disabled)
54aff467 37 generalise Errno way of extracting cpp symbols and use that in
24e11b2a 38 Errno and Fcntl (ExtUtils::CppSymbol?)
54aff467 39 the _r-problem: for all the {set,get,end}*() system database
2607c2e4
JH
40 calls (and a couple more: readdir, *rand*, crypt, *time,
41 tmpnam) there are in many systems the _r versions
54aff467 42 to be used in re-entrant (=multithreaded) code
24e11b2a 43 Icky things: the _r API is not standardized and
54aff467
GS
44 the _r-forms require per-thread data to store their state
45 memory profiler: turn malloc.c:Perl_dump_mstats() into
24e11b2a
JH
46 an extension (Devel::MProf?) that would return the malloc
47 stats in a nice Perl datastructure (also a simple interface
54aff467 48 to return just the grand total would be good)
8990e307 49
a0d0e21e 50Possible pragmas
85e6fe83 51 debugger
54aff467 52 optimize (use less qw[memory cpu])
463ee0b2
LW
53
54Optimizations
a0d0e21e
LW
55 constant function cache
56 switch structures
a0d0e21e 57 foreach(reverse...)
54aff467
GS
58 optimize away constant split at compile time (a la qw[f o o])
59 cache eval tree (unless lexical outer scope used (mark in &compiling?))
463ee0b2 60 rcatmaybe
54aff467
GS
61 shrink opcode tables via multiple implementations selected in peep
62 cache hash value? (Not a win, according to Guido)
63 optimize away @_ where possible
8990e307 64 "one pass" global destruction
54aff467 65 rewrite regexp parser for better integrated optimization
aa00cc68 66 LRU cache of regexp: foreach $pat (@pats) { foo() if /$pat/ }
463ee0b2 67
a0d0e21e 68Vague possibilities
54aff467 69 ref function in list context?
463ee0b2 70 make tr/// return histogram in list context?
54aff467
GS
71 loop control on do{} et al
72 explicit switch statements
463ee0b2
LW
73 built-in globbing
74 compile to real threaded code
75 structured types
85e6fe83 76 autocroak?
54aff467 77 modifiable $1 et al