What is Perl 6?
chromatic writes "Perl.com has a new article entitled What is Perl 6?. It analyzes the changes to the language in light of the good and bad points of Perl 5 and provides new information about the current state of the project: Perl 6 exists, you can write code in it today, and it's more consistent and easier to use than Perl 5."
Yeah, I know I'm late to get on this but
My work here is dung.
You can never be told what Perl is.
You just have to see it for yourself.
sorry, i just had to.
An old-timer with old-timey ideas.
Baby don't hurt me,
Don't hurt me
No more
I never really understood Data Structures until I learned Perl. I was consistently and thoroughly confused in my DS class. The language used there was C++. There was simply too much baggage in the language that obfuscated the very points we were being taught. If you can't get past the template syntax, how in the world are you going to be able to understand the data structure concepts?
Then I met Perl (5.003). What a difference it made! The data structures were built in, and on top of that, it was EASY to nest structures to build complex data types. It was like having a semester of Data Structures immediately made clear.
Then I found myself back with C++ again. First I wrote my own List classes. However I soon realized that STL made available exactly the types of data structures that Perl has. Maps, Lists, Vectors. And since I understood what I was doing in Perl, it was so much easier to catch on with C++.
Perl taught me C++. Who would have thought?
I can't define it, but I know it when I see it.
Rob
What makes Perl strong, in my opinion, is the community's interest in maintaining a large and well-tested library of useful code in CPAN. Without CPAN, it's not clear that Perl would be as alive and healthy as it is today.
What Perl 6 offers is a rejuvenation of the language. Perl 5 still works great (better than ever due to new efforts to stamp out even the most obscure bugs) but this new revision is attracting some *really* smart people who are bringing interesting new ideas to the language. Audrey Tang and Luke Palmer come to mind right away.
My greatest hope, however, is not that a revitalized Perl will squash the other dynamic languages (Python, Ruby, PHP, ECMAScript, etc) but will instead bring them into a state of interoperability. I really, really want Parrot to succeed so well that the other languages decide to target it as a backend so I can trivially call Python or C libraries from Perl and vice versa.
One thing that perl is good for that I hope it continues to be good for in the future in command line scripting.
~tuxmaster
My compilers professor has nothing but bad things to say about a language whose syntax is inelegant and tricky. After all, if a language is inelegant, it will be hard to read and understand, as well as hard to create a proper grammar for, or parse.
"(Perl 5 overloaded curly braces in six different ways. If you can list four, you're doing well.)" ! Java has something like 22 levels of precedence. Most people will use the bare minimum of that, lest they tread upon a dragon's tail.
And, one of my favourite points: "Why is the method call operator two characters (one shifted), not a single dot? "
Perl 6 means a simpler, better parser, while keeping all the language strengths. This means it won't be such a bitch to deal with mod_perl's weird gleeps once it's Perl 6. This means smaller process overhead. This means quicker development of web applications that are cool (although I must admit, Ruby on Rails is also pretty neat looking).
The new regex syntax alone is reason to switch!
--
Internet Explorer (n): Another bug -- that is, a feature that can't be turned off -- in Windows.
A.Two Kiwi oysters going at it.
..now that we got Ruby.
Mark Kretschmann - Amarok Developer, KDE Member
From TFA:
Whipituptitude?!
That is awesome. Made up words a--
Whats this? Manipulexity?
How much awesome can you cram into a single sentence?
Three years ago, I could program in C, but had never used a scripting language (except bash, for very basic stuff). I needed to do some non-trivial manipulation of text files and figured that this was a good time to learn. Since others in the group were using perl, I tried perl.
I knew what I wanted to do, but needed to learn the language. I struggled with the awful syntax for three days. The breaking point came when I wanted a list of lists and realised that Perl "flattens" nested lists. How do you write nested lists such as [[1,2],[3,4],5,[6,7,8]]? In Python, it's trivial (that's how you'd write it), but in perl, nobody I talked to could give me an answer. It flattens it, unasked, to [1,2,3,4,5,6,7,8] and, try as I might, I can't see the point. (It turns out it's possible to have nested lists, but it's yet another example of perl's horrendous syntax).
Finally, I decided to give python a try. I spent an hour reading the python tutorial, and in another three hours, I had reimplemented everything I'd done in the last three days in perl, and an hour after that I'd finished the job. Python syntax was, and still is, the cleanest I've ever seen. It's an amazing language. And it changed the way I think about programming: it gave me an appreciation of functional methods (I now use ocaml a lot) and also changed the way I write C (vastly for the better).
That was it. No more perl for me.
yet another Virtual Machine nobody needs, that's supposed to be well at executing lots of different languages, but probably won't really.
It's a new language built by rewriting an ugly, old hack, that only fans of the old version will probably ever use. Everybody who didn't like Perl already moved on.
With all respect to the importance of strategic management, it is only one way to achieve success. Many of the great organizations of today didn't have a vision when they started and made it up as they went along.
Linux began as just for fun, Bill Gates' vision when starting Microsoft was "join the bandwagon as fast as you can before you miss the oppurtunity", and Perl itself started as a replacement for awk.
IMO, you can go either way- top down or bottom up- as long as you're competent enough to see oppurtunity and smart enough to know good decisions from bad.
People in the mid-1990s spoke of "overnight obsolescence", that Perl 6 would replace everything in a few weeks, and that you had better learn a new programming language every month. Over 10 years later, perl 6 is still in beta mode.
Hello.
We need 5 years experience Perl 6 programmers for 3D game. Reference: P6DNF.
-Woof woof woof!
The article talks about some of the defining features for perl. Well, one of the defining features in my perl experience has been Perl Data Language, pdl. PDL _is_ whipitupitude. Its a wonderful wonderful matrix library. And it comes with the best perl shell I know.
I had to break down a equation into a sequence of linear equations. So I hacked up some PDL in like 2 hours to do that. Couldn't have been easier, even though I'd never used PDL or its perldl perl shell; I just started typing in the interactive shell until it worked as expected and until I knew what I was doing. Then I needed the results in interger, so I rounded everything down, built a permuter and sorted the permuted results for each individual segment. That took three hours, but only because I kept botching the matrix multiplication. Even with huge datasets, generating hundreds of thousands of linear equations, each spanning dozens of datapoints, permuting the linear equations, sorting them and selecting the optimal, PDL would run it all my slow arse 800mhz crusoe laptop in seconds. Matlab couldnt touch it.
Thats the other really truly thing about PDL; the performance. If someone else would chime in and do it better justice, but my crude understanding is that it generates some kind of extremely optimized machine code on first use and runs whatever equations you've thrown at it like silk from that point on.
Little late and a little off topic, but PDL really is just a masterpiece of perl hackability. The PDL perl shell is truly spectacular; get some symbolic integrators and differential equation solving packages in there and I wouldn't need to break open Mathematica or Matlab ever again. Ok, long way away, pdl is really just about matricies, but it is really really sweet, and its shell is good for anyone who just wants to try something out really quickly in fully interactive perl.
That being said, I really cant wait to see where the perl6 VM is going.
G'night!
Myren
The article mentions blocks being closures and the fact that Perl 6 -- much like the new regex system -- is itself really a programmable grammar. It sounds like we now have real macros.
The question is: is Perl becoming a LISP implementation?
Here http://www.pugscode.org/ is something on the PUGS project, which is making an implementation of Perl 6 in Haskell, conformant to the spec.
Apparently they are having a lot of fun.
http://www.thebricktestament.com/the_law/when_to_
I do scientific computing (astronomy). I never met the task that was too cumbersome to write in C, while at the same time too complex to write in awk.
I keep waiting for a task where it would make sense for me to learn perl... it's never come along.
Normally you wait until a language is actually released before learning it. Traditionally, you let a couple early adopters build something with it first too. Most smart organizations wait to make sure the langauge actually is somewhat stable before buying into the list of benefits. They wait for books to be released.
Perl6 is not really here yet. Read the last page. Author doesnt come out and state it directly, but the current best implementation runs on Haskell.
I dunno, somehow I dont think the take-away was supposed to be "learn this or get fired, parrot is the one vm to rulezor them all!!11," I think it was more "perl6 is still coming and has some really cool new features, as well as being built around a much more solid core." There's mainstream technologies worth reading up on if you feel the heat to stay up to date for your job. Then there's things like Perl6/Parrot; cool technologies to read up on if you're actually fucking interested in computer languages or vm's. Forgive me, I realize you simply werent aware of the status of perl6, but perhaps you should see how many band members are actually on the bandwagon before hoping aboard yourself.
Myren
If the release of Perl 5 was any indication, Perl 6 is the single magic bullet that will kill all of my (Perl) code.
.NET.
Perl 6 may be more akin to a divine programming language, which makes the implimentation of complex data structures simple and sublime. Then again, it could all be a nasty trick to lead us away from the true path of enlightenment.
Perl 6 is not
Perl 6 is not controlled by any major corporation; I haven't decided whether this is advantageous or not yet.
If I were to have a child, would it be written in Perl 6?
Can Perl 6 be used to unlock the secret mysteries of the Bible code to reveal the end times?
Is Perl 6 really being developed by the descendants of Jesus Christ? Is the Pope trying to cover it up? Does the Pope know what Perl is? If so, is using Perl 5 a sin? How about Perl 6?
I bought a preview book on Perl 6 a few years ago. Is it still useful? Can I have my money back?
If Ruby was an upgrade to Perl, and Perl 6 is a an upgrade to Perl and Ruby, will Ruby need to changes their name in such a way as to play off of Ruby Tuesdays?
If I enter the Perl 6, can I change my mind later?
If Perl 6 is brillian, but no one uses it, is it still brilliant? What if it's awful and everyone uses it?
So very tired....
That's what Parrot's NCI layer does. It's a foreign function interface to shared libraries. It's much nicer than Perl 5's XS.
how to invest, a novice's guide
Ok, Perl6 does indeed look cool. Lots of interesting things there. Sure, you can apparently write Perl6 code today and run it on PUGS (a Haskell implementation of Perl 6; that's gotta be speedy, eh?). But as is mentioned in the article, Perl6 was announced at OSCON 2000; that's 5.5 years ago. It's now become the posterchild for vaporware in the open source world, hence this article to keep the faithful hopeful (and to keep'em from sneaking off to Ruby, Python or even Io). Really, it just looks like the purpose of the article is to say "yes, we're still here working on Perl 6. We're working hard, we really are. Please, don't lose hope. This is hard work. It'll be here one day and it'll be great", while a lot of Perl folks who yearned for something better have already moved on to Ruby or Python.
I really hope that Perl 6 arrives one day. I'm pretty deep into using Ruby these days having left Perl 5 behind long ago (the part of the article about what's wrong with Perl 5 was really superfluous; maybe it was intended to convince the remainingn Perl folks who are happy with 5 to check out 6), but I'll give Perl 6 a look when it arrives. The grammar support alone looks pretty awesome; it'd be great to have a viable lex/yacc alternative. In the meantime I want to learn some languages that have a bit more immediate promise like Io. It seems that maybe the plans for Perl 6 were just too ambitious. Yes, it's great to start with a clean slate and try to revolutionize, but often it's evolution that wins out.
In other words, the spec still isn't nailed down. I may have only been been loosely following Perl 6's progress, but having seen the concatention operator change from . to ~ to _ during Perl 6's development, I'll wait until the final spec comes out, thanks.
GLaDOS for President 2016! "Well here we are again. It's always such a pleasure." -- GLaDOS, 2011
...it's more consistent and easier to use than Perl 5
Some thing are just so easy there's no pride in it. Now make something more wich is harder to read then Perl 5 and you've achieved something. It may be better, but is it good?
I hope you're sitting down since this might come as a shock but ... theres
more to C++ than the STL! Yes , I know , its amazing isn't it that a language
thats only been around 20 years and is based on C which has been around for
over 30 is more complex than this , but, well son , its true. Until you
understand not just all the cool trendy OO and generic side but also understand
pointer arithmetic, indirection , word boundary alignment issues and 101 other
low level topics inherited from C then you DO NOT "know" C++ at all.
* In TFA1: whipituptitude
* In TFA2 referenced from TFA1: whipuptitude
With Perl, there is always more than one way to spell it.
Being bitter is drinking poison and hoping someone else will die
From the examples I've seen, I'm worried. Perl5 already has too much syntax for my liking (see the subthread on nested refs. yuck), and Perl6 seems to be going much, much furthur in that direction. Will it be powerful? You bet! The problem is that Larry thinks power is the sort of subtle change of inflection that can alter your meaning from "Greetings!" to "Greetings, shithead!", but only when the moon is in the third house. I'll hold off my judgement until it ships; I certainly owe Larry that much for how much use I get out of 5. In the meantime, though, I will be using Ruby as much as I can and wondering how anything else can be more fun to write in.
The question is "What is Perl 6"?
The Question is "Who Cares"
Thanks for your interest in Amber. I'm the author of Amber for Parrot which, although in the early stages of development, will hopefully become sufficiently complete to be really useful, sometime this year.
Although Perl 6 is a nice cleanup and enhancement, the Parrot Virtual Machine is going to be far more important to the computing world than Perl 6. Parrot will do for scripting languages what the JVM and .NET are doing for compiled languages.
Parrot is not yet functionally complete, but it's genuinely usable. It has been a delight to to target Parrot, because most things just work - and when they don't, the Parrot developers have gone out of their way to help.
Parrot development has been pretty rapid recently - although you can't always tell from the documentation which often lags behind.
Paid Q&A/Research
> isn't something you should expect to build a whole program ...
... I guess that'd be "weak typecasting" in this case ...
oh, horse crap on that.
Over 6 years ago, I built a GUI front end to a workflow system (read: database + some business logic) using perl/Tk. An entire department runs the app on it's unix workstations from an NFS mount, and they've been doing it day-in and day-out for that entire 6 year period. All kinds of people have mangled that thing to hell and back, using it in the most inapropriate of ways, yet it's never been broken.
Perl is what it is, man. It got it's name in the 90's as a web programming language, and I guess it got typecast. Heh
Saying perl is dead because PHP r0x0rz so hard is like saying hammers are dead because of nail guns. Pounding nails ain't the only thing a hammer can do.
Perl 6 reminds me of the super-revamped, object-oriented COBOL that came out in the 90s -- by the time this perfect language was created (and it was a decent upgrade, although the OO stuff was so verbose it wasn't funny), COBOL 85 had such a huge installed base that COBOL 9x was irrelevant. The amount of code written to the COBOL 85 standard was immense, and most new development had moved on to other languages. Maybe Perl 6 can escape the Fortran 9x and COBOL 9x trap of being really great languages about a decade too late. The biggest hurdle Perl 6 is going to face is its own installed base. It will have to be 100% compatible with Perl 5 to get people with a code base of Perl 5 code to even think about using it. Plus, it needs to have a compelling story to tell. I was excited about Perl 6 five or six years ago.
Whenever I hear people saying things like this I think that they really lack visibility or understanding into the language's design process. Granted, the coming-to-life of Perl 6 hasn't been the quickest miracle we've seen, but I'm a hundred thousand percent positive that its being done in the best possible manner.
Think about it. Larry Wall accepted numerous RFCs from programmers of all walks, discussing Perl's problems / desires for new features / suggestions for new implementations / ideas how to change the syntax. He commented on each one, indicating whether (1) he agreed with the problem, (2) whether he agreed with the solution, (3) what, if anything, he thought should be done about it.
In the mean time, a radically new language glue system is introduced - Parrot. Perl had such wild success with XS - granted, Parrot isn't just about making language A talk to language B, but it's certainly an example of natural evolution.
As for Pugs, it's been fantastic. It's allowed lots of people to write real and working Perl 6 code (including lots of tests) to evaluate all aspects of the Perl 6 design before it goes into production.
Now, I'm not addressing you directly with this last part; rather, a greater community of Slashdot trolls. If you don't feel like Perl is for you, or if you feel like Perl is no longer for you, fine. Find your way to Ruby, Python, Java or whatever floats your boat.
But please, it's getting really goddamned irritating to have to sift through the comments of a handful of armchair morons that sit at home, interfacing with something called "comments.pl", eating doritos and talking about how the greater Perl community should just drop everything and go to language X, or repeating a tired meme about how the language is making no progress at all (when all they need to do to see the massive progress is read Audrey Tang's blog or visit pugscode.org). And then, there are some mods that feel it appropriate to mark clueless jabs as "insightful".
I am thankful of one thing - Perl's momentum. While everyone else is barking about how (name my scripting language) is great this week for doing web pages or some nonsense, there is still a huge community of devoted, bleeding edge language researchers and smart people, chisel in hand, forming Perl 6 from the rocks.
And while the naysayers are switching languages once a week as they make incremental advantages over eachother -- while they're totally clueless that so many of the 'advancements' in their own languages over the years have been 'borrowed' from or 'inspired' by perl, the aforementioned language scientists are preparing to do once again what Larry Wall did, intentionally or not, when he released Perl on the world - bring about a revolution.
Will Perl 6 finally end the sheer madness of allowing a function to use loop control statements like next and last to meddle with the loops in their calling functions?
Some of us have predecessor's code to use and maintain that do the darnedest things, you know. A bit of protection from the madness of others, that's all I'm asking for.
I believe that this is what you are slandering on about, and this is one possible workaround.
;) The readability alone is a huge win over other languages (IMHO).
I asked around in #ruby-lang about this, and this is not only the #1 bug in Ruby, it will be fixed in 2.0.
If you had a more concrete broken-lexical-scoping example, please feel free to provide.
In the meantime, if this is the biggest Ruby bug, I'm planning on sticking around for sure
Did I say everyone should drop Perl 6? To the contrary, I said I was looking forward to it.
I think you're in denial of what's gone wrong with the P6 process, regardless of how great a language it may be five years from now. You don't develop a language by soliciting opinions and letting things pile up for years without prototyping anything. You certainly don't throw out everything on every level all at once and start up an independent project to develop a virtual machine for an undefined language. Mr. Tang has done things the right way. He wrote a very simple, very straightforward prototype and has been iterating it ever since. Were it not for him--arguably a random hacker--there STILL wouldn't be any kind of P6 prototype.
The P6 process should have started with a simple, high-level testbed for Perl ideas.