Live data from Hacker News

Why Perl Didn't Win

outspeaking.com

81–90 of 187 posts

Re: Why Perl Didn't Win

#81
post #34

Version number is micro, this is a macro question, to wit, the following: When I converted a perl script to python and saved 50% LOC I didn't know which version of which I was using. Am only vaguely aware of the Python 2.x vs. 3 issues. Never was aware of Perl 5 vs. 6. When Python and Ruby fade, I look forward to the hand wringing about how version whatever didn't get pushed out fast enough. But that won't be the rea…

But you're not a thousand companies who have built their business on Python 2 and have no interest in rewriting working code when they don't have to. Your "scripts" are pretty much irrelevant.

Re: Why Perl Didn't Win

#82

Earlier quoted context omitted.

A small correction there, you aren't making them public by putting them in EXPORT. What you're doing is actually using another module to munge the namespace that used your class. In fact by default all functions defined in a package that is used as a class are public by default. And here's the boiler plate for more modern perl: package MyClass; use Moose; 1; You can define properties of the class using has 'property'…

Why do you need to return 1 though? That seems pretty ridiculous.

Technically, you don't need to return 1; you need to return a truthy value. The string "Perl syntax is dumb and hateful" works just as well.

Re: Why Perl Didn't Win

#83
post #55

Earlier quoted context omitted.

Online yes - but a hell of a lot of Tcl was being written too, by people who just couldn't be bothered posting about it.

Tcl was and still is undiscovered gold.

I'm very glad that only game writers are using Tcl for scripting their games. It's a godawful language I'd never want to maintain any real software in. Python and Ruby are bad, but Tcl is a degenerate joke. Let's please leave it undiscovered.

Re: Why Perl Didn't Win

#84
Define won.

This is the way I see it. Perl5 is still being actively developed, perl6 is coming along nicely, cpan more awesome than ever, and there's still work for a perl dev.

If everyone was using the same language, then we'd all suffer because no one would be getting the new ideas.

Competition keeps things healthy.

Re: Why Perl Didn't Win

#85
When I was younger I pushed myself to know Perl 5. I tried to learn Perl with one book. It was surprinsingly hard. I took a simpler book. I also failed grasping Perl. Those were the two recommended books for learning.

I've come to realize years after that Perl is simply difficult to learn, lots of little things to memorize. Its community took pride in language arcana. Things that are now simple in other languages are unbelievably difficult in Perl, like "hashes of arrays of hashes" and things like that.

On top of that, it's also difficult to read. No wonder Perl is losing, and to me the faster the world is cleanup from that, the better.

Re: Why Perl Didn't Win

#86
post #20

You know what rocked? Perl 4. I started on Perl 4 in the mid-1990s. It was fantastic! I started replacing thousand-line C programs with hundred-line Perl programs that were more robust and worked better, and replacing shell scripts made of awkward sed/awk pipelines with neat, tight Perl. Arrays and hashes as first class data structures? Marvelous! Then Perl 5 ruined it all. The ridiculous, bloated "object oriented" s…

Is there an actively maintained fork of Perl 4 (or earlier) somewhere? Sounds like there should be.

There's really not much point. Perl 5 is 99% backwards compatible with Perl 4, so if you think Perl 4 was great, just use the Perl 5 compiler (but none of the new features).

Re: Why Perl Didn't Win

#87

Earlier quoted context omitted.

> And Perl 6? Fourteen years and nothing to show for it ... except a nearly feature-complete [1] compiler [2] and an impressive test suite [3] [1] http://perl6.org/compilers/features [2] http://rakudo.org/ [3] https://github.com/perl6/roast/ > and it'll have to be backwards compatible to all the things violently wrong with Perl 5 Not at all. The whole point about Perl 6 is that it breaks backwards compatibility to fi…

> The whole point about Perl 6 is that it breaks backwards compatibility I think this is is a contributor to why Perl 6 will never amount to anything. That boat has sailed. Python 3 broke backwards compatibility and to my knowledge everybody is still using Python 2. Python has a lot of energy right now, so that might save it, or it might go the way of Perl when the next cool language comes out and everybody jumps shi…

Everybody IN ENTERPRISE is still using Python 2. Realistically, most of the Python ecosystem is compatible 2+3, we are seeing new libraries and programs compatible 3.3+-only, and there's no broad reason to use Python 2 anymore, with minor exceptions.

Re: Why Perl Didn't Win

#88
post #16

Earlier quoted context omitted.

It is a different departure, and it isn't a 1:1 comparison. That's true. But Python3 is an obvious failure and no one is admitting it, yet. I've seen claims from the core dev team about how Python3 is doing well because it has more downloads from Python.org, which is so stupid I won't even address it. A comparison of PyPI download statistics says it all. Python3 migration had many ridiculous ways of pushing people to…

> Is that -really- worth forcing unicode handling? I dunno. I'm new to Python (version 2 so far) and I easily spend 25-50% of my coding time fighting with ascii/unicode issues in Python. I wish Python 2.x just did something smarter. Similar, but not quite as bad, is the need for me to put str() around non-string values in concatenation. Just f'ing doing it for me. I'll write a bunch of code, put together a message in…

To avoid str() calls with concatenation, use % formatting:

    '%s %s' % ('hello', 'world')
Avoiding these implicit behaviors helps avoid bugs; it's worth it.

I'd recommend going for Python 3 unless there's a specific reason (library) keeping you on 2.

Re: Why Perl Didn't Win

#89

I think it is cool to think of one's self as the hero in the story of their life. You battle adversaries, have little victories, complete long story arcs, find a sweetheart and have romance. I feel Perl does not deserve to be mentioned in a hero's tale. There's been too much rankling and nincompoopery out of perl's characters given the size of that community. Far, FAR too much griping. Perl is a bummer, and that is w…

This is pretty good advice to live by. I should keep this in mind for myself.

Re: Why Perl Didn't Win

#90
post #56
post #23

I don't think Perl will ever recover from the Perl 6 fiasco, and I'm worried for Python for the same reason. PHP, on the other hand, handled the PHP 6 "failure" relatively gracefully. There was a bit of stagnation in the days of PHP 5.2 when the devs devoted too much energy to PHP 6 and not enough on improving the current version. But soon, PHP 6 was put on hold and some of its better parts began to be ported to PHP…

Python will be beaten by those caring about performance for writting applications instead of plain server scripts. Those will migrate to Julia, Go, or something else. I used Python a lot in the last decade (2000 - 2004) for automatation and little applications. Nowadays my choice would be OCaml for the same type of tasks. EDIT: typo, automatic => automatation

Those caring about performance are already using Python, in combination with extension modules written in C/Cython. You would have to complete your argument by explaining why they would rather switch to a completely new language without a huge (scientific) ecosystem of libraries, instead of writing more extension modules in the places where it really matters.

The appeal of a scripting language is that "automatation and little applications" do not take a lot of friction to write, I'd say OCaml is less suited in this regard.

Post reply on HN