http://qs1969.pair.com?node_id=171067

So thanks to Ovid (here) and Tilly (here), I've been reading a lot of Paul Graham's Lisp advocacy. In one article, he claims that, among other things, all languages approach Lisp. (I'm not particularly strong on the theory, but IIRC lambda calculus is Turing-equivalent, so he's de dicto correct for any Turing-complete language. But that's not my point.) He talks about how Perl features many Lisp-isms, and how Python is steadily progressing towards apotheosis as Yet Another Lisp Dialect.

Graham's basic, unspoken axiom is that Lisp is the One True Way. Well, we've heard that one before. "Structured Languages are the One True Way." "Object-Oriented Programming is the One True Way." "AI is the One True Way." Yeah, yeah, yeah.

Myself, I suspect that in twenty years, most of the programming will be done by the language, and that most of the time we'll be writing Constraint Logic programs. I'm guessing that our programming environment in a couple of decades will be an optimizing compiler writ large, that can look at a constraint-based description of a problem, determine the best approach, and write (and execute) code to solve it. Sure, a lot of the interesting work will be done at a much lower level, but for most business problems, CLP will be the way to go. (I also think that regexes will be the preferred way to express those constraints.) Who cares what I think? Predicting the future is almost universally a futile exercise.

My copy of High Performance Computing, Second Edition cites an anonymous quote:

"I don't know what language they will be using to program high performance computers 10 years from now, but we do know it will be called FORTRAN."

I can do one better than that:

"I don't know what language we'll be using to solve ubiquitous, practical problems 20 years from know, but I do know it will be called Perl."

Why? Because Perl borrows shamelessly and ruthlessly the idioms and techniques of other languages and of emergent styles of programming, and makes them work together. If CLP really is the way to go, we'll have a Logic::CLP module for Perl 6 and CLP builtins in Perl 7. If a totally different model of computation appears, we'll have that within a couple of releases.

Perl, and its developers, concentrate on making it easy to solve real problems. Stylistic elegance, mathematical brilliance, Byte-headlining buzzwords and, when necessary, programming tradition all take a back seat to that goal.

Perl isn't the One True Way because it's Perl, Perl is as close as we've ever come to the One True Way because it incorporates most of the other, reasonably successful, One True Ways. And instead of sitting back and dogmatically defending its current form, Perl seeks out and assimilates more techniques. Currying. Hyper operators. Anonymous classes (IMHO, the one thing that Java got so very right). Firm typing. More explicit declarations. If it works, we'll take it.

In hoc lingua vinces

--
The hell with paco, vote for Erudil!
/msg me if you downvote this node, please.
:wq

Replies are listed 'Best First'.
Re: Total Perl Domination
by cjf (Parson) on Jun 03, 2002 at 00:52 UTC
    I don't know what language we'll be using to solve ubiquitous, practical problems 20 years from now, but I do know it will be called Perl.

    Don't be so sure. There are many other languages out there, all of which have their uses and several of which do what Perl does at the same level (or possibly even better?).

    Many things change considerably over time as well. Will Perl be able keep up with these changes, or will it amass too much baggage to remain useful? Keep in mind that overzealous advocates who turn people off a language can be considered "baggage" as well.

    You're also preaching to the converted here. I see far too many of these "Why Perl is so good" posts. It would be far, far better to focus on why Perl isn't so good, and how we can fix it.

    That should be enough to get the flames started :).

      In accordance to what I noted above: it would, if this place weren't about Perl - which has always been aware of the fact that other languages have their merits and concerned itself with how to learn from them, rather than how to be able to beat them in clash-of-zealots situations. Perl is humble.

      Makeshifts last the longest.

        I'm assuming you're referring to the last paragraph of my post(?). If this is the case please see any thread (either here or on any other Perl-related site) with "vs." in the title. That should provide you with plenty of counter-examples.

      > Don't be so sure. There are many other languages
      > out there, all of which have their uses and several
      > of which do what Perl does at the same level (or
      > possibly even better?).

      The language that will be the problem solver du jour 20 years from now will have more to do with what 800 pound gorilla is backing it and less with what it can actually get done. Perl will always be an underdog in the corporate world that we live in.

      > It would be far, far better to focus on why Perl
      > isn't so good, and how we can fix it.

      I think that they have that pretty well covered.

      ()-()
       \"/
        `                                                     
      
          I don't know what language we'll be using to solve ubiquitous, practical problems 20 years from now, but I do know it will be called Perl.
        Don't be so sure. There are many other languages out there, all of which have their uses and several of which do what Perl does at the same level (or possibly even better?).

      That's pretty much exactly my point. There are many other languages out there, and the overwhelming majority of them do at least a few things better than Perl. But Perl has a tradition of embracing and incorporating the good bits, rather than sticking to its guns and pretending that it's way is the only way. (TIMTOWTDI, remember?) So (I contend that) Perl in 20 years may look nothing like it does now, but it'll still be Perl, not some language that replaced Perl's successor.

      --
      The hell with paco, vote for Erudil!
      /msg me if you downvote this node, please.
      :wq

        Sorry, I wasn't very clear. By "and several of which do what Perl does at the same level" I meant what you are referring to - borrowing from other languages.

Re: Total Perl Domination
by ariels (Curate) on Jun 03, 2002 at 08:21 UTC
    I use Perl wherever I can (and that's quite a lot). I don't see it as taking over the world. And I don't want it to do that.

    My job is in Computational Biology. Some of the work requires gluing together various "bits": data in various formats, lots of fairly simple string work, nice output reports, etc. Perl is close to ideal for that. It's also excellent for running various programs, for automating tasks such as database downloads, for quick&dirty GUI programming, and similar tasks.

    It helps if you help Perl help you: when I created a new data format, I gave it a nice C interface (for our C programs). Not wanting to write (and maintain!) 2 parsers, I wrapped the C interface, with SWIG, to be usable from Perl. The Perl interface is object-oriented, of course, so it's actually nicer than the C interface. And recently I removed the need to free the allocated C objects manually, making the Perl interface even nicer.

    But I also have to use C. Perl offers excellent performance for "built-in" tasks, such as regexp matching. But if you require high performance with non built-in structures and algorithms, the performance hit is huge. So the core, high performance tasks are done in C (or C++).

    Perl's goal never was to replace other languages; it does its best to work with the others (unlike, say, SmallTalk or Prolog, and even most Lisps), and it makes some (maybe even many) types of programming easier and more pleasant. But it's no panacea, nor is it meant to be one.

    ``Use the right tool for the job''. If that means Perl, use it. If it means something else, use that.

Re: Total Perl Domination
by TheDamian (Vicar) on Jun 04, 2002 at 07:38 UTC
    Thanks for this thread.

    It's incredibly heartening to those of us who are grinding away at designing the next generation of Perl to know that at least some folks "get" it.

    Apocalypse 5 ("Regexes and Parsing") will be released in the next day or so and it's going to be a prime example of that "stealing from the rich" philosophy. Regexes are going to change Big Time (e.g. imagine having the full power of yacc/RecDescent native in Perl!)

    There will no doubt be much kicking and screaming about some of the fundamental changes we're planning. But we're doing it precisely because certain other languages currently do some aspects of pattern matching and parsing very much better than Perl. So we'll steal their ideas, perlize them, and end up surpassing the originals.

      So we'll steal their ideas, perlize them, and end up surpassing the originals.

      Regexes are someplace where this "steal and synthesize" philosophy has worked so well. Perl's syntax has been all encompassing yet revolutionary, so much to the point that the things Perl copied have come around and copied Perl. It's interesting to see Perl as a filter, gluing together cultures - operating systems, individual languages and tools all stealing from Perl, but really stealing from someplace that was outside of their field of vision.

      I think that it should also be noted that Perl has gone from stealing ideas abut regexes to making them up before anybody else does. Regexes as a whole (outside of Perl, as well as in) need a serious cleanup, and this is a place where we've taken all these ideas and synthesized them, and now realized that we need a whole new language for expressing that synthesis. I say "feh" to those who balk at Perl 6 regexes - even if we don't get it right, someone has to try, and Perl has always been about the dirty jobs.

      Cheers,
      Erik

      Light a man a fire, he's warm for a day. Catch a man on fire, and he's warm for the rest of his life. - Terry Pratchet

Re: Total Perl Domination
by Aristotle (Chancellor) on Jun 02, 2002 at 22:09 UTC
    Or maybe that should be, "Larry will take it." Of course he takes things that work, based on the experience of the collective, not just his own. His approach to Perl as something resembling a natural language rather than an orthogonal, abstract mathemtical construct is what led to the success it has seen.

    Makeshifts last the longest.

      His approach to Perl as something resembling a natural language

      For those who haven't read it yet, Natural Language Principles in Perl is very interesting and well worth the read.

Re: Total Perl Domination
by shotgunefx (Parson) on Jun 03, 2002 at 07:38 UTC
    While I think pg is a very smart guy and I like some things about LISP, I think he has tunnel vision. In my experience he is right and so are you if you agree with him.

    That being said I think right now Perl is a "best of breed". If Perl can continue to borrow what works from other languages without getting saddled under it's own weight, I think Perl will thrive IMHO. Otherwise, I think natural selection and hubris will create offspring that do fufill those goals. Personally, I am crazy about Perl but if it changes in ways that are un-Perlish, I'm sure that there will be alternatives that, if not in the name, in spirit will satisfy my Perl needs.

    -Lee

    "To be civilized is to deny one's nature."

      I think perl is an ugly mutt. But if it needs to get timmy out of a well, it'll run fast enough, bark loud enough, and bite hard enough to get him out, whereas the pretty dogs that win awards might to one of those things a little better... but not much, and if it can, well, it'll just have to learn their tricks. We're hardly above stealing from the best.


      We are using here a powerful strategy of synthesis: wishful thinking. -- The Wizard Book

Re: Total Perl Domination
by Beatnik (Parson) on Jun 03, 2002 at 06:32 UTC
    I personally like davorgs approach on how to get perl to dominate the world...

    Greetz
    Beatnik
    ... Quidquid perl dictum sit, altum viditur.
Re: Total Perl Domination
by tjh (Curate) on Jun 03, 2002 at 17:27 UTC
    Perl may be dominating without appearing to.

    It's certainly a primary language for many, doing lots of interesting things.

    Perl is also infrastructure, being used as a glue language. Infrastructure's a wonderful place to be.

Re: Total Perl Domination
by Anonymous Monk on Jun 04, 2002 at 20:22 UTC
    NB: This is all in response to a few of FoxtrotUniform's statements with respect to Lisp. I may be making a mountain out of an anthill, you've been warned.

    I like Perl and I like Lisp, but I like them both for the same reason: they adapt to me and my problem domain. If I want to write structured code I can, if I want to write OO I can, if I want to build an unmaintainable goto hell I can. Lisp (in the form know as Common Lisp) is just as much about solving real problems as Perl is and it's about using the best tools available, be they libs or paradigms, just like Perl. When OO became the Big Thing it was added to Lisp (CLOS). When the next Big Thing comes along (Aspect Oriented Programming? CLP? distributed programming?) you'll find a CPAN module for it and a Lisp package for it. It's the ability to adapt to the programmer and the problem (aka TIMTOWTDI) which Paul Graham likes so much in Lisp.

    Love Perl, make Perl the greatest, fight for Total Perl Domination, but don't think you're special.