6 ms·
Judging by the title, I was expecting to read about the advantages of dynamically-typed functional programming languages like Scheme and Clojure over statically
by linguae 4y ago
Judging by the title, I was expecting to read about the advantages of dynamically-typed functional programming languages like Scheme and Clojure over statically-typed functional languages like Standard ML and Haskell. It seems to me that large segments of the functional programming community love static typing, and the research community has done (and continues to do) a lot of work applying type theory to the design of programming languages. However, there are still many advocates of dynamically-typed functional programming languages, generally from the Lisp family.
I don’t think of functional programming when I use Python, even though it’s possible to program in a functional style. I’m also unaware of any Python development environments that offer Smalltalk or Common Lisp levels of interactivity, though this is less of a criticism of the language and more of a matter of tooling.
- falcolas 4y agoYup, I would love to see a bit more love for Lisp style languages. They're incredibly powerful and it's a shame they're relegated to the fringes of professional programming.
- bslatkin 4y ago100% agree with both of these comments. I'd love to see a resurgence of interest in this area.
- kaveh808 4y agoWhat we need are examples of Lisp-style languages leading to big wins. Clojure did that to some extent, but unfortunately in the Common Lisp world successful commercial or technical projects are few and far between. Our best bet is probably making interesting advances in the open source field, until something takes off, which is largely a factor of luck.
- AtlasBarfed 4y agoMy biggest critique of the Lisp crowd. I mean, look at what gets made in Go, Go is barely 10 years old. Go is a worse Java, not as egregious an example of "worse is better" as Javascript, but still... a backwards step outside of its threading model. For a language with such raw purported power, it is lacking in databases, operating systems, management software, games, etc. AI used to be it's killer app, but it seems the latest AI revolution isn't functional programming based. One of the issues is that Lisp makes an individual programmer very powerful. The Paul Graham Lisp essay that gets brought up CONSTANTLY is an example of that. He built an entire ecommerce site by himself, but it was incomprehensible to the people that bought it from him and they rewrote it in some more pedestrian language. Lisp lends itself to ivory tower constructions of abstractions that are ridiculously powerful to the one person that wrote them: the programmer, but the rest of the world will just end up reinventing their own wheels. It takes a higher IQ that the person that wrote code to understand it about as well as the original author. But if LISP people are all high IQ, then the people capable of reading other Lisp code is of such high IQ that it falls apart. I look at people like the Jepsen guy who uses clojure to test about the most difficult thing to test in the world: concurrent distributed systems, and other ultrasmart people and understand that FP is powerful. It also has advantages in true heavy concurrent programming, although FP seems to be squandering this. I think it goes back to the operating environment. If Lisp machines were the killer apps they seemed, the lisp people need a novel OS + GUI + IDE + REPL computing environment to visually sell themselves, kind of like what smalltalk did back in the day.
- kaveh808 4y agoI can't express how much I agree with everything you say. Often, I've wondered if Lisp attracts, due to it power and flexibility, a certain type of "lone hacker" who builds amazing but unscalable ivory towers of abstractions. One example of this, often mentioned as a success, but which I consider a failure if you take the longer view, is Naughty Dog using Lisp to develop their game engine compiler and such. This was so specialized that their new owner Sony balked and made them use standard tools. Alternately, you could say that Lisp does exactly what it was meant to do: enable single and small teams of developers to engage in very productive exploratory programming. Carl Hewitt once told me that back in the heyday of Lisp (the 80's) they believed general AI would be solved by small teams of developers. Current AI efforts are the total opposite. In this alternate interpretation, perhaps Common Lisp is simply not suited for large scale development or collaborations. Either due to language features or personality types. So maybe prototype in CL, then hire a few dozen Java devs to go to market. I'm not trying to be down on CL. I love it and have been developing my open-source 3D system in it. But man, I can't believe there isn't a single cross-platform GUI toolkit for CL! Or a decent open-source IDE. I guess we can do our small part and hope for the best.
- falcolas 4y ago> What we need are examples of Lisp-style languages leading to big wins. How about JPL, used to control Mars probes and landers using ANSI lisp? The most successful and influential CS course to date? This website? Lisp successes are out there. But it is harder to learn and understand than imperative languages, so it will never win out over Java and C# and Go and their ilk. Due to the demand for developers outstripping the supply, we need languages that are safe for developers with wildly varying levels of skill to use - that limit the blast radius of their efforts in the worst case. One of the early design goals of Golang was exactly this - to make it simple for developers of varying skill to work together on code. This isn't a knock on mediocre developers individually, but it is an unfortunate side effect of our need for so many of them.
- kaveh808 4y agoThe JPL Lisp story is a fun story, and cool application of Lisp over 20 years ago. But it is by no means a Lisp success story. There is a reason no space probe since then has been controlled using Lisp (as far as I know). Your links didn't come through, so I don't know what web site you are referring to. Maybe Orbitz? That was one success and still continues to be developed in CL by Google AFAIK. One outlier data point perhaps. As for the 6.001 course at MIT, I took that course back in the day, and was saddened to hear it now is taught in Python. You are correct that we need languages which have a ready supply of developers. In a commercial setting that fact alone will trump any language features or technology advantage. Java was meant to be the new Cobol and works hard at limiting programmer flexibility so they don't shoot themselves in the foot.
- ovis 4y ago"This website" referred to Hacker News itself, which is written in a Lisp (Arc).
- NtochkaNzvanova 4y agoI don't think there's anything remarkable about this website that could be considered a "big win" for Lisp. It's a totally run-of-the-mill dynamic web app that could have been developed more quickly in any web framework such as Rails or Django. In fact, the hacky way it was implemented in Lisp had some clear downsides. In the early days (I'm probably going to mess up the details but hopefully the gist will come through) there was a notorious failure mode due to the way entities such as stories and comments were stored in memory using closures. These closures obviously had to be cleaned out periodically, and so if you stayed on a page too long and then clicked a link on the page, it would be invalid. You'd have to go back and refresh the page and click the link again. I don't think it's out of bounds to say this website is basically a rehash of the hacks pg came up with in the mid 90s to implement web apps in Lisp for Viaweb. The fact that he got rich off those hacks may have been a selling point for Lisp 20 years ago when he wrote Beating the Averages, but the world has moved on.
- grumpyprole 4y agoLisp evolved into ML and Haskell and these have influenced professional programming enormously over the last few decades. Or are you advocating we ditch all progress and go back to Lisp? Have you tried an ML such as OCaml? It has built-in cons lists, convenient symbol manipulation and macros.
- bslatkin 4y agoWhy do you think so many Lisp fans (e.g., Norvig) went on to use Python instead of those ML alternatives?
- grumpyprole 4y agoNorvig is a teacher and author who wants to reach the widest audience possible. So in his case, it was either Java or Python.
- charlieflowers 4y agoNorvig wrote an article or post where he deemed Python to be “an acceptable lisp” (or something like that, I may not have it exactly right).
- grumpyprole 4y agoHardly a ringing endorsement! Python is certainly succinct and expressive like Lisp (when his alternative is Java). ML was designed to be a better Lisp.
- _19qg 4y agoML wasn't designed as a better Lisp. It was designed as a 'better' (and statically typed) functional programming language for writing proofs in a theorem prover. The theorem prover and then also the first ML version was written in Lisp. That was the motivation for the first version of ML.
- AtlasBarfed 4y agoIt's because LISP has a "great filter" for high IQs. Programming has many such filters: Understanding pointers / references separates the python/script kiddies from the "real" C programmers and understanding von neumann architecture. Recursion separates the programming-is-a-job with the beginnings of algorithmic understanding of computation. LISP is heavy recursion, non-infix notation, lambda calculus, and other concepts that are simply too much for a garden variety programmer.