NAME

Perl 6 FAQ

GENERAL QUESTIONS

Will I be able to convert my Perl 5 programs to Perl 6?

Yes. Larry Wall and others are already working on a Perl 5 to Perl 6 translator, which will be able to translate (most) Perl 5 source code to the equivalent Perl 6 syntax.

In addition, Perl 6 will provide a "Perl 5 compatibility mode", allowing the compiler to directly execute any code that it recognizes as being written in Perl 5.

Is anyone going to bother to switch from Perl 5 to Perl 6?

Yes. Unlike Perl 5, Perl 6 will provide:

explicit strong typing
proper parameter lists
active metadata on values, variables, subroutines, and types
declarative classes with strong encapsulation
full OO exception handling
support for the concurrent use of multiple versions of a module
extensive introspection facilities (including of POD)
LL and LR grammars (including a built-in grammar for Perl 6 itself)
subroutine overloading
multiple dispatch
named arguments
a built-in switch statement
hierarchical construction and destruction
distributive method dispatch
method delegation
named regexes
overlapping and exhaustive regex matches within a string
named captures
parse-tree pruning
incremental regex matching against input streams
macros (that are implemented in Perl itself)
user-definable operators (from the full Unicode set)
chained comparisons
a universally accessible aliasing mechanism
lexical exporting (via a cleaner, declarative syntax)
multimorphic equality tests
state variables
hypothetical variables
hyperoperators (i.e. vector processing)
function currying
junctions (i.e. superpositional values, subroutines, and types)
coroutines
lazy lists
strong module and language versioning

Developers who want to take advantage of those new and/or improved features will switch to Perl 6.

Perl 6 looks even more obfuscatory and line-noisy than Perl 5 is -- does Perl 6 make it likely that programmers will write code that is unreadable/unmaintainable by mere mortals?

Many of the features mentioned in the previous answer are specifically aimed at making well-written Perl 6 code even more readable and maintainable than well-written Perl 5 code.

As for line-noisy, Perl 6 will remove or mitigate many of the usual suspects. For example, the majority of the punctuation variables are gone, and the regex syntax has been considerably sanitized. However, much of what Perl's detractors refer to as "line-noise", we prefer to call "the actual syntax of the language". Complaining that Perl is "noisy" is like complaining that English is "wordy": all those confusing pronouns and gerunds and prepositions and conjunctive adverbs, etc. making it hard to read.

Perl's fundamental philosophy in that area isn't going to change, so Perl 6 will still have a rich grammar in which distinct components are specified using distinctive syntactic forms.

Will people be able to develop in Perl 6 and release stand-alone executables, so as to protect their original code?

Parrot (the virtual machine on which Perl 6 will run) can compile your program to bytecode and -- on commonly used platforms -- to native executable files. So Perl 6 will be exactly like every other compiled language: it will be possible to protect your source code, but only from those who don't know how to run a disassembler.

Will people be able to develop in Perl 6 and release stand-alone executables that don't require any other system resources?

Maybe. The parrot bytecode requires the parrot to run it, but if you are in desperate need for a stand alone executable, you can statically link parrot and your program to a single executable.

Is there a release date set for perl 6.0 ?

In regards to Perl 6, the answer on release dates is really "when it's ready". There is no major commercial sponsor for the language development so the majority of the work is driven by volunteers and donations from the Perl Foundation (http://www.perlfoundation.org/).

That said, there is much progress being made in the last year, including the Pugs project which allows you to start testing experimenting with some perl 6 features .. now!

For more information on the latest re: perl 6, check out:

http://planetsix.perl.org/
http://dev.perl.org/perl6/
http://www.pugscode.org/
http://www.parrot.org/
http://rakudo.org/

You may also wish to have a look at some of the Perl6::* modules. which experiment with adding new language features to perl5. See the current list on CPAN (http://search.cpan.org/search?query=Perl6&mode=module).

If you really want to see Perl 6 done faster, the best answer is ... get involved! Sign up for the mailing lists and consider contributing some tests, documentation, or code to the Parrot or Pugs projects depending on your level of experience (or even donate real dollars to the Perl Foundation ;)

© Copyright 2002-2005 The Perl Foundation
Site Information and Contacts
Perl.org sites : books | dev | history | jobs | learn | lists | use   
When you need perl, think perl.org  
the camel