bleadperl is out there

by Adriano Ferreira

The 5.9.5 release of Perl was announced today and may be downloaded at your nearest CPAN mirror. This is a release from the development branch of the Perl interpreter, also known as "perl-current, bleading edge perl, bleedperl or bleadperl".


John Drago
2007-07-09 09:58:05
This distribution has a huge accumulated set of long waited-for features, some of them backported from Perl 6.

I see that we have a new switch construct, but how about an example?

Adriano Ferreira
2007-07-09 12:58:39
@John Drago:

I could not provide a better example than one given by Ricardo Signes at the mailing list. His message is well worthy reading, explaining why Perl never got a dumb switch and why this new construction is a switch on steroids.

given ($variable) {
when (1) { # $variable == 1
when (@edge_cases) { # if $variable in @edge_cases
when ($_ > 10e6) { # if $variable is over a million
when (\&test) { # if test($_) is true
say "the test was true!";
when (/^\Q$somepattern\E$/) {
say "seen $somepattern";
default {

The example is augmented by a clause suggested in a reply from the same thread as the original message.

2007-07-11 18:33:12
I for one will be very excited when 5.10 finally hits the streets. I have a project coming up for a re-write that I would love to use 5.10 for.