9 ms·
Because most programming is done by people trying to do a job and it requires broad tooling support and familiarity, LISP is a language that has neither. LISP,
by thot_experiment 3y ago
Because most programming is done by people trying to do a job and it requires broad tooling support and familiarity, LISP is a language that has neither.
LISP, (similarly to Haskell) requires you to bend your mind and pay an upfront mental cost in order to access it's benefits, which are that everything is equally easy to describe. No construct in LISP feels like it requires you to bend the language in an awful way because LISP is a fantastically generic tool, some things that are common and easy in other languages are more difficult in LISP, but as you get into the weeds building more complex constructs it will never get in your way.
(and since i mentioned it, the benefit of Haskell is that you can make a LOT of statements about your code you know to be true)
- agumonkey 3y agothe upfront mental cost debate is still going, a few people tried teachings lisps as first languages and people didn't struggle i personally cried a few tears when learning java, whereas the weird drscheme class made me all calm and happy programming also blends a few layers into one, and some people are operating at one (line by line modification of data), some want generic infinite freedom[0], you can rapidly see who will enjoy what there [0] one trauma i got during studies is failing an exam because after reviewing ada's manual twice, I couldn't find the page explaining the `object'field` syntax and failed not being able to split a string. i never liked ad-hoc syntax much...
- quantified 3y agoLogo was a great teaching language. If you're not already patterned into C-style programming, it is a great experience.
- thot_experiment 3y agoYeah that's fair, it also came naturally to me but anecdotally I've found a lot of people struggle with it, especially those who came up through a "get shit done first" type python or java pipeline in a traditional institution or bootcamp rather than having a true CS background.
- agumonkey 3y agopython I understand, but get shit done and Java is not a given :p (partly joking, I understand the platform is industry grade)
- WillAdams 3y agoFor my comparative programming class in college, I was the only person who got all the Lisp assignments done on time and correctly (it helped that I was deeply into TeX at the time), so there is definitely a mind-frame to be in, and some sort of hurdle which a fair percentage of folks find difficult. One big problem w/ Lisp is that it is so difficult to distribute programs written using it --- I'd give a lot for the ability to compile to a stand-alone program which could then be distributed.
- massysett 3y agoSBCL has save-lisp-and-die. The binaries are big though. LispWorks will give you smaller binaries, but it costs money.
- mark_l_watson 3y agoWhen you build SBCL from source, enable the compressed heaps option. Then when you create an app with save-lisp-and-die, you get a fairly small app even without having a treeshaker to remove unused code.
- vindarel 3y agoMy web app with dozens of dependencies is ±35MB, using SBCL core compression. So that's heavier than Rust, lighter than Deno, maybe in par with Go when the application grows. It starts up in 0.4s, without compression it does in 0.01s. https://lispcookbook.github.io/cl-cookbook/scripting.html#building-a-smaller-binary-with-sbcls-core-compression https://lispcookbook.github.io/cl-cookbook/scripting.html#bu...
- JohnFen 3y agoI didn't find Lisp to be particularly costly in terms of mental energy to become competent in. Rust, however, was a heavy lift. Perhaps different people are inherently more or less compatible with different languages?
- AnimalMuppet 3y ago> Perhaps different people are inherently more or less compatible with different languages? I think this is true. Peoples' minds work differently; different languages fit different minds better.
- shrimp_emoji 3y agoI feel like Rust is easy; it's just responsible, 21st century C code with more data structures in the standard library. Functional languages are like being forced to fry an egg while on LSD. Eventually, you get the hang of it, and you start seeing Spinoza's God in the form constants, but holy shit was it difficult! It's a totally disorienting and mind-bending challenge of re-learning how to do the most basic things!
- thot_experiment 3y agoI find Rust so onerous, I gave it a fair shot, and I see it's merits but I just don't find myself in situations where Rust feels like the right fit very often. Where the cost of it feels worth the benefit. Writing C is and always has been an absolute joy for me and almost everything I'd want to do in Rust I'd rather tackle in C with a big smile on my face.
- deleted 3y ago[deleted]
- PaulDavisThe1st 3y agoWhen I learned emacs lisp back in the mid-80s, I didn't find any requirement to bend my mind or pay any upfront cost. It was a little different from C (and BASIC), certainly, but once I grasped a few basic concepts, it felt extremely elegant and very well suited to the task(s) to which I was putting it. More recently, I've felt that way about Python, and about a few chunks of my favorite blobs of self-written C++.
- taeric 3y agoThis is only true in terms of "free" options. There were (and are?) decent paid options that had quite good tooling. In the free software realm, though, it was lacking. And... this is kind of the point of the post. The python community doesn't just push to advance only the language, they advance the use of the language in the free software world. What is the closest that the common lisp world has?
- munchler 3y agoI agree with you about the upfront costs. As a functional programming fan (F# in particular), I can’t deny that it sometimes feels like puzzle solving. Fun, but not easy at first. On the other hand, you can quickly throw together some crappy Python code to do the same thing, but you end up paying 10x the cost over the long run in debugging and rewriting. So my advice for people who care about the code they write is to pay the upfront cost to do it well. The good news is that the learning curve does get less steep eventually, and at that point you feel like a goddamn ninja.
- doug_durham 3y agoPython != Crappy code. Lisp != good code. You can write crappy code in any language. My experience is that it is much less expensive to maintain Python in a team environment in the long run. People aren't tempted to create their own personal "domain specific languages" in Python. Lisp kind of encourages that.
- munchler 3y agoI'm not saying Python is always crappy. It's just easier to create crappy code in Python, due to dynamic typing, rampant side effects, null values, OO madness, etc. If your team has the discipline not to do that, great.
- erik_seaberg 3y ago> dynamic typing, rampant side effects, null values I’m afraid these are also problems in Common Lisp.
- munchler 3y agoYeah, I’m not a Lisp fan myself. I was comparing Python to functional languages, like Haskell or F#.
- vindarel 3y agomuch, much, much less than Python. CL compilers (looking at SBCL) get you many type checks, at compile time, instantly (you compile the function at point), or you can send computation to compile time yourself, and the OO is different, etc.
- linguae 3y agoRust requires people to learn how to adapt to Rust’s borrow checker, which can be challenging for programmers coming from other languages, yet this hasn’t stopped Rust’s rapid adoption in systems programming. In fact, Rust’s safety features are Rust’s selling point. Of course, it helps that Rust came from Mozilla and that it’s used in Firefox. Other than Grammarly and some internal Google products, I don’t know any modern-day high-profile projects written in Common Lisp. What would help bolster Common Lisp would be a high-profile project that would be much more difficult to implement in other languages.
- tcmart14 3y agoI'm not sure if Rust is a good comparison though. Rust is a lot closer to C, it is a language influenced by C, and current popular programming languages tend to also be influenced by C. So while there is a lot different with Rust, a lot of knowledge from, lets say, a C developer can carry over. Say your a C developer, or C++ developer and I am a Rust developer trying to sell you on Rust. You have to learn a new language. No way around it. Even though people may have problems with this statement, at a high level it is close enough, I can sell you on Rust probably by saying, 'it C/C++ with better (subjective) or more modern features and extra constraints (think borrow checker) to guarantee memory safety.' I would not be able to make that same argument with LISP. The next question could be why this could be true, or more importantly, why are so many people using C-like languages. I'd probably place it on portability and UNIX from when C emerged. And LISP machines died. In other words, I don't think it would be appropriate to try to draw a comparison between the two with the two of them in a vacuum. If LISP machines survived and were popular today, we could see Rust today having the same popularity of LISP today.
- shrimp_emoji 3y agoI'd argue Lisps are worse today. They encourage a thing that's generally discouraged in C: macro programming and typedefs. You're coding in Lisp, but you're actually coding in your own dialect of Lisp, eventually, with lots of idiosyncratic code that's difficult to reason about. That doesn't scale well in collaborative environments, where many people are touching a vast codebase (which I don't think was really a thing back in the '70s). That's when you want the uniformity and clarity of static type declarations and C++'s <algorithm> header functions. With Rust, you're just adding modernity and safety on top of that. Great! Lisp is crazy lone wizard shit.