This Week on p5p 2001/10/21

This fortnight on perl5-porters (08-21 October 2001)


This Week on P5P

5.8.0 TODO




AUTOLOAD and packages



Please send corrections and additions to where YYYYMM is the current year and month. Changes and additions to the perl5-porters biographies are particularly welcome.

5.8.0 TODO

Jarkko posted a list of things to do before the 5.8.0 release (later, he posted another, shorter TODO list.) The main remaining issues are:

  • PerlIO, Threading, and Multiplicity

  • Attributes are Broken

  • Basic Unicode Support

  • FAQ Updates

Nick Ing-Simmons, who was unable to work on Perl for a while because of intellectual property restrictions at his new job, is back, and working very hard on fixing the PerlIO issues. Arthur Bergman has quietly but steadily been making threads::shared work well enough to be shipped with 5.8.0. Damian has suitably evil plans for attributes, which Arthur and I plan to assimilate into the core.

Jarkko, apparently working all alone, has made considerable progress towards making Perl comply with “Level 1 - Basic Unicode Support”, as defined by the Unicode standard, TR#18 “Unicode Regular Expression Guidelines”. Some features remain unimplemented, though, including character class subtraction and end-of-line matching.

The Perl FAQ needs extensive updates, to remove obsolete material and add new material where appropriate.

Any volunteers?


In August, as he embarked on a rewrite of the POD documentation, Sean M. Burke said:

A markup language without a clear specification simply invites everyone, including implementors, to have their own shaky idea of what the language means. And that, along with the general tendency for markup language parsing to produce write-only code, explains much of the upsetting current state of Pod::* modules.

After several revisions, Sean has now released the final draft of his changes, which include a complete rewrite of the perlpod manpage (a POD reference suitable for module authors), and the new perlpodspec manpage (a more formal POD specification). The documents attempt to formalise best current practice in parsing and rendering POD, without introducing any radically new features. They were greeted with sighs of relief, and have been incorporated into perl-current.

This is an excellent step towards alleviating the upsetting state of the Pod::* modules, but there is still a lot of work to be done. Patches towards making the core documentation comply with the new specification are particularly welcome.

Brad Appleton (the author of Pod::Parser and Pod::Checker) may not be able to hack on his POD modules for a while, and welcomes help. I am sure many of the other module authors could use a hand with testing and updating their modules in light of perlpodspec.

If you want to help, or are interested in seeing what’s going on, Sean recommends that you join the pod-people mailing list.


Perl has been doing better and better in tests, and H. Merijn Brand sums up the situation nicely:

    **Lot's* of 'O's :))

We got a full set of ‘O’s (OK) for various AIX and HP-UX systems with their native compilers (and later, with gcc 3 under HP-UX). Hal Morris reports that perl passes all tests under Linux/390, while a few failures remain under UTS and VMS.

More test reports from weird platforms are most welcome.


When Perl is running in taint mode (because it was started with the -T switch), a global variable (in the core) named PL_tainting is set to 1 (it is usually 0). Michael G. Schwern posted a patch to make this value accessible to Perl programs as ${^TAINT}. Jarkko said:

<troll>Why ${^TAINT} is read-only? It would be *so* convenient to …</troll>

Of course, my HTML-hating email program stripped the <troll> tags, so I had to post a patch to make ${^TAINT} writable (thereby making local ${^TAINT} = 0 work as expected). The patch made Jarkko go temporarily blind (but not blind enough to accidentally apply it).

The magic_get()/set() functions in mg.c retrieve and set the values of special variables like ${^TAINT} and $^S (where “specialness” is defined by the is_gv_magical() function in gv.c). Both functions are big switch statements which try to recognise the name of a variable, and then take some appropriate action. Schwern’s patch made magic_get() assign the value of PL_tainting to ${^TAINT} and make it read-only; mine removed the read-only markings, and taught magic_set() to update PL_tainting when ${TAINT} is assigned to.

It might be an interesting exercise to pick a special variable (say, $^W) and figure out what Perl does to get or set its value. Rusty grep skills can be further polished by figuring out when and where the get and set functions are called. If you’re still bored, figure out how the value of PL_tainting is computed and used.

AUTOLOAD and packages

Paul Johnson posted a message about some weird AUTOLOAD behaviour. What should the following code do?

package P1;

    *P2::AUTOLOAD = sub {
        print "|$::AUTOLOAD|$P1::AUTOLOAD|$P2::AUTOLOAD|\n";


Nobody was very sure, but perl-current behaves differently from 5.6.1, so something must be broken.


Will somebody please write a B::Parrot module and post it to P5P, so that I can write about it in the summary? (Rather than just make things up, as certain unscrupulous individuals suggest I should do.)


Michael G. Schwern released Test::Simple 0.32. In the process, he introduced $ENV{PERL_CORE}, to enable modules distributed both in the core and on the CPAN to use the same tests everywhere, thereby simplifying life greatly.

Johan Vromans released Getopt::Long 2.26_02, a prerelease of version 2.27. Its guts have been redesigned to make room for expansion; testers and bug reports are particularly welcome.

Russ Allbery released podlators 1.11, with several bug-fixes and some new features. (Russ still has a pile of mail to dig through, and he hopes to release another version soon.)

Jarkko promptly assimilated all three, and found the time to release no less than seven snapshots.

Kirrily Robert also submitted final drafts of some new documentation: perlintro (a Perl introduction for beginners), and perlmodstyle (a discussion of the current “best practices” in writing modules).

Gisle Aas made a brief appearance to post an ExtUtils::MakeMaker patch which causes $ENV{PERL_MM_USE_DEFAULT}, when set, to instruct ExtUtils::MakeMaker::prompt to return the default answer to every question without waiting for input.

Randolph Werner ported perl to 64-bit Windows (!).

Perl 5.6.1 is now installed by default with HP-UX 11.00.

The perl5-changes mailing list records each patch to Perl when it is committed into the repository. It is highly recommended (Pumpking approved! 100% signal!) for people who want to keep in touch with perl-current. (Speaking of lists, a passing remark that P5P mail should have a munged Reply-To fortunately did not elicit any, er… strong opinions.)

Charles Lane fixed some niggling problems under VMS, and Craig A. Berry found some new ones. VMSperl now builds with PerlIO as the default, and it is possible to configure it for 64-bitness (although this causes a colourful test failure, evidently due to bugs in the system’s gcvt() function, used to stringify numbers).

Mikhail Zabaluev patched perldoc to use File::Temp instead of creating temporary files in an ad-hoc fashion. Tim Jenness tried to convince him that he should fix various other things in perldoc, but Mikhail didn’t fall for it. Does anyone else want to try? (One of the changes, to use Pod::Man rather than the pod2man program, is similar to Schwern’s recent change to installhtml.)

Perlbug posted an intriguing, but somewhat hard-to-decipher overview of the bug database, before dying again. Several “Hello, is this thing on?” messages and a flood of pent-up bug reports later, it is reported to be working again.

Perl 5 had its seventh birthday on October 17th, 2001.

Abhijit Menon-Sen



Something wrong with this article? Help us out by opening an issue or pull request on GitHub