This Week on perl5-porters - 13-19 October 2008 *"It's far from being a critical issue, and I'm not saying that magic shouldn't be enabled there. But I'd really like to see magic behave in the most predictable possible way."* -- Vincent Pit, inventing a new meaning for "predictable". Topics of Interest use bytes pragma Karl Williamson, in his ongoing overhaul of Unicode handling, discovered some inconsistencies between the documentation for and implementation of the "bytes" pragma. As such, he wasn't willing to hazard a change, but wondered how often it was used in real life. http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00377.html PATL/autorequire-0.08.tar.gz broken since perl5.8.8@30113 Slaven Rezic noted that refactoring in DynaLoader had caused this module to fail, and traced it down to some hairy .PL template code. Vadim Konovalov admitted guilt over the template syntax and offered to atone for his sins by writing the machinery that would allow nicer templating during the build. http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00411.html ties and other filehandle bondage Ricardo Signes uncovered an ugly problem with opening a file handle to a reference of a tied scalar. And while this was probably not the wisest thing to do in the first place, any error message would be better than none. Vincent Pit reasoned that the best way to solve this would be to have magic triggered on every "print" argument, but that might be woefully expensive. Nicholas Clark thought that correctness was better than speed, and if you're into magic you probably don't care about efficiency. http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00415.html blead and Glib's lazy-loader Torsten Schönfeld reported a problem with "av_clear" on @ISA not doing the right thing, and having to call "av_shift" repeatedly instead. (I seem to remember summarising a similar issue a couple of weeks ago). http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00471.html Change 32016 breaks a test in "MPEG::Audio::Frame" Slaven Rezic uncovered a bug in "MPEG::Audio::Frame". Nicholas Clark noted that this was because Yuval Kogman was a wicked man who peeked, and relied upon the implementation. Yuval admitted that the module ought to be fixed up (rather than perl), but confessed to low amounts of tuits. Nicholas was also in awe of the amount of testing Slaven was doing in tracking the changes for 5.8.9. http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00473.html TODO of the week Add a code coverage target to the Makefile Make it easy for anyone to run "Devel::Cover" on the core's tests. The steps to do this manually are roughly * do a normal "Configure", but include "Devel::Cover" as a module to install (see INSTALL for how to do this) * make perl * cd t; HARNESS_PERL_SWITCHES=-MDevel::Cover ./perl -I../lib harness * Process the resulting Devel::Cover database This just give you the coverage of the .pms. To also get the C level coverage you need to * Additionally tell "Configure" to use the appropriate C compiler flags for "gcov" * make perl.gcov (instead of "make perl") * After running the tests run "gcov" to generate all the .gcov files. (Including down in the subdirectories of ext/ * (From the top level perl directory) run "gcov2perl" on all the ".gcov" files to get their stats into the cover_db directory. * Then process the Devel::Cover database. It would be good to add a single switch to "Configure" to specify that you wanted to perform perl level coverage, and another to specify C level coverage, and have "Configure" and the Makefile do all the right things automatically. New and old bugs from RT "File::Copy" module (#32135) Nicholas Clark disagreed with Adriano Ferreira's comment of what was the underlying problem in this bug report. He wondered if the real problem did not in fact lie with "IO::Scalar". http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00467.html In a related report ("File::Copy" does not handle file objects sanely (bug #59650)), a rabbit supplied a patch to deal with "IO::Scalar" objects (which is probably why Nicholas revived the preceding bug. Nicholas had a minor quibble over the use of "xor" rather than "ne", and wondered if there were any corner cases where they would behave differently. http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00459.html Unicode problem (#58182) Karl Williamson reported back on his progress in dealing with Unicode in Perl. He now has a good idea of what he wants to do, but had some questions of a practical nature regarding C coding standards. He asked a very interesting question: what is the feeling regarding the use of lookup table to push design decisions into data, rather than code. Another crucial design assumption was that "uc" tries to convert in place if possible. Karl wondered if it would reasonable to always return a new SV regardless of whether the original container would fit, as it would simplify the code. To this latter point, Rafaël Garcia-Suarez told him to go ahead with whatever was easiest; there would always be time to optimise it later on, should the need arise. In another subthread, Karl pointed people at the bikeshed and asked for colour schemes. That is, this new Unicode functionality will be enabled via a pragma in 5.10 (becoming the default behaviour in 5.12). What, then, should be the name of the pragma? Karl had a number of ideas, but was dissatisfied with all of them. http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00376.html Memory leak with regex in 5.10.0 (#59516) Marcus Holland-Moritz plugged the leak with a well-placed "SvREFCNT_dec". http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00457.html bun in perl 5.8.8 on AIX 5.3 (#59866) Rainer Tammer noted a perfect 64-bit build on AIX 5.2, but *ceteris paribus* a failure AIX 5.3. A 32-bit build was fine. H.Merijn Brand was able to repeat the failure. http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00335.html Variable falls out of scope but is not garbage-collected (#59882) Frédéric Brière reported a problem of a variable with no remaining references not being garbage collected. Dave Mitchell explained that method lookup caching was interfering with things and suggested an alternate syntax to Do The Right Thing. Nicholas Clark thought that caching should only improve performance, not require people to jump through hoops to avoid side effects. He proposed a change to the implementation but wondered if there were any corner cases that might be affected. Dave Mitchell was reluctant to entertain any changes, since the GV implementation has not been widely studied. the cold light of day http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00345.html "x" forces scalar context on array variables (#59884) James Schneider stumbled over an edge case with "x", the replication operator. Much discussion about context, parentheses and "qw()" followed. http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00347.html "\x", "\0", and "\N{}" not ok in double-quotish when followed by > \x100 (#59908) Karl Williamson needs someone to tell him where to look in the source to track down the problem he summarised in this bug report. help, I need somebody http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00400.html tainted values in ternary conditional (#59916) Dean wanted the propagation of tainted values with ternary expressions to change, and wrote some tests to describe the behaviour he sought. http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00398.html Errors in compilation (#59922) Rajini S was encountering difficulties in testing a 32-bit build on HP-UX. H.Merijn Brand and Andy Dougherty thought that the new build was getting mixed up with parts of the system perl. http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00399.html Memory leak when accessing "%+" (#59942) Marc Lehmann reported a problem with "%+", but Renée Bäcker thought it had already been solved in blead by change #34151, and suggested looking at bug #57024. http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00419.html "Modification of read-only value" in grep (#59956) Ed Avis set up a construct that produced a misleading error message. Eric Brine explained that the so-called modification error was due to autovivification, and suggested that it would be nice to have a better error message. http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00447.html Bug in threads / perl 5.8.8 on AIX 5.2 / 5.3 (#59960) Rainer Tammer found, and solved, a bug in threads on AIX. H.Merijn Brand suggested that at the very least, a maintainer for README.aix would be a great idea, should Rainer feel like volunteering. http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00448.html Memory leak when using the "qr" operator (#59994) Roland Illig independently (re-)discovered the "qr//" leak, only to learn it had been fixed. Marcus Holland-Moritz suggested what he hoped was an appropriate patch for Roland's 5.10.0 installation since 5.10.1 is not yet shipping. http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00477.html "crypt()" returns tainted data even when input strings are detainted (#59998) Frédéric Buclin uncovered some inconsistencies with tainted data when "crypt" is involved. http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00491.html Perl5 Bug Summary 279 new + 1054 open = 1333 (+15 -5) http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00333.html http://rt.perl.org/rt3/NoAuth/perl5/Overview.html New Core Modules Archive::Tar 1.40 http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00334.html CPAN.pm 1.9301 http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00349.html ExtUtils::MakeMaker 6.47_01 http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00364.html ExtUtils::MakeMaker 6.47_02 http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00414.html Test::More/Simple/Builder 0.82 http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00375.html Test::More/Simple/Builder 0.84 http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00387.html In Brief Yamashina Hio found that "Storable::thaw" segfaults on blessed reference to overloaded object and supplied a patch that Nicholas Clark was happy to apply. http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00382.html Jerry D. Hedden saw some problems arising following change #33119 that integrated some consting goodness to cygwin.c. http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00336.html Jerry then suggested a small lib/DB.t fix, and Nicholas Clark fixed the problem with change #34554. applied http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00405.html Karl Williamson wondered if there was a document that helped porters come to grips with the use of git. The answer was to note things on the wiki. This could then be folded into perlhack at a later date. http://www.perlfoundation.org/perl5/index.cgi?move_to_git_todo_list http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00453.html Niko Tyni pushed a Debian patch to fix "h2xs" enum handling with C++ comments unapplied http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00490.html Niko also posted a patch because "h2xs" incorrectly treats enum values like macros. also unapplied http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00489.html While discussing the (im?)possibility of prototype-based polymorphism, Michael G. Schwern thought that "Method::Signatures" was probably the way to go. just a smop http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00481.html Last week's summary This Fortnight on perl5-porters - 28 September-12 October 2008 http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2008-10/msg00480.html About this summary This summary was written by David Landgren. Weekly summaries are published on http://use.perl.org/ and posted on a mailing list, (subscription: perl5-summary-subscribe@perl.org). The archive is at http://dev.perl.org/perl5/list-summaries/. Corrections and comments are welcome. If you found this summary useful, please consider contributing to the Perl Foundation or attending a YAPC to help support the development of Perl.