Perl 5.11.0 Released 235
jamie points out that Perl 5.11.0 was released yesterday, as well as a schedule for future 5.11.x releases, planned for the 20th of every month. Jesse Vincent encouraged testing of the new (development) version, saying, "If you write software in Perl, it is particularly important that you test your software against development releases. While we strive to maintain source compatibility with prior releases wherever possible, it is always possible that a well-intentioned change can have unexpected consequences. If you spot a change in a development release which breaks your code, it's much more likely that we will be able to fix it before the next stable release. If you only test your code against stable releases of Perl, it may not be possible to undo a backwards-incompatible change which breaks your code."
Wow. . . (Score:5, Funny)
It must be real good if it goes to eleven.
Re:Wow. . . (Score:5, Funny)
Is anyone hosting a Perl 5.11.0 House Party? Will there be deviled eggs?
Re: (Score:2)
Is anyone hosting a Perl 5.11.0 House Party? Will there be deviled eggs?
I've gotten several invitations, but they were all in perl, and I've taken it to some of the best linguists of the world, and nobody could make heads or tails of them.
Seriously? (Score:3, Interesting)
and first post i think.
Re: (Score:3, Funny)
Re: (Score:3, Funny)
no, proves instead of being dead it's stagnant. Perl 5.x lingers like scent of dead skunk under the porch while the Frankenstein of Perl 6 is still on the mad scientist's table, metaphorically getting body parts sewn on from morgues and cemeteries and hospitals across the globe. Perl 6 is the undead Creeper [wikipedia.org] of programming languages
Where's BadAnalogyGuy when you need him?
Re:Seriously? (Score:5, Informative)
Uhm...
Perl 5 development is stagnant for one simple reason: Perl 5 is near perfect, there is nothing left to be developed there.
Some wanted better Perl with more consistent syntax. That's what Perl 6 is for. 5.10/etc are intermediate releases serving the purpose of facilitating future migration to Perl 6: some ambiguous constructs of previous version are gone in 5.10/etc.
I personally do not care much about 6th - I yet to find any pathological problem in Perl 5 which would persuade me somehow to move to next big thing. Perl 5 is well documented, has piles of modules and examples all over the net. I see no point to move from it.
Re:Seriously? (Score:5, Funny)
and Perl use had dropped to 15% of its former level in the past five years because the perfect number of applications have been developed with it, there's almost no software left to write.
Re:Seriously? (Score:4, Insightful)
Benchmarks and whatnot have little relevance to the real world.
It's true that thanks to the "there is more than one way to do the same thing" isn't very appealing to commercial companies. But at the same time in the past 15+ years I work, literally every employer had some part of its infrastructure supported by Perl programs.
Perl isn't for everyone. Obviously simpler languages like Java or C# or Python would tend to dominate because barrier to entry is lower. Nothing new.
Perl dominated Web in the times when it was a new thing. Internet itself was a new thing. And obviously to start something new you need smart and experienced people. Among such people Perl tend to be quite popular. Now Web design became something what even your mom can do - tools are abundant. There is no need to employ such heavy lifting tools like Perl anymore.
But thinking that Perl was used exclusively to do web stuff is a rather silly mistake to make.
Re: (Score:3, Interesting)
I call BS (or, less confrontationally, perhaps simply "you know of very few companies"). Microsoft uses Perl throughout their build environment.
Re: (Score:3, Insightful)
I personally know of exactly one company that uses Perl at the moment, and that's only for text cleanup.
Perhaps you don't know many companies :-)
Re: (Score:3, Insightful)
Of course Java is simpler than Perl.
Java is strict typed - Perl is weak typed.
Java does support run-time dynamic loading of classes - Perl supports run-time compilation from text.
Java's class tree is static - Perl's one is dynamic and can be twisted any funny way at any point of time.
Java is explicit language (has no/little of side-effects) - many Perl constructs are by definition implicit and some side-effects are documented as features.
In the end, Java is simpler to learn, simpler to devel
Re: (Score:2)
You forgot to link to the data supporting this figure. But what the hell, it's only another smear of the perl community, it's not like you're ever going to be called on it.
Re: (Score:2)
I know you mean well, but despite the fact that it's certainly true that perl5 is a mature language, there's plenty of active development happening in the perl5 world. There were a lot of interesting features added to perl5 with the 5.10 release. Just to pick one, they added recursive regular expressions, which enabled Damian Conway to write this: Regexp::Grammars [cpan.org].
Re:Seriously? (Score:4, Informative)
Its not an indication of anything. 5.11 is a development branch. In theory it should be released the moment they implement one feature that doesn't belong in 5.10.
Re: (Score:2)
The statement that they are unsure if they are going to break something is probably just the thing to kill it in my eyes. I have about 50,500 lines of perl running a production system, and this announcement has me seriously thinking I should port it all to a language I can rely on. I don't need a routine yum update breaking my system, and I sure as hell don't have time to test their code constantly.
Re: (Score:3, Interesting)
I'm sure you are just being a wag, because obviously anyone concerned about the stability of a production system like that wouldn't make foolish mistakes such as changing the version of their runtimes or libraries or platforms.
You don't mean to seriously suggest that you would rewrite 50,000 lines of code rather than just, you know, *do nothing*, and not update anything?
Also try Perl 6 (Score:5, Insightful)
Re: (Score:3, Insightful)
uh, I'd rather do an implementation in a language that's not in pre-release status. My clients like their money handled by language that 1. exists 2. has stable specification 3. has stable releases
Re:Also try Perl 6 (Score:5, Informative)
1. exists
People have been using Perl 6 for years now. It certainly exists.
2. has stable specification
"Stable" is a biologist term, it means "dead". The problem with a set specification (the "waterfall" model) is you discover after something was implemented that it was a bad idea, the whirlpool model prevents this.
3. has stable releases
Rakudo has a release every month. The "big" release is coming next April.
Re: (Score:2)
no No NO. partial implementations of a pre-release language in flux exist, people who need to write reliable real world applications aren't going to touch that with ten foot pole. Perl 6 is the HURD of programming languages, high school science project with some cool ideas here and there.
Re: (Score:2)
partial implementations of a pre-release language in flux exist, people who need to write reliable real world applications aren't going to touch that with ten foot pole.
People only code in languages that never change?
Re: (Score:2)
for real world apps, they code in languages that have definite stable production release version.
Re: (Score:3, Informative)
Who are these "people" using "Perl 6" for "years"? Name them now, please. The only people I know "using" Perl 6 are those who installed Rakudo, saw that it was a piece of cowshit, and promptly ignored it for being the excrement that it is.
That's weird, because the number of projects known the proto perl6 module manager are increasing [perlgeek.de]. Rakudo is passing more spectests [rakudo.de], and its commits are increasing [rakudo.de]. There's an entire IRC channel full of users on freenode in #perl6 is you want a list.
a lack of changes that will break our code
A stagnant and dead product gets no changes that will break your code. It is that simple.
I don't give a fuck if Rakudo releases every month. My clients don't give a fuck.
Maybe no one cares what your opinions about Perl 6 are? But here we are.
Perl 6 and Rakudo do not.
Really? Can you give examples of problems in Rakudo that would stop it being used in production? Didn'
Re: (Score:2, Insightful)
"a Perl 6 implementation on the Parrot Virtual Machine, already implements a significant portion of the language."
you really can't seriously suggest I recommend this to a paying client? Perl 6 is pre-release as it has been for 9 years, parrot just has its first 1.0 release, and Rakudo implements some subset of Perl pre-6?
Re: (Score:2, Informative)
I have a year's worth of benchmarks and profiles that disagree with you.
Re: (Score:3, Informative)
It makes the JVM look efficient
The JVM is really VERY good by VM standards. Yeah the class libraries are a bit bloated leading to long startup times but other than that it is one of the few VMs to come anywhere close to (and in some benchmarks even exceed) the performance of tradtional compiled languages.
According to http://shootout.alioth.debian.org/u64q/benchmark.php?test=all&lang=all&d=data&gpp=on&java=on&ghc=on&csharp=on&sbcl=on&hipe=on&mzscheme=on&lua=on&php= [debian.org]
Re: (Score:2)
So clearly it's not targeted at you. Nobody cares.
Re: (Score:2)
clearly it's not targeted at anyone who writes real world scripting langauge applications. everyone cares since no one is using it other than as a fun diversion to fart around with ideas
Re: (Score:2)
I don't think major implementations for professional clients is the right time to be "adventurous".
Re: (Score:2)
haha, but note perl 5.8 or 5.10 *would* meet my criteria. pre-release 6 does not
Other stuff that is out (Score:5, Funny)
Kernel 2.6.31.1
PHP 5.2.11
Apache 2.2.13
Debian 5.0.3
Keep up with all those thrilling point released with slashdot.org
Perl has died in industry. (Score:5, Interesting)
For software of any appreciable size, Perl has unfortunately died in industry. People just aren't using it for anything more than 10-line throwaway scripts.
Perl 6 was something those of us in industry had been anticipating with glee. We expected it to modernize the Perl platform, and make it a contender against Java, .NET and C++ for large-scale software development. But we also expected we'd have that around 2005. It's nearly 2010, and we still don't see much real progress on that front. Rakudo just isn't a production-grade product yet.
I'm sad to admit it, but instead of waiting for incremental Perl 5 releases for the next decade until Perl 6 is finally mature enough, the company I'm with has started to migrate from Perl to Python. Unlike the Perl community, the Python community has shown with Python 3 that they're capable of working together to create a major release with many new features in a relatively short amount of time (especially compared to the Perl 6 effort).
Rewriting our approximately 3 million lines of Perl code into Python has actually gone reasonably well. Although I was a staunch defender of Perl, I do have to give Python its kudos. Every day it looks more and more like we've made the right choice moving away from Perl, and towards Python.
Re: (Score:3, Insightful)
People just aren't using it for anything more than 10-line throwaway scripts.
You just posted on a website running Slash. Although it is Perl, so maybe the codebase is less than ten lines.
But we also expected we'd have that around 2005.
You were expecting it the same year the very first implementation (Pugs) was started? That was silly of you.
It's nearly 2010, and we still don't see much real progress on that front. Rakudo just isn't a production-grade product yet.
Unless lives are at risk, Rakudo is stable enough for production (although you may want to wait for the April "Rakudo Star" release).
I'm sad to admit it, but instead of waiting for incremental Perl 5 releases for the next decade until Perl 6 is finally mature enough
Perl 6 != Perl 5. They are two VERY different languages. Perl 5 and 6 will continue to be maintained in parallel.
until Perl 6 is finally mature enough, the company I'm with has started to migrate from Perl to Python.
You're complaining about maturity and yet you're
Re:Perl has died in industry. (Score:5, Interesting)
Ok, I actually do use perl professionally, but even I realize there are some serious problems with it. The reality is a middle ground between you and the grandparent.
But we also expected we'd have that around 2005.
You were expecting it the same year the very first implementation (Pugs) was started? That was silly of you.
Pugs was started in 2005 as an attempt to inject life into what looked like a dying project. The language spec started in 2000. In five years they hadn't nailed it down. In ten years there still isn't a working implementation.
It's nearly 2010, and we still don't see much real progress on that front. Rakudo just isn't a production-grade product yet.
Unless lives are at risk, Rakudo is stable enough for production (although you may want to wait for the April "Rakudo Star" release).
That is EXTREMELY wishful thinking. It may have changed in the last couple months, but I tried this perl 6 code out earlier in the summer:
my $blah = "blah";
$blah = $blah.reverse;
print $blah;
and that SIMPLE code resulted in an infinite recursion error.
I'm sad to admit it, but instead of waiting for incremental Perl 5 releases for the next decade until Perl 6 is finally mature enough
Perl 6 != Perl 5. They are two VERY different languages. Perl 5 and 6 will continue to be maintained in parallel.
Perl 5 has problems inherent with the language that inhibit large scale use, and this is coming from someone who works on a multi-million line perl 5 project. Recent frameworks have tried to address the problems by grafting perl6 like features onto perl5, but they always impact performance, and are never perfect. And goddammit, I've still found no way around the broken behavior of the SUPER keyword.
until Perl 6 is finally mature enough, the company I'm with has started to migrate from Perl to Python.
You're complaining about maturity and yet you're using Python?
Unlike the Perl community, the Python community has shown with Python 3 that they're capable of working together to create a major release with many new features in a relatively short amount of time (especially compared to the Perl 6 effort).
Perl 6 has many, many more changes than Python 3. It is an entire rewrite of the language from the ground up, they didn't just change the print statement to a function and call it a day.
Rewriting our approximately 3 million lines of Perl code into Python has actually gone reasonably well.
That would have been what, 6 million lines in Python? Now I know you're trolling.
You're being a bit unfair to Python. I'm not a huge fan of the language (if I had to move anywhere it'd be ruby), but python 3 while it didn't change much in the language itself, was a huge boost in performance to the interpreter. There are incremental changes happening to the perl5 interpreter, but nothing major structural can, because the codebase just isn't very maintainable. In fact that was one of the main reasons they decided to scrap it and develop parrot from scratch instead of working from the perl5 base. Try embedding the python interpreter and the perl5 interpreter in a C program, see which one has internals that make more sense.
Not to mention that python is immensely more parsable. There are identical python interpreters in C, on the JVM, and on the CLR. Its been said that the only thing that can parse perl5 is perl5, and that is evidenced by the fact that the parrot project gave up on implementing a perl5 parser.
That's not to say there aren't things python does wrong. Every time there's a point release it seems everyone's code completely breaks, while perl5 is backward compatible to perl1. And frankly, I hate significant whitespace, but that's a personal preference.
Regardess things are not completely happy in the perl world.
Re: (Score:3, Informative)
my $blah = "blah"; $blah = $blah.reverse; print $blah; and that SIMPLE code resulted in an infinite recursion error.
Might be because it's wrong? reverse is for lists.
$ perl6
> my $blah = 'blah'; $blah = $blah.flip; say $blah;
halb
> my @a = ; say @a.reverse;
dcba
>
Re: (Score:2)
my @a = <a b c d>; say @a.reverse;
Re: (Score:3, Insightful)
I thought there was a reverse string function. In that case, why is it an infinite recursion and not a method not found?
Re: (Score:2)
Re:Perl has died in industry. (Score:4, Interesting)
Ok, but why would that result in infinite recursion? Correct or not, that code still exposes a bug.
Re:Perl has died in industry. (Score:5, Insightful)
Then maybe they need to have two VERY different names. Have we learned nothing from the problems caused by Java and JavaScript? It's nearly 2010 and people still think those two languages have something in common with one another. Now we have two different languages with the same name. Did anyone think that that would not cause confusion?
Re: (Score:2)
You just posted on a website running Slash.
Is that supposed to impress us? Slashdot is by far the most buggy and unstable website I visit.
Re: (Score:2)
Is that supposed to impress us? Slashdot is by far the most buggy and unstable website I visit.
To a large extent, the reason for that is because the editorial staff felt a need to "modernise," presumably due to pressure from the brainless Web 2.0 crowd.
Pre-2.0, the site was as solid as a rock. The editors should have ignored whoever was howling for cosmetic changes and stayed with their instincts.
Re: (Score:2, Informative)
No, I'm actually programming. How about you? What have you produced lately?
who uses PERL (Score:3, Informative)
"Large and high profile [luv.asn.au] websites using Perl [perlfoundation.org] include: Slashdot, The Internet Movie Database, Amazon.com, CMPnet technical magazines
Re: (Score:3, Interesting)
Also, the AirWave Management Platform [airwave.com] is in Perl (with C/XS/etc as appropriate in certain places). It sells for thousands-of to millions-of dollars, depending on your licensing and support needs. It's basically the only wireless network NMS out there which supports multiple brands of access point (Aruba, Cisco, HP/Colubris, Meru, Proxim, Symbol/Motorola, Foundry...) and its main competitor is basically Cisco WCS, which only manages/monitors Cisco devices.
Perl's take on object-oriented programming seems a
Re:who uses PERL (Score:4, Informative)
Is that why the interface is such fucking shit?
include: Slashdot
I can't believe I have to explain this to somebody reading Slashdot, but interface is built with html and css, not perl (or any other server language).
Re: (Score:2)
For software of any appreciable size, Perl has unfortunately died in industry. People just aren't using it for anything more than 10-line throwaway scripts.
Wasn't that the whole point of Perl? Perhaps we should be ashamed for doing large projects with it in the first place.
Re: (Score:2)
For software of any appreciable size, Perl has unfortunately died in industry.
Industry doesn't end with "web design".
People just aren't using it for anything more than 10-line throwaway scripts.
Perl is one of those languages which grows on you. I had wrote year ago primitive forking HTTP servers with minimalistic CGI support. In the time it was 20 lines + 100 lines for the CGI scripts themselve. Now that is about 5K lines of code.
But in the end, yes, many 10-line Perl scripts become throwaway - when you realize how to do the job in 1 line.
Perl 6 was something those of us in industry had been anticipating with glee. We expected it to modernize the Perl platform, and make it a contender against Java, .NET and C++ for large-scale software development. But we also expected we'd have that around 2005. It's nearly 2010, and we still don't see much real progress on that front. Rakudo just isn't a production-grade product yet.
Change your dealer. He sells you something funny. Or get a real job.
I'm sad to admit it, but instead of waiting for incremental Perl 5 releases for the next decade until Perl 6 is finally mature enough, the company I'm with has started to migrate from Perl to Python. Unlike the Perl community, the Python community has shown with Python 3 that they're capable of working together to create a major release with many new features in a relatively short amount of time (especially compared to the Perl 6 effort).
If you were unable to exploit Perl 5 fully - it
Re: (Score:2)
I fully agree : Perl is a language which takes time to learn, but the most fantastic thing about is that code that I have written 9 year ago hasn't had the need to be changed, despite going from Perl 5.6.0 to 5.10.0.
What I learned was that the following books (in addition to the traditional camel book) are a valuable addition to Perl knowledge :
If you work through these books, then you will understand wh
Re: (Score:2)
So when you say "in industry" you mean your industry, software development (not IT), and you mean dead for large projects (not dead).
Re: (Score:2, Informative)
Re: (Score:2, Informative)
Guido switched jobs in early 2000 in part to work on Python 3000. Eight and a half years is not a "relatively short amount of time" for the delta between Python 2 and Python 3.
No, Completely Wrong (Score:2)
I find it is much easier to get people from a traditional programming environment, FORTRAN, C, C++ productive in Python than Perl, since the style is much more compatible. Perl as line noise is a joke and is easy to write well and debug.
But again, you must learn your tools, but all learning is at a cost. Also developers tend to overcomplicate.
The which is the best Programming language | Methodology
Re: (Score:3, Insightful)
Wait, wait. I'm not clear on your concept. Are you saying that compilation makes programs more stable and maintainable? What's the connection between stability, maintainability, and compilation?
Are you saying that if I ran C or C++ code inside an interpreter (and there are some), then that code would somehow become less stable and maintainable?
Re: (Score:2, Interesting)
But I gave up on Perl because CPAN never worked properly on Solaris (I know about the gcc version, don't get me started). So it seems after the Perl kids grew
Re:Perl has died in industry (mod away, kids) (Score:4, Funny)
*cough* *cough* (Score:2, Insightful)
...
unit tests.
Re: (Score:2, Insightful)
Unit tests are only as good as the programmer that programs them.
Many times, your solution is not cut and dry.
Re:*cough* *cough* (Score:5, Informative)
Did you know for example that when you upload something to CPAN, it gets automatically smoked [cpantesters.org] on dozens of platforms and hundreds of different boxes, test reports sent to the author and assistance provided to diagnose platform specific problems if needed?
Manual testing is for the problems not caught by the huge array of automated tests.
Obligatory (Score:3, Funny)
Perl -- Goodbye Old Friend (Score:2)
Perl was so. fricking. awesome. back when the only choices were shell scripts or compiled apps. It was such a leap forward. Who wouldn't be excited about Perl back in the '90s
But we're far beyond the sophistication of Perl. I'm not saying that you can't do some pretty fricking awesome things in Perl, but that Perl doesn't do many of the meta-tasks that we've come to expect in languages. These supporting features don't necessarily make things run or run fast, but rather help developers in the process of crea
Re: (Score:2)
Perl is awesome. Still today it is the best choice for large applications. I dont know where people get that it is not elegant, it is an extremely elegant language to use and its design makes good sense. Especially compared to C++. Perl produces far better code than what you would do with C++, easier to debug, etc.
Re: (Score:2)
1) Easy Refactoring.
2) Somewhat related - Easy to write an IDE for. You can't right-click on a method call in some perl code and go "show definition". This is partially the nature of this class of languages though.
3) Something better than POD. Make it XML based. Steal from Javadoc or XMLdoc.
4) One damn way to inherit and one damn way to build a class. Yeah I know Perl wasn't originally OO, and it shows.
Perl was my bread and butter for many years, but quite frankly I've been spoiled rotten by the new la
Re: (Score:2)
Why? Pod kinda sucks compared to the other two. I guess that is just personal though.
Whats new? (Score:2)
Hey I still use and love perl!
Is there a list online of the cool new features?
Also, people dumping perl... what are you moving to?
(Thanks)
What do people use Perl for? (Score:2)
I've found I can do pretty much everything I need with shell. I've also tended to find that I can store and retrieve whatever data I'm working with in flatfiles with awk, as well. Some people might find that horribly primitive, but truthfully flat text is a lot easier for me to understand and work with than XML.
I feel that awk has an excessively bad rap, to be honest. I know of some people who like it, but it doesn't seem to get used much. I find it very useful at times.
What do people use Perl for?
Re: (Score:2, Insightful)
I use Perl for one-time jobs... Repairing badly-formatted 80GB data files. Splitting flat files into multiple output files. Testing uniqueness of various fields. Finding the line(s) in a 250GB file that is crashing the sqlload program, and fixing it, because you have two hours or we'll lose the project. (nevermind it's the client's data). Editing several files to purge or excise fields or characters before doing serious work with them. Most of these I do via the command line. I'll write actual Perl
Re: (Score:2)
I acknowledge; this was a dumb comment. I know Perl can be used as a CGI scripting language, and for any number of other things besides.
Let me clarify, however; what do people use Perl for, that they *wouldn't* write in another language?
Re: (Score:2)
I have no clue? You assign values to an array in Perl in pretty much the same way as in any other language: $array[1] = $value;
Re: (Score:2)
uh huh, then there's @array=qw(its whale guts) or @array=("its","whale","guts")
behold the whale guts!
Re:Great! Another language to learn! (Score:5, Informative)
qw(the list of strings operator) is awesome and is equivalent to a list of strings. The main complication of Perl data types: If the thing you're assigning to, or getting out, is an array, it starts with an @: @states = ("Alabama", "Alaska", "Arizona", "Arkansas"); (or if you don't like typing ",s all day long, @states = qw(Alabama Alaska Arizona Arkansas). If the thing you're assigning to, or getting out, is a scalar, it starts with a $: $states[0] eq 'Alabama' or $states[0] = "Canada". If you want an array reference, the reference itself is a scalar, and the thing you're pulling out is also a scalar because that's all you can put into arrays (which is why complex data structures are arrays or hashes with references to other arrays or hashes inside). $stateref = \@states; $stateref->[0] eq 'Canada'; $other_ref = [qw(manitoba vancouver tiajuana)]; @array_again = @$stateref; @array_again = @{$other_ref}.
And that's really all there is to it, unless you want array slices or something (and who doesn't? @threestates = @states[0..3]).... or getting those out of a reference (@{$stateref}[0..3]).
Oh, and hashes work on the same principle, but with % for the hash, {} for the indexes, () for populating the hash with an even-sized list, {} for the anonymous reference, and you can do @a_codes = @state_to_postal_codes{qw(alabama alaska arizona arkanasas)}
Re: (Score:2)
I love Perl, but I'll admit that after 6 months away I'm having to think a bit to get back into the all the reference/derefernce idioms.
So when the parent post explaining it all gets modded as funny... well, I hate to admit it, but that's kind of funny itself.
Re: (Score:3, Insightful)
Every so often when I think that Perl might be worth considering again, I come across some truly baffling example of misguided intentions like this.
I'm sure someone thought it was a brilliant idea to save keystrokes - why type "list.GetRange(0,3)" when you can create syntax using random unused symbols on your keyboard like @states[0..3]? After all, the metric we use to judge programmer productivity is the number of keystrokes they use writing code, not the maintainability of their code.
Oh yeah! And let's
Re:Great! Another language to learn! (Score:4, Insightful)
What random symbols? the 0..3 type of syntax seems to be pretty common outside of Perl as well.
And Perl doesn't have a .GetRange(0,3) type syntax since it's not an OO language originally. OO was grafted on to it later, so a list in Perl is still a list, and not an object with methods.
Same logic could apply to exactly any other function. Personally I think "print" is a much more logical name for a function a programmer might want to use than "qw" (if your code has functions with names like that, I don't want to deal with it).
As a language construct though, it'd be weird if "qw" had a much longer name, since it's intended to help make things shorter. And it probably stands for "quote words" which seems pretty logical given what it does.
Also, this complaint seems odd in regards to Perl, which has a much cleaner namespace than many other languages, and helps keeping it clean.
I don't get this part?
I agree, though in part only.
Seriously, Perl gives you a choice. If you don't like it, don't use it. I don't use every single construct I can either. Sometimes they help:
Why type all those quotes and commas, which can easily be messed up, leading to a compile failure? It's even more readable this way. Sometimes things like $_ help inside things like map, sometimes they make things more confusing. A good programmer knows when a tool is appropiate.
Sometimes quick and dirty is a good thing. When I make a log parser in 15 minutes to gather some stats for a one time event, it helps being able to take some shortcuts. But those are by no means necessary, and I don't use them when writing bigger things.
Re: (Score:3, Interesting)
How about:
Python's full grammar specification [python.org] fits on two pages of A4.
Re: (Score:2)
So you can also do @list[1,1,2,3,5,8,13,21,34] or @list[getFibonacci(0..8)] or any one of a number of things like that. So you can say
.
Re: (Score:3, Interesting)
OK, then there's Ruby. It preserves the best pieces of Perl, Smalltalk, Python, and Lisp.
Perl's `qw(one two three);` actually works in Ruby as `%w{one two three}` but many constructs are semi-close to Perl.
It is considered to be in the Perl family of languages but is a supremely cleaned up / ultra powerful OOP language, in the Smalltalk vein.
In general, Ruby is as pragmatic as Perl, if not more so. It has a cleaner, more readable syntax, and code is very/most often shorter than a Perl equivalent.
As an ex-
Re: (Score:2)
qw and similar are there just to make assigning multiple values more comfortable. You can completely ignore its existence and not miss anything.
That leaves the '@array=("its","whale","guts")' form, which is also very similar to many other languages.
qw vs. explode or split (Score:2)
qw and similar are there just to make assigning multiple values more comfortable. You can completely ignore its existence and not miss anything.
But what does Perl qw do that PHP explode() or Python str.split() doesn't?
Re: (Score:3, Informative)
Perl has that too.
With the additional advantage of that it uses a regular expression, so you can split by a much more complex criteria.
The difference is that qw happens at compile time, and split happens at runtime, so it has efficiency advantages. Additionally, qw lets you choose the delimiter. For instance:
Re: (Score:2)
The difference is that qw happens at compile time, and split happens at runtime, so it has efficiency advantages.
That's an implementation issue. A smart implementation of the language would apply what C calls the as if rule [sco.com] to methods of literal values. I don't know whether the Python bytecode compiler already does this.
Re: (Score:2)
It doesn't actually have to split a string, which can be considered a reasonably expensive operation.
The parser still has to split the string when compiling the program to bytecode.
Re: (Score:3, Insightful)
Limitations in studio, please.
Larry is old enough we should start placing bets, does he die before Perl 6 comes out?
I'm accepting bets whether a card runs you over before you read the comment.
Re: (Score:2, Insightful)
too many better competitors with powerful features have sprung up
Such as... what? A Visual Basic clone (Python), a rewrite of VB itself (.Net), a Java ripoff (C#), something that brings a website to its knees before it hits 20 simultaneous users (Ruby), or an absolutely appalling clusterfuck of a language that can't even use consistent function names within a single module (its name shall not be spoken).
Re: (Score:3, Funny)
an absolutely appalling clusterfuck of a language that can't even use consistent function names within a single module (its name shall not be spoken).
I think its name should be spoken. I doubt that I'm the only one who doesn't know what language you're talking about.
Let's just say that you might need a Physicians Health Plan after trying to remember whether or not a function name has an underscore.
Re: (Score:2, Informative)
Re: (Score:2)
\the syntax is just to arcane.
Perhaps the syntax of English is just a little too arcane as well?
Re:netcraft didn't confirm but Perl is dying (Score:4, Insightful)
nice to hear of universe between your ears, where it's 1999. outside of that, in real world use, Perl has plummeted in use in last five years, from third most widely used language to eleventh. the language has stagnated and any Perl creative effort being wasted on the undead Perl 6.
Re: (Score:2, Informative)
Really? [indeed.com] Or are you just making stuff up?
Re: (Score:2)
uh, your graph shows constant ~1% of all language *internet listings* of Perl for the last four years. Proving what, I'm not sure. And let me tell you how internet job listings work. One place has a real job, and then 30 other recruiting firms see that job and also run same listing with slight variabtion hoping to find person they can then present to the original company so they can get a cut. So the number of real actual Perl jobs on your graph is in the "statistical noise" percentage of perhaps 0.03% o
Add SQL to the list (Score:2)
Add SQL to the list and it beats even C.
http://www.indeed.com/jobtrends?q=c%2C+java%2C+perl%2C+php%2C+python%2C+ruby%2C+sql&l= [indeed.com]
Cool ass site! This rocks... (Score:2)
I know I already replied to this. But if you click "relative" you get an idea of the growth in language jobs (though I suspect that the y axis needs to be logarithmic). On a whim I decided to include web frameworks too. e.g. Django, ruby on rails. SQL and C are still on top (followed by VBA) in the absolute, but in relative Ruby on Rails and Django appear to smoke everything else.
absolute: http://www.indeed.com/jobtrends?q=c%2C+java%2C+perl%2C+php%2C+python%2C+ruby%2C+sql%2C+postgresql%2C+mysql%2C+django%2C [indeed.com]
Re: (Score:3, Informative)
We must REALLY be behind the times like it's 1999. Because a lot of our stuff is not only written in Perl, but deployed on FreeBSD too!
Most of our stuff was in PHP and usually what the public sees in the terms of our control panel and shopping cart system is PHP. But behind the scenes, it's all perl. All our billing scripts, maintenance scripts, log parsing scripts, reporting scripts, and API are all Perl. Anything that needs extensive regex is Perl. Granted, most of those scripts I've built probably 1
Re: (Score:3, Insightful)
Yeah, I'm gonna use this statistic, but only the part of it that I like.
Re: (Score:2)
hahaha, never heard of github until now? and the fifth most popular language of these gits means what exactly? bet Perl was their #1 a few years back if that site more than four years old
Re: (Score:2)
But there is more!
print qq{The title is $Book.\n}; # double quotes, not forgetting the \n
print q!The title is !.$Book.q!.\n!; # single quotes, not forgetting the \n
Quoting is the f***ing best feature in Perl. Ever.
Re: (Score:2)
#!/usr/bin/perl -wT
use strict;
sub bar {
my $c=shift||'';
return join(" ","Perl For Dummies", $c);
}
my $foo=<<"EOT";
Hey everyone, guess what...
The title of the book is "${\( bar(2))}".
Go figure.
EOT
print $foo;
Yes it's ugly that you can in effect interpolate functions in a huge blob of text. But it does save a lot of time compared to the printf or python way. You don't have to keep checking to see if the number of %s matches the number of things you want to interpo
Re: (Score:2)
Re: (Score:2)
Thats a bunch of nonsense. Perl interpretor does not use anywhere near that. Its pretty efficient, and only uses a small amount of ram. How do people come up with these lies?