Gossamer Forum
Home : General : Perl Programming :

Apocalypse 5

Quote Reply
Apocalypse 5
Apocalypse 5 has been released.

Read all about it here:

http://www.perl.com/...2002/06/04/apo5.html

This is the document outlining Larry Wall's design of Perl 6. The biggest 'shock' here is the major redesign of the regex engine and how he has set out to intentionally 'break' a lot of the regular expression traditions we're all used to.

- wil

Last edited by:

Wil: Jun 5, 2002, 9:42 AM
Quote Reply
Re: [Wil] Apocalypse 5 In reply to
Well, not quite a shock. That's why it was taking 5+ months or so to get number 5 out. Hopefully (or so I've heard), the rest will come out much quicker.

Cheers,

Alex
--
Gossamer Threads Inc.
Quote Reply
Re: [Alex] Apocalypse 5 In reply to
Yes, you're right. I used the term 'shock' to convey something more of a 'focuss'.

What do you think of the proposed changes, however? We all know changes were needed, and to be fair, it is quite a radical makeover. What do you think? Do you think the proposed changes make sense?

Best thing is the introduction of closures and boolean expression assertions, imo.

- wil

Last edited by:

Wil: Jun 5, 2002, 1:06 PM
Quote Reply
Re: [Wil] Apocalypse 5 In reply to
Hi Wil,

Well, to be honest, I'm not that excited about the new syntax/grammar changes. I think it will be an improvement, and definately help the language, but for me, perl works great as is.

One of the things I am really excited in seeing is byte code compilation. I'd love to be able to ship a byte code file that contains the entire program, have it run on windows/unix, and be a lot faster as it is compiled + optimized already. Java has this now, but I think Parrot will be considerably faster.

Cheers,

Alex
--
Gossamer Threads Inc.
Quote Reply
Re: [Alex] Apocalypse 5 In reply to
Won't all this mean learning perl again basically from scratch? Unsure
Quote Reply
Re: [Paul] Apocalypse 5 In reply to
You will still be able to use perl 5 grammar with parrot (one of the big things is custom grammar/syntax -- you will be able to use parrot with ruby and possibly other languages). But yes, there are major changes in both the OO and the syntax of languages (fundamentals such as a hash is always %hash, even if it is a reference to a hash).

Cheers,

Alex
--
Gossamer Threads Inc.
Quote Reply
Re: [Paul] Apocalypse 5 In reply to
The concepts in this thread are scary for someone who is still struggling to grasp the current version/format of the language!Frown


http://www.iuni.com/...tware/web/index.html
Links Plugins
Quote Reply
Re: [Alex] Apocalypse 5 In reply to
Well, most of the changes called for are needed for Parrot's parser anyway.

I'm more excited about the new grammer/logical issues, myself as I'm not as advanced at Perl as yourself - so these little tweaks make a big difference in understanding and implementing complex regexes. Embedded code is handled in better, for example. This allows you to properly debug your regexes incrementally by good old print statement embedding.

When I first read Apocalypse, I hated the <s and >s, because it was too html-like. When reading more, it becomes clearer why this is.

I don't know. I think it's a good step forward for people that come to Perl from a non-technical/programming background. And there's a lot more standirdization here and it seems that the ability to standerdize rules into modules will benefit a lot of people working on group projects.

- wil
Quote Reply
Re: [Wil] Apocalypse 5 In reply to
And on this note, I should probably mention that anyone interested can now download Parrot 0.0.6:

http://www.cpan.org/src/parrot_0.0.6.tgz

- wil
Quote Reply
Re: [Ian] Apocalypse 5 In reply to
Quote:
The concepts in this thread are scary for someone who is still struggling to grasp the current version/format of the language!


Perl 6 is still quite a ways from becoming a reality, and even when it is, it is fundamentally different so perl 5 is not going anywhere anytime soon. Don't worry. =)

Cheers,

Alex
--
Gossamer Threads Inc.
Quote Reply
Re: [Alex] Apocalypse 5 In reply to
Phewww.... lets not let perl progress get in the way of my progressWink


http://www.iuni.com/...tware/web/index.html
Links Plugins
Quote Reply
Re: [Ian] Apocalypse 5 In reply to
Perl 6 will most likely be installed on most servers alongside Perl 5 for a very, very long time.

For example, my web host and many others still use a Perl package a number of years old. My web host is still running version 5.004 which I think is over 5 years old now. So there's no need to rush into things. Perl 6 is a hell of a long way away, anyway. But once in the mainstream, there will be some fundamental differences, and all your scripts might not work as things are not that backwards-compatible as some wished for.

- wil
Quote Reply
Re: [Wil] Apocalypse 5 In reply to
Quote:
not that backwards-compatible as some wished for.
What a pain in the ass for the programming community. But as you say, if this will be a long time off, its not that much of a concern yet.


http://www.iuni.com/...tware/web/index.html
Links Plugins
Quote Reply
Re: [Paul] Apocalypse 5 In reply to
I wouldn't get too worried, there will be an additional modifier to your regexes to say "interpret this regex according to p5 rules".

Here's a quote from Larry:

"Finally, there's the :p5 modifier, which causes the rest of the regex (or group) to be parsed as a Perl 5 regular expression, including any interpolated strings. (But it still doesn't enable Perl 5's trailing modifiers.)"

So, what this means is that:

Code:
PERL 6:

m:w/ foo\ bar \h* \: (baz)*/

PERL 5:

m:p5/\s*foo bar[\040\t\p{Zs}]*:\s*(baz)*/

Which one would you prefer? =)

- wil

Last edited by:

Wil: Jun 5, 2002, 2:33 PM
Quote Reply
Re: [Wil] Apocalypse 5 In reply to
I don't see how that works.

In the perl 5 regex you have \s* but in the perl 6 regex you just have a blank space...why would one blank space match 0 or more spaces?....that doesn't seem sensible.

...and why does \h match tabs too?

Last edited by:

Paul: Jun 5, 2002, 3:42 PM
Quote Reply
Re: [Paul] Apocalypse 5 In reply to
Read up on the new design specs. From my interpretation ..

\w, space, \w will have \s+ instead of the space, otherwise, it'll be \s*

Therefore:

Code:
m:w/foo bar , baz , , foo bar/

is the same as saying:

m:p5/foo\s+bar\s*,\s*baz\s*,\s*,\s*foo\s+bar/

As for \h, yeah that will match (horizontal) tabs.

- wil
Quote Reply
Re: [Wil] Apocalypse 5 In reply to
>>\w, space, \w will have \s+ instead of the space<<

Exactly, it doesn't make sense.

One blank space should equal \s not \s+